TankGeometry Class#

Class to define the geometry of a tank. It is used to calculate the geometrical properties such as volume, area and radius. The tank is axi-symmetric, and its geometry is defined by a set of Functions that are used to calculate the radius as a function of height.

Geometrical attributes
TankGeometry.geometry#

Dictionary containing the geometry of the tank. The dictionary keys are disjoint domains of the corresponding coordinates in meters on the TankGeometry symmetry axis. The dictionary values are rocketpy.Function objects that map the Tank height to its corresponding radius. As an example, { (-1,1): Function(lambda h: (1 - h**2) ** (1/2)) } defines an spherical tank of radius 1.

Type:

dict

TankGeometry.radius#

Piecewise defined radius in meters as a rocketpy.Function based on the TankGeometry.geometry dict.

Type:

rocketpy.Function

TankGeometry.average_radius#

The average radius in meters of the Tank radius. It is calculated as the average of the radius Function over the tank height.

Type:

float

TankGeometry.bottom#

The bottom of the tank. It is the lowest coordinate that belongs to the domain of the geometry.

Type:

float

TankGeometry.top#

The top of the tank. It is the highest coordinate that belongs to the domain of the geometry.

Type:

float

TankGeometry.total_height#

The total height of the tank, in meters. It is calculated as the difference between the top and bottom coordinates.

Type:

float

TankGeometry.area#

Tank cross sectional area in meters squared as a function of height, defined as the area of a circle with radius TankGeometry.radius.

Type:

rocketpy.Function

TankGeometry.volume#

Tank volume in in meters cubed as a function of height, defined as the Tank volume from the bottom to the given height.

Type:

rocketpy.Function

TankGeometry.total_volume#

Total volume of the tank, in meters cubed. It is calculated as the volume from the bottom to the top of the tank.

Type:

float

TankGeometry.inverse_volume#

Tank height as a function of volume, defined as the inverse of the TankGeometry.volume Function.

Type:

rocketpy.Function

TankGeometry.volume_moment : rocketpy.Function

Tank first volume moment in m^4 of the tank as a function of height. See TankGeometry.volume_moment for more details.

TankGeometry.Ix_volume : rocketpy.Function

Tank volume of inertia in m^5 around the an axis that is perpendicular to the tank symmetry axis. The reference is the zero height coordinate. See TankGeometry.Ix_volume for more details.

TankGeometry.Iz_volume : rocketpy.Function

Tank volume of inertia in m^5 around the tank symmetry axis. The reference is the zero height coordinate. See TankGeometry.Iz_volume for more details.

TankGeometry.add_geometry : None

Adds a new geometry to the tank. See TankGeometry.add_geometry for more details.