Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F64195798
kitemath.h
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sat, May 25, 06:01
Size
1 KB
Mime Type
text/x-c
Expires
Mon, May 27, 06:01 (2 d)
Engine
blob
Format
Raw Data
Handle
17866304
Attached To
R1517 test_package
kitemath.h
View Options
#ifndef KITEMATH_H
#define KITEMATH_H
#include "casadi/casadi.hpp"
enum
IntType
{
RK4
,
CVODES
,
CHEBYCHEV
};
namespace
kmath
{
/** quaternion arithmetic */
casadi
::
SX
quat_multiply
(
const
casadi
::
SX
&
q1
,
const
casadi
::
SX
&
q2
);
casadi
::
SX
quat_inverse
(
const
casadi
::
SX
&
q
);
/** collection of custom functions */
casadi
::
SX
heaviside
(
const
casadi
::
SX
&
x
,
const
double
K
);
double
deg2rad
(
const
double
&
deg
){
return
(
M_PI
/
180
)
*
deg
;}
/** integration */
casadi
::
SX
rk4_symbolic
(
const
casadi
::
SX
&
X
,
const
casadi
::
SX
&
U
,
casadi
::
Function
&
func
,
const
casadi
::
SX
&
h
);
/** @brief: compute Chebyshev collocation points for a given interval */
void
cheb
(
casadi
::
DM
&
CollocPoints
,
casadi
::
DM
&
DiffMatrix
,
const
unsigned
&
N
,
const
std
::
pair
<
double
,
double
>
interval
);
casadi
::
SX
mat_func
(
const
casadi
::
SX
&
matrix_in
,
casadi
::
Function
&
func
);
casadi
::
SX
mat_dynamics
(
const
casadi
::
SX
&
arg_x
,
const
casadi
::
SX
&
arg_u
,
casadi
::
Function
&
func
);
}
#endif
// KITEMATH_H
Event Timeline
Log In to Comment