gemseo / disciplines

Hide inherited members

utils module

A set of functions to handle disciplines.

gemseo.disciplines.utils.get_all_inputs(disciplines, skip_scenarios=True)[source]

Return all the input names of the disciplines.

Parameters:
  • disciplines (Iterable[MDODiscipline]) – The disciplines including potentially Scenario objects.

  • skip_scenarios (bool) –

    If True, skip the Scenario objects. Otherwise, consider their disciplines.

    By default it is set to True.

Returns:

The names of the inputs.

Return type:

list[str]

gemseo.disciplines.utils.get_all_outputs(disciplines, skip_scenarios=True)[source]

Return all the output names of the disciplines.

Parameters:
  • disciplines (Iterable[MDODiscipline]) – The disciplines including potentially Scenario objects.

  • skip_scenarios (bool) –

    If True, skip the Scenario objects. Otherwise, consider their disciplines.

    By default it is set to True.

Returns:

The names of the outputs.

Return type:

list[str]

gemseo.disciplines.utils.get_sub_disciplines(disciplines, recursive=False)[source]

Determine the sub-disciplines.

This method lists the sub-disciplines’ disciplines. It will list up to one level of disciplines contained inside another one unless the recursive argument is set to True.

Parameters:
  • disciplines (list[MDODiscipline]) – The disciplines from which the sub-disciplines will be determined.

  • recursive (bool) –

    If True, the method will look inside any discipline that has other disciplines inside until it reaches a discipline without sub-disciplines, in this case the return value will not include any discipline that has sub-disciplines. If False, the method will list up to one level of disciplines contained inside another one, in this case the return value may include disciplines that contain sub-disciplines.

    By default it is set to False.

Returns:

The sub-disciplines.

Return type:

list[MDODiscipline]

Examples using get_all_inputs

Application: Sobieski’s Super-Sonic Business Jet (MDO)

Application: Sobieski's Super-Sonic Business Jet (MDO)

Discipline

Discipline

Example for exterior penalty applied to the Sobieski test case.

Example for exterior penalty applied to the Sobieski test case.

Examples using get_all_outputs

Application: Sobieski’s Super-Sonic Business Jet (MDO)

Application: Sobieski's Super-Sonic Business Jet (MDO)

Discipline

Discipline

Example for exterior penalty applied to the Sobieski test case.

Example for exterior penalty applied to the Sobieski test case.