Paparazzi UAS  v5.14.0_stable-0-g3f680d1
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
pprz_algebra_float.c File Reference

Paparazzi floating point algebra. More...

+ Include dependency graph for pprz_algebra_float.c:

Go to the source code of this file.

Functions

void float_vect3_integrate_fi (struct FloatVect3 *vec, struct FloatVect3 *dv, float dt)
 in place first order integration of a 3D-vector More...
 
void float_rates_integrate_fi (struct FloatRates *r, struct FloatRates *dr, float dt)
 in place first order integration of angular rates More...
 
void float_rates_of_euler_dot (struct FloatRates *r, struct FloatEulers *e, struct FloatEulers *edot)
 
void float_rmat_inv (struct FloatRMat *m_b2a, struct FloatRMat *m_a2b)
 Inverse/transpose of a rotation matrix. More...
 
float float_rmat_norm (struct FloatRMat *rm)
 Norm of a rotation matrix. More...
 
void float_rmat_comp (struct FloatRMat *m_a2c, struct FloatRMat *m_a2b, struct FloatRMat *m_b2c)
 Composition (multiplication) of two rotation matrices. More...
 
void float_rmat_comp_inv (struct FloatRMat *m_a2b, struct FloatRMat *m_a2c, struct FloatRMat *m_b2c)
 Composition (multiplication) of two rotation matrices. More...
 
void float_rmat_vmult (struct FloatVect3 *vb, struct FloatRMat *m_a2b, struct FloatVect3 *va)
 rotate 3D vector by rotation matrix. More...
 
void float_rmat_transp_vmult (struct FloatVect3 *vb, struct FloatRMat *m_b2a, struct FloatVect3 *va)
 rotate 3D vector by transposed rotation matrix. More...
 
void float_rmat_mult (struct FloatEulers *rb, struct FloatRMat *m_a2b, struct FloatEulers *ra)
 rotate angle by rotation matrix. More...
 
void float_rmat_transp_mult (struct FloatEulers *rb, struct FloatRMat *m_b2a, struct FloatEulers *ra)
 rotate angle by transposed rotation matrix. More...
 
void float_rmat_ratemult (struct FloatRates *rb, struct FloatRMat *m_a2b, struct FloatRates *ra)
 rotate anglular rates by rotation matrix. More...
 
void float_rmat_transp_ratemult (struct FloatRates *rb, struct FloatRMat *m_b2a, struct FloatRates *ra)
 rotate anglular rates by transposed rotation matrix. More...
 
void float_rmat_of_axis_angle (struct FloatRMat *rm, struct FloatVect3 *uv, float angle)
 initialises a rotation matrix from unit vector axis and angle More...
 
void float_rmat_of_eulers_321 (struct FloatRMat *rm, struct FloatEulers *e)
 Rotation matrix from 321 Euler angles (float). More...
 
void float_rmat_of_eulers_312 (struct FloatRMat *rm, struct FloatEulers *e)
 
void float_rmat_of_quat (struct FloatRMat *rm, struct FloatQuat *q)
 
void float_rmat_integrate_fi (struct FloatRMat *rm, struct FloatRates *omega, float dt)
 in place first order integration of a rotation matrix More...
 
static float renorm_factor (float n)
 
float float_rmat_reorthogonalize (struct FloatRMat *rm)
 
void float_quat_comp (struct FloatQuat *a2c, struct FloatQuat *a2b, struct FloatQuat *b2c)
 Composition (multiplication) of two quaternions. More...
 
void float_quat_comp_inv (struct FloatQuat *a2b, struct FloatQuat *a2c, struct FloatQuat *b2c)
 Composition (multiplication) of two quaternions. More...
 
void float_quat_inv_comp (struct FloatQuat *b2c, struct FloatQuat *a2b, struct FloatQuat *a2c)
 Composition (multiplication) of two quaternions. More...
 
void float_quat_comp_norm_shortest (struct FloatQuat *a2c, struct FloatQuat *a2b, struct FloatQuat *b2c)
 Composition (multiplication) of two quaternions with normalization. More...
 
void float_quat_comp_inv_norm_shortest (struct FloatQuat *a2b, struct FloatQuat *a2c, struct FloatQuat *b2c)
 Composition (multiplication) of two quaternions with normalization. More...
 
void float_quat_inv_comp_norm_shortest (struct FloatQuat *b2c, struct FloatQuat *a2b, struct FloatQuat *a2c)
 Composition (multiplication) of two quaternions with normalization. More...
 
void float_quat_differential (struct FloatQuat *q_out, struct FloatRates *w, float dt)
 Delta rotation quaternion with constant angular rates. More...
 
void float_quat_integrate_fi (struct FloatQuat *q, struct FloatRates *omega, float dt)
 in place first order quaternion integration with constant rotational velocity More...
 
void float_quat_integrate (struct FloatQuat *q, struct FloatRates *omega, float dt)
 in place quaternion integration with constant rotational velocity More...
 
void float_quat_vmult (struct FloatVect3 *v_out, struct FloatQuat *q, const struct FloatVect3 *v_in)
 rotate 3D vector by quaternion. More...
 
void float_quat_derivative (struct FloatQuat *qd, struct FloatRates *r, struct FloatQuat *q)
 Quaternion derivative from rotational velocity. More...
 
void float_quat_derivative_lagrange (struct FloatQuat *qd, struct FloatRates *r, struct FloatQuat *q)
 Quaternion derivative from rotational velocity. More...
 
void float_quat_of_eulers (struct FloatQuat *q, struct FloatEulers *e)
 quat of euler roation 'ZYX' More...
 
void float_quat_of_eulers_zxy (struct FloatQuat *q, struct FloatEulers *e)
 quat from euler rotation 'ZXY' This rotation order is useful if you need 90 deg pitch More...
 
void float_quat_of_eulers_yxz (struct FloatQuat *q, struct FloatEulers *e)
 quat from euler rotation 'YXZ' This function calculates a quaternion from Euler angles with the order YXZ, so pitch, roll, yaw, instead of the conventional ZYX order. More...
 
void float_quat_of_axis_angle (struct FloatQuat *q, const struct FloatVect3 *uv, float angle)
 Quaternion from unit vector and angle. More...
 
void float_quat_of_orientation_vect (struct FloatQuat *q, const struct FloatVect3 *ov)
 Quaternion from orientation vector. More...
 
void float_quat_of_rmat (struct FloatQuat *q, struct FloatRMat *rm)
 Quaternion from rotation matrix. More...
 
void float_eulers_of_rmat (struct FloatEulers *e, struct FloatRMat *rm)
 
void float_eulers_of_quat (struct FloatEulers *e, struct FloatQuat *q)
 euler rotation 'ZYX' More...
 
void float_eulers_of_quat_yxz (struct FloatEulers *e, struct FloatQuat *q)
 euler rotation 'YXZ' This function calculates from a quaternion the Euler angles with the order YXZ, so pitch, roll, yaw, instead of the conventional ZYX order. More...
 
void float_eulers_of_quat_zxy (struct FloatEulers *e, struct FloatQuat *q)
 euler rotation 'ZXY' This rotation order is useful if you need 90 deg pitch More...
 
bool float_mat_inv_2d (float inv_out[4], float mat_in[4])
 2x2 matrix inverse More...
 
void float_mat2_mult (struct FloatVect2 *vect_out, float mat[4], struct FloatVect2 vect_in)
 Multiply 2D matrix with vector. More...
 
static float float_mat_minor_4d (float m[16], int r0, int r1, int r2, int c0, int c1, int c2)
 
static void float_mat_adjoint_4d (float adjOut[16], float m[16])
 
static float float_mat_det_4d (float m[16])
 
bool float_mat_inv_4d (float invOut[16], float mat_in[16])
 4x4 Matrix inverse More...
 
void float_mat_invert (float **o, float **mat, int n)
 Calculate inverse of any n x n matrix (passed as C array) o = mat^-1 Algorithm verified with Matlab. More...
 
void float_mat_exp (float **a, float **o, int n)
 
float float_mat_norm_li (float **a, int m, int n)
 

Detailed Description

Paparazzi floating point algebra.

Definition in file pprz_algebra_float.c.

Function Documentation

static void float_mat_adjoint_4d ( float  adjOut[16],
float  m[16] 
)
static

Definition at line 778 of file pprz_algebra_float.c.

References float_mat_minor_4d().

Referenced by float_mat_inv_4d().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static float float_mat_det_4d ( float  m[16])
static

Definition at line 798 of file pprz_algebra_float.c.

References float_mat_minor_4d().

Referenced by float_mat_inv_4d().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static float float_mat_minor_4d ( float  m[16],
int  r0,
int  r1,
int  r2,
int  c0,
int  c1,
int  c2 
)
static

Definition at line 770 of file pprz_algebra_float.c.

References c1, and c2.

Referenced by float_mat_adjoint_4d(), and float_mat_det_4d().

+ Here is the caller graph for this function:

static float renorm_factor ( float  n)
inlinestatic

Definition at line 275 of file pprz_algebra_float.c.

Referenced by float_rmat_reorthogonalize().

+ Here is the caller graph for this function: