# Mathematica: Convolution Integral

• Mathematica
• QuantumKnoll
In summary, the code provided performs a convolution integral using the functions a, b, c, and d. However, there is an error message stating that the argument of the sin function is not numerical. This is because the argument should be dimensionless, with k multiplied by x instead of divided by x. The plot also does not show up. Suggestions are needed to fix the code.
QuantumKnoll
Hi all! I'm new to Mathematica.
I have written a code for performing a convolution integral (as follows) but it seems to be giving out error messages:

My code is:

a[x_?NumericQ] := PDF[NormalDistribution[40, 2], x]
b[k_?NumericQ, x_?NumericQ] := 0.0026*Sin[1.27*k/x]^2
c[k_?NumericQ, x_?NumericQ] := {a[x]*b[k, x]}
d[k_?NumericQ] := NIntegrate[c[k, x], {x, 0, Infinity}]
Plot [d[k], {k, 0, 350}]

It gives the following error message multiple times:

ntegrand c[0.00715,x] is not numerical at {x} = {124.67}And the plot dosen't show up..!
Does anyone have any suggestions on how to fix it ?

Last edited:
The argument of the sin function is wrong. It must be dimensionless, i.e. k multiplied by x not divided by x.

## What is a convolution integral in Mathematica?

A convolution integral in Mathematica is a mathematical operation that combines two functions to create a new function. It is often used in signal processing, image processing, and other areas where data is manipulated or transformed.

## How do I perform a convolution integral in Mathematica?

To perform a convolution integral in Mathematica, you can use the built-in function Convolve or the * operator. Convolve takes two functions as input and returns the convolution integral of those functions. The * operator can be used to multiply two functions and then integrate them.

## What is the purpose of using a convolution integral in Mathematica?

The purpose of using a convolution integral in Mathematica is to combine two functions to create a new function that represents the combined effect of the two original functions. This can be useful for analyzing and manipulating data, as well as for solving differential equations.

## Can I use a convolution integral to convolve more than two functions in Mathematica?

Yes, you can use a convolution integral to convolve more than two functions in Mathematica. You can either use the Convolve function multiple times, or use the * operator to multiply all the functions together and then integrate them.

## Are there any limitations to using convolution integrals in Mathematica?

One limitation of using convolution integrals in Mathematica is that the functions must be defined for all values of the variable of integration. If the functions have singularities or are not defined for certain values, the convolution integral may not converge. Additionally, the functions should have finite integrals for the convolution integral to be valid.

• MATLAB, Maple, Mathematica, LaTeX
Replies
4
Views
2K
• MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
521
• MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
579
• MATLAB, Maple, Mathematica, LaTeX
Replies
13
Views
2K
• MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
2K
• MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
1K
• MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
4K
• MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
3K
• MATLAB, Maple, Mathematica, LaTeX
Replies
34
Views
4K
• Quantum Physics
Replies
2
Views
716