test_lambertSolverConvergence

Check root convergence and invalid-output handling independently of the starters.

test_lambertSolverConvergence.battin_time(x, lam)[source]

Evaluate smooth zero-revolution flight time with SciPy’s hypergeometric function.

test_lambertSolverConvergence.test_alignment_rejection_and_recovery(method, direction, revolutions, angle_degrees)[source]

Reject only the aligned update and recover without resetting the module.

Start with an aligned input, then alternate aligned and valid geometries on the same message and module. Rejected updates must clear both solution and performance slots. Each recovered result must match a fresh module, including when the valid endpoint and flight time change.

test_lambertSolverConvergence.test_alignment_threshold_recovery(method, direction)[source]

Reevaluate the same input after changing the alignment threshold without a reset.

test_lambertSolverConvergence.test_converged_solution_passes_validator(method, direction, r2_xy, transfer_time)[source]

Accept converged solutions with the validator’s default convergence checks.

test_lambertSolverConvergence.test_independent_branch_validity(method, direction)[source]

Preserve a resolved branch when the other exceeds the evaluator’s resolution.

The long-time right root lies close to x = 1, where small root errors produce large flight-time errors. If resolved, it must meet the independent residual check. A following normal request must resolve both roots.

test_lambertSolverConvergence.test_numerical_failure_and_recovery(method, direction, revolutions)[source]

Zero failed solutions, then recover without reusing their roots or validity.

test_lambertSolverConvergence.test_parabolic_roundoff_and_nearby_times(method, direction, angle_degrees, time_offset)[source]

Resolve exact and nearby parabolic transfers without a flat flight-time interval.

test_lambertSolverConvergence.test_roots_converge_near_minimum(method, direction, lam, revolutions, excess_time)[source]

Resolve both roots just above the minimum using independent branch brackets.

test_lambertSolverConvergence.test_safeguards_preserve_fast_convergence(method, direction, r2_xy, transfer_time, reference_x)[source]

Keep starters, fallback recovery, and tiny corrections within the validator’s iteration budget.

test_lambertSolverConvergence.test_short_transfer_convergence(method, direction, lam, fraction)[source]

Propagate short transfers that previously exhausted Izzo’s eight iterations.

test_lambertSolverConvergence.test_small_step_alone_is_not_convergence(method, lam, time_offset)[source]

Require an independent flight-time residual even when the final step is small.

The former near-parabolic evaluator had a flat interval. The smooth evaluator must resolve this request rather than treating a small step alone as success.