Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/RobTillaart/Arduino
/ eccentricity
Method
eccentricity
libraries/ellipse/ellipse.cpp:79–85 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
77
78
79
float ellipse::eccentricity()
80
{
81
if (_a == _b) return 0; // quick circle check.
82
float x = _a * _a - _b * _b;
83
if (x < 0) x = -1 * x;
84
return sqrt(x)/ _a;
85
}
86
87
88
bool ellipse::isCircle(float epsilon)
Callers
1
unittest
Function · 0.80
Calls
1
sqrt
Function · 0.85
Tested by
1
unittest
Function · 0.64