add a :t- property to Lagrangian particles? #2503
-
Hello, in relation to a discussion I started earlier, about forcing a tracer at a specific time in the model (see here, I wonder if one could add particles to a model at a specific time, and how to code that? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 4 replies
-
The so you should be able to add particles at any time. You can run a model for some time:
and then continue:
You can also use I'm not immediately familiar with the syntax to do this because I don't use Lagrangian particles --- it'd be great if you post what you figure out to this discussion! |
Beta Was this translation helpful? Give feedback.
-
Thanks Greg, I am going to give it a try. will have some learning to do as I haven't yet stopped and resumed a model before...
doesn't seem to work; the stop_time has not been updated |
Beta Was this translation helpful? Give feedback.
The
particles
areStructArray
:Oceananigans.jl/src/LagrangianParticleTracking/LagrangianParticleTracking.jl
Line 49 in 3322f18
so you should be able to add particles at any time. You can run a model for some time:
and then continue:
You can also use
Callback
to add particles, I think.I'm not immediately familiar with the syntax to do this because I don't use Lagrangian particles --- it'd be great if you post what you figure out to this discussion!