-
Notifications
You must be signed in to change notification settings - Fork 111
BWB FLOPS Fortran_to_Aviary #947
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
aviary/subsystems/geometry/flops_based/characteristic_lengths.py
Outdated
Show resolved
Hide resolved
aviary/subsystems/mass/flops_based/test/test_thrust_reverser.py
Outdated
Show resolved
Hide resolved
| input_values: NamedValues = vehicle_data['input_values'] | ||
|
|
||
| # if reference + scaled thrust both provided, set scale factor | ||
| # if reference + scaled thrust both provided, set scale factor -- Is this comment still true? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| input_values.set_val(Aircraft.Fuselage.SIMPLE_LAYOUT, [True], 'unitless') | ||
| else: | ||
| input_values.set_val(Aircraft.Fuselage.SIMPLE_LAYOUT, [False], 'unitless') | ||
| elif design_type[0] == 3: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should add a catch all 'else' for design_type. FLOPS has options 0,1,2,3.
If a user attempts to convert a FLOPS deck with 1 or 2 set then maybe Aviary should Error to make the user aware that we can't convert those ones yet?
|
|
||
| design_type, design_units = input_values.get_item(Aircraft.Design.TYPE) | ||
| if design_type[0] == 0: | ||
| input_values.set_val(Aircraft.Design.TYPE, ['transport'], design_units) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we use the enum here rather than a string?
| input_values.set_val(Aircraft.Wing.INPUT_STATION_DIST, input_station_dist) | ||
| n_dist = len(input_station_dist) | ||
| chord_per_semispan_dist = input_values.get_val(Aircraft.Wing.CHORD_PER_SEMISPAN_DIST) | ||
| chord_per_semispan_dist = [-1.0] + chord_per_semispan_dist[0 : n_dist - 1] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
|
|
||
| if Aircraft.Engine.SCALED_SLS_THRUST in input_values: | ||
| # not sure why THRUST=70000,1,0,0,0,0, just grab the first entry | ||
| # does it apply to transporters? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| wing_tc = input_values.get_val(Aircraft.Wing.THICKNESS_TO_CHORD, 'unitless')[0] | ||
| input_values.set_val(Aircraft.Fuselage.HEIGHT_TO_WIDTH_RATIO, [wing_tc], 'unitless') | ||
|
|
||
| if not Aircraft.Fuel.WING_FUEL_FRACTION in input_values: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we only need to do this conversion if WING_FUEL_FRACTION does appear in input_values?
Otherwise we can just use the default value? Perhaps we need to set a default value...?
| else: | ||
| # If detail wing is not provided, initialize it to [0, 0.5, 1] | ||
| input_values.set_val(Aircraft.BWB.DETAILED_WING_PROVIDED, [False]) | ||
| input_values.set_val(Aircraft.Wing.INPUT_STATION_DIST, [0.0, 0.5, 1.0]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perhaps add a comment to the user if this is the case?
| aircraft:crew_and_payload:baggage_mass_per_passenger,35.0,lbm | ||
| aircraft:crew_and_payload:design:num_business_class,20,unitless | ||
| aircraft:crew_and_payload:design:num_first_class,16,unitless | ||
| aircraft:crew_and_payload:design:num_passengers,154,unitless |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see comments in fortran_to_aviary, but I don't believe we need to total up the passengers on conversion, that should be handled by preprocessors I think...!
| aircraft:engine:geopotential_alt,False,unitless | ||
| aircraft:engine:ignore_negative_thrust,False,unitless | ||
| aircraft:engine:mass_scaler,1.15,unitless | ||
| aircraft:engine:num_engines,2,unitless |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As for passenger totals I think this should be handled by preprocessors?
| mission:design:thrust_takeoff_per_eng,0.25,lbf | ||
| mission:landing:initial_velocity,140,ft/s | ||
| mission:landing:lift_coefficient_max,3.0,unitless | ||
| #mission:landing:lift_coefficient_max,3.0,unitless |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this commented out?
| mission:design:thrust_takeoff_per_eng,0.25,lbf | ||
| mission:landing:initial_velocity,140,ft/s | ||
| mission:landing:lift_coefficient_max,3.0,unitless | ||
| #mission:landing:lift_coefficient_max,3.0,unitless |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check if this is supposed to be commented out



Summary
This PR updates utility application
fortran_to_aviaryto include the features needed for FLOPS based BWB aircraft dataset.Related Issues
Backwards incompatibilities
None
New Dependencies
None