mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-21 02:13:33 +08:00
New tests.
This commit is contained in:
@@ -15,6 +15,9 @@ int main()
|
|||||||
assert(fabs(v1.norm() - 7.416198487095663f) < 1e-5);
|
assert(fabs(v1.norm() - 7.416198487095663f) < 1e-5);
|
||||||
Vector<float, 5> v2(data2);
|
Vector<float, 5> v2(data2);
|
||||||
assert(fabs(v1.dot(v2) - 130.0f) < 1e-5);
|
assert(fabs(v1.dot(v2) - 130.0f) < 1e-5);
|
||||||
|
v2.normalize();
|
||||||
|
Vector<float, 5> v3(v2);
|
||||||
|
assert(v2 == v3);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user