Displaying 1 result from an estimated 1 matches for "numbparts_longint".
2006 Apr 24
1
unsigned long long integers
...tion is defined by a delicate recursive algorithm that is exact
for integer arithmetic, but wildly incorrect for doubles.
The function increases rapidly with its argument, and ordinary integers
are not enough to illustrate my point (in a paper I am writing).
The C function is as follows:
void numbparts_longint(int *n, double *p){/* p(1)...p(n) calculated */
int i,s,f,r;
unsigned long long int *ip;
unsigned long long int pp[*n];
/* COMPLICATED RECURSIVE ALGORITHM IN WHICH PP IS FILLED SNIPPED */
for(i=0 ; i < *n ; i++){
p[i] = (double) pp[i];...