/*CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC C C C COMPUTE MERTENS FUNCTION (using Deleglise and Rivat's algorithm) C C 08/31/15 (DKC) C C C CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC*/ #include <math.h> double newloc(unsigned int x1, unsigned int x2, unsigned int u, char *mob, int *M); double newhic(unsigned int x1, unsigned int x2, unsigned int u, char *mob, int *M); int newriv(unsigned int x1, unsigned int x2, unsigned int u, char *mobb, int *M) { double f1,f2,f3; f1=newloc(x1,x2,u,mobb,M); f2=newhic(x1,x2,u,mobb,M); f3=(double)M[u-1]-f1-f2; return((int)f3); }