export_time_variables¶
- Powertrain.export_time_variables(folder_path: str, time_unit: str | None = 'sec', angular_position_unit: str | None = 'rad', angular_speed_unit: str | None = 'rad/s', angular_acceleration_unit: str | None = 'rad/s^2', torque_unit: str | None = 'Nm', driving_torque_unit: str | None = 'Nm', load_torque_unit: str | None = 'Nm', force_unit: str | None = 'N', stress_unit: str | None = 'MPa', current_unit: str | None = 'A') None
It exports the powertrain’s
elements’ computed time variables to some files.It creates a file for each rotating object in the powertrain’s
elements. The file name is taken from the rotating object’sname.The exported files are a
.csvfiles. The time variables are exported in a tabular form, in which each column is a time variable and each row is a simulated time step. The columns are separated by a comma. The first column reports the simulated time steps and the first row reports the column names.Parameters¶
folder_pathstrPath to the folder in which to save the time variables’ files. It must be a non-empty
str.time_unitstr, optionalSymbol of the unit of measurement to which convert the time values in the exported files. It must be a
str. Default is'sec'. SeeTime.unitfor more details.angular_position_unitstr, optionalSymbol of the unit of measurement to which convert the angular position values in the exported files. It must be a
str. Default is'rad'. SeeAngularPosition.unitfor more details.angular_speed_unitstr, optionalSymbol of the unit of measurement to which convert the angular speed values in the exported files. It must be a
str. Default is'rad/s'. SeeAngularSpeed.unitfor more details.angular_acceleration_unitstr, optionalSymbol of the unit of measurement to which convert the angular acceleration values in the exported files. It must be a
str. Default is'rad/s^2'. SeeAngularAcceleration.unitfor more details.torque_unitstr, optionalSymbol of the unit of measurement to which convert the torque values in the exported files. It must be a
str. Default is'Nm'. SeeTorque.unitfor more details.driving_torque_unitstr, optionalSymbol of the unit of measurement to which convert the driving torque values in the exported files. It must be a
str. Default is'Nm'. SeeTorque.unitfor more details.load_torque_unitstr, optionalSymbol of the unit of measurement to which convert the load torque values in the exported files. It must be a
str. Default is'Nm'. SeeTorque.unitfor more details.force_unitstr, optionalSymbol of the unit of measurement to which convert the force values in the exported files. It must be a
str. Default is'N'. SeeForce.unitfor more details.stress_unitstr, optionalSymbol of the unit of measurement to which convert the stress values in the exported files. It must be a
str. Default is'MPa'. SeeStress.unitfor more details.current_unitstr, optionalSymbol of the unit of measurement to which convert the electric current values in the exported files. It must be a
str. Default is'A'. SeeCurrent.unitfor more details.
Raises
TypeErrorIf
folder_pathis not astr,if
time_unitis not astr,if
angular_position_unitis not astr,if
angular_speed_unitis not astr,if
angular_acceleration_unitis not astr,if
torque_unitis not astr,if
driving_torque_unitis not astr,if
load_torque_unitis not astr,if
force_unitis not astr,if
stress_unitis not astr,if
current_unitis not astr.
ValueErrorIf
folder_pathis an emptystr.