Skip to content

Analysis B1 from the AIRBRAKE exit: stated wing limits, energy-against-distance front, gap to C - #8

Merged
harshabose merged 2 commits into
masterfrom
feat/b1-airbrake-exit
Oct 28, 2026
Merged

harshabose merged 2 commits into
masterfrom
feat/b1-airbrake-exit

Conversation

@harshabose

Copy link
Copy Markdown
Owner

Implements docs/B1_fix_spec.md: B1 now starts at the AIRBRAKE exit like D and C, and answers one question: the least bus energy as a function of distance, under a stated wing limit.

Stacked PR: the base is feat/c-ardupilot-z-loop (PR #7), so the diff shows only this change. Stack: #2 A, #3 D, #4 Q2, #5 E, #6 D addenda, #7 C, this. Retarget to master once the stack merges. No other branch or PR was touched.

Commits

  1. Docs: B1_fix_spec.md.
  2. B1 (spec 3-10): collocation.py: make_problem_exit, CollocationOptions.alpha_max, with_options keeps the entry state (it used to rebuild a cruise problem), schedule_summary, bound_check_c, compare through restricted.evaluate_c; bound_check stays as legacy. task_b1 rewritten (per variant: the front over eps_x_m at the 1 m band, the band sweep, the gap to C, the sensitivities). Tables B1_front, B1_gap, B1_sens, B1_schedule. B1Cfg is list-based; an old scalar eps_x_m is rejected with a message. B2 keeps its level-cruise start through _b1_problem_cruise. Configs and READMEs.

Checked against the spec (S-01, real configs)

  • 1: cruise entry 10 m band: 6.083 kJ, 83.4 m, 6.09 s, 10.00 m. B2's cruise-start solve: identical arrays and energy (6083.479 J) on the C tip and on this branch.
  • 2: exit entry, 10 m band, attached: 6.265 kJ, 95.9 m, 7.41 s, 9.60 m.
  • 3: attached, 1 m band, eps_x 300: 8.922 kJ / 72.7 m / 6.69 s (end band 0.5, carry); 8.918 / 72.8 / 6.69 (1.76, carry); 8.921 / 72.6 / 6.68 (0.5, idle).
  • 4: attached at eps_x 40 and 57: not converged from three starts; rows kept with energy blank.
  • 5: c_envelope at eps_x 40: 8.226 kJ, 38.7 m, 3.84 s (end band 0.5: 8.220); with the 34.4 deg pitch limit 7.748 kJ / 39.6 m / 3.74 s at eps_x 40 and 7.605 / 49.5 / 4.51 at eps_x 300.
  • 6: C at the reduced-search optimum: 12.68 kJ, 0.52 m, 40.1 m (as in the spec). B1 c_envelope at that excursion and distance: 8.34 kJ, 34% less.
  • 7: replayed peak wing angle: attached 13.4 deg (limit 13.6); c_envelope 30.47 deg (limit 30.5).
  • 8: rotors come in at about 2.3 s on S-01 attached, at idle until then.
  • 9-11: S-02 has below_vs true; bound_check and compare still run; the old scalar eps_x_m is rejected.
  • 175 existing tests pass; ruff, mypy and lint-imports clean. No tolerance exceeded.
  • A reduced end-to-end run.py --only B1 (S-01 and S-02, eps_x 40 and 300) writes the four tables and the report section.

Not run

The full 6-scenario, about 100-solve block (2 to 3 hours on one core) was not run; only the reduced study above. No new tests (the spec leaves them to the owner).

Notes for review

  • B1.gap_c is an addition. The B1 tasks are independent processes and cannot read C's optimum, so the gap evaluates C at B1.gap_c (paste the four values from C_params), or at the register values with q = 2 if it is null. The table says which.
  • The attached gap rows do not converge at C's 40 m (attached cannot go much below 73 m at a 1 m band). That is a solver result, not proven infeasibility.
  • schedule_summary takes (prob, check, gate), not just the replay, because it needs the dead zone and the stall speed. t_rotor_on is the first time after the throttle has rested at its minimum that it exceeds idle + 0.05 (the spec does not define idle for a carry start). An extra column alpha_w_peak_above_vs_deg carries check 7's gate.
  • The rotor-start flip and the 0.5 m/s end band run on the first variant (attached); the 34.4 deg pitch limit on the first absolute-angle variant (c_envelope).
  • Eleven exact-Hessian solves at once ran out of memory (std::bad_alloc) on a 24-core workstation; limit parallel.max_workers if memory is short.
  • The old Pareto figure no longer fits a fixed 1 m band and is not produced; B1_schedule holds the replay series for a plot.
  • B1 is clairvoyant, open loop and has no rotor lag (C has rotor_lag_s); the end band bounds climb as well as sink (C bounds sink only). VRS is only reported (B-3). B2 is not on this entry yet, so B-9 stays open.
  • The frozen tests/data/placeholder_configs/study.yaml B1 block follows the new format.

🤖 Generated with Claude Code

harshabose and others added 2 commits October 27, 2026 17:22
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018QKS75nmeebgQ4roJCLSfM
…y-against-distance front, gap to C (B1 spec 3-10)

collocation.py: make_problem_exit (AIRBRAKE-exit entry state), CollocationOptions.alpha_max,
with_options keeps the entry state (it rebuilt a cruise problem), schedule_summary, bound_check_c
and compare through restricted.evaluate_c. bound_check stays as legacy. task_b1 rewritten:
per variant (attached, c_envelope) the front over eps_x_m at the 1 m band, the band sweep, the gap
to C and the sensitivities; B1_front, B1_gap, B1_sens, B1_schedule. B2 keeps its level-cruise start
through _b1_problem_cruise (its start solve is bit-identical). B1Cfg is a list-based block and an
old scalar eps_x_m is rejected with a message; the frozen placeholder study.yaml follows.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018QKS75nmeebgQ4roJCLSfM
@harshabose harshabose mentioned this pull request Oct 28, 2026
@harshabose
harshabose changed the base branch from feat/c-ardupilot-z-loop to master October 28, 2026 22:37
@harshabose
harshabose merged commit b49ef81 into master Oct 28, 2026
4 checks passed
@harshabose
harshabose deleted the feat/b1-airbrake-exit branch October 28, 2026 22:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant