MCPcopy Create free account
hub / github.com/TheAlgorithms/Java / fpart

Method fpart

src/main/java/com/thealgorithms/geometry/WusLine.java:212–214  ·  view source on GitHub ↗

Returns the fractional part of a number. @param x the input number @return the fractional part (always in range [0.0, 1.0))

(double x)

Source from the content-addressed store, hash-verified

210 * @return the fractional part (always in range [0.0, 1.0))
211 */
212 private static double fpart(double x) {
213 return x - Math.floor(x);
214 }
215
216 /**
217 * Returns the reverse fractional part of a number (1 - fractional part).

Callers 4

processEndpointMethod · 0.95
addEndpointPixelsMethod · 0.95
drawMainLineMethod · 0.95
rfpartMethod · 0.95

Calls 1

floorMethod · 0.45

Tested by

no test coverage detected