kritz
4f3565da94
Add asserts ( #115 )
...
* Add asserts
* Type cast literals
* asserts for indexing vectors
* include assert
* Fix accessing elements outside of slice
5 years ago
kritz
2f6398168d
Add several functions that are useful for coavriance matrices: ( #114 )
...
* uncorrelateCovariance
* uncorrelateCovarianceSetVariance
* makeBlockSymmetric
* makeRowColSymmetric
* isBlockSymmetric
* isRowColSymmetric
5 years ago
kritz
5cbcf6035a
Set Matrix's col amd row to single value ( #113 )
5 years ago
kritz
ef442fab92
Getter function for the diag elements of slice ( #112 )
5 years ago
kritz
de6a2d31ff
Slice assign value ( #111 )
...
* Assign value to slice
* Readme for formatting
5 years ago
Daniel Agar
a8009a36a3
Quaternion multiply inline return
5 years ago
Daniel Agar
dba84236cb
Vector3f cross product directly return result ( #109 )
5 years ago
Matthias Grob
de85dcff97
Vector: switch read only functions to const ( #108 )
5 years ago
Julien Lecoeur
a172c3cdac
Add implementation of pseudo-inverse ( #102 )
...
* Fix compilation error
* Add implementation of pseudo-inverse
The implementation is based on this publication:
Courrieu, P. (2008). Fast Computation of Moore-Penrose Inverse Matrices, 8(2), 25–29. http://arxiv.org/abs/0804.4809
It is a fully templated implementation to guaranty type correctness.
* Add tests for pseudoinverse
* Apply suggestions from code review
Co-Authored-By: Mathieu Bresciani <brescianimathieu@gmail.com>
* Adapt fullRankCholesky tolerance to type
* Add pseudoinverse test with effectiveness matrix
* Fix coverage
* Fix rebase issue
* Fix SquareMatrix test, add null Matrix test
5 years ago
Daniel Agar
cd185c995b
add braces around statements and cleanup formatting ( #107 )
5 years ago
kritz
38e966cea1
Add min, max, constrain function for Matrix ( #105 )
...
* Add min, max, constrain function for Matrix
* Set individual elements to nan in constrain
* Deal with NANs
5 years ago
kritz
93d42947b6
Add test for setting Quaternion to Identity ( #104 )
5 years ago
Julian Kent
9f46483951
Fix GCC-4.8 bug
5 years ago
Julian Kent
445f58d484
Fix weird C preprocessor conflicts ( #101 )
5 years ago
Julian Kent
215203fc6f
Automatic Differentiation 'Dual' Type ( #100 )
...
* Dual numbers initial implementation
* Add test coverage, with partial derivative example
* Add Jacobian test, fix small issues
* Improve test to demonstrate non-square jacobian
* Better naming for collectReals/Derivatives
* Improve comments
* Potential GCC 4.8 bug workaround
* Add fallback workaround for non-IEEE float platforms
5 years ago
Julian Kent
92d1c8761e
More features: longerThan, norm, copyTo and slice on a Slice ( #97 )
...
* Allow slices of slices, add longerThan to Vector/Slice
5 years ago
Matthias Grob
740324cf1e
Make all array constructors explicit ( #99 )
...
* Make all array constructors explicit
to avoid accidental implicit casts like e.g.
Vector3f v = 0;
assigning nullpointer content.
5 years ago
Julian Kent
7b34c1c51d
Enable branch coverage
5 years ago
Matthias Grob
973999a4d3
Fix some template type conversions and style
5 years ago
Matthias Grob
c34e8dc98f
helper: consider matrices with the same NANs and INFINITYs equal
...
to simplify bulk checks when these values are expected
5 years ago
Matthias Grob
bbaa93880b
helper: consider NAN equal to NAN such that vectors can be compared exactly
5 years ago
Matthias Grob
33a629105c
Matrix: add proper print function testing
...
Before the print function was just implicitly called somewhere
and that's why we had 100% line coverage. With this we have actual
testing of the functions.
5 years ago
Matthias Grob
b0b7d7229a
Multiplication test: fix division resulting in NAN
5 years ago
Matthias Grob
3747232724
LeastSquaresSolver: Fix nasty GCC compile optimization error
...
The original implementation with no wrapping on size_t is more readable
but the compiler errors with:
internal compiler error: in trunc_int_for_mode, at explow.c:55
I read up and it's apparently a loop optimization problem.
Inspired by https://stackoverflow.com/a/27224697/6326048
I used a far less readable implementation that works fine and
wrote a comment to explain it.
5 years ago
Matthias Grob
5844b0e46e
Implement one float equality check and use it everywhere
5 years ago
Matthias Grob
1e80807e8e
test: Add uncovered equality checks with NAN and INFINITE
5 years ago
Matthias Grob
a374f37a54
Include helper_functions like all other library components
5 years ago
James Goppert
60c9c99dcc
Fix type for division.
5 years ago
Julian Kent
b4714e2ed2
Don't lose array sizes in copyTo
5 years ago
Julian Kent
51d2f9f0dc
Remove direct access to internal data
5 years ago
Julian Kent
18218c8f9c
Test non-square matrix multiplication ( #91 )
...
* Test non-square matrix multiplication
5 years ago
Julian Kent
b817e8677d
Add helpers based on Slice: row(), col(), xy()
5 years ago
Julian Kent
82d565f4d9
Add support for Slice to Matrix, SquareMatrix, Vector
5 years ago
Julian Kent
af1378cc55
Add Slice class
5 years ago
Julian Kent
15865b741c
Help compiler with name resolution to avoid overload mixups
6 years ago
Julian Kent
03ffd696a6
Replace pow with sqrt
6 years ago
Julian Kent
22bf63cb71
A smaller codesize wrap, since it gets inlined in many places
6 years ago
Matthias Grob
74ace7d1d5
helper test: cover wrap close to limits cases ( #84 )
6 years ago
Tanja Baumann
26fd962cbe
fix bug in matrix wrap function ( #83 )
6 years ago
Julian Kent
4a4309327a
better API comment
...
Co-Authored-By: Julian Oes <julian@oes.ch>
6 years ago
Matthias Grob
31450c407c
Matrix: use existing print() if isEqual test fails
6 years ago
Matthias Grob
938274fce5
helper test: add extensive wrap tests
6 years ago
Matthias Grob
315010bae1
helper_functions: generalize wrap function to any range
6 years ago
Matthias Grob
007c7c58c4
fix math defines to have M_PI and M_TWOPI
6 years ago
Martina Rivizzigno
cc084e0791
matrix: add method to check all values are nan ( #82 )
6 years ago
kritz
84b3da227c
Canonical Quaternion with tests ( #81 )
6 years ago
Matthias Grob
56b069956d
slice test: fix trailing whitespace style
6 years ago
Oskar Weigl
5ccfa74c72
Fix const error
6 years ago
Oskar Weigl
eea6b59973
Implement slice as copy loop
6 years ago
Oskar Weigl
93375fbd3c
Fix copy-paste error
6 years ago