Skip to content

Cleaned up Examples#800

Merged
jkirk5 merged 37 commits intoOpenMDAO:mainfrom
jkirk5:examples
Jul 7, 2025
Merged

Cleaned up Examples#800
jkirk5 merged 37 commits intoOpenMDAO:mainfrom
jkirk5:examples

Conversation

@jkirk5
Copy link
Copy Markdown
Contributor

@jkirk5 jkirk5 commented Jun 13, 2025

Summary

Simplified and streamlined the example problems available with Aviary. The goal is to have each example provide a complete (and working) problem that demonstrates a single feature. There should be as few examples as possible to teach those features.

This PR is mostly targeted at the actual python scripts in the repo, and docs changes will come as a follow-on

Removed Files

  • Redundant examples such as separate scripts for reserve missions with different mission methods (they don't teach the user anything new about specifying a reserve mission)
  • Unnecessary models that don't have a clear purpose (such as a copy of an engine deck that just changes fuel flow units)
  • Duplicate files (such as FLOPS 28k engine deck, which had 2 copies in repo)

Renames

  • Example files are renamed to be clearer what feature they explain, as well as contain the word "example" in them
  • Tabular data files are given .csv file extensions instead of arbitrary extensions such as .deck, .prop, .map, etc. so they can be recognized and opened by other programs
  • Renamed N3CC to "advanced_single_aisle"

Reorganization

  • Moved some models that are only for testing purposes into models/test_aircraft along with a README to explain what they are and their purpose
  • Separated out models into "aircraft", "engines", and "missions" subfolders. Moved default phase_info to "missions" instead of "interface"

Related Issues

  • Resolves #

Backwards incompatibilities

None

New Dependencies

None

Comment thread aviary/api.py Outdated
)
from aviary.interface.default_phase_info.two_dof import phase_info as default_2DOF_phase_info
from aviary.interface.default_phase_info.two_dof_fiti import (
from aviary.models.missions.default_phase_info.two_dof import phase_info as default_2DOF_phase_info
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.

the missions directory only contains a phase_info directory, so I think we could move all the files up. Maybe just make the dir "mission_phase_info".

Copy link
Copy Markdown
Contributor Author

@jkirk5 jkirk5 Jun 17, 2025

Choose a reason for hiding this comment

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

I assume at some point we might have other missions besides the defaults, but I could just change the filenames to have the word "default" in them to avoid confusion without adding another directory

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Made that suggested change & added "default" to file names

Comment thread aviary/examples/external_subsystems/OAS_weight/simple_OAS_mission_example.py Outdated
@Kenneth-T-Moore
Copy link
Copy Markdown
Member

merging in #802 should help the failing CI.

Copy link
Copy Markdown
Member

@Kenneth-T-Moore Kenneth-T-Moore left a comment

Choose a reason for hiding this comment

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

Good once everything passes.

@jkirk5 jkirk5 merged commit f72f496 into OpenMDAO:main Jul 7, 2025
9 checks passed
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.

2 participants