4 #include "local_proto.h"
10 double d, s,
t = 0., *xcopy, m2, s1 = 0., s2, mn = 0.0;
12 if ((xcopy = (
double *)
malloc(n *
sizeof(
double))) ==
NULL) {
13 fprintf(stderr,
"Memory allocation error\n");
17 for (i = 0; i < n; ++i)
20 qsort(xcopy, n,
sizeof(
double),
Cdhc_dcmp);
22 for (i = 0; i < n; ++i) {
23 t += xcopy[i] * ((i + 1) - 0.5 * (n + 1));
28 for (i = 0; i < n; ++i)
29 s1 += (xcopy[i] - m2) * (xcopy[i] - m2);
37 y[1] = sqrt((
double)n) * (y[0] - 0.28209479) / 0.02998598;
40 fprintf(stdout,
" TEST4 DAGN =%10.4f\n", y[0]);
double * Cdhc_dagostino_d(double *x, int n)
int Cdhc_dcmp(const void *i, const void *j)