Tagged Questions

Questions on the use of numerical functions NIntegrate and NDSolve.

learn more… | top users | synonyms

1
vote
0answers
29 views

Using real numbers gives suspicious result

In the code below when I use a real number for number 4 in the exponent in the irf function, it returns wrong result. ...
3
votes
2answers
107 views

Compute the average distance from the base of a rectangular pyramid to its apex

How can I compute the average distance from the base of a rectangular pyramid to its apex? For example, if the base of the pyramid is 30 feet by 8 feet, and the height of the pyramid is 12 feet, then ...
3
votes
1answer
60 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 ...
0
votes
0answers
23 views

How to tell NDSolve to ignore small values in choosing step size

I have a very large system of first order differential equations, which can be written (on paper) as dX/dt=F(X), where X is a vector and F is a vector function. All elements of X are strictly positive ...
0
votes
0answers
15 views

Calculate (designate) area of ​​the largest area [migrated]

The values ​​of a function of two variables z = f (x, y), where x, y, z are float. Calculate (designate) area of ​​the largest area of flat O. By 'flat area' O mean a sub area T wherein for each ...
0
votes
0answers
26 views

Mathematica Integrate implicit assumptions returns a function not defined in some points while NIntegrate performs integration safely

Hi guys i'm performing a standard integration with mathematica routine Integrate, the function i'm integrating is the following: ...
0
votes
0answers
49 views

Plotting a Function that contains a Numerical Integration

I'm using mathematica to plot a function that has been defined in the following way: ...
1
vote
1answer
57 views

Mathematica multi-dimensional numerical integration default method

I'm performing multidimensional Numerical integrations with mathematica I was wondering what was the default method that mathematica was using. Also i'm changing some parameter inside the integration, ...
1
vote
1answer
64 views

Strange integration

I tried to evaluate this line Integrate[((-I/2) (E^((-I) x) - E^(I x)) + ((E^((-I) x) + E^(I x)) x)/ 2)/((-1 + E^x) x), {x, 0, Infinity}] Then I get $14$ ...
0
votes
0answers
60 views

Need help with this integration [closed]

I am trying to solve the following differential equation and then integrate the solution by a Gaussian function. The solution to the DE has some Lorentzian functions and Mathematica seems to have a ...
1
vote
0answers
23 views

Can NIntegrate be used with the Levin method in several dimensions?

I've got some data in the form of an interpolating function. It's a function of three variables, $\rho(x,y,z)$. I'd basically like to integrate this with some phase over a cube of known size, like $$ ...
0
votes
1answer
33 views

Error messages from NIntegrate [closed]

I've been trying to work on some integrals (Actuarial Science, for those interested) but somehow this always returns an error for me. ...
1
vote
0answers
62 views

Numerical solution to two non-linear coupled differential equations [closed]

I am trying to solve two differential equations representing the position of an object in space. I have specified arbitrary initial conditions. ...
0
votes
0answers
14 views

How does this integration make sense? [migrated]

I simply don't understand how integration can lead from: $ds^2 = a^2(t) \frac{dr^2}{1 - kr^2}$ to $s(r) = \frac{\sin^{-1}(\sqrt{k}r)}{\sqrt{k}}$ I appologize, I've never been quite capable of ...
3
votes
0answers
52 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 ...
0
votes
0answers
40 views

Problems with NIntegrate, levmaxord error

I am trying to integrate some spherical harmonics, for scattering over a sphere, using the SphericalHarmonicY and NIntegrate ...
0
votes
0answers
46 views

Numerical integration with large exponents

To make a long story short, I am doing mostly analytic calculations and therefore do note have good skills in numerical integration. I have to numerical integrate the following integral ...
2
votes
1answer
110 views

2D Fourier transform of a few (4) disjoint discs on a plane

I'd really appreciate some advice. Short Version I'm trying to calculate the following $$ ...
2
votes
0answers
48 views

Number recognition in Mathematica [closed]

Suppose that I have a number $n$ with many decimal digits of precision. What is the code to use to get Mathematica to recognize possible closed-form expressions for that number?
0
votes
1answer
73 views

How to compute an integral with 300 digits accuracy [closed]

I'm new to Mathematica and I would like to ask what is the code to use to calculate numerically an integral with 300 digits precision; also, I would like to know what is the right code to use the ...
1
vote
1answer
69 views

Computer freezes during NIntegrate[]

I have a notebook that freezes the computer every time I run it (I mean the whole computer becomes unresponsive and do not react to ctrl-shift-esc and ctr-alt-delete as well as alt-tab and ...
1
vote
0answers
52 views

PDE with Integral constraint

I am trying to solve the Non-linear Schrodinger equation $-\Delta \psi(r) + \psi(r) - |\psi(r)|^2\psi(r) = 0$ where $r \in \Omega$ In a square domain ($(x,y) \in \Omega$ where $\Omega=[0,1]\times ...
2
votes
1answer
81 views

StateResponse is non-deterministic

I observed non-deterministic behaviour in StateResponse. Let's look at an example. ...
1
vote
1answer
66 views

How to evaluate complex numerical integral in mathematica?

I have an integral of the form \begin{align} F(\omega) = \int_0^{\infty} f(s,\omega) \mathrm{d}s \end{align} which I would like to numerically evaluate and plot for a range of $\omega \in ...
1
vote
1answer
92 views

Solving Fredholm Equation of the first kind [duplicate]

I want to numerically solve Fredholm integral equations of the first kind, equations of the form $$g(t)=\int_a^b K(t,s)f(s)\,\mathrm{d}s$$ where we know the functions $K(t,s)$ and $g(t)$ and seek to ...
0
votes
1answer
69 views

NIntegrate:eincr error

I am trying to solve this expression in Mathematica with the function NIntegrate: ...
0
votes
2answers
67 views

NIntegrate Error

I am trying to solve this expression with the function NIntegrate: ...
3
votes
2answers
83 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}] ...
1
vote
1answer
78 views

Definite Integral over Bessel Function

Hello I am interested in evaluating the following integral. ...
3
votes
4answers
146 views
2
votes
0answers
81 views

Puzzling NDSolve[] behavior for PDE (smooth solution, inconsistent with boundary conditions)

Consider the following: NDSolve[{D[z[x, y], x, x] + D[z[x, y], y, y] == 0, z[x, 0] == Sin[x], z[0, y] == Cos[y]}, z[x, y], x, y] {{z[x, y] -> ...
2
votes
1answer
117 views

2-Dimensional NFourierTransform

Mathematica FourierSeries package contains the NFourierTransform function for calculating 1-D Fourier integral numerically. ...
0
votes
2answers
87 views

Numerical Integration

I have used the following code to evaluate an integral (val) numerically ...
2
votes
0answers
72 views

Solve integral equation for upper bound

I need to find the upper bound of an integral knowing the value of the lower bound and the result of the integral. Here is my function: ...
7
votes
2answers
144 views

Efficient way to obtain values of a function defined by an Integral

Consider the following equation: $$S(q)=\frac{(4 \pi \rho ) \int r (h(r)-1) \sin (q r) \, dr}{q}$$ I want to numerically obtain values for $S(q)$ given that I have data points representing $h(r)$ ...
-2
votes
0answers
89 views

Solving Laplace's equation in rectangle domain by separation of variables

I wanted to solve numerically Laplace's equation $\Delta \psi = 0$ by separation of variables, ie: 1.) ansatz $\psi(x,y,t) = X(x)Y(y)$ (t will be important later, think of it as a parameter) 2.) ...
0
votes
0answers
48 views

Calculate the relationship between the duration of two oscillating functions

I am trying to quantitatively determine the relationship between the length of two oscillating functions. Meaning, what is the duration of the green spike in relation to the blue square? Does anyone ...
1
vote
1answer
103 views

NDSolve giving the wrong solution?

I'm considering the non-linear second order ODE DE $=0$, with DE given by ...
0
votes
0answers
78 views

How do I perform the following numerical integration

I have the following integral to evaluate numerically: $$x(t) = \frac{1}{f(t)}\int_0^{t_b} t^m (t + n)^o \sin(pt) \mathrm{d}t \quad m,n,o,p \in \mathbb{R}$$ ...
4
votes
1answer
74 views

Possible bug / numerical issues with HypergeometricU — any suggestions for a fast workaround?

I've encountered some problematic behaviour with HypergeometricU. I have a probability distribution on the positive integers that takes the following form after ...
4
votes
1answer
123 views

Solution to a T+U = E equation

I needed to solve really easy differential equation (in dimensionless units): $$ \mathcal{T} (\dot{\xi}) + \mathcal{U} (\xi) = \text{const.} \equiv \varepsilon ; \quad T(\dot{\xi}) = \dot{\xi}^2 ; ...
6
votes
2answers
177 views

Interpolating an Antiderivative

I'd like to be able to make InterpolatingFunctions for antiderivatives of functions that can't be integrated symbolically. However, the following code returns several error messages: ...
4
votes
3answers
361 views

Find arc length

I am trying to find the arc length for using ...
5
votes
1answer
102 views

Determining the range of parameters that yield real values for a certain NIntegrate form

I have specified just one set of $s$ and $g$ values that yields a real value for the NIntegrate below. It is possible that some $s,g$ combination can give rise to ...
1
vote
2answers
126 views

Integrating Squared of Interpolating Function with respect to one variable

I am interested in evaluating a two dimensional interpolating function produced by solving the wave equation. Here is the code that includes the resulting interpolating function. ...
0
votes
0answers
45 views

Getting message NIntegrate::inumr: in V10; did not happen in V9 [duplicate]

I just tried making a ParametricPlot that worked error-free in Mathematica 9, but now produces errors before successfully plotting in Mathematica 10. It appears to ...
3
votes
0answers
54 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): ...
1
vote
3answers
121 views

Improving convergence in a numerical integration (Version 5.2)

I have a double integral that I am trying to calculate numerically, and I'm having convergence issues. ...
0
votes
0answers
57 views

Problem solving a Fredholm integral equation

Based on the algorithm by PlatoManiac presented here Integral equation numerical solution with NDSolve I am solving a Fredholm integral equation with the following constants and arguments: ...