solprop.translate.validation#

What translation refuses, and what it warns about, before a problem is returned.

The policy solprop.translate.assembly.assemble() applies to its arguments and to the problem it assembled: the refusals of a route’s settings (a wall off the capillary route, operator settings without a spatial grid, a save plane on an index jump, a frame that removes beta_0 beside the third harmonic, a TDSE response off its route, the general modal route’s legacy knobs), the split collar’s fixed-schedule limit and the coupled flow’s advisory step (validate_coupled_flow()). The kernel contract’s own checks are solprop.translate.problem.PropagationProblem.validate() and solprop.translate.problem.validate_run(), which also refuses dense observation where its interpolant is not the run’s field, so a request changed after assembly is refused there too.

Module Attributes

DEFAULT_FLOW_CONDITION_LIMIT

Largest inverse conditioning a general modal coupled flow is admitted at.

MOVING_FLOW_CERTIFICATE

The certificate_id a moving solid guide's coupled flow carries.

TAPER_FLOW_CERTIFICATE

The certificate_id of a multimode capillary taper's coupling without a wall.

Functions

validate_coupled_flow(problem, stepper)

Warn when a run's declared steps exceed its coupled flow's advisory limit.

solprop.translate.validation.DEFAULT_FLOW_CONDITION_LIMIT: float = 10000.0#

Largest inverse conditioning a general modal coupled flow is admitted at.

Dimensionless, and the same number solprop.modes.capillary.CoherentWall.condition_limit defaults to, because it bounds the same thing: how far the interaction picture’s inverse action may amplify the nonlinear source over one step. A general guide’s block is far below it – a unitary rotation of a lossless split block has an exactly Hermitian-free part and reads 1.0 – so this is a guard and not a tuning knob, and there is no declaration object on this route to put it on.

solprop.translate.validation.MOVING_FLOW_CERTIFICATE: str = 'general-moving-frozen-residual'#

The certificate_id a moving solid guide’s coupled flow carries.

solprop.translate.validation.TAPER_FLOW_CERTIFICATE: str = 'taper-frozen-residual'#

The certificate_id of a multimode capillary taper’s coupling without a wall.

solprop.translate.validation.validate_coupled_flow(problem, stepper)[source]#

Warn when a run’s declared steps exceed its coupled flow’s advisory limit.

A validate diagnostic in the manner of the in-stage absorber’s stable_step warning: it names the term, the section, the frequency, the residual norm K, the conditioning factor and the limit, and it does not change the caller’s tolerances or schedule. The limit is 0.9/(K ||U_s|| ||U_s^-1||) (solprop.translate.coupled.advisory_step()), and the warning says plainly that it is advisory: a wall difference can have positive real eigenvalues – local growth relative to the frozen attenuating frame – and no positive step makes that residual alone contractive, so neither its spectral radius nor a test of the stability polynomial is a complete rule.

The three steps a run can declare are checked: dz_init, dz_max and, when a fixed schedule is replayed, its own largest step, which the controller can neither shorten nor reject.

Parameters:
problemPropagationProblem

The assembled contract. A problem carrying no coupled flow, or one whose residual is identically zero, has nothing to warn about and is returned from in silence.

stepperStepperSettings

The run’s stepper section, whose declared steps are checked.

Warns:
solprop.exceptions.SolpropWarning

Naming the step that exceeds the limit, with the term, the section, the frequency, K, the conditioning factor and the limit.

Examples

>>> from solprop.translate.validation import validate_coupled_flow
>>> validate_coupled_flow.__name__
'validate_coupled_flow'