-
Notifications
You must be signed in to change notification settings - Fork 236
Ensure the substeps
we pass to SplitExplicitFreeSurface
are the actual used substeps
#4348
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
SplitExplicitFreeSurface
are the actual substepssubsteps
we pass to SplitExplicitFreeSurface
are the actual used substeps
...Models/HydrostaticFreeSurfaceModels/SplitExplicitFreeSurfaces/split_explicit_free_surface.jl
Show resolved
Hide resolved
I tried to read to the code to figure out what's going on but I didn't get it quickly. Isn't another option to change the meaning of what the user passes to |
...Models/HydrostaticFreeSurfaceModels/SplitExplicitFreeSurfaces/split_explicit_free_surface.jl
Outdated
Show resolved
Hide resolved
Can a fix be to take the user input for |
in
main
this is not the case because the number of substeps is adapted to the averaging function by assuming that we cut the interval2Δt
in asubstep
number of substeps.This PR calculates the correct ending fractional time based on the averaging function. Typically this corresponds to the time at which the averaging function reaches zero typically between 1 and 2 (times the baroclinic timesteps).
Other kernels might have a more complicated ending time (for example a constant function never reaches zero) for which users have to specify it themselves. For this purpose, this PR adds an
AveragingKernel
that stores also the ending fractional time and can be passed to theSplitExplicitFreeSurface
constructor.Finally the weights calculation cuts
last_fractional_time * Δt
in asubstep
number of substeps.