Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #4073

Re: NIntegrate issue with symbolic parameters

From Andrew Moylan <amoylan@wolfram.com>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: NIntegrate issue with symbolic parameters
Date 2011-07-30 09:59 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <j10kld$om0$1@smc.vnet.net> (permalink)

Show all headers | View raw


To prevent evaluation until the parameters are numeric, you can add a Condition to the definition for Curv. For example, change

Curv[R_] :=

to

Curv[R_] /; VectorQ[R, NumberQ] :=

Don't forget to Clear[Curv] if you have already given the old definition.

Andrew Moylan
Wolfram Research



----- Original Message -----
> From: "gopher" <gophergoon@gmail.com>
> To: mathgroup@smc.vnet.net
> Sent: Friday, July 29, 2011 10:01:55 PM
> Subject: NIntegrate issue with symbolic parameters
> 
> 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
> 
> 

Back to comp.soft-sys.math.mathematica | Previous | Next | Find similar | Unroll thread


Thread

Re: NIntegrate issue with symbolic parameters Andrew Moylan <amoylan@wolfram.com> - 2011-07-30 09:59 +0000

csiph-web