Re: Monte Carlo in Mathematica ?

• To: mathgroup at smc.vnet.net
• Subject: [mg23932] Re: Monte Carlo in Mathematica ?
• From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
• Date: Fri, 16 Jun 2000 00:57:13 -0400 (EDT)
• Organization: Universitaet Leipzig
• References: <8i9qic\$2o3@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

```Hi,

the Mathematica book say that

NIntegrate[_,_,Method->MonteCarlo]

make a Monte Carlo integration. It says also that
N[expr,prec] konvert all numbers in expr in floating
point numbers with prec precision.

It say *not* what

M[expr, opts___] pass the options opts to all numerical
expressions in expr (it whould be stupid)

Regards
Jens

>
> I have a complicated problem to solve in Mathematica.
>
> Basically,
> a=Sum[Integrate[.....,{},{},{}],{}] ;(*The integral is over three
> variables*)
> Print[N[a,MaxPoints->2000]];
>
> This yields an error that 2000 is not a machine sized real number in the
>
> range \$MinPrecision(0 in my case) and \$MaxPrecision(1x10^6 in my case).
>
> I have even tried MaxPoints->(\$MinPrecision+\$MaxPrecision)/2 ! Had I not
>
> been in a hurry, I would have probably found this amusing.
>
> The usual adaptive recursive algorithm for NIntegrate takes too long and
>
> I want Mathematica to give me an approximate answer by using Monte Carlo
>
> (or so the Mathematica book indicates) by using MaxPoints.
>
> Any ideas ?
>
> With regards,