Why don't you define a simple function like: numeric qrt(numeric n){ if (n>=0) return pow(n,numeric(1)/numeric(3)); else return -pow(-n,numeric(1)/numeric(3)); } and use that in your particular problem. Cheers, H.P.