Function coord_transforms::d2::cartesian2logpolar
source · Expand description
Converts 2-d cartesian coordinates to 2-d log polar coordinates
Arguments
cart_vec
- Vector2 reference to the cartesian vector (x, y)
Return Value
nalgebra::Vector2<f64>
- rho, theta (in radians)
Formula
- r = log(sqrt( x^2 + y^2 ))
- theta = arctan(y / x)