## Bug: Definite integral of positive function is neg...

Let:

`f:=x->1/sqrt(2*Pi)*exp(-x^2/2);`

I.e. f is a standard Gaussian PDF.

Then (in Maple 2016.1):

```Int(convert(f(x)*f(y)*x*x*abs(x+y),piecewise,x),x=-infinity..infinity,y=-infinity..infinity):
evalf(%);```

Returns:

`1.692568751`

However (again in Maple 2016.1):

```int(convert(f(x)*f(y)*x*x*abs(x+y),piecewise,x),x=-infinity..infinity,y=-infinity..infinity):
evalf(%);```

Returns:

`-0.5641895835`

This is clearly incorrect, as the integral of a positive function must be positive.

This also seems to be a problem in which ever version of Maple is used behind the scenes on this forum.

gives:

## Gaussian noise generation...

Hi everyone

I am going to add a continious time white guassian noise n(t) to a function f(t), and plot g(t)=f(t)+n(t). Any suggestion?

Also, I am going to filter this white noise, and analysis colored noise. How can I apply a frequency-domain rectangular window to a function?

## How to remove block ?...

There have come unwanted lines and marks . I donot know how to remove them. Using doc.block, remove block seems to be little tough to incorporate! Please enlighten me. Modified doc. is most welcome. Thanks. Ramakrishnan V

 Gaussian Elimination Method

 (1)
Coefficient Tanle
 Equation 1 Equation 2 Equation 3 Equations =  =  =

The equations in matrix form is given by

 (2)

The Gaussian Elimination gives the simplified natrix equation as given below:

 (3)

The equations in simplified form are:

 (4)
 (5)
 (6)

The aolution ia obtained by solving the above equations in reverse order

 (7)

## Gaussian elimination routine using loops...

I am attempting to write a Gaussian elimination routine to solve a system Ax = b using loops, but I have been having trouble.  Any help would be mcuh appreciated.  Thanks!

## How to create 2d Gaussian random field?...

Of course, with Maple. This object is described in Wiki.
Its plot looks like

Also the 2d Gaussian free field is of great interest. As far as I understand it, a one-dimensional Gaussian random field is formed by the
Finance[GaussMarkovProcess] command of Maple.

PS. The googling brings, in particular, http://mathematica.stackexchange.com/questions/4829/efficiently-generating-n-d-gaussian-random-fields.

## 2D numerical Integration Error...

Hi,

I have been trying to solve 2D Diffusion Equation with zero Neumann BC over the unit disk. If I use Gaussian type function with a sharp peak as initial condition, I get huge errors between initial values. Let's say u(r,phi,t) is the solution of the PDE and f(r,phi) is initial value function. The expectation is for the point (r*,phi*) ,  u(r*,phi*,0)=f(r*,phi*), but it is not.

Is Numerical integration in Maple not able to handle such sharp peak? I tried some of the built-in methods such as MonteCarlo,CubaVegas but no difference.

It might be a good idea to specify some nodes arround the peak. There is a command called "peaks", but I could not use it, error message says "invalid arguments".

## Analytical solution of 2D diffusion equation in po...

Hello,

I have been trying to compute the analytical solution of two dimensional diffusion equation with zero neumann boundary conditions (no-flux) in polar coordinates using the solution in Andrei Polyanin's book. When I use 2d Gaussian function as initial condition, i cannot get the result. If I use some nicer function like f(r,phi)=1-r; there is no problem.

Any idea why this happens? or any suggestion to compute the analytical solution?

Thanks!

HB

 >
 >
 >
 >
 >
 >

## What's up with inttrans[fourier]?...

I am trying to get a Fourier transform of a Gaussian:

so I say

and get

The Fouriertransform of a Gaussian is well known and the result I expect is something like

exp(1/2*sigma^2*omega^2)

ignoring normalizations & other factors. I know that I can add functions to inttrans, but I kind-of expected inttrans[fourier] to know how to transform a Gaussian, it is a commonly used transformation. Even if I set phi0 to 0 it does not produce anything useful.

???

Mac Dude

## Discrete Fourier Transform...

Hello, I am trying to do a fourier transfrom using the package < DiscreteTransfroms >.

The function is an gaussian function for now,

Here is the code I tried

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

restart

with(DiscreteTransform):

> X := Vector(1000, proc (k) options operator, arrow; (1/200)*k-5/2 end proc);
> Y := Vector(1000, proc (k) options operator, arrow; evalf(exp(-10*((1/100)*k-5)^2)) end proc);

> X2, Y2 := FourierTransform(X, Y);
Vector[column](%id = 18446744080244879358),

Vector[column](%id = 18446744080244879478)
> plot(X2, Re(Y2));

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

The program returns two vector, X2 and Y2 who are supposed to be the fourier transforme of a gaussian so.. a gausian but when I plot the result X2 on the horizontal and Y2 on vertical, the graph doesn't resemble a gaussian function or any function at all.

Alex

## Show intermediate steps for rank calculation...

Hi there,

I am calculating he rank of a matrix in Maple and I have a result. However, I want Maple to show me the intermediate steps that it used. I know that the rank function uses gaussian eliminations. Is it possible to make it display these steps?

The matrix is 8*8 so I think it is taugh to use the tutor tool.

I tried ShowSteps but it says that rank is not a valid problem.

Any ideas?

## truncated normal distribution...

Dear all,

I have two questions regarding truncated normal distribution.

1. Is there a convenient way in Maple to compute and plot the density function of a truncated normal distribution? I know that in Maple, after creating a random variable, I can use the function Statistics:-PDF to compute the density function, and use DensityPlot to draw the function. But for truncated distribution, I have to compute it manually by doing integration to compute the normalized...

## Find the width of a plot...

Hi all,

Is there some way i can find the width of a plot?

I have the equation below:

Prob:=(w,T)->(B^2)*(sin(w*(T/2))^2)/((w/2)^2);

plot(Prob(w,6),wf=-3..3);

Which produces a gaussian looking plot, the plot reaches zero at some...

## Plotting Gaussian Primes Connected by Steps k...

Hi hi,

I've been sourcing various codes to help with plotting gaussian primes. I've managed a plot of gaussian primes within a given range with no problem at all. However, I'm looking now to make a plot of all gaussian primes connected by a step k or less to help communicate the Gaussian moat problem.  ( similar to figure 2 in http://mathdl.maa...