|
- #ifndef LICKS_LINALG_H
- #define LICKS_LINALG_H
-
- typedef struct {
- double x,y,z;
- } vector3d;
-
- typedef struct {
- double x[3],y[3],z[3];
- } matrix3x3d;
-
- extern void copy_vector3d(vector3d *v1, vector3d *v2);
- extern void add_vector3d(vector3d *v1, vector3d *v2, vector3d *result);
- extern void sub_vector3d(vector3d *v1, vector3d *v2, vector3d *result);
- extern void scalar_mult_vector3d(vector3d *v1, double s, vector3d *result);
- extern void cross_mult_vector3d(vector3d *v1, vector3d *v2, vector3d *result);
- extern void matrix_mult_vector3d(vector3d *v1, matrix3x3d *M, vector3d *result);
- extern void rot_x_vector3d(vector3d *v, double a, vector3d *result);
- extern void rot_y_vector3d(vector3d *v, double a, vector3d *result);
- extern void rot_z_vector3d(vector3d *v, double a, vector3d *result);
-
- #endif
|