Bill Allombert on Thu, 17 May 2012 11:47:17 +0200


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: "Unknown function" message for compiled function


On Thu, May 17, 2012 at 11:30:40AM +0200, Ewan Delanoy wrote:
> Hello all,
> 
>  I have a function below (called "polforcedshrink") that does not work
>  (whenever I call it I get the error message " *** unknown function or error
>  in formal parameters: "), although the interpreter remains silent at compile
>  time.
> 
>  Can anyone tell me what's wrong with the code ?
>  parisize = 4000000, primelimit = 500000
>  ? polforcedshrink(paul,var,a,b,l)=local(local_runner,local_c,local_adj,answer);answer=[];local_runner=paul;for(k=1,length(l),local_c=l[k];answer=concat([subst(local_runner,var,local_c)],answer);local_adj=1-2*(local_c==b);local_runner=local_adj*((local_runner-subst(local_runner,var,local_c))/(var-local_c)););return(answer);
>  ? g1=5+6*x+7*(x^2)+8*(x^3)
>  %1 = 8*x^3 + 7*x^2 + 6*x + 5
>  ? test1=paulforcedshrink(g1,x,0,1,[1,0,0,0,0])
>  *** unknown function or error in formal parameters: test1=paulforcedshrink(g1,

Your function is called polforcedshrink, not paulforcedshrink.

Cheers,
Bill.