My knowledge of mathematics says to me that if I attempt to perform (-5)^0.5, the result should be undefined, or some imaginary number (in this case ~ -2.23i). When I attempt to do this with rust:

`-5.0f64.powf(0.5f64)`

The result is `-2.23606797749979`

, without anything to indicate that this is an imaginary number and would normally be undefined.

Is there an efficient way to determine whether or not `powf()`

results in an imaginary number/undefined result?