ARGoS
Large-scale robot simulations
home
about
download
documentation
examples
user manual
dev manual
API
forum
publications
core
utility
math
matrix
squarematrix.cpp
Go to the documentation of this file.
1
9
#include "
squarematrix.h
"
10
11
namespace
argos
{
12
13
/****************************************/
14
/****************************************/
15
16
template
<>
17
Real
CSquareMatrix<1>::GetDeterminant
()
const
{
18
return
m_pfValues[0];
19
}
20
21
/****************************************/
22
/****************************************/
23
24
template
<>
25
Real
CSquareMatrix<2>::GetDeterminant
()
const
{
26
return
m_pfValues[0] * m_pfValues[3] - m_pfValues[2] * m_pfValues[1];
27
}
28
29
/****************************************/
30
/****************************************/
31
32
template
<>
33
CSquareMatrix<2>
CSquareMatrix<2>::GetCofactorMatrix
()
const
{
34
Real
pfValues[] = {m_pfValues[3], -m_pfValues[2], -m_pfValues[1], m_pfValues[0]};
35
return
CSquareMatrix<2>
(pfValues);
36
}
37
38
/****************************************/
39
/****************************************/
40
}
Real
float Real
Collects all ARGoS code.
Definition:
datatypes.h:39
squarematrix.h
argos
The namespace containing all the ARGoS related code.
Definition:
ci_actuator.h:12
argos::CSquareMatrix< 2 >
argos::CSquareMatrix::GetDeterminant
Real GetDeterminant() const
Definition:
squarematrix.h:62