turbo_moc.jax_rotor.isentrope module#

JAX lookups along the relative isentrope, identical to FluidManager’s SciPy splines.

JaxIsentrope.from_manager takes the table nodes and the piecewise-cubic coefficients of the SciPy CubicSpline objects that FluidManager._build_nu_table already built, and evaluates them in JAX (same interval search, same Horner form, same clipping). Values therefore agree with the NumPy path to round-off, and every lookup is differentiable in its argument.

The table itself depends on the inlet state (P0_rel, T0_rel); derivatives with respect to the inlet state are not provided here (phase 1b of the plan): the table is a constant of the traced functions.

class turbo_moc.jax_rotor.isentrope.JaxIsentrope(nu_of_V_poly: PPoly, a_of_V_poly: PPoly, rho_of_V_poly: PPoly, V_of_nu_poly: PPoly, V_min: Array, V_max: Array, nu_max: Array, a_star: Array)[source]#

Bases: object

nu(V), a(V), rho(V), V(nu) on the relative isentrope, plus the critical speed a*.

Methods

from_manager(manager)

From a built thermo_characteristics.FluidManager (cached by get_fluid_manager).

V_of_M

V_of_nu

a_of_V

mach_of_V

nu_of_V

rho_of_V

tree_flatten

tree_unflatten

V_max: Array#
V_min: Array#
V_of_M(M)[source]#
V_of_nu(nu)[source]#
V_of_nu_poly: PPoly#
a_of_V(V)[source]#
a_of_V_poly: PPoly#
a_star: Array#
classmethod from_manager(manager)[source]#

From a built thermo_characteristics.FluidManager (cached by get_fluid_manager).

mach_of_V(V)[source]#
nu_max: Array#
nu_of_V(V)[source]#
nu_of_V_poly: PPoly#
rho_of_V(V)[source]#
rho_of_V_poly: PPoly#
tree_flatten()[source]#
classmethod tree_unflatten(aux, children)[source]#
class turbo_moc.jax_rotor.isentrope.PPoly(x: Array, c: Array)[source]#

Bases: object

Piecewise cubic of scipy.interpolate.CubicSpline (breakpoints x, coefficients c of shape (4, n-1)).

Methods

__call__(value)

Call self as a function.

from_scipy

tree_flatten

tree_unflatten

c: Array#
classmethod from_scipy(spline)[source]#
tree_flatten()[source]#
classmethod tree_unflatten(aux, children)[source]#
x: Array#
turbo_moc.jax_rotor.isentrope.check_range(iso, M)[source]#

The reference raises outside the table; JAX cannot raise inside a trace, so callers check concrete inputs.

turbo_moc.jax_rotor.isentrope.to_numpy_tree(tree)[source]#