[NTG-context] Parenthesis error in metapost

Hans Hagen j.hagen at xs4all.nl
Wed Apr 7 11:29:25 CEST 2021


On 4/7/2021 10:14 AM, Mikael Sundqvist wrote:
> Hi,
> 
> the following code has been working before:
> 
> \starttext
> \startMPpage[instance=decimalfun]
> draw function(1,"x","x*sin(x)",0.5,1,1/100) scaled 1in;
> \stopMPpage
> \stoptext
> 
> Now (with an updated ConTeXt) I get an error:
> 
> metapost        > loading 'metafun' as 'metafun.mpxl' using method 'decimal'
> metapost        > initializing number mode 'decimal'
> metafun         > log >
> metafun         > log > error: Missing ')' has been inserted
> metafun         > log >
> metapost        > log > <to be read again>
> metapost        > log >                    (
> metapost        > log > <scantokens> x*sin(
> metapost        > log >                    x)
> metapost        > log > <to be read again>
> metapost        > log >                    )
> 
> Maybe I have done something wrong earlier, but I cannot see any
> unmatched parenthesis now.
sin is just not defined in decimal mode (in scaled and double they use 
the math library) .. so i'll fix that

Hans


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------


More information about the ntg-context mailing list