In search of cbrt() ...

Doug Gwyn gwyn at smoke.brl.mil
Thu Dec 13 15:17:52 AEST 1990


In article <Dec.12.18.31.04.1990.3356 at paul.rutgers.edu> rcruz at paul.rutgers.edu (Rafael Cruz) writes:
>... make use of the library function cbrt().  This library
>is in the Unix math library but TC doesn't seem to support it. 

I don't know what version of UNIX you had in mind; it isn't in the
math library in most known UNIX environments.

However, if all it does is extract a cube-root, it's trivial to emulate:
	#include <math.h>
	#define cubrt(x) pow(x,1.0/3.0)



More information about the Comp.lang.c mailing list