fastoad.models.performances.mission.openmdao.mission_wrapper module

Mission wrapper.

class fastoad.models.performances.mission.openmdao.mission_wrapper.MissionWrapper(*args, **kwargs)[source]

Bases: MissionBuilder

Wrapper around MissionBuilder for using with OpenMDAO.

Parameters
  • mission_definition – a file path or MissionDefinition instance

  • propulsion – if not provided, the property propulsion must be set before calling build()

  • reference_area – if not provided, the property reference_area must be set before calling build()

setup(component: ExplicitComponent, mission_name: Optional[str] = None)[source]

To be used during setup() of provided OpenMDAO component.

It adds input and output variables deduced from mission definition file.

Parameters
  • component – the OpenMDAO component where the setup is done.

  • mission_name – mission name (can be omitted if only one mission is defined)

compute(start_flight_point: FlightPoint, inputs: Vector, outputs: Vector) DataFrame[source]

To be used during compute() of an OpenMDAO component.

Builds the mission from input file, and computes it. outputs vector is filled with duration, burned fuel and covered ground distance for each part of the flight.

Parameters
  • start_flight_point – starting point of mission

  • inputs – the input vector of the OpenMDAO component

  • outputs – the output vector of the OpenMDAO component

Returns

a pandas DataFrame where column names match fields of FlightPoint

get_reserve_variable_name() str[source]
Returns

the name of OpenMDAO variable for fuel reserve. This name is among the declared outputs in setup().