replace strtod with strtof
replace sqrt, hypot, sin, cos with float variants (ie sqrtf, hypotf, sinf, cosf)