#include <math.h>
#include <string.h>
#include <gandalf/linalg/2x2matrixf.h>
#include <gandalf/common/misc_error.h>
#include <gandalf/linalg/matf_symmetric.h>
#include <gandalf/linalg/matf_diagonal.h>
#include <gandalf/linalg/matf_scaledI.h>
#include <gandalf/linalg/matf_triangular.h>
#include <gandalf/common/endian_io.h>
Defines | |
#define | GAN_MATTYPE Gan_Matrix22_f |
#define | GAN_MATRIX_TYPE Gan_Matrix_f |
#define | GAN_SQUMATRIX_TYPE Gan_SquMatrix_f |
#define | GAN_VECTOR_TYPE Gan_Vector_f |
#define | GAN_MAT_ELEMENT_TYPE GAN_FLOAT |
#define | GAN_REALTYPE float |
#define | GAN_FWRITE_LENDIAN gan_fwrite_lendian_f32 |
#define | GAN_FREAD_LENDIAN gan_fread_lendian_f32 |
#define | GAN_VECTYPE1 Gan_Vector2_f |
#define | GAN_VECTYPE2 Gan_Vector2_f |
#define | GAN_MATTYPEL Gan_Matrix22_f |
#define | GAN_MATTYPER Gan_Matrix22_f |
#define | GAN_SQUMATTYPEL Gan_SquMatrix22_f |
#define | GAN_SQUMATTYPER Gan_SquMatrix22_f |
#define | GAN_MAT_FPRINT gan_mat22f_fprint |
#define | GAN_MAT_PRINT gan_mat22f_print |
#define | GAN_MAT_FSCANF gan_mat22f_fscanf |
#define | GAN_MAT_FWRITE gan_mat22f_fwrite |
#define | GAN_MAT_FREAD gan_mat22f_fread |
#define | GAN_MAT_ZERO_Q gan_mat22f_zero_q |
#define | GAN_MAT_ZERO_S gan_mat22f_zero_s |
#define | GAN_MAT_COPY_Q gan_mat22f_copy_q |
#define | GAN_MAT_COPY_S gan_mat22f_copy_s |
#define | GAN_MAT_SCALE_Q gan_mat22f_scale_q |
#define | GAN_MAT_SCALE_I gan_mat22f_scale_i |
#define | GAN_MAT_SCALE_S gan_mat22f_scale_s |
#define | GAN_MAT_DIVIDE_Q gan_mat22f_divide_q |
#define | GAN_MAT_DIVIDE_I gan_mat22f_divide_i |
#define | GAN_MAT_DIVIDE_S gan_mat22f_divide_s |
#define | GAN_MAT_NEGATE_Q gan_mat22f_negate_q |
#define | GAN_MAT_NEGATE_I gan_mat22f_negate_i |
#define | GAN_MAT_NEGATE_S gan_mat22f_negate_s |
#define | GAN_MAT_UNIT_Q gan_mat22f_unit_q |
#define | GAN_MAT_UNIT_I gan_mat22f_unit_i |
#define | GAN_MAT_UNIT_S gan_mat22f_unit_s |
#define | GAN_MAT_ADD_Q gan_mat22f_add_q |
#define | GAN_MAT_ADD_I1 gan_mat22f_add_i1 |
#define | GAN_MAT_ADD_I2 gan_mat22f_add_i2 |
#define | GAN_MAT_INCREMENT gan_mat22f_increment |
#define | GAN_MAT_ADD_S gan_mat22f_add_s |
#define | GAN_MAT_SUB_Q gan_mat22f_sub_q |
#define | GAN_MAT_SUB_I1 gan_mat22f_sub_i1 |
#define | GAN_MAT_SUB_I2 gan_mat22f_sub_i2 |
#define | GAN_MAT_DECREMENT gan_mat22f_decrement |
#define | GAN_MAT_SUB_S gan_mat22f_sub_s |
#define | GAN_VEC_OUTER_Q gan_vec22f_outer_q |
#define | GAN_VEC_OUTER_S gan_vec22f_outer_s |
#define | GAN_MAT_MULTV_Q gan_mat22f_multv2_q |
#define | GAN_MAT_MULTV_S gan_mat22f_multv2_s |
#define | GAN_MATT_MULTV_Q gan_mat22Tf_multv2_q |
#define | GAN_MATT_MULTV_S gan_mat22Tf_multv2_s |
#define | GAN_MAT_LMULTMT_Q gan_mat22f_lmultm22T_q |
#define | GAN_MAT_LMULTMT_S gan_mat22f_lmultm22T_s |
#define | GAN_MAT_RMULTM_Q gan_mat22f_rmultm22_q |
#define | GAN_MAT_RMULTM_S gan_mat22f_rmultm22_s |
#define | GAN_MAT_RMULTMT_Q gan_mat22f_rmultm22T_q |
#define | GAN_MAT_RMULTMT_S gan_mat22f_rmultm22T_s |
#define | GAN_MAT_LMULTMT_SYM_Q gan_mat22f_lmultm22T_sym_q |
#define | GAN_MAT_LMULTMT_SYM_S gan_mat22f_lmultm22T_sym_s |
#define | GAN_MAT_RMULTMT_SYM_Q gan_mat22f_rmultm22T_sym_q |
#define | GAN_MAT_RMULTMT_SYM_S gan_mat22f_rmultm22T_sym_s |
#define | GAN_MAT_SLMULTT_Q gan_mat22f_slmultT_q |
#define | GAN_MAT_SLMULTT_S gan_mat22f_slmultT_s |
#define | GAN_MAT_SRMULTT_Q gan_mat22f_srmultT_q |
#define | GAN_MAT_SRMULTT_S gan_mat22f_srmultT_s |
#define | GAN_MAT_LMULTS_Q gan_mat22f_lmults22_q |
#define | GAN_MAT_LMULTS_S gan_mat22f_lmults22_s |
#define | GAN_MAT_RMULTS_Q gan_mat22f_rmults22_q |
#define | GAN_MAT_RMULTS_S gan_mat22f_rmults22_s |
#define | GAN_SYMMATL_LRMULT_Q gan_symmat22f_lrmultm22T_q |
#define | GAN_SYMMATL_LRMULT_S gan_symmat22f_lrmultm22T_s |
#define | GAN_SYMMATR_LRMULT_Q gan_symmat22f_lrmultm22_q |
#define | GAN_SYMMATR_LRMULT_S gan_symmat22f_lrmultm22_s |
#define | GAN_MAT_LMULTL_Q gan_mat22f_lmultl22_q |
#define | GAN_MAT_LMULTL_S gan_mat22f_lmultl22_s |
#define | GAN_MAT_LMULTL_I gan_mat22f_lmultl22_i |
#define | GAN_MAT_LMULTLI_Q gan_mat22f_lmultl22I_q |
#define | GAN_MAT_LMULTLI_S gan_mat22f_lmultl22I_s |
#define | GAN_MAT_LMULTLI_I gan_mat22f_lmultl22I_i |
#define | GAN_MAT_LMULTLT_Q gan_mat22f_lmultl22T_q |
#define | GAN_MAT_LMULTLT_S gan_mat22f_lmultl22T_s |
#define | GAN_MAT_LMULTLT_I gan_mat22f_lmultl22T_i |
#define | GAN_MAT_LMULTLIT_Q gan_mat22f_lmultl22IT_q |
#define | GAN_MAT_LMULTLIT_S gan_mat22f_lmultl22IT_s |
#define | GAN_MAT_LMULTLIT_I gan_mat22f_lmultl22IT_i |
#define | GAN_MAT_RMULTL_Q gan_mat22f_rmultl22_q |
#define | GAN_MAT_RMULTL_S gan_mat22f_rmultl22_s |
#define | GAN_MAT_RMULTL_I gan_mat22f_rmultl22_i |
#define | GAN_MAT_RMULTLI_Q gan_mat22f_rmultl22I_q |
#define | GAN_MAT_RMULTLI_S gan_mat22f_rmultl22I_s |
#define | GAN_MAT_RMULTLI_I gan_mat22f_rmultl22I_i |
#define | GAN_MAT_RMULTLT_Q gan_mat22f_rmultl22T_q |
#define | GAN_MAT_RMULTLT_S gan_mat22f_rmultl22T_s |
#define | GAN_MAT_RMULTLT_I gan_mat22f_rmultl22T_i |
#define | GAN_MAT_RMULTLIT_Q gan_mat22f_rmultl22IT_q |
#define | GAN_MAT_RMULTLIT_S gan_mat22f_rmultl22IT_s |
#define | GAN_MAT_RMULTLIT_I gan_mat22f_rmultl22IT_i |
#define | GAN_MAT_SUMSQR_Q gan_mat22f_sumsqr_q |
#define | GAN_MAT_SUMSQR_S gan_mat22f_sumsqr_s |
#define | GAN_MAT_FNORM_Q gan_mat22f_Fnorm_q |
#define | GAN_MAT_FNORM_S gan_mat22f_Fnorm_s |
#define | GAN_MAT_FROM_MAT_Q gan_mat22f_from_matf_q |
#define | GAN_MAT_FROM_MAT_S gan_mat22f_from_matf_s |
#define | GAN_MAT_FROM_SQUMAT_Q gan_mat22f_from_squmatf_q |
#define | GAN_MAT_FROM_SQUMAT_S gan_mat22f_from_squmatf_s |
#define | GAN_SQUMAT_FROM_SQUMAT_Q gan_squmat22f_from_squmatf_q |
#define | GAN_SQUMAT_FROM_SQUMAT_S gan_squmat22f_from_squmatf_s |
#define | GAN_SQUMAT_IDENT_Q gan_mat22f_ident_q |
#define | GAN_SQUMAT_IDENT_S gan_mat22f_ident_s |
#define | GAN_SQUMAT_TPOSE_Q gan_mat22f_tpose_q |
#define | GAN_SQUMAT_TPOSE_S gan_mat22f_tpose_s |
#define | GAN_SQUMAT_TPOSE_I gan_mat22f_tpose_i |
#define | GAN_MAT_SADDT_Q gan_mat22f_saddT_q |
#define | GAN_MAT_SADDT_S gan_mat22f_saddT_s |
#define | GAN_SQUMAT_INVERT gan_mat22f_invert |
#define | GAN_SQUMAT_INVERT_Q gan_mat22f_invert_q |
#define | GAN_SQUMAT_INVERT_S gan_mat22f_invert_s |
#define | GAN_SQUMAT_INVERT_I gan_mat22f_invert_i |
#define | GAN_SQUMAT_ADJOINT_Q gan_mat22f_adjoint_q |
#define | GAN_SQUMAT_ADJOINT_S gan_mat22f_adjoint_s |
#define | GAN_SQUMAT_ADJOINTT_Q gan_mat22f_adjointT_q |
#define | GAN_SQUMAT_ADJOINTT_S gan_mat22f_adjointT_s |
#define | GAN_SQUMAT_DET_Q gan_mat22f_det_q |
#define | GAN_SQUMAT_DET_S gan_mat22f_det_s |
#define | GAN_SQUMAT_TRACE_Q gan_mat22f_trace_q |
#define | GAN_SQUMAT_TRACE_S gan_mat22f_trace_s |
#define | GAN_MATTYPE Gan_SquMatrix22_f |
#define | GAN_MATRIX_TYPE Gan_SquMatrix_f |
#define | GAN_SQUMATRIX_TYPE Gan_SquMatrix_f |
#define | GAN_VECTOR_TYPE Gan_Vector_f |
#define | GAN_MAT_ELEMENT_TYPE GAN_FLOAT |
#define | GAN_REALTYPE float |
#define | GAN_FWRITE_LENDIAN gan_fwrite_lendian_f32 |
#define | GAN_FREAD_LENDIAN gan_fread_lendian_f32 |
#define | GAN_VECTYPE1 Gan_Vector2_f |
#define | GAN_VECTYPE2 Gan_Vector2_f |
#define | GAN_FIXED_MATRIX_TYPE GAN_SYMMETRIC_MATRIX22_F |
#define | GAN_MAT_FPRINT gan_symmat22f_fprint |
#define | GAN_MAT_PRINT gan_symmat22f_print |
#define | GAN_MAT_FSCANF gan_symmat22f_fscanf |
#define | GAN_MAT_FWRITE gan_symmat22f_fwrite |
#define | GAN_MAT_FREAD gan_symmat22f_fread |
#define | GAN_MAT_ZERO_Q gan_symmat22f_zero_q |
#define | GAN_MAT_ZERO_S gan_symmat22f_zero_s |
#define | GAN_MAT_COPY_Q gan_symmat22f_copy_q |
#define | GAN_MAT_COPY_S gan_symmat22f_copy_s |
#define | GAN_MAT_SCALE_Q gan_symmat22f_scale_q |
#define | GAN_MAT_SCALE_S gan_symmat22f_scale_s |
#define | GAN_MAT_SCALE_I gan_symmat22f_scale_i |
#define | GAN_MAT_DIVIDE_Q gan_symmat22f_divide_q |
#define | GAN_MAT_DIVIDE_S gan_symmat22f_divide_s |
#define | GAN_MAT_DIVIDE_I gan_symmat22f_divide_i |
#define | GAN_MAT_NEGATE_Q gan_symmat22f_negate_q |
#define | GAN_MAT_NEGATE_S gan_symmat22f_negate_s |
#define | GAN_MAT_NEGATE_I gan_symmat22f_negate_i |
#define | GAN_MAT_UNIT_Q gan_symmat22f_unit_q |
#define | GAN_MAT_UNIT_S gan_symmat22f_unit_s |
#define | GAN_MAT_UNIT_I gan_symmat22f_unit_i |
#define | GAN_MAT_ADD_Q gan_symmat22f_add_q |
#define | GAN_MAT_ADD_I1 gan_symmat22f_add_i1 |
#define | GAN_MAT_ADD_I2 gan_symmat22f_add_i2 |
#define | GAN_MAT_INCREMENT gan_symmat22f_increment |
#define | GAN_MAT_ADD_S gan_symmat22f_add_s |
#define | GAN_MAT_SUB_Q gan_symmat22f_sub_q |
#define | GAN_MAT_SUB_I1 gan_symmat22f_sub_i1 |
#define | GAN_MAT_SUB_I2 gan_symmat22f_sub_i2 |
#define | GAN_MAT_DECREMENT gan_symmat22f_decrement |
#define | GAN_MAT_SUB_S gan_symmat22f_sub_s |
#define | GAN_MAT_MULTV_Q gan_symmat22f_multv2_q |
#define | GAN_MAT_MULTV_S gan_symmat22f_multv2_s |
#define | GAN_MAT_SUMSQR_Q gan_symmat22f_sumsqr_q |
#define | GAN_MAT_SUMSQR_S gan_symmat22f_sumsqr_s |
#define | GAN_MAT_FNORM_Q gan_symmat22f_Fnorm_q |
#define | GAN_MAT_FNORM_S gan_symmat22f_Fnorm_s |
#define | GAN_SQUMAT_IDENT_Q gan_symmat22f_ident_q |
#define | GAN_SQUMAT_IDENT_S gan_symmat22f_ident_s |
#define | GAN_SQUMAT_INVERT gan_symmat22f_invert |
#define | GAN_SQUMAT_INVERT_Q gan_symmat22f_invert_q |
#define | GAN_SQUMAT_INVERT_S gan_symmat22f_invert_s |
#define | GAN_SQUMAT_INVERT_I gan_symmat22f_invert_i |
#define | GAN_SQUMAT_DET_Q gan_symmat22f_det_q |
#define | GAN_SQUMAT_DET_S gan_symmat22f_det_s |
#define | GAN_SQUMAT_TRACE_Q gan_symmat22f_trace_q |
#define | GAN_SQUMAT_TRACE_S gan_symmat22f_trace_s |
#define | GAN_VEC_OUTER_SYM_Q gan_vec22f_outer_sym_q |
#define | GAN_VEC_OUTER_SYM_S gan_vec22f_outer_sym_s |
#define | GAN_SYMMAT_CHOLESKY gan_symmat22f_cholesky |
#define | GAN_SYMMAT_CHOLESKY_Q gan_symmat22f_cholesky_q |
#define | GAN_SYMMAT_CHOLESKY_S gan_symmat22f_cholesky_s |
#define | GAN_SYMMAT_CHOLESKY_I gan_symmat22f_cholesky_i |
#define | GAN_MATTYPE Gan_SquMatrix22_f |
#define | GAN_MATRIX_TYPE Gan_SquMatrix_f |
#define | GAN_SQUMATRIX_TYPE Gan_SquMatrix_f |
#define | GAN_VECTOR_TYPE Gan_Vector_f |
#define | GAN_MAT_ELEMENT_TYPE GAN_FLOAT |
#define | GAN_REALTYPE float |
#define | GAN_FWRITE_LENDIAN gan_fwrite_lendian_f32 |
#define | GAN_FREAD_LENDIAN gan_fread_lendian_f32 |
#define | GAN_VECTYPE1 Gan_Vector2_f |
#define | GAN_VECTYPE2 Gan_Vector2_f |
#define | GAN_SQUMATTYPEL Gan_SquMatrix22_f |
#define | GAN_SQUMATTYPER Gan_SquMatrix22_f |
#define | GAN_FIXED_MATRIX_TYPE GAN_LOWER_TRI_MATRIX22_F |
#define | GAN_MAT_FPRINT gan_ltmat22f_fprint |
#define | GAN_MAT_PRINT gan_ltmat22f_print |
#define | GAN_MAT_FSCANF gan_ltmat22f_fscanf |
#define | GAN_MAT_FWRITE gan_ltmat22f_fwrite |
#define | GAN_MAT_FREAD gan_ltmat22f_fread |
#define | GAN_MAT_ZERO_Q gan_ltmat22f_zero_q |
#define | GAN_MAT_ZERO_S gan_ltmat22f_zero_s |
#define | GAN_MAT_COPY_Q gan_ltmat22f_copy_q |
#define | GAN_MAT_COPY_S gan_ltmat22f_copy_s |
#define | GAN_MAT_SCALE_Q gan_ltmat22f_scale_q |
#define | GAN_MAT_SCALE_S gan_ltmat22f_scale_s |
#define | GAN_MAT_SCALE_I gan_ltmat22f_scale_i |
#define | GAN_MAT_DIVIDE_Q gan_ltmat22f_divide_q |
#define | GAN_MAT_DIVIDE_S gan_ltmat22f_divide_s |
#define | GAN_MAT_DIVIDE_I gan_ltmat22f_divide_i |
#define | GAN_MAT_NEGATE_Q gan_ltmat22f_negate_q |
#define | GAN_MAT_NEGATE_S gan_ltmat22f_negate_s |
#define | GAN_MAT_NEGATE_I gan_ltmat22f_negate_i |
#define | GAN_MAT_UNIT_Q gan_ltmat22f_unit_q |
#define | GAN_MAT_UNIT_S gan_ltmat22f_unit_s |
#define | GAN_MAT_UNIT_I gan_ltmat22f_unit_i |
#define | GAN_MAT_ADD_Q gan_ltmat22f_add_q |
#define | GAN_MAT_ADD_I1 gan_ltmat22f_add_i1 |
#define | GAN_MAT_ADD_I2 gan_ltmat22f_add_i2 |
#define | GAN_MAT_INCREMENT gan_ltmat22f_increment |
#define | GAN_MAT_ADD_S gan_ltmat22f_add_s |
#define | GAN_MAT_SUB_Q gan_ltmat22f_sub_q |
#define | GAN_MAT_SUB_I1 gan_ltmat22f_sub_i1 |
#define | GAN_MAT_SUB_I2 gan_ltmat22f_sub_i2 |
#define | GAN_MAT_DECREMENT gan_ltmat22f_decrement |
#define | GAN_MAT_SUB_S gan_ltmat22f_sub_s |
#define | GAN_MAT_MULTV_Q gan_ltmat22f_multv2_q |
#define | GAN_MAT_MULTV_S gan_ltmat22f_multv2_s |
#define | GAN_MAT_MULTV_I gan_ltmat22f_multv2_i |
#define | GAN_MATT_MULTV_Q gan_ltmat22Tf_multv2_q |
#define | GAN_MATT_MULTV_S gan_ltmat22Tf_multv2_s |
#define | GAN_MATT_MULTV_I gan_ltmat22Tf_multv2_i |
#define | GAN_MAT_SRMULTT_Q gan_ltmat22f_srmultT_q |
#define | GAN_MAT_SRMULTT_S gan_ltmat22f_srmultT_s |
#define | GAN_MAT_SRMULTT_I gan_ltmat22f_srmultT_i |
#define | GAN_MAT_SLMULTT_Q gan_ltmat22f_slmultT_q |
#define | GAN_MAT_SLMULTT_S gan_ltmat22f_slmultT_s |
#define | GAN_MAT_SLMULTT_I gan_ltmat22f_slmultT_i |
#define | GAN_MAT_SUMSQR_Q gan_ltmat22f_sumsqr_q |
#define | GAN_MAT_SUMSQR_S gan_ltmat22f_sumsqr_s |
#define | GAN_MAT_FNORM_Q gan_ltmat22f_Fnorm_q |
#define | GAN_MAT_FNORM_S gan_ltmat22f_Fnorm_s |
#define | GAN_SQUMAT_IDENT_Q gan_ltmat22f_ident_q |
#define | GAN_SQUMAT_IDENT_S gan_ltmat22f_ident_s |
#define | GAN_SQUMATI_MULTV_Q gan_ltmat22If_multv2_q |
#define | GAN_SQUMATI_MULTV_S gan_ltmat22If_multv2_s |
#define | GAN_SQUMATI_MULTV_I gan_ltmat22If_multv2_i |
#define | GAN_SQUMATIT_MULTV_Q gan_ltmat22ITf_multv2_q |
#define | GAN_SQUMATIT_MULTV_S gan_ltmat22ITf_multv2_s |
#define | GAN_SQUMATIT_MULTV_I gan_ltmat22ITf_multv2_i |
#define | GAN_SQUMAT_INVERT gan_ltmat22f_invert |
#define | GAN_SQUMAT_INVERT_Q gan_ltmat22f_invert_q |
#define | GAN_SQUMAT_INVERT_S gan_ltmat22f_invert_s |
#define | GAN_SQUMAT_INVERT_I gan_ltmat22f_invert_i |
#define | GAN_SQUMAT_DET_Q gan_ltmat22f_det_q |
#define | GAN_SQUMAT_DET_S gan_ltmat22f_det_s |
#define | GAN_SQUMAT_TRACE_Q gan_ltmat22f_trace_q |
#define | GAN_SQUMAT_TRACE_S gan_ltmat22f_trace_s |
#define | GAN_MATTYPE Gan_SquMatrix22_f |
#define | GAN_MATRIX_TYPE Gan_SquMatrix_f |
#define | GAN_SQUMATRIX_TYPE Gan_SquMatrix_f |
#define | GAN_VECTOR_TYPE Gan_Vector_f |
#define | GAN_MAT_ELEMENT_TYPE GAN_FLOAT |
#define | GAN_REALTYPE float |
#define | GAN_MAT_FPRINT gan_ltmat22Tf_fprint |
#define | GAN_MAT_PRINT gan_ltmat22Tf_print |
#define | GAN_MAT_FSCANF gan_ltmat22Tf_fscanf |
#define | GAN_FIXED_MATRIX_TYPE GAN_LOWER_TRI_MATRIX22_F |
#define | gan_ltmat22Tf_fwrite gan_ltmat22f_fwrite |
#define | gan_ltmat22Tf_fread gan_ltmat22f_fread |
Functions | |
Gan_Bool | gan_mat22f_fprint (FILE *fp, const Gan_Matrix22_f *A, const char *prefix, int indent, const char *fmt) |
Print 2x2 matrix to file. | |
Gan_Bool | gan_mat22f_fscanf (FILE *fp, Gan_Matrix22_f *A, char *prefix, int prefix_len) |
Read 2x2 matrix from file. | |
Gan_Matrix22_f | gan_mat22f_fill_s (float XX, float XY, float YX, float YY) |
Fill 2x2 matrix with values. | |
Gan_Matrix22_f * | gan_mat22f_tpose_i (Gan_Matrix22_f *A) |
Transpose 2x2 matrix in-place. | |
Gan_Matrix22_f * | gan_mat22f_invert (Gan_Matrix22_f *A, Gan_Matrix22_f *B, int *error_code) |
Invert 2x2 matrix. | |
Gan_Matrix22_f * | gan_mat22f_adjoint_q (const Gan_Matrix22_f *A, Gan_Matrix22_f *B) |
Compute adjoint of 2x2 matrix. | |
Gan_Matrix22_f * | gan_mat22f_adjointT_q (const Gan_Matrix22_f *A, Gan_Matrix22_f *B) |
Compute adjoint transpose of 2x2 matrix. | |
void | gan_mat22f_get_rows_s (const Gan_Matrix22_f *A, Gan_Vector2_f *p, Gan_Vector2_f *q) |
Extract rows of 2x2 matrix. | |
void | gan_mat22f_get_cols_s (const Gan_Matrix22_f *A, Gan_Vector2_f *p, Gan_Vector2_f *q) |
Extract columns of 2x2 matrix. | |
Gan_Matrix22_f * | gan_mat22f_from_matf_q (const Gan_Matrix_f *A, Gan_Matrix22_f *B) |
Convert generic rectangular matrix to 2x2 matrix structure. | |
Gan_Matrix22_f * | gan_mat22f_from_squmatf_q (const Gan_SquMatrix_f *A, Gan_Matrix22_f *B) |
Convert symmetric matrix to generic 2x2 matrix structure. | |
Gan_SquMatrix22_f * | gan_squmat22f_from_squmatf_q (const Gan_SquMatrix_f *A, Gan_SquMatrix22_f *B) |
Convert symmetric matrix to specific 2x2 symmetric matrix structure. | |
Gan_Bool | gan_symmat22f_fprint (FILE *fp, const Gan_SquMatrix22_f *A, const char *prefix, int indent, const char *fmt) |
Print 2x2 symmetric matrix to file. | |
Gan_Bool | gan_symmat22f_fscanf (FILE *fp, Gan_SquMatrix22_f *A, char *prefix, int prefix_len) |
Read 2x2 symmetric matrix from file. | |
Gan_SquMatrix22_f | gan_symmat22f_fill_s (float XX, float YX, float YY) |
Return 2x2 symmetric matrix filled with values. | |
Gan_SquMatrix22_f * | gan_symmat22f_cholesky (Gan_SquMatrix22_f *A, Gan_SquMatrix22_f *B, int *error_code) |
Compute Cholesky factorisation of symmetric 2x2 matrix. | |
Gan_SquMatrix22_f * | gan_symmat22f_invert (Gan_SquMatrix22_f *A, Gan_SquMatrix22_f *B, int *error_code) |
Compute inverse of symmetric 2x2 matrix. | |
Gan_Matrix22_f * | gan_symmat22f_to_mat22f_q (const Gan_SquMatrix22_f *A, Gan_Matrix22_f *B) |
Convert symmetric 2x2 matrix to generic 2x2 matrix. | |
Gan_Matrix22_f | gan_symmat22f_to_mat22f_s (const Gan_SquMatrix22_f *A) |
Convert symmetric 2x2 matrix to generic 2x2 matrix. | |
Gan_Bool | gan_ltmat22f_fprint (FILE *fp, const Gan_SquMatrix22_f *A, const char *prefix, int indent, const char *fmt) |
Print 2x2 lower triangular matrix to file. | |
Gan_Bool | gan_ltmat22f_fscanf (FILE *fp, Gan_SquMatrix22_f *A, char *prefix, int prefix_len) |
Read 2x2 lower triangular matrix from file. | |
Gan_Bool | gan_ltmat22Tf_fprint (FILE *fp, const Gan_SquMatrix22_f *A, const char *prefix, int indent, const char *fmt) |
Print 2x2 upper triangular matrix to file. | |
Gan_Bool | gan_ltmat22Tf_fscanf (FILE *fp, Gan_SquMatrix22_f *A, char *prefix, int prefix_len) |
Read 2x2 upper triangular matrix from file. | |
Gan_SquMatrix22_f | gan_ltmat22f_fill_s (float XX, float YX, float YY) |
Return 2x2 lower triangular matrix filled with values. | |
Gan_SquMatrix22_f * | gan_ltmat22f_invert (Gan_SquMatrix22_f *A, Gan_SquMatrix22_f *B, int *error_code) |
Compute inverse of lower triangular 2x2 matrix. | |
Gan_Matrix22_f | gan_mat22f_ident_s (void) |
Return fixed size square matrix filled with identity. | |
Gan_Matrix22_f | gan_mat22f_tpose_s (const Gan_Matrix22_f *A) |
Transpose fixed size square matrix. | |
Gan_SquMatrix22_f | gan_mat22f_saddT_s (const Gan_Matrix22_f *A) |
Add matrix to its own transpose. | |
Gan_Matrix22_f | gan_mat22f_invert_s (const Gan_Matrix22_f *A) |
Invert fixed size square matrix. | |
Gan_Matrix22_f | gan_mat22f_adjoint_s (const Gan_Matrix22_f *A) |
Compute adjoint of fixed size square matrix. | |
Gan_Matrix22_f | gan_mat22f_adjointT_s (const Gan_Matrix22_f *A) |
Compute adjoint transpose of fixed size square matrix. | |
float | gan_mat22f_det_s (const Gan_Matrix22_f *A) |
Determinant of square matrix. | |
float | gan_mat22f_trace_s (const Gan_Matrix22_f *A) |
Trace of square matrix. | |
Gan_Bool | gan_mat22f_print (const Gan_Matrix22_f *A, const char *prefix, int indent, const char *fmt) |
Print fixed size matrix to standard output. | |
Gan_Bool | gan_mat22f_fwrite (FILE *fp, const Gan_Matrix22_f *A, gan_uint32 magic_number) |
Write fixed size matrix to file stream. | |
Gan_Bool | gan_mat22f_fread (FILE *fp, Gan_Matrix22_f *A, gan_uint32 *magic_number) |
Read fixed size matrix from file stream. | |
Gan_Matrix22_f | gan_mat22f_zero_s (void) |
Set fixed size matrix to zero. | |
Gan_Matrix22_f | gan_mat22f_copy_s (const Gan_Matrix22_f *A) |
Copy fixed size matrix. | |
Gan_Matrix22_f | gan_mat22f_scale_s (const Gan_Matrix22_f *A, float a) |
Scale fixed size matrix. | |
Gan_Matrix22_f | gan_mat22f_divide_s (const Gan_Matrix22_f *A, float a) |
Divide fixed size matrix by scalar. | |
Gan_Matrix22_f | gan_mat22f_negate_s (const Gan_Matrix22_f *A) |
Negate fixed size matrix. | |
Gan_Matrix22_f * | gan_mat22f_unit_q (Gan_Matrix22_f *A, Gan_Matrix22_f *B) |
Scale matrix to unit norm. | |
Gan_Matrix22_f | gan_mat22f_unit_s (const Gan_Matrix22_f *A) |
Scale matrix to unit norm. | |
Gan_Matrix22_f | gan_mat22f_add_s (const Gan_Matrix22_f *A, const Gan_Matrix22_f *B) |
Add two fixed size matrices. | |
Gan_Matrix22_f | gan_mat22f_sub_s (const Gan_Matrix22_f *A, const Gan_Matrix22_f *B) |
Subtract two fixed size matrices. | |
Gan_Matrix22_f | gan_vec22f_outer_s (const Gan_Vector2_f *p, const Gan_Vector2_f *q) |
Compute the outer product of two fixed size vectors. | |
Gan_Vector2_f | gan_mat22f_multv2_s (const Gan_Matrix22_f *A, const Gan_Vector2_f *p) |
Matrix/vector product. | |
Gan_Vector2_f | gan_mat22Tf_multv2_s (const Gan_Matrix22_f *A, const Gan_Vector2_f *p) |
Matrix/vector product with the matrix transposed. | |
Gan_Matrix22_f | gan_mat22f_lmultm22T_s (const Gan_Matrix22_f *A, const Gan_Matrix22_f *B) |
Left-multiply a matrix by the transpose of another matrix. | |
Gan_Matrix22_f | gan_mat22f_rmultm22_s (const Gan_Matrix22_f *A, const Gan_Matrix22_f *B) |
Right-multiply a matrix by another matrix. | |
Gan_Matrix22_f | gan_mat22f_rmultm22T_s (const Gan_Matrix22_f *A, const Gan_Matrix22_f *B) |
Right-multiply a matrix by the transpose of another matrix. | |
Gan_SquMatrix22_f | gan_mat22f_lmultm22T_sym_s (const Gan_Matrix22_f *A, const Gan_Matrix22_f *B) |
Matrix product producing a symmetric matrix. | |
Gan_SquMatrix22_f | gan_mat22f_rmultm22T_sym_s (const Gan_Matrix22_f *A, const Gan_Matrix22_f *B) |
Matrix product producing a symmetric matrix. | |
Gan_SquMatrix22_f | gan_mat22f_slmultT_s (const Gan_Matrix22_f *A) |
Left-multiply a matrix by its own transpose, producing a symmetric matrix. | |
Gan_SquMatrix22_f | gan_mat22f_srmultT_s (const Gan_Matrix22_f *A) |
Right-multiply a matrix by its own transpose, producing a symmetric matrix. | |
Gan_Matrix22_f | gan_mat22f_lmults22_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Left-multiply a matrix by a symmetric matrix. | |
Gan_Matrix22_f | gan_mat22f_rmults22_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Right-multiply a matrix by a symmetric matrix. | |
Gan_SquMatrix22_f | gan_symmat22f_lrmultm22T_s (const Gan_SquMatrix22_f *A, const Gan_Matrix22_f *B, Gan_Matrix22_f *C) |
Matrix triple product involving symmetric matrices. | |
Gan_SquMatrix22_f | gan_symmat22f_lrmultm22_s (const Gan_SquMatrix22_f *A, const Gan_Matrix22_f *B, Gan_Matrix22_f *C) |
Matrix triple product involving symmetric matrices. | |
Gan_Matrix22_f | gan_mat22f_lmultl22_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Left-multiply a matrix by a lower-triangular matrix. | |
Gan_Matrix22_f | gan_mat22f_lmultl22I_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Left-multiply a matrix by the inverse of a lower-triangular matrix. | |
Gan_Matrix22_f | gan_mat22f_lmultl22T_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Left-multiply a matrix by the transpose of a lower-triangular matrix. | |
Gan_Matrix22_f | gan_mat22f_lmultl22IT_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Left-multiply a matrix by the inverse transpose of a lower-triangular matrix. | |
Gan_Matrix22_f | gan_mat22f_rmultl22_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Right-multiply a matrix by a lower-triangular matrix. | |
Gan_Matrix22_f | gan_mat22f_rmultl22I_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Right-multiply a matrix by the inverse of a lower-triangular matrix. | |
Gan_Matrix22_f | gan_mat22f_rmultl22T_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Right-multiply a matrix by the transpose of a lower-triangular matrix. | |
Gan_Matrix22_f | gan_mat22f_rmultl22IT_s (const Gan_Matrix22_f *A, const Gan_SquMatrix22_f *B) |
Right-multiply a matrix by the inverse transpose of a lower-triangular matrix. | |
float | gan_mat22f_sumsqr_s (const Gan_Matrix22_f *A) |
Returns sum of squares of matrix elements. | |
float | gan_mat22f_Fnorm_s (const Gan_Matrix22_f *A) |
Frobenius norm of matrix. | |
Gan_Matrix22_f | gan_mat22f_from_matf_s (const Gan_Matrix_f *A) |
Convert generic rectangular matrix to fixed size matrix structure. | |
Gan_Matrix22_f | gan_mat22f_from_squmatf_s (const Gan_SquMatrix_f *A) |
Convert square matrix to fixed size matrix structure. | |
Gan_SquMatrix22_f | gan_squmat22f_from_squmatf_s (const Gan_SquMatrix_f *A) |
Convert a square matrix to a symmetric fixed size matrix. | |
Gan_SquMatrix22_f | gan_vec22f_outer_sym_s (const Gan_Vector2_f *p) |
Returns the outer product of vector with itself. | |
Gan_SquMatrix22_f | gan_symmat22f_cholesky_s (const Gan_SquMatrix22_f *A) |
Compute Cholesky factorisation of fixed size symmetric matrix. | |
Gan_SquMatrix22_f | gan_symmat22f_ident_s (void) |
Return fixed size square matrix filled with identity. | |
Gan_SquMatrix22_f | gan_symmat22f_invert_s (const Gan_SquMatrix22_f *A) |
Invert fixed size square matrix. | |
float | gan_symmat22f_det_s (const Gan_SquMatrix22_f *A) |
Determinant of square matrix. | |
float | gan_symmat22f_trace_s (const Gan_SquMatrix22_f *A) |
Trace of square matrix. | |
Gan_Bool | gan_symmat22f_print (const Gan_SquMatrix22_f *A, const char *prefix, int indent, const char *fmt) |
Print fixed size matrix to standard output. | |
Gan_Bool | gan_symmat22f_fwrite (FILE *fp, const Gan_SquMatrix22_f *A, gan_uint32 magic_number) |
Write fixed size matrix to file stream. | |
Gan_Bool | gan_symmat22f_fread (FILE *fp, Gan_SquMatrix22_f *A, gan_uint32 *magic_number) |
Read fixed size matrix from file stream. | |
Gan_SquMatrix22_f | gan_symmat22f_zero_s (void) |
Set fixed size matrix to zero. | |
Gan_SquMatrix22_f | gan_symmat22f_copy_s (const Gan_SquMatrix22_f *A) |
Copy fixed size matrix. | |
Gan_SquMatrix22_f | gan_symmat22f_scale_s (const Gan_SquMatrix22_f *A, float a) |
Scale fixed size matrix. | |
Gan_SquMatrix22_f | gan_symmat22f_divide_s (const Gan_SquMatrix22_f *A, float a) |
Divide fixed size matrix by scalar. | |
Gan_SquMatrix22_f | gan_symmat22f_negate_s (const Gan_SquMatrix22_f *A) |
Negate fixed size matrix. | |
Gan_SquMatrix22_f * | gan_symmat22f_unit_q (Gan_SquMatrix22_f *A, Gan_SquMatrix22_f *B) |
Scale matrix to unit norm. | |
Gan_SquMatrix22_f | gan_symmat22f_unit_s (const Gan_SquMatrix22_f *A) |
Scale matrix to unit norm. | |
Gan_SquMatrix22_f | gan_symmat22f_add_s (const Gan_SquMatrix22_f *A, const Gan_SquMatrix22_f *B) |
Add two fixed size matrices. | |
Gan_SquMatrix22_f | gan_symmat22f_sub_s (const Gan_SquMatrix22_f *A, const Gan_SquMatrix22_f *B) |
Subtract two fixed size matrices. | |
Gan_Vector2_f | gan_symmat22f_multv2_s (const Gan_SquMatrix22_f *A, const Gan_Vector2_f *p) |
Matrix/vector product. | |
float | gan_symmat22f_sumsqr_s (const Gan_SquMatrix22_f *A) |
Returns sum of squares of matrix elements. | |
float | gan_symmat22f_Fnorm_s (const Gan_SquMatrix22_f *A) |
Frobenius norm of matrix. | |
Gan_SquMatrix22_f | gan_ltmat22f_ident_s (void) |
Return fixed size square matrix filled with identity. | |
Gan_Vector2_f | gan_ltmat22If_multv2_s (const Gan_SquMatrix22_f *A, const Gan_Vector2_f *p) |
Computes the product of the inverse of a matrix and a vector. | |
Gan_Vector2_f | gan_ltmat22ITf_multv2_s (const Gan_SquMatrix22_f *A, const Gan_Vector2_f *p) |
Computes the product of the inverse transpose of a matrix and a vector. | |
Gan_SquMatrix22_f | gan_ltmat22f_invert_s (const Gan_SquMatrix22_f *A) |
Invert fixed size square matrix. | |
float | gan_ltmat22f_det_s (const Gan_SquMatrix22_f *A) |
Determinant of square matrix. | |
float | gan_ltmat22f_trace_s (const Gan_SquMatrix22_f *A) |
Trace of square matrix. | |
Gan_Bool | gan_ltmat22f_print (const Gan_SquMatrix22_f *A, const char *prefix, int indent, const char *fmt) |
Print fixed size matrix to standard output. | |
Gan_Bool | gan_ltmat22f_fwrite (FILE *fp, const Gan_SquMatrix22_f *A, gan_uint32 magic_number) |
Write fixed size matrix to file stream. | |
Gan_Bool | gan_ltmat22f_fread (FILE *fp, Gan_SquMatrix22_f *A, gan_uint32 *magic_number) |
Read fixed size matrix from file stream. | |
Gan_SquMatrix22_f | gan_ltmat22f_zero_s (void) |
Set fixed size matrix to zero. | |
Gan_SquMatrix22_f | gan_ltmat22f_copy_s (const Gan_SquMatrix22_f *A) |
Copy fixed size matrix. | |
Gan_SquMatrix22_f | gan_ltmat22f_scale_s (const Gan_SquMatrix22_f *A, float a) |
Scale fixed size matrix. | |
Gan_SquMatrix22_f | gan_ltmat22f_divide_s (const Gan_SquMatrix22_f *A, float a) |
Divide fixed size matrix by scalar. | |
Gan_SquMatrix22_f | gan_ltmat22f_negate_s (const Gan_SquMatrix22_f *A) |
Negate fixed size matrix. | |
Gan_SquMatrix22_f * | gan_ltmat22f_unit_q (Gan_SquMatrix22_f *A, Gan_SquMatrix22_f *B) |
Scale matrix to unit norm. | |
Gan_SquMatrix22_f | gan_ltmat22f_unit_s (const Gan_SquMatrix22_f *A) |
Scale matrix to unit norm. | |
Gan_SquMatrix22_f | gan_ltmat22f_add_s (const Gan_SquMatrix22_f *A, const Gan_SquMatrix22_f *B) |
Add two fixed size matrices. | |
Gan_SquMatrix22_f | gan_ltmat22f_sub_s (const Gan_SquMatrix22_f *A, const Gan_SquMatrix22_f *B) |
Subtract two fixed size matrices. | |
Gan_Vector2_f | gan_ltmat22f_multv2_s (const Gan_SquMatrix22_f *A, const Gan_Vector2_f *p) |
Matrix/vector product. | |
Gan_Vector2_f | gan_ltmat22Tf_multv2_s (const Gan_SquMatrix22_f *A, const Gan_Vector2_f *p) |
Matrix/vector product with the matrix transposed. | |
Gan_SquMatrix22_f | gan_ltmat22f_slmultT_s (const Gan_SquMatrix22_f *A) |
Left-multiply a matrix by its own transpose, producing a symmetric matrix. | |
Gan_SquMatrix22_f | gan_ltmat22f_srmultT_s (const Gan_SquMatrix22_f *A) |
Right-multiply a matrix by its own transpose, producing a symmetric matrix. | |
float | gan_ltmat22f_sumsqr_s (const Gan_SquMatrix22_f *A) |
Returns sum of squares of matrix elements. | |
float | gan_ltmat22f_Fnorm_s (const Gan_SquMatrix22_f *A) |
Frobenius norm of matrix. | |
Gan_Bool | gan_ltmat22Tf_print (const Gan_SquMatrix22_f *A, const char *prefix, int indent, const char *fmt) |
Print fixed size matrix to standard output. |
Part of: Gandalf Library