(* http://en.wikipedia.org/wiki/Kerr-Newman_metric *) include Deriv;; open Deriv;; let kn bM bQ bJ = let bSI = lc 2.99792458e8, (* Speed of Light *) lc 6.67384e-11, (* Gravitational Constant *) lc 8.9875517873681764e9 (* Coulomb's Constant *) and gu = lc 1., lc 1., lc 1. in let c, bG, ke = if 0<1 then gu else bSI (* choice of units *) in let sq x = x * x and a = bJ / (bM * c) in let rs = lc 2. * bG * bM / sq c and rQ2 = sq bQ * bG * ke / sq (sq c) in fun r th dt dr dth dp -> let r2 = sq r and a2 = sq a and sth2 = sq (Sin th) in let del = r2 - rs * r + a2 + rQ2 and rh2 = r2 + a2 * (lc 1. - sth2) in ( sq (c * dt - a * sth2 * dp) * (del / rh2) - (sq dr / del + sq dth) * rh2 - sq ((r2 + a2) * dp - a * c * dt) * sth2 / rh2) / sq c in Printf.printf "Boo\n"