Andrew Tridgell
0f2f0d4cb2
AP_Math: allow for double EKF build
4 years ago
Michelle Rossouw
f95cb16434
AP_Math: Add Vector2f+z initialiser for Vector3f
4 years ago
Andrew Tridgell
978ea307b0
AP_Math: fixed the value LATLON_TO_CM
...
it didn't have enough digits of precision, and was inconsistent with
LOCATION_SCALING_FACTOR
4 years ago
Andrew Tridgell
aa03afafa7
AP_Math: added matrix3 tofloat and todouble
4 years ago
Andrew Tridgell
9b91cfe4ee
AP_Math: implement double versions of some position control methods
4 years ago
Andrew Tridgell
3a3a30ab22
AP_Math: define postype_t and vectors
4 years ago
Andrew Tridgell
3315ec5acc
AP_Math: added tofloat() and todouble() methods to Vector2 and Vector3
4 years ago
Andrew Tridgell
639570505b
AP_Math: cleanups from Leonards feedback
4 years ago
Andrew Tridgell
566dd8ca8b
AP_Math: cleanup API comments on control code
4 years ago
Andrew Tridgell
86f09cad09
AP_Math: cleanup position control APIs
...
use Vector2 for xy, float for z
4 years ago
Andrew Tridgell
fe4abc521a
AP_Math: make vector3 xy() method return a reference
4 years ago
Josh Henderson
566621e2ba
AP_Math: SCurve check direction.length_squared is_zero
4 years ago
Andrew Tridgell
f19b604a0c
AP_Math: added xy() method on Vector3
...
useful for getting xy length
4 years ago
Rishabh
b9fbf1a661
AP_Math: Update segment_to_segment_dis test
4 years ago
Rishabh
547f0efd57
AP_Math: Add segment to plane intersection function
4 years ago
Pierre Kancir
519b1a6913
AP_Math: correct and increase unit test coverage
...
AP_Math: correct some tests
AP_Math: more vector2 tests
AP_Math: make test_vector2 complete
AP_Math: add initial unittest for vector3
4 years ago
Randy Mackay
b263a1d751
AP_Math: add Quaternion::roll_pitch_difference
4 years ago
Andrew Tridgell
154ae64e63
AP_Math: support either polarity in linear_interpolate()
4 years ago
Peter Barker
d77d258442
AP_Math: add tests for the sqrt_controller
4 years ago
Leonard Hall
5c47c0a131
AP_Math: Fix before squash
4 years ago
Andrew Tridgell
53e5bef0c2
AP_Math: added rotate_xy to Vector3f
...
this makes it easy to rotate a vector3f in xy plane for earth/body
navigation
4 years ago
Leonard Hall
c4bb8baf0c
AP_Math: Control: Add XY S-Curve shapers and shaping limits
4 years ago
Leonard Hall
3530d9121f
AP_Math: minor format fix to SCurve::advance_target_along_track
4 years ago
Tom Pittenger
ba6bb21560
AP_Math: added helper for16bit float conversions
4 years ago
hs293go
93a13bbf0e
AP_Math: Implement tests for the Quaternion class
...
These tests cover Quaternion multiplication, conversion to rotation
matrix, and the optimized rotation operator
4 years ago
hs293go
8bc02ab00b
AP_Math: Implement quaternion vector rotation operator
...
Overloads operator*() with semantics of applying a rotation to a vector, in
common with usage in Eigen/OpenGL. This implementation carries out 30
operations, compared to 58 operations for the q*v*q.inverse() formula
4 years ago
Randy Mackay
bc0da915c4
AP_Math: add SplineCurve library
...
Co-authored-by: Leonard Hall <leonardthall@gmail.com>
includes corrections from peer review
4 years ago
Leonard Hall
af7403f4e9
AP_Math: add SCurve library
...
SCurve const more local variables
rename update to get_jerk_vel_pos_at_time
removed unused update
debug output in SITL
fixes to ensure finished at end of path
fixes including validity check
includes corrections from peer review
4 years ago
Randy Mackay
0e506a71a1
AP_Math: remove control's limit_vector_length
...
these have been moved to Vector2f and Vector3f
4 years ago
Randy Mackay
e2b46d05dc
AP_Math: Vector2,3 get limit_length methods
4 years ago
Leonard Hall
3bb0482795
AP_Math: add update_pos_vel_accel to control
...
also add shape_vel, shape_pos_vel and stopping_distance
also add calculation of kinematic limits
4 years ago
Andrew Tridgell
1f60eb68ec
AP_Math: removed assert calls
...
these waste flash space and do not do us any good
4 years ago
Andrew Tridgell
e884e4c5ac
AP_Math: added fixedwing_turn_rate() helper
4 years ago
Patrick José Pereira
5d7d955378
AP_Math: Add missing const in member functions
...
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
4 years ago
Rishabh
f3d825bebe
AP_Math: Add unit tests for 3-D lines
4 years ago
Rishabh
1262d73071
AP_Math: Add new methods to support 3D avoidance
4 years ago
Rishabh
79d5e432ee
AP_Math: Add new method to extrapolate 3D vector given distance, yaw, pitch
4 years ago
Andrew Tridgell
a1fb0592a9
AP_Math: specialise polyfit for vectors
...
this is needed to get the precision good enough for wide temperature
ranges when summing the resulting polygon coefficients
4 years ago
Andrew Tridgell
999268cbba
AP_Math: fixup matrix algorithms to be in cpp file
...
this fixes an issue where optimize O2 was forced on any file that
included AP_Math.h. It also fixes the test suite for matrix_alg, and
fixes the type handling to be consistent
4 years ago
bugobliterator
3b3e2c01f8
AP_Math: templatize matrix_alg methods
4 years ago
Andrew Tridgell
64d9f43d94
AP_Math: added polygon fitting code
4 years ago
Andrew Tridgell
720f9a1de0
AP_Math: cleanup maths functions
...
use class template instantiation, and cleanup const in matrix code
4 years ago
Leonard Hall
1e38440c83
AP_Math: add control common functions
4 years ago
Andrew Tridgell
d9dbcb17c4
AP_Math: enable constrain value with line numbers on all boards
4 years ago
Peter Barker
c81df7b5ad
AP_Math: add tests for circle-segment-intersection
4 years ago
Peter Barker
f534963413
AP_Math: consolidate error checking
4 years ago
murata
4ffc559ccc
AP_Math: judge isnan judgment before operation
4 years ago
Gone4Dirt
5edae526fd
AP_Math: Add conversion Ams to mAh
4 years ago
Andrew Tridgell
806852c9c3
AP_Math: speedup fill nanf
4 years ago
Andrew Tridgell
cdcf32d22c
AP_Math: added calc_lowpass_alpha_dt()
...
used in several places
4 years ago