Module iron_shapes::math[][src]

Math helper functions.

Traits

FastInvSqrt

Implement the fast approximate computation of '1/sqrt(x)' for a type.

Functions

fast_invsqrt_32

Fast approximate computation of 1/sqrt(x). The error should be below 0.2%.

fast_invsqrt_64

Fast approximate computation of 1/sqrt(x). The error should be below 0.2%.

int_sqrt_floor

Compute square root of integers using Newtons method. Returns the biggest integer which is smaller or equal to the actual square root of n. Similar to (i as f64).sqrt().floor() as T but without type conversions.