if (q <= 0.0) { if (q == floor(q)) {
mtherr("zeta", SING);
retinf: return (MAXNUM);
} if (x != floor(x)) goto domerr; /* because q^-x not defined */
}
/* Euler-Maclaurin summation formula */ /* if(x<25.0)
*/
{ /* Permit negative q but continue sum until n+q > +9 . *Thiscaseshouldbehandledbyareflectionformula. *Ifq<0andxisaninteger,thereisarelationto *thepolygammafunction.
*/
s = pow(q, -x);
a = q;
i = 0;
b = 0.0; while ((i < 9) || (a <= 9.0)) {
i += 1;
a += 1.0;
b = pow(a, -x);
s += b; if (fabs(b / s) < MACHEP) goto done;
}
w = a;
s += b * w / (x - 1.0);
s -= 0.5 * b;
a = 1.0;
k = 0.0; for (i = 0; i < 12; i++) {
a *= x + k;
b /= w;
t = a * b / A[i];
s = s + t;
t = fabs(t / s); if (t < MACHEP) goto done;
k += 1.0;
a *= x + k;
b /= w;
k += 1.0;
}
done: return (s);
}
/* Basic sum of inverse powers */ /* pseres:
s=pow(q,-x); a=q; do { a+=2.0; b=pow(a,-x); s+=b; } while(b/s>MACHEP);
b=pow(2.0,-x); s=(s+b)/(1.0-b); return(s);
*/
}
Messung V0.5 in Prozent
¤ Dauer der Verarbeitung: 0.1 Sekunden
(vorverarbeitet am 2026-06-10)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.