Drive every forced incoming wave and store the perturbation fields.
Solves one single-node excitation per (terminal, wave family) via :func:excite_perturbation – sharing a single factorization of the prescribed operator across them – and stacks the resulting fields into a :class:PerturbationResponse, from which transfer/scattering matrices are extracted without re-solving.
Parameters
Name
Type
Description
Default
prob
CompiledProblem or Solution
The compiled flow network. Pass a solved :class:nefes.Solution to have its problem and mean state supplied for you (then omit x_bar).
required
x_bar
ndarray
Converged mean-flow state vector. Omit when prob is a Solution.
required
freqs
array_like
Frequencies (Hz) to solve at.
required
forcing
tuple of int
The pair of terminal node ids to force (default: every open terminal).
None
excite
sequence of str
Wave families to drive with a unit incoming amplitude. "acoustic" is mandatory; add "entropy" for the 3 x 3 acoustic+entropy response, and on a reacting network add any transported scalar by its label (from prob.scalar_names) to drive its convected composition wave – the matrices then grow to the full n_solve x n_solve block. Families not listed stay prescribed but pinned to zero, so the boundaries never float. Default ("acoustic",) – the clean, well-conditioned acoustic response with the incoming entropy (and any scalars) pinned out.
('acoustic',)
freeze
sequence of int or str
Terminals whose physical boundary condition is kept during the measurement instead of being neutralized into a port. Each entry is a node id (int) or an element name (str) and must name an existing 1-port terminal. A frozen terminal stays closed by its own BC – a wall reflects (R = +1), an explicit PerturbationBC applies its closure – so an interior branch terminated by a wall (a closed stub / side resonator) is folded into the operator and the network reduces to its genuine open ports (a branched two-port then reads out directly via :meth:~PerturbationResponse.acoustic_scattering_matrix, with no multiport condensation). Frozen terminals are not driven and are dropped from the measured terminal set. Default () neutralizes every terminal (the boundary-independent multiport). Caveat: a lossless frozen termination reintroduces real-axis resonances, so the response is ill-conditioned at those frequencies (add a small wall loss, or step off the exact pole).
()
eps
float
Operator-assembly regularizers forwarded to build_acoustic_blocks.
None
eps_fb
float
Operator-assembly regularizers forwarded to build_acoustic_blocks.
None
u_floor
float
Operator-assembly regularizers forwarded to build_acoustic_blocks.
None
Returns
Name
Type
Description
PerturbationResponse
The stacked independent perturbation fields.
Raises
Name
Type
Description
ValueError
If excite omits "acoustic"/names an unknown family, entropy is requested with no inflow terminal to seat it, or a freeze entry names a missing node or a non-terminal node.