117 Commits

Author SHA1 Message Date
Daniel Agar
f1bee775a0 use default constructors and skip unnecessary initialization 2018-08-31 08:11:02 +02:00
Daniel Agar
03a3e3ad46 helper_functions add wrap_2pi 2018-06-10 10:56:45 +02:00
James Goppert
e7c95fa027 Fix README/cmake format. 2018-03-28 00:11:03 -04:00
James Goppert
d142ac234c Fix coverage and bug in matrix equal test. 2018-03-28 00:09:01 -04:00
Matthias Grob
f835d39017 Quaternion/Vector: Small refactor for review: put more comments, switched type conversions, took out default destination vector because confusing 2017-12-04 15:34:13 +01:00
Matthias Grob
af2610ec04 Test: added check for quaternion vector to vector rotation constructor
including all the parallel vector corner cases
2017-12-04 15:34:13 +01:00
Matthias Grob
d513c94f85 Test: added check for Vector.norm_squared() 2017-12-04 15:34:13 +01:00
Matthias Grob
41ad2bdea5 Matrix: added copyToRaw method to allow copying to a pointer
because most uORB messages still contain all components of a vector one by one after each other
2017-11-17 09:30:56 +01:00
Matthias Grob
308a6c91cb Test: added copyTo tests for Vector3, Quaternion and Matrix including clolumn-major order 2017-11-16 04:42:54 +01:00
Matthias Grob
3bd94fcd6f Test vector: structured & commented, added normalize and unit_or_zero tests, removed duplicate data preparation 2017-11-06 17:58:52 +01:00
Matthias Grob
d259ab2108 Test: add Quaternion rotate() test that catches non-commutating rotations 2017-10-17 17:37:23 +02:00
Matthias Grob
0a772f59dd Quaternion: added direct efficient body z-axis calculation with test 2017-09-26 11:20:56 +02:00
James Goppert
e595ebb9a7 Switch to Hamilton quaternions and add Cholesky decomposition. 2017-08-31 11:09:20 +02:00
Pavel Kirienko
e09cf12e2e Removed all uses of C library from tests 2017-03-17 12:18:39 -04:00
Pavel Kirienko
b74749fb61 Un-poisoned fabs 2017-03-17 12:18:39 -04:00
Pavel Kirienko
8af7b8c130 Poisoned the C library identifiers 2017-03-17 12:18:39 -04:00
Daniel Agar
cf924956d7 test vector3 using matrix::isEqual 2017-02-24 20:47:41 -05:00
Daniel Agar
cfa68c2196 clang-tidy trivial cleanup 2017-02-24 20:47:41 -05:00
Daniel Agar
5f2f6f0308 rename cmake "Profile" to "Coverage" and add builds 2017-02-24 20:47:41 -05:00
Daniel Agar
f00edc9442 update to astyle 2.06 and fix formatting 2017-02-24 20:47:41 -05:00
Daniel Agar
68c7cc5bfd Quaternion add copyTo 2017-02-24 20:47:41 -05:00
James Goppert
63aea23f9e Add cholesky decomp, Closes #30, and dynamic print buf 2017-02-03 17:54:16 -05:00
James Goppert
a154e14439 Fix coverage for inverse. 2017-02-03 17:24:15 -05:00
Matthias Grob
47c0a93140 Quaternion: added tests for the corner cases of Dcm to quaternion conversion 2016-12-14 18:25:06 +01:00
James Goppert
74a120f554 Handle some divide by zero edge cases on init. 2016-11-30 01:27:48 -05:00
James Goppert
bf69be7f17 Fix formatting. 2016-11-22 10:07:08 -05:00
James Goppert
f3e478cbff Fix matrix inverse pivotting logic. 2016-11-22 10:04:45 -05:00
James Goppert
34fccdd680 add renormalize method (#32) 2016-11-02 12:10:30 -04:00
James Goppert
db4374882b Fix attitude tests. 2016-08-18 16:54:43 -04:00
James Goppert
3aeb099249 Revert "Use Hamilton quaternion definition."
This reverts commit 19554c4470cd6322ffd18cb20a96485940f226b6.
2016-08-18 16:51:00 -04:00
James Goppert
4653626d92 Format. 2016-08-16 19:04:23 -04:00
James Goppert
0eb8aa0c0b Support more of mathlib function for easier swap in px4. 2016-08-16 19:03:54 -04:00
James Goppert
262a715d90 Fix some when building in px4. 2016-08-16 12:37:41 -04:00
James Goppert
9af58f7e08 Coverage fix. 2016-08-16 12:00:37 -04:00
James Goppert
37b00b0880 Added check or consistency of dcm and quaternion product. 2016-08-16 11:37:45 -04:00
James Goppert
1a87564b85 Added dcm quat prod consistency check. 2016-08-16 11:33:56 -04:00
James Goppert
4f13809420 Added axis angle accessors, removed == operator. 2016-08-16 11:05:01 -04:00
James Goppert
19554c4470 Use Hamilton quaternion definition. 2016-08-16 03:59:06 -04:00
James Goppert
e6a6b4680c Use quaternion multiplaction for quaternion derivative. 2016-08-16 01:03:23 -04:00
James Goppert
9353e4cb64 Fix bugs in axis angle. 2016-07-06 01:37:50 -04:00
James Goppert
0f41af271a Added axis angle attitude representation. (#25) 2016-07-05 20:59:42 -04:00
James Goppert
dd8ff8db12 Made coverage html output optional. 2016-05-09 12:13:00 -04:00
James Goppert
061609322a Added command line output for coverage. 2016-05-09 12:01:20 -04:00
James Goppert
155202f6b0 Found a few coverage gaps with local coverage testing. 2016-05-09 11:49:45 -04:00
James Goppert
8b7eae3b4a Merge branch 'maetugr-fix2' of https://github.com/MaEtUgR/Matrix into MaEtUgR-maetugr-fix2 2016-05-09 11:24:28 -04:00
James Goppert
bd8420fcf6 Added example of assignment to already created object. 2016-05-09 11:12:06 -04:00
MaEtUgR
b2eb4d13d8 Matrix.setCol off by one bug fixed
The Column Vector you are copying from, only has one Column and it is indexed by 0 not 1.
I also completed the unit test stub that would have found this bug.
2016-05-05 13:18:51 +02:00
Matthias Grob
65679fbcbb Features and fixes
* added the trace function for a SquareMatrix

* added Vector3.hat() and it's counterpart Dcm.vee()
for skewsymskew symmetric matrix operations in relation to the cross product
see https://en.wikipedia.org/wiki/Hat_operator

* Matrix::write_string produced runtime errors when I used it in PX4 posix simulation, i simplified it

* a Matrix3f is a SquareMatrix

* added tests for SquareMatrix.trace, Vector3.hat and Dcm.vee

* added a test for quaternion initialisation from array

* preventing buffer overflows in Matrix.write_string method
2016-04-28 15:16:36 -04:00
James Goppert
711b57d2d4 Added unit function that returns normalized vector. 2016-03-15 18:09:48 -04:00
James Goppert
0e14e11183 Added support for attitude_estimator_q functions. 2016-03-15 06:35:13 -04:00