fastoad.models.performances.mission.segments.transition module
Class for very simple transition in some flight phases.
- class fastoad.models.performances.mission.segments.transition.DummyTransitionSegment(target: fastoad.model_base.flight_point.FlightPoint, propulsion: Optional[fastoad.model_base.propulsion.IPropulsion] = None, polar: Optional[fastoad.models.performances.mission.polar.Polar] = None, reference_area: float = 1.0, time_step: float = 0.2, engine_setting: fastoad.constants.EngineSetting = EngineSetting.CLIMB, altitude_bounds: tuple = (- 500.0, 40000.0), mach_bounds: tuple = (0.0, 5.0), name: str = '', interrupt_if_getting_further_from_target: bool = True, mass_ratio: float = 1.0, reserve_mass_ratio: float = 0.0)[source]
Bases:
fastoad.models.performances.mission.segments.base.FlightSegment
Computes a transient flight part in a very quick and dummy way.
compute_from()
will return only 2 or 3 flight points.The second flight point is the end of transition and its mass is the start mass multiplied by
mass_ratio
. Other parameters are equal to those provided intarget
.If
reserve_mass_ratio
is non-zero, a third flight point, with parameters equal to flight_point(2), except for mass where:mass(2) - reserve_mass_ratio * mass(3) = mass(3).
In different words, mass(3) would be the Zero Fuel Weight (ZFW) and reserve can be expressed as a percentage of ZFW.
- mass_ratio: float = 1.0
The ratio (aircraft mass at END of segment)/(aircraft mass at START of segment)
- reserve_mass_ratio: float = 0.0
The ratio (fuel mass)/(aircraft mass at END of segment) that will be consumed at end of segment.
- propulsion: fastoad.model_base.propulsion.IPropulsion = None
Unused
- polar: fastoad.models.performances.mission.polar.Polar = None
Unused
- compute_from(start: fastoad.model_base.flight_point.FlightPoint) pandas.core.frame.DataFrame [source]
Computes the flight path segment from provided start point.
Computation ends when target is attained, or if the computation stops getting closer to target. For instance, a climb computation with too low thrust will only return one flight point, that is the provided start point.
- Parameters
start – the initial flight point, defined for altitude, mass and speed (true_airspeed, equivalent_airspeed or mach). Can also be defined for time and/or ground_distance.
- Returns
a pandas DataFrame where columns names match fields of
FlightPoint()
- get_gamma_and_acceleration(flight_point: fastoad.model_base.flight_point.FlightPoint) Tuple[float, float] [source]
Computes slope angle (gamma) and acceleration.
- Parameters
flight_point – parameters after propulsion model has been called (i.e. mass, thrust and drag are available)
- Returns
slope angle in radians and acceleration in m**2/s
- get_distance_to_target(flight_points: List[fastoad.model_base.flight_point.FlightPoint]) float [source]
Computes a “distance” from last flight point to target.
Computed does not need to have a real meaning. The important point is that it must be signed so that algorithm knows on which “side” of the target we are. And of course, it should be 0. if flight point is on target.
- Parameters
flight_points – list of all currently computed flight_points
- Returns
if target is attained, a non-null value otherwise
- compute_propulsion(flight_point: fastoad.model_base.flight_point.FlightPoint)[source]
Computes propulsion data.
Provided flight point is modified in place.
Generally, this method should end with:
self.propulsion.compute_flight_points(flight_point)
- Parameters
flight_point –