Linked Questions

39 votes
2 answers
2k views

How to implement custom integration rules for use by NIntegrate?

How can NIntegrate be extended with custom implementation of integration rules? This answer of the question "Monte Carlo integration with random numbers generated ...
Anton Antonov's user avatar
9 votes
4 answers
418 views

How to avoid repetitive calculation when doing numerical integral?

Suppose I have a function f[x] which is very complicated, together with a function g[f[x]]+h[x] to integrate. That is: ...
an offer can't refuse's user avatar
3 votes
3 answers
719 views

NIntegrate not working after interpolation

I used linear interpolation between points: ...
skrat's user avatar
  • 1,275
4 votes
2 answers
2k views

NIntegrate over a list of functions

This question is the result of these other two questions. Question 1 and 2. I thought it would be better to ask a new question rather than deleting previous one. I think When ...
MOON's user avatar
  • 3,876
3 votes
2 answers
847 views

NIntegrate piecewise vector function

Is there a way to numerically integrate a vector function defined via Piecewise? Example: ...
Thomas's user avatar
  • 133
9 votes
2 answers
414 views

Unify the sampling of NIntegrate[ {f, g, h} w ]

I'm trying to numerically integrate a function which has a vector-valued slow part and a much faster component which is shared by all the components, i.e. an integral of the form $$ \int_a^b\begin{...
Emilio Pisanty's user avatar
4 votes
2 answers
308 views

NIntegrate on a solution of a matrix ODE

I've seen similar questions on this site but somehow the solutions there didn't manage to solve my specific problem. I have a function mat1 that takes a square $n \times n$ matrix G, and some final ...
Sahand Tabatabaei's user avatar
3 votes
2 answers
226 views

Can this type of function be plotted faster using NDSolve instead of NIntegrate?

In this post How to speed up the plot of NIntegrate? it was suggested that we can speed up the plotting of NIntegrate by using ...
user3911153's user avatar
4 votes
1 answer
77 views

Extract symbolically processed form of NIntegrated function

As I understand NIntegrate does some symbolic preprocessing of inputs before it actually goes ahead and numerically integrates. I'm wondering if there is some way to access this intermediate ...
alessandro's user avatar
1 vote
2 answers
221 views

NIntegrate or NExpectation a vector function

Question How do I use NIntegrate/NExpectation to integrate over a vector function for which each element is a function of a ...
FalafelPita's user avatar
0 votes
2 answers
87 views

How to make integrals of interpolated matrices constructed by other interpolated quantities?

I have the following code producing an interpolated unitary matrix: ...
Knomes's user avatar
  • 55
2 votes
0 answers
107 views

NIntegrate a vector function without using Indexed and NDSolveValue?

I encoutered an issue about integrand being non-numerical while trying to integrate a vector function using NIntegrate as shown below: ...
Lukas's user avatar
  • 2,702
0 votes
0 answers
57 views

Improve speed of NIntegrate for functions which are sums of complex exponentials

I need to improve the efficiency for numerically evaluating a matrix element, which uses NIntegrate of the several functions (which are all sums of complex exponentials). Creating the functions from ...
Trock's user avatar
  • 53