Skip to content

Add external atmosphere option to FlightConditions and PR_guess to Nozzle - #124

Open
anushka-tahiliani wants to merge 1 commit into
OpenMDAO:masterfrom
anushka-tahiliani:external-atmosphere
Open

anushka-tahiliani wants to merge 1 commit into
OpenMDAO:masterfrom
anushka-tahiliani:external-atmosphere

Conversation

@anushka-tahiliani

Copy link
Copy Markdown

Summary

Adds two small, opt-in options. Neither changes results with its default value, and both work with any pyCycle model; neither needs an external initial guess.

They come out of coupling pyCycle engine models to multidisciplinary aircraft optimization in FINCH (ideas-um/FINCH#281), an Aviary-compatible package (private for now; a public release is planned). There the mission analysis supplies the ambient state at every node, including hot-day takeoff, and the engine models need a better starting point for low pressure ratio nozzles. FINCH uses both options today through a fork of pyCycle; this PR lets it depend on pyCycle directly.

FlightConditions(use_external_atmosphere=True)

FlightConditions always builds its ambient state from the built-in US1976 table (alt, dTs). When pyCycle runs inside a larger model, like a mission analysis, the atmosphere is usually already computed upstream: a non-standard or hot day, a different atmosphere model, or a temperature profile that a constant dTs can't represent.

With use_external_atmosphere=True, the Ambient subsystem is replaced by a passthrough with the same ambient.Ts, ambient.Ps and ambient.rhos outputs. The element then takes these inputs instead of alt and dTs:

input units
ambient_static_temperature degR
ambient_static_pressure psi
ambient_density slug/ft**3

Everything downstream (the Tt/Pt balance and the flow start) is unchanged.

Nozzle(PR_guess=...)

Sets the starting value of the PR_bal total-to-static pressure ratio. It is currently hard-coded to 2.0, which is a poor starting point for low pressure ratio nozzles, such as turboshaft, fan and propulsor exhausts, and for off-design points near PR = 1. It is a plain option: pass any value greater than 1 (FINCH's turboshaft uses PR_guess=1.05). The default stays 2.0.

Tests

  • test_flightconditions.ExternalAtmosphereTestCase
    • Feeds one FlightConditions the ambient state of a second, standard one. It checks that total and static P, T, W and V match to 1e-8 at 35,000 ft / M0.8 and on a +27 degR sea-level hot day.
    • Checks partials of the passthrough with complex step.
    • Checks that alt and dTs are not inputs in this mode.
  • test_nozzle.test_PR_guess checks the initial PR with and without the option.

The full test suite passes, and so does ruff check . --select NPY201.

…zzle

FlightConditions(use_external_atmosphere=True) replaces the built-in
atmosphere with ambient_static_temperature, ambient_static_pressure and
ambient_density inputs, so the ambient state can come from another model
such as a mission analysis or a non-standard day. Nozzle(PR_guess=...)
sets the starting value of the PR_bal pressure ratio, previously fixed
at 2.0. Both defaults leave results unchanged.
@anushka-tahiliani
anushka-tahiliani marked this pull request as ready for review November 17, 2026 15:53

This branch has not been deployed

No deployments
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