Skip to content

DOC: document grains_bonded and simplify its docstrings - #1223

Merged
Gui-FernandesBR merged 4 commits into
developfrom
doc/grains-bonded
Nov 21, 2026
Merged

Gui-FernandesBR merged 4 commits into
developfrom
doc/grains-bonded

Conversation

@Gui-FernandesBR

Copy link
Copy Markdown
Member

Related to #1209
Related to #1138

Covers the #1138 docs part of the Motors item of the v1.14.0 checklist, as asked in #1194. The grains_bonded docstrings drop the internal and "BATES-style" wording and say grain_separation is a solid spacer, and solidmotor.rst gets a short "Unbonded Grains" section with an example. On the Calisto of the first simulation the static margin drops by at most 0.0298 calibers during the burn, which the page states as about 0.03.

🤖 Generated with Claude Code

https://claude.ai/code/session_01XDW575d9C9zpS7Z1v2KXVq

@Gui-FernandesBR
Gui-FernandesBR requested a review from a team as a code owner November 17, 2026 20:58
@codecov

codecov Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.67%. Comparing base (c7859c3) to head (915932f).
⚠️ Report is 5 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #1223   +/-   ##
========================================
  Coverage    86.67%   86.67%           
========================================
  Files          131      131           
  Lines        18275    18275           
========================================
  Hits         15839    15839           
  Misses        2436     2436           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@CharlesXmf CharlesXmf left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This docs pass is clearer than the previous "BATES-style" / "first-order packing model" wording, and the new "Unbonded Grains" section is a useful user-facing explanation of grains_bonded=False.

One accuracy issue: the implementation still signs the shift with _csys:

return self.grains_center_of_mass_position - self._csys * (
    self.grain_number / 2.0
) * (self.grain_initial_height - self.grain_height)

The new constructor and center_of_propellant_mass notes drop that factor and write the shift as (grain_number / 2) * (grain_initial_height - grain_height(t)). The prose "moves toward the nozzle" is still right, but the formula is only complete for one coordinate_system_orientation. I'd keep a brief mention that the numeric shift is signed by _csys, as the old notes did.

Minor: the example prints bonded vs unbonded center_of_propellant_mass, while the following sentence quotes a ~0.03 caliber static-margin change for Calisto that the executed snippet does not compute. That is fine as a stated result, but it might help to say it was measured on the First Simulation Calisto rather than implying the example output shows it.

@Gui-FernandesBR

Copy link
Copy Markdown
Member Author

@CharlesXmf Both points are addressed in dc35d2d and 8a61c55. For the sign, I wrote it in terms of coordinate_system_orientation (subtracted for "nozzle_to_combustion_chamber", added for "combustion_chamber_to_nozzle") rather than _csys, since that is the public parameter users actually set.

@Gui-FernandesBR Gui-FernandesBR mentioned this pull request Nov 20, 2026
11 tasks done
Gui-FernandesBR and others added 4 commits November 21, 2026 09:59
The grains_bonded docs mentioned a private attribute, DEM contacts and future
work, and called bonded grains BATES-style, but BATES is only a grain shape.
Rewrite them in plain language and state that grain_separation is a solid
spacer, not an air gap.

Related to #1209.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01XDW575d9C9zpS7Z1v2KXVq
The solid motor usage page did not mention grains_bonded. Add a short section
with a runnable example comparing the propellant center of mass, and note that
the effect on the Calisto static margin is about 0.03 calibers at most.

Related to #1209.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01XDW575d9C9zpS7Z1v2KXVq
The shift is subtracted or added depending on coordinate_system_orientation,
as in the code; the simplified docstrings had dropped that.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01XDW5786UJyjdQdjM1E58pG
@Gui-FernandesBR
Gui-FernandesBR merged commit 6b2a37f into develop Nov 21, 2026
8 checks passed
@Gui-FernandesBR
Gui-FernandesBR deleted the doc/grains-bonded branch November 21, 2026 13:00
MateusStano added a commit that referenced this pull request Nov 28, 2026
Describe the forecast reuse and the opt-in disk cache that replaced the
first cache (#1219), and add the PRs merged after the backfill: #1221,
#1222, #1223, #1224, #1231, #1232, #1234, #1239 and #1242.

Co-Authored-By: Claude Fable 5.2 <[email protected]>
MateusStano added a commit that referenced this pull request Nov 28, 2026
* DOC: backfill the v1.14.0 changelog

The changelog automation has not run since #1112, so the PRs merged into develop after it were missing from [Unreleased]. Add them, add the entries for #1225, #1226 and #1227, update the tip-off, tube-fins and parachute-seed entries to what the release ships, and drop the raw commit link, the back-merge entry and the duplicate StochasticFreeFormFins entry.

Related to #1209

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01XDW575d9C9zpS7Z1v2KXVq

* DOC: add a Breaking changes section to the v1.14.0 changelog

List what changes for a v1.13.0 user: Monte Carlo seeding and numbering, the deprecated static_margin assignment, the parachute trigger ValueError on the rail, the shifted flight results, and the sensor default temperature.

Related to #1209

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01XDW575d9C9zpS7Z1v2KXVq

* DOC: bring the v1.14.0 changelog up to date with develop

Describe the forecast reuse and the opt-in disk cache that replaced the
first cache (#1219), and add the PRs merged after the backfill: #1221,
#1222, #1223, #1224, #1231, #1232, #1234, #1239 and #1242.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
Co-authored-by: MateusStano <[email protected]>
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.

3 participants