MBot Software Library  v1.0
An API documentation to mbot_firmware repository
algebra.h
1 
11 #ifndef RC_ALGEBRA_H
12 #define RC_ALGEBRA_H
13 
14 #ifdef __cplusplus
15 extern "C" {
16 #endif
17 
18 #include <rc/math/matrix.h>
19 
35 
49 
63 
74 
88 
106 void rc_algebra_set_zero_tolerance(double tol);
107 
121 
145 int rc_algebra_fit_ellipsoid(rc_matrix_t points, rc_vector_t* center, rc_vector_t* lengths);
146 
147 
148 #ifdef __cplusplus
149 }
150 #endif
151 
152 #endif // RC_ALGEBRA_H
153 
int rc_algebra_qr_decomp(rc_matrix_t A, rc_matrix_t *Q, rc_matrix_t *R)
Calculate the QR decomposition of matrix A.
Definition: algebra.c:145
int rc_algebra_invert_matrix(rc_matrix_t A, rc_matrix_t *Ainv)
Inverts matrix A via LUP decomposition method.
Definition: algebra.c:263
int rc_algebra_fit_ellipsoid(rc_matrix_t points, rc_vector_t *center, rc_vector_t *lengths)
Fits an ellipsoid to a set of points in 3D space.
Definition: algebra.c:491
int rc_algebra_lup_decomp(rc_matrix_t A, rc_matrix_t *L, rc_matrix_t *U, rc_matrix_t *P)
Performs LUP decomposition on matrix A with partial pivoting.
Definition: algebra.c:174
void rc_algebra_set_zero_tolerance(double tol)
Sets the zero tolerance for detecting singular matrices.
Definition: algebra.c:437
int rc_algebra_lin_system_solve_qr(rc_matrix_t A, rc_vector_t b, rc_vector_t *x)
Finds a least-squares solution to the system Ax=b for non-square A using QR decomposition method.
Definition: algebra.c:442
int rc_algebra_lin_system_solve(rc_matrix_t A, rc_vector_t b, rc_vector_t *x)
Solves Ax=b for given matrix A and vector b.
Definition: algebra.c:349
int rc_algebra_invert_matrix_inplace(rc_matrix_t *A)
Inverts matrix A in place.
Definition: algebra.c:335
Struct containing the state of a matrix and a pointer to dynamically allocated memory to hold its con...
Definition: matrix.h:32
Struct containing the state of a vector and a pointer to dynamically allocated memory to hold its con...
Definition: vector.h:41