As I already posted above, you can either use approximation formulas, use a lookup table with pre-calculated values, or write your own custom COM-DLL that provides math functions.
_________________________
There are two types of vessels, submarines and targets.