Questions on the use of numerical functions NIntegrate and NDSolve.

learn more… | top users | synonyms

3
votes
1answer
340 views

A Bessel & Struve functions related integral

I try to numerically compute this integral and I don't figure out why on earth Mathematica is not able to do it. Is my input correct? Does it possibly have a closed form? ...
3
votes
1answer
488 views

Tips for efficiently solving large system coupled (nonlinear) ODEs

I'm trying to solve a system of nonlinear, coupled ODEs, where the governing equation for the $n-th$ ODE is of the form: $\sum_k^M Q_{nk} \ddot{a}_k -\sum_{\ell}^M\sum_k^M S_n(\ell,k) \dot{a}_{\ell} ...
3
votes
1answer
753 views

Monitoring the Evaluation of NDSolve: time to finish estimation

My problem is quite simple: I run a NDSolve with a system of many ODEs, a calculation that will run for many hours, and I would like to know the progress of the ...
3
votes
1answer
529 views

NDSolve with vector function

(Possible duplicate yet I still can't understand.) Basic 2D revolving around origin: ...
3
votes
2answers
538 views

Animating the Lorenz Equations

I am trying to use the Animate command to vary a parameter of the Lorenz Equations in 3-D phase space and I'm not having much luck. The equations are: ...
3
votes
1answer
504 views

Integrating over data points from an external source (wolfram|alpha and weather)

I moved to another city and the weather sucks. Sometimes I feel like getting sad and so I go to wolfram|alpha and check for example ${}$ ...
3
votes
1answer
241 views

Numerical integration's speed

Consider this numerical integration of Bessel function: Do[NIntegrate[BesselJ[2, x], {x, 0, 10000}], {i, 1, 100}] // AbsoluteTiming {4.033403, Null} This is ...
3
votes
1answer
77 views

NIntegrate on tetrahedron

I've been trying to numerically calculate an integral in a tetrahedron of a discretized domain. In some cases when I specify a method I've been getting the error message NIntegrate::femonly ...
3
votes
2answers
183 views

NIntegrate giving message NIntegrate::slwcon:

I got this interesting answer from Mathematica when trying to integrate my function numerically: f[x_] := Sqrt[17*x^2 + x^4] NIntegrate[f[x], {x, -1, 2}] ...
3
votes
1answer
171 views

How to do this complex integration on the real line?

$m, r$ are parameters in the following integral: Integrate[z Exp[I z r]/Sqrt[z^2 + m^2], {z, -∞, ∞}] How to do this integration directly? The result should be ...
3
votes
1answer
83 views

Evaluating a numerical integration with infinity as limit

I am trying to evaluate a numerical integration (to get an expression of the constant Ω) Suppose that h[x_] := 1/(1 + a x^2) ...
3
votes
1answer
383 views

Integrating a functional of an InterpolatingFunction

It is straightforward to Integrate an InterpolatingFunction. However, even for a simple functional of an ...
3
votes
1answer
241 views

Integrate equations of motion when force depends on position

I'm fairly new to Mathematica. I'm trying to test my C++ implementation of a fourth order Runge Kutta method for Newton's equations of motion. I want to test my integrator when the applied force is ...
3
votes
1answer
717 views

NDSolve for a large system of simple ODEs

I am solving a system of many (more than 100) ODEs. It is the kind of standard rate equation encountered in semiconductor physics. Here is the system: ...
3
votes
2answers
691 views

NDSolve: Normalizing at every step

Suppose I have an transport equation with an initial conditions: ...
3
votes
2answers
426 views

How to set the initial condition? (to make IC and BC consistent)

I want to find the initial condition which fits mixed boundary condition of Phi[r, Theta, t]. The original initial condition in text is Phi[r, Theta, 0] == 1 . ...
3
votes
1answer
90 views

NIntegrate and Interval regions

NIntegrate does not seem to like Intervals as regions. Consider the following example function defined for a parameter "a" ...
3
votes
1answer
366 views

Combining Gravity Turn and Orbit Models

I have a mathematical model for the motion of an orbiting spacecraft about Earth: ...
3
votes
1answer
231 views

Surface area of intersecting spheres

Given a sphere of radius 1 centered at the origin and $n$ spheres with radii $r_i$ centered at predefined coordinates, $c_i$, in space, I am after the surface area of the unit sphere that is not ...
3
votes
1answer
463 views

Question on accuracy and precision of NIntegrate

As a Mathematica newbie, I was testing the accuracy/precision of NIntegrate (9.0.1.0 on Mac) and have obtained a very peculiar result. ...
3
votes
1answer
204 views

NDSolve: Reinitialize fails with If condition

I have found a weird problem using If conditions containing an state inequality of the form state<=. First consider the simple ODE with an If condition ...
3
votes
1answer
463 views

Multi-dimensional integral in the complex plane with poles and essential singularity

I've passed the last week searching a way to numerically integrate this multi-dimensional integral in the complex plane at the poles and avoiding the singularity at z=0: $$ \oint_{C}\oint_{C\ auound\ ...
3
votes
1answer
1k views

NDSolve does not respond

For some sets of constants, NDSolve gives me true solutions, but when I try for example, T = 1/(2*2200), Mathematica does not respond. What can I do? The code below ...
3
votes
1answer
387 views

NIntegrate inside NSum

Consider the following function with a numerical integration: ...
3
votes
1answer
112 views

What boundary is added when NDSolve::bcart pops up?

When insufficient boundary conditions are given to NDSolve for solving PDE, the warning NDSolve::bcart pops up: ...
3
votes
1answer
111 views

List interpolation

Hi mathematica people! So i am looking for the best way to interpolate a function given a list of its values. I have an iterative algorithm which needs high precision otherwise the numerical noise is ...
3
votes
2answers
130 views

NIntegrate returns zero for non zero integrand, 4d Integration

I am trying to calculate the following integral. ...
3
votes
1answer
1k views

Can Mathematica solve integro-differential equations?

I have integro-differential equations like this: ...
3
votes
1answer
199 views

Construct DifferentialMatrices and Kernel for LevinRule for this integral and ODE set

I've made a lot of progress on my problem the last few days thanks to all the help I've received on here. I think I'm upto the final step of greatly improving the performance of NIntegrate[..] on my ...
3
votes
1answer
477 views

Second Order Non Linear Differential Equation

I'm trying to solve the following differential equation numerically: ...
3
votes
1answer
427 views

Efficient way to perform elementary integration step with NDSolve internal method

I'm trying to tweak the NDSolve function to perform one elementary integration step (using some explicitly selected stepping algorithm via ...
3
votes
0answers
110 views

Obtaining NIntegrate error estimate

Is there a way to extract the error that Mathematica estimates when calculating a numerical integral using NIntegrate? Internally Mathematica must keep track of this error, because it is used to ...
3
votes
0answers
137 views

Numerical integration: complicated 2D integral seems to be poorly estimated

In the course of some physics research I've been working on, a very annoying integral has appeared that I'm having difficulty evaluating numerically. Any help you could offer would be greatly ...
3
votes
0answers
63 views

Integrate yields complex value, while after variable transformation the result is real. Bug?

I have the follwoing integral: Integrate[1/Sqrt[0.7 + 0.3*(1 + z)^3], {z, 0, Infinity}, Assumptions -> z \[Element] Reals] >> -3.36354 - 3.85013 I the ...
3
votes
0answers
59 views

NIntegrate::ncvbr: How should we interpret and handle this error not mentioned in any documentation?

I have some user-defined module describing my integrand which has to be computed numerically (it's much more complicated than this but bear with me): ...
3
votes
0answers
67 views

What are good/best practices to take the Fourier transform of an InterpolatingFunction?

I have a function which I have obtained from numerical integration of a differential equation, and I would like to take its Fourier transform. What are good practices for doing this? To make things ...
3
votes
0answers
277 views

Function with a sharp resonance which Mathematica fails to integrate. Why?

I'm a new user of Mathematica and I'm trying to use it to calculate the collisional cross-section as a function of energy for a given potential and decay rate. I know that the resulting function ...
3
votes
0answers
135 views

Non-linear integral equation

I'm trying to solve with Mathematica an integral equation. I found this excellent answer (How to solve a non-linear integral equation?) solving with a collocation method a problem which can be ...
3
votes
0answers
997 views

Using NDSolve for Integro-Differential Equations

I have a fairly complicated set of coupled non-linear integro-differential equations that I am trying to solve using NDSolve. The equations are: ...
3
votes
0answers
432 views

Numerically solving PDE with high precision

I want to numerically solve the PDE $\partial_t u(t,x)=c\partial_x u(t,x)+(mx-l)u(t,x)$ with some initial and boundary conditions and given parameters $c$, $m$ and $l$. Consider the code ...
3
votes
0answers
236 views

Numerical-Symbolical Integration (Calculus)

I created a simple numeric-symbolic integration. Here you can use symbolical and numerical techniques at the same time. You can also interpolate numerical integrals. The problem with my function is ...
3
votes
0answers
1k views

Solving a system of nonlinear equations self-consistently

I am trying to solve a set of three non-linear equations in Mathematica. I need help with them. The Mathematica code (in plain text format) is attached below. If you copy & paste the code below ...
2
votes
4answers
431 views

How to calculate this integral?

I am trying to Integrate the following Integral : $\int_1^{\infty } \dfrac{\left(x^2-1\right)^{13/2} e^{-ax} }{x^{10}} \, dx \,\, \,\,\,\,\,\,\,\,\,\,\,\,(a=\textrm{real>0})$ Mathematica didn't ...
2
votes
4answers
282 views
2
votes
2answers
1k views

optimization problem with NDSolve

I want to minimize the function fcc. When fcc is calculated for a specified point the answer is correct: ...
2
votes
3answers
146 views

Inefficient NIntegrate and Which

In version 10 a simple numerical integraton of piecewise function is highly inefficient: ...
2
votes
2answers
202 views

NIntegrate piecewise vector function

Is there a way to numerically integrate a vector function defined via Piecewise? Example: ...
2
votes
2answers
196 views

Plot result of non analytical-integral

I have the following function: h = 1; c = 1; k = 1; B2 = (2*h*c^2)/(x^5 (Exp[(h*c)/(x*k*T)] - 1)); (someone can see that this integral is the Planck function). ...
2
votes
2answers
106 views

FindFit working with Integrate but not NIntegrate - I am using “?NumericQ”

I'm having some syntax problems with finding a fit to an equation that doesn't have an analytical expression for it's integral. Because I think the problem is one of syntax, I am substituting a ...
2
votes
2answers
401 views

How to compute this triple integral? [closed]

In Mathematica how can I compute this integral:$$ \iiint_{D}\sqrt{(1-9z^2)(1-4y^2-9z^2)}\,dx\,dy\,dz$$ where D is the domain: $$D: x^2 +4y^2+9z^2\le1$$ Please I need help!!!