Skip to content

Fuel Calculations Revamp#1068

Open
ehariton wants to merge 39 commits intoOpenMDAO:mainfrom
ehariton:issue_1032v2
Open

Fuel Calculations Revamp#1068
ehariton wants to merge 39 commits intoOpenMDAO:mainfrom
ehariton:issue_1032v2

Conversation

@ehariton
Copy link
Copy Markdown
Contributor

@ehariton ehariton commented Apr 1, 2026

Summary

Updates how fuel mass and fuel constraints are calculated. New calculations were added for FUEL_TAXI_OUT, FUEL_TAXI_IN, Takeoff.FUEL, BLOCK_FUEL to enable the user to input those values and have them included even if they didn't run a taxi or takeoff phase. FUEL_TAXI_IN will work for all ODEs. FUEL_TAXI_OUT and Takeoff.FUEL will only work for energy-state ODE because 2DOF uses phases to calculate taxi and takeoff. Details on how Mission.TOTAL_FUEL (the fuel burn for the whole mission) is now being calculated are best explained by viewing Fuel_Breakdown.png.

  • Mission.Constraints.MASS_RESIDUAL now forces fuel loaded into the aircraft to be the same as fuel burned by the mission

  • Variable hiarchy adds: Mission.Taxi.FUEL_TAXI_OUT, FUEL_TAXI_IN, Mission.BLOCK_FUEL.

  • Variable higharchy mods: Mission.Takeoff.FUEL_SIMPLE & Mission.Takeoff.FUEL_BURN -> Mission.Takeoff.FUEL

  • Mission.TOTAL_FUEL is now calculated in pre-mission, enabling CG & stability calculations

  • Fuel_Breakdown graph has upd fuel names and new organization

  • test_post_mission_promotion unit test removed, it was not useful and was failing due to updates in TOTAL_FUEL now being calculated correctly in pre-mission

  • simplified_takeoff.py, it now accepts: Mission.Taxi.FUEL_TAXI_OUT as an input to calculate mass at end of taxi and drive takeoff calcs based on that rather than just gross-mass.

  • BLOCK_FUEL calc and tests added

  • Mission.Takeoff.FINAL_MASS calculation added to energy-state problem configurator to ensure it's always calculated regardless if include_takeoff.

  • ZERO_FUEL_MASS calculation added to gasp-based mass. This allows us to make Mission.TOTAL_FUEL calc in aviary group uniform.

  • Test values updates. We had to change test results for 9 tests that were failing because they had include_takeoff=False but specified a takeoff fuel burn. In the past we ignored the takeoff fuel burn if include_takeoff=False. However, to be consistent with the new architecture we had to accept the takeoff-fuel-burn values from the csv and process them normally this made the fuel mass and thus the gross mass of these flights slightly larger by a few 100s of lbm. We could not remove that takeoff fuel burn from the csv because that would have caused errors when takeoff=true.

Related Issues

Backwards incompatibilities

None

New Dependencies

None

ehariton added 30 commits March 24, 2026 12:45
…FUEL_BUREND + RESERVE_FUEL, some errors still
…ividual problem configurators, and moved it off of acting on Mission.Summary.OPERATING_MASS plus TOTAL_FUEL_MASS plys GROSS_MASS, put it back on enforcing that mission fuel burn + reserve fuel was the same as the pre-mission value given by Mission.Summary.TOTAL_FUEL_MASS
…and calculating TOTAL_FUEL_MASS in pre-mission broke it
…e, this has caused examples like test_battery_in_a_mission.py to start failing because it has a non-zero mission:takeoff:fuel_burn,577
…at describes how all the fuel burns add up together. Some tests will fail on this PR because the new naming scheme is only half implemented
…SIDUAL constraint calculation, all tests passing except 1
@ehariton ehariton marked this pull request as ready for review April 2, 2026 14:48
@ehariton ehariton changed the title Issue 1032v2 Fuel Calculations Revamp Apr 2, 2026
@ehariton ehariton requested a review from Kenneth-T-Moore April 2, 2026 15:23
self.configurator.add_takeoff_systems(self)

# Calculate Mission.TOTAL_FUEL
pre_mission.add_subsystem(
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Pondering whether this should be at the top in pre_mission, or it should be down in the mass group.

One effect of having it here is that it is active no matter which problemtype we are using, but does this hook up to anything in 2dof? I dont think zero_fuel_mass is there.

# Users can set the below constraint to lower=0.0, which will allow for more fuel on the aircraft than the mission
# requires. however, caution will need to be taken to ensure the ref is of the right magnitude otherwise the optimizer
# may not try as hard as needed to minimize this.
self.add_constraint(
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Moving this out of the configurators will break the Solved-2dof problems. We hadn't been adding a mass constraint to those problems because they end at the start of climb.

We probably also need a way to turn this constraint off if we aren't doing sizing.

tolerance=1e-12,
)
assert_near_equal(prob_fallout.get_val(Mission.RANGE), 2438.6, tolerance=1e-3)
assert_near_equal(prob_fallout.get_val(Mission.RANGE), 2377.4, tolerance=1e-3)
Copy link
Copy Markdown
Member

@Kenneth-T-Moore Kenneth-T-Moore Apr 3, 2026

Choose a reason for hiding this comment

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

Adding taxi-out + simple takeoff burned 60 miles of fuel?

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.

Change how fuel burn is calculated

2 participants