Blame view

src/ExternLib/Magnitude/magnitude.hh 434 Bytes
fbe3c2bb   Benjamin Renard   First commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/**
 * Magnitude.hh
 *
 *  Created on: 31 oct. 2012
 *      Author: AKKA IS
 */

#ifndef MAGNITUDE_HH_
#define MAGNITUDE_HH_

#include <vector>

/**
 * @bried Compute the magnitude of el
 * @return  sqrtf(vec[0] * vec[0] + vec[1] * vec[1] + vec[2] * vec[2]);
 */
float magnitude(const std::vector<float>& el);

ed4f5039   Benjamin Renard   Add double, long ...
19
20
21
22
double magnitude(const std::vector<double>& vec);

int magnitude(const std::vector<int>& vec);

fbe3c2bb   Benjamin Renard   First commit
23
#endif /* MAGNITUDE_HH_ */