fluidsim.base.forcing.kolmogorov
Kolmogorov flow (fluidsim.base.forcing.kolmogorov
)
- class fluidsim.base.forcing.kolmogorov.KolmogorovFlow(sim)[source]
Bases:
_KolmogorovFlowBase
,SpecificForcingPseudoSpectralSimple
Kolmogorov flow forcing
This forcing can be used with solvers based on ns2d or ns3d.
By default, the flow is forced along the x axis with a gradient along the z axis for 3D solvers and the y axis for the 2D solvers.
Examples
from fluidsim.solvers.ns3d.solver import Simul as SimulNotExtended from fluidsim.base.forcing.kolmogorov import extend_simul_class, KolmogorovFlow Simul = extend_simul_class(SimulNotExtended, KolmogorovFlow) params = Simul.create_default_params() params.forcing.enable = True params.forcing.type = "kolmogorov_flow"
The parameters can be modified as follow:
params.forcing.kolmo.ik = 3 params.forcing.kolmo.amplitude = 2.0 params.forcing.key_forced = "ux_fft" params.forcing.kolmo.letter_gradient = "y"
- class fluidsim.base.forcing.kolmogorov.KolmogorovFlowNormalized(sim)[source]
Bases:
_KolmogorovFlowBase
,NormalizedForcing
Kolmogorov flow forcing with constant energy injection rate
This forcing can be used with solvers based on ns2d or ns3d.
By default, the flow is forced along the x axis with a gradient along the z axis for 3D solvers and the y axis for the 2D solvers.
Examples
from fluidsim.solvers.ns3d.solver import Simul as SimulNotExtended from fluidsim.base.forcing.kolmogorov import extend_simul_class, KolmogorovFlowNormalized Simul = extend_simul_class(SimulNotExtended, KolmogorovFlowNormalized) params = Simul.create_default_params() params.forcing.enable = True params.forcing.type = "kolmogorov_flow_normalized"
The parameters can be modified as follow:
params.forcing.kolmo.ik = 3 params.forcing.forcing_rate = 10.0
Note that
params.forcing.kolmo.amplitude
has no effect for this forcing type.
Classes
|
Kolmogorov flow forcing |
Kolmogorov flow forcing with constant energy injection rate |