geometryconfig#

namespace saltro
namespace disturbances
class GeometryConfig#
#include <geometryconfig.h>

Static, flight-safe configuration for satellite geometry.

The GeometryConfig class defines the geometric and aerodynamic properties of the satellite’s external surfaces. This configuration is used by disturbance models (e.g., drag, solar radiation pressure) to compute forces and torques.

This implementation uses static allocation with a maximum number of faces defined by saltro::limits::MAX_NUM_GEOMETRY_FACES, ensuring no dynamic memory allocation occurs during runtime (flight-safe).

Public Types

using Vec3 = Eigen::Vector3d#
using FaceArray = std::array<GeometryFace, saltro::limits::MAX_NUM_GEOMETRY_FACES>#

Public Functions

GeometryConfig()#

Default constructor creates an empty geometry configuration.

bool addFace(const GeometryFace &face)#

Add a face to the geometry configuration.

Parameters:

face – The GeometryFace to add

Returns:

true if face was added successfully, false if max capacity reached

inline size_t numFaces() const#

Get the number of faces currently configured.

Returns:

Number of faces

const GeometryFace &getFace(size_t index) const#

Get a reference to a specific face.

Parameters:

index – Face index [0, numFaces())

Returns:

Reference to the GeometryFace

GeometryFace &getFace(size_t index)#

Get mutable reference to a specific face.

Parameters:

index – Face index [0, numFaces())

Returns:

Reference to the GeometryFace

void clear()#

Clear all faces from the configuration.

inline const FaceArray &faces() const#

Direct access to the underlying face array (const).

Returns:

Const reference to the face array

inline FaceArray &faces()#

Direct access to the underlying face array (mutable).

Returns:

Reference to the face array

Public Static Functions

static inline constexpr size_t maxFaces()#

Get the maximum number of faces that can be stored.

Returns:

Maximum capacity

Private Members

FaceArray faces_#

Static array of geometry faces.

size_t num_faces_#

Current number of active faces.

struct GeometryFace#
#include <geometryconfig.h>

Represents a single geometric face/surface element of a satellite.

Each face has:

  • Geometric properties: area, centroid, normal vector

  • Optical properties: specular (eta_s), diffuse (eta_d), absorptivity (eta_a)

  • Aerodynamic properties: drag coefficient (CD)

Public Types

using Vec3 = Eigen::Vector3d#

Public Functions

GeometryFace()#

Default constructor initializes all values to zero.

GeometryFace(double area_, const Vec3 &centroid_, const Vec3 &normal_, double eta_s_ = 0.0, double eta_d_ = 0.0, double eta_a_ = 0.0, double CD_ = 0.0)#

Construct a GeometryFace with specified parameters.

Parameters:
  • area_ – Surface area [m²]

  • centroid_ – Centroid position vector [m]

  • normal_ – Surface normal unit vector

  • eta_s_ – Specular reflection coefficient (default: 0)

  • eta_d_ – Diffuse reflection coefficient (default: 0)

  • eta_a_ – Absorptivity coefficient (default: 0)

  • CD_ – Drag coefficient (default: 0)

Public Members

double area#

Surface area [m²].

Vec3 centroid#

Centroid position in body frame [m].

Vec3 normal#

Surface normal unit vector in body frame.

double eta_s#

Specular reflection coefficient [0-1].

double eta_d#

Diffuse reflection coefficient [0-1].

double eta_a#

Absorptivity coefficient [0-1].

double CD#

Drag coefficient.