ProjectTorreyPines / IMAS.jl

Physics, engineering, math and plotting on top of IMASDD.jl
https://projecttorreypines.github.io/IMAS.jl/dev
Apache License 2.0
1 stars 0 forks source link

Add function for calculating r_outboard and r_inboard for equilibrium profiles_1d #185

Closed eldond closed 1 month ago

eldond commented 1 month ago
eldond commented 1 month ago

@orso82 is this the right way to set up this kind of thing?

eldond commented 1 month ago

@eldond the main limitation of this function is that it operates on the closest row to zmaxis. Furthermore, IMAS.flux_surfaces(eqt) will do this for you (and a lot more) more accurately.

Try this:

filename = joinpath(dirname(dirname(pathof(IMAS.IMASdd))), "sample", "D3D_eq_ods.json")
dd = IMAS.json2imas(filename; verbose = false)
eqt = dd.equilibrium.time_slice[]
IMAS.flux_surfaces(eqt)
eqt.profiles_1d.r_outboard
eqt.profiles_1d. r_inboard

I remember something failing due to lack of r_outboard, but okay, I see that I can generate this field as you say.