fluidsim.solvers.ns2d.state

State for the NS2D solver (fluidsim.solvers.ns2d.state)

class fluidsim.solvers.ns2d.state.StateNS2D(sim, oper=None)[source]

Bases: StatePseudoSpectral

State for the solver ns2d.

Contains the variables corresponding to the state and handles the access to other fields.

Inheritance diagram of StateNS2D
static _complete_info_solver(info_solver)[source]

Complete the info_solver container (static method).

compute(key, SAVE_IN_DICT=True, RAISE_ERROR=True)[source]

Compute and return a variable

statephys_from_statespect()[source]

Compute state_phys from statespect.

statespect_from_statephys()[source]

Compute state_spect from state_phys.

init_from_rotfft(rot_fft)[source]

Initialize the state from the variable rot_fft.

init_from_uxfft(ux_fft)[source]

Initialize the state from the variable ux_fft

init_from_uyfft(uy_fft)[source]

Initialize the state from the variable uy_fft

init_statespect_from(**kwargs)[source]

Initializes state_spect using arrays provided as keyword arguments.

init_statephys_from(**kwargs)[source]

Initialize state_phys from arrays.

Parameters:
**kwargs{key: array, …}

keys and arrays used for the initialization. The other keys are set to zero.

Examples

kwargs = {'a': Fa}
init_statespect_from(**kwargs)

init_statespect_from(ux=ux, uy=uy, eta=eta)

Classes

StateNS2D(sim[, oper])

State for the solver ns2d.