Mechanism to extend a Simul class with just a simple class

fluidsim.extend_simul.extend_simul_class(Simul, extenders)[source]

Extend a Simul class with “Simul extenders”.

“Simul extenders” are classes deriving from fluidsim.extend_simul.SimulExtender.

class fluidsim.extend_simul.SimulExtender[source]

Bases: object

Abstract class to define a “Simul extender”

Simul extenders are classes that can extend a Simul class to change its behavior for some simulations.

This class is meant to be subclassed. The child class has to contain one class attribute _module_name and two class methods get_modif_info_solver and complete_params_with_default. An example can be found in the module fluidsim.extend_simul.spatial_means_regions_milestone.

classmethod get_modif_info_solver()[source]

Create a function to modify info_solver.

Note that this function is called when the object info_solver has not yet been created (and cannot yet be modified)! This is why one needs to create a function that will be called later to modify info_solver.

classmethod complete_params_with_default(params)[source]

Should complete the simul parameters


Spatial means regions