cross_implementation.h
Go to the documentation of this file.
1
8
#ifndef _CLASS_CROSSIMP
9
#define _CLASS_CROSSIMP
10
11
#include "
ndcurves/fwd.h
"
12
13
namespace
ndcurves
{
14
inline
15
Eigen::Vector3d
cross
(
const
Eigen::VectorXd& a,
const
Eigen::VectorXd& b){
16
Eigen::Vector3d c;
17
c << a[1]*b[2] - a[2]*b[1], a[2]*b[0] - a[0]*b[2], a[0]*b[1] - a[1]*b[0] ;
18
return
c;
19
}
20
21
inline
22
Eigen::Vector3d
cross
(
const
Eigen::Vector3d& a,
const
Eigen::Vector3d& b){
23
return
a.cross(b);
24
}
25
26
inline
27
Eigen::Vector3f
cross
(
const
Eigen::Vector3f& a,
const
Eigen::Vector3f& b){
28
return
a.cross(b);
29
}
30
31
template
<
typename
N,
bool
S>
32
linear_variable<N,S>
cross
(
const
linear_variable<N,S>
& a,
const
linear_variable<N,S>
& b){
33
return
a.
cross
(b);
34
}
35
}
// namespace ndcurves
36
#endif //_CLASS_CROSSIMP
ndcurves::cross
Eigen::Vector3d cross(const Eigen::VectorXd &a, const Eigen::VectorXd &b)
Definition:
cross_implementation.h:15
fwd.h
forward declaration of all curves class
ndcurves
Definition:
bernstein.h:20
ndcurves::linear_variable::cross
linear_variable_t cross(const linear_variable_t &other) const
Compute the cross product of the current linear_variable and the other. This method of course only ma...
Definition:
linear_variable.h:139
ndcurves::linear_variable
Definition:
fwd.h:55
include
ndcurves
cross_implementation.h
Generated by
1.8.17