TakeOffTrajectoryController

class sharpy.controllers.takeofftrajectorycontroller.TakeOffTrajectoryController[source]

The settings that this solver accepts are given by a dictionary, with the following key-value pairs:

Name

Type

Description

Default

trajectory_input_file

str

Route and file name of the trajectory file given as a csv with columns: time, x, y, z

None

dt

float

Time step of the simulation

None

trajectory_method

str

Trajectory controller method. For now, “lagrange” is the supported option

lagrange

controlled_constraint

str

Name of the controlled constraint in the multibody context Usually, it is something like constraint_00.

None

controller_log_route

str

Directory where the log will be stored

./output/

write_controller_log

bool

Controls if the log from the controller is written or not.

True

free_trajectory_structural_solver

str

If different than and empty string, the structural solver will be changed after the end of the trajectory has been reached

free_trajectory_structural_substeps

int

Controls the structural solver structural substeps once the end of the trajectory has been reached

0

initial_ramp_length_structural_substeps

int

Controls the number of timesteps that are used to increase the structural substeps from 0

10

control(data, controlled_state)[source]

Main routine of the controller. Input is data (the self.data in the solver), and currrent_state which is a dictionary with [‘structural’, ‘aero’] time steps for the current iteration.

Parameters
  • data – problem data containing all the information.

  • controlled_statedict with two vars: structural and aero containing the timestep_info that will be returned with the control variables.

Returns

A dict with structural and aero time steps and control input included.

process_trajectory(dxdt=True)[source]

See https://docs.scipy.org/doc/scipy-0.15.1/reference/generated/scipy.interpolate.UnivariateSpline.html