Mathematica 9 is now available
Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2011

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: NIntegrate issue with symbolic parameters

  • To: mathgroup at smc.vnet.net
  • Subject: [mg120582] Re: NIntegrate issue with symbolic parameters
  • From: Heike Gramberg <heike.gramberg at gmail.com>
  • Date: Sat, 30 Jul 2011 05:59:30 -0400 (EDT)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com
  • References: <201107291201.IAA15650@smc.vnet.net>

You could prevent Mathematica from evaluating Curv in the symbolic stage 
by only defining your function Curv for numeric arguments, so for 
example

Clear[Curv];
Curv[{a_?NumericQ, b_?NumericQ, c_?NumericQ}] := With[{R = {a, b, c}}, <original definition> ]

Flux[0.9]

returns

12.5664

Heike.

On 29 Jul 2011, at 13:01, gopher wrote:

> The docs say that NIntegrate evaluates the integrand with the
> variables being symbolic, and then repeatedly evaluates the result
> numerically. This is a problem for me as my integrand calls
> Eigenvectors which results in a symbolic calculation of the
> eigenvectors. If the variables were passed numerically instead, there
> would be no problem.
>
> In the end, I get errors about oscillation and convergence, 'slwcon'
> and 'eincr', which should never occur since the integrand is actually
> constant! (theoretically and also confirmed by Plot3D).
>
> Is there a way out?  Since the details are a bit long, I am putting a
> link to the file below:
>
> https://netfiles.uiuc.edu/aroy2/www/nintegrate-issue.nb
>
> Thanks for any help,
> Abhishek
>





  • Prev by Date: Re: Memory leak or flawed garbage collector
  • Next by Date: Re: CompressedData in Buttons
  • Previous by thread: NIntegrate issue with symbolic parameters
  • Next by thread: Re: NIntegrate issue with symbolic parameters