[gmx-developers] How to include <math.h> when Adding code in md.c

Yukun Wang wangykoo at gmail.com
Tue Mar 29 10:19:27 CEST 2011

Hi all:

     I add some code in the end of md.c, in which I called a function
"sqrt()", and at the start of md.c I add: #include <maths.h>.
     As you know "sqrt()" is an often used function in the mathlib of C,
however, when I complie this code, system give an error:

md.c:3011: error: `squr' undeclared (first use in this function)
md.c:3011: error: (Each undeclared identifier is reported only once
md.c:3011: error: for each function it appears in.)
make[3]: *** [md.o] Error 1

I guess I included a wrong mathlib headfile,is there anyone can tell me when
Gromacs itself need to extract a root which headfile was included?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://maillist.sys.kth.se/pipermail/gromacs.org_gmx-developers/attachments/20110329/9269ea3b/attachment.html>

More information about the gromacs.org_gmx-developers mailing list