COMPGROUPS.NET | Search | Post Question | Groups | Stream | About | Register

### FFT+inverse FFT

• Email
• Follow

```Hey! I'm a beginner at IDL and have problem with FFT. I'm trying to
perform 2d-FFT but the code doesn't work properly even on test images.
So I create an image, make the Fourier transform, then the inverse
Fourier transform and finally I expect to get the initial image. But
the resulting image is the initial one, reversed with respect to the
center.

My code:
nx=256L
x1=findgen(nx)-nx/2.0+1.0
x2=findgen(nx)-nx/2.0+1.0

ytest=fltarr(nx,nx)
for i=0l,nx-1 do begin
for j=0l,nx-1 do begin
if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0  and x2[j] ge
0.0) then begin
ytest[i,j]=1.0
endif
endfor
endfor

; So the initial image is a squre in the right upper corner

FFTtest=FFT(ytest)
sh_FFTtest=SHIFT(FFTtest,nx/2.0-1.0,nx/2.0-1.0)
inv_test=FFT(FFTtest,-1)

;The result is the square in the LEFT LOWER corner.

I would be very grateful for comments/advices/solutions

Thank for help,
Natalya
```
 0
Reply 12/5/2010 5:48:54 PM

See related articles to this posting

```Natalya Lyskova writes:

> Hey! I'm a beginner at IDL and have problem with FFT. I'm trying to
> perform 2d-FFT but the code doesn't work properly even on test images.
> So I create an image, make the Fourier transform, then the inverse
> Fourier transform and finally I expect to get the initial image. But
> the resulting image is the initial one, reversed with respect to the
> center.
>
> My code:
> nx=256L
> x1=findgen(nx)-nx/2.0+1.0
> x2=findgen(nx)-nx/2.0+1.0
>
> ytest=fltarr(nx,nx)
> for i=0l,nx-1 do begin
> for j=0l,nx-1 do begin
>  if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0  and x2[j] ge
> 0.0) then begin
>     ytest[i,j]=1.0
>  endif
> endfor
> endfor
>
> ; So the initial image is a squre in the right upper corner
>
> FFTtest=FFT(ytest)
> sh_FFTtest=SHIFT(FFTtest,nx/2.0-1.0,nx/2.0-1.0)
> inv_test=FFT(FFTtest,-1)
>
> ;The result is the square in the LEFT LOWER corner.
>
> I would be very grateful for comments/advices/solutions

I think you need to read the on-line help for the FFT function. :-)

Your code should look like this:

FFTtest = FFT(ytest, -1)
inv_test = Real_Part(FFT(FFTtest, 1))

Now ytest and inv_test are essentially the same.

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
```
 0
Reply David 12/5/2010 7:06:30 PM

```On Dec 5, 2:06=A0pm, David Fanning <n...@dfanning.com> wrote:
> Natalya Lyskova writes:
> > Hey! I'm a beginner at IDL and have problem with FFT. I'm trying to
> > perform 2d-FFT but the code doesn't work properly even on test images.
> > So I create an image, make the Fourier transform, then the inverse
> > Fourier transform and finally I expect to get the initial image. But
> > the resulting image is the initial one, reversed with respect to the
> > center.
>
> > My code:
> > nx=3D256L
> > x1=3Dfindgen(nx)-nx/2.0+1.0
> > x2=3Dfindgen(nx)-nx/2.0+1.0
>
> > ytest=3Dfltarr(nx,nx)
> > for i=3D0l,nx-1 do begin
> > for j=3D0l,nx-1 do begin
> > =A0if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0 =A0and x2[j] ge
> > 0.0) then begin
> > =A0 =A0 ytest[i,j]=3D1.0
> > =A0endif
> > endfor
> > endfor
>
> > ; So the initial image is a squre in the right upper corner
>
> > FFTtest=3DFFT(ytest)
> > sh_FFTtest=3DSHIFT(FFTtest,nx/2.0-1.0,nx/2.0-1.0)
> > inv_test=3DFFT(FFTtest,-1)
>
> > ;The result is the square in the LEFT LOWER corner.
>
> > I would be very grateful for comments/advices/solutions
>
> I think you need to read the on-line help for the FFT function. :-)
>
> Your code should look like this:
>
> =A0 =A0FFTtest =3D FFT(ytest, -1)
> =A0 =A0inv_test =3D Real_Part(FFT(FFTtest, 1))
>
> Now ytest and inv_test are essentially the same.
>
> Cheers,
>
> David
>
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming:http://www.dfanning.com/
> Sepore ma de ni thui. ("Perhaps thou speakest truth.")

Hello,
Im working with the FFT also but not directly in IDL, I work in ENVI.
I wonder how ENVI or IDL can perform a FFT on a rectangular image?
Theorically the image must be a square of dimension of coefficient of
2. (512x512, 1024 x1024 etc... ) So what is the process that make
possible to do a FFT on a rectangular image? Other Image Processing
software like PCI Geomatica cant do that.

Thank you,
Max
```
 0
Reply burton449 12/5/2010 8:05:30 PM

```On Dec 5, 12:48=A0pm, Natalya Lyskova <natalya.lysk...@gmail.com> wrote:
> Hey! I'm a beginner at IDL and have problem with FFT. I'm trying to
> perform 2d-FFT but the code doesn't work properly even on test images.
> So I create an image, make the Fourier transform, then the inverse
> Fourier transform and finally I expect to get the initial image. But
> the resulting image is the initial one, reversed with respect to the
> center.
>
> My code:
> nx=3D256L
> x1=3Dfindgen(nx)-nx/2.0+1.0
> x2=3Dfindgen(nx)-nx/2.0+1.0
>
> ytest=3Dfltarr(nx,nx)
> for i=3D0l,nx-1 do begin
> for j=3D0l,nx-1 do begin
> =A0if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0 =A0and x2[j] ge
> 0.0) then begin
> =A0 =A0 ytest[i,j]=3D1.0
> =A0endif
> endfor
> endfor
>
> ; So the initial image is a squre in the right upper corner
>
> FFTtest=3DFFT(ytest)
> sh_FFTtest=3DSHIFT(FFTtest,nx/2.0-1.0,nx/2.0-1.0)
> inv_test=3DFFT(FFTtest,-1)
>
> ;The result is the square in the LEFT LOWER corner.
>
> I would be very grateful for comments/advices/solutions
>
> Thank for help,
> Natalya

As a side note, a better (both faster and more readable) way of
creating the original image instead of the double FOR loop is:

if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0  and x2[j] ge
0.0) then begin
ytest[i,j]=3D1.0

upperright =3D where(x1 le 20.0 and x1 ge 0.0 and x2 le 20.0 and x2 ge
0.0, nupperright)
if nupperright gt 0 then ytest[upperright]=3D1.0

-Jeremy.
```
 0
Reply Jeremy 12/6/2010 2:16:07 PM

```On 6 d=E9c, 15:16, Jeremy Bailin <astroco...@gmail.com> wrote:
> On Dec 5, 12:48=A0pm, Natalya Lyskova <natalya.lysk...@gmail.com> wrote:
>
>
>
>
>
> > Hey! I'm a beginner at IDL and have problem with FFT. I'm trying to
> > perform 2d-FFT but the code doesn't work properly even on test images.
> > So I create an image, make the Fourier transform, then the inverse
> > Fourier transform and finally I expect to get the initial image. But
> > the resulting image is the initial one, reversed with respect to the
> > center.
>
> > My code:
> > nx=3D256L
> > x1=3Dfindgen(nx)-nx/2.0+1.0
> > x2=3Dfindgen(nx)-nx/2.0+1.0
>
> > ytest=3Dfltarr(nx,nx)
> > for i=3D0l,nx-1 do begin
> > for j=3D0l,nx-1 do begin
> > =A0if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0 =A0and x2[j] ge
> > 0.0) then begin
> > =A0 =A0 ytest[i,j]=3D1.0
> > =A0endif
> > endfor
> > endfor
>
> > ; So the initial image is a squre in the right upper corner
>
> > FFTtest=3DFFT(ytest)
> > sh_FFTtest=3DSHIFT(FFTtest,nx/2.0-1.0,nx/2.0-1.0)
> > inv_test=3DFFT(FFTtest,-1)
>
> > ;The result is the square in the LEFT LOWER corner.
>
> > I would be very grateful for comments/advices/solutions
>
> > Thank for help,
> > Natalya
>
> As a side note, a better (both faster and more readable) way of
> creating the original image instead of the double FOR loop is:
>
> =A0if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0 =A0and x2[j] ge
> 0.0) then begin
> =A0 =A0 ytest[i,j]=3D1.0
>
> upperright =3D where(x1 le 20.0 and x1 ge 0.0 and x2 le 20.0 and x2 ge
> 0.0, nupperright)
> if nupperright gt 0 then ytest[upperright]=3D1.0
>
> -Jeremy.- Masquer le texte des messages pr=E9c=E9dents -
>
Even simpler since IDL 8.0:

ytest[where(x1 le 20.0 and x1 ge 0.0 and x2 le 20.0 and x2 ge 0.0, /
NULL)]=3D1.0

alx.
```
 0
Reply alx 12/6/2010 3:10:24 PM

```On Dec 5, 3:05=A0pm, burton449 <burton...@gmail.com> wrote:
> On Dec 5, 2:06=A0pm, David Fanning <n...@dfanning.com> wrote:
>
>
>
> > Natalya Lyskova writes:
> > > Hey! I'm a beginner at IDL and have problem with FFT. I'm trying to
> > > perform 2d-FFT but the code doesn't work properly even on test images=
..
> > > So I create an image, make the Fourier transform, then the inverse
> > > Fourier transform and finally I expect to get the initial image. But
> > > the resulting image is the initial one, reversed with respect to the
> > > center.
>
> > > My code:
> > > nx=3D256L
> > > x1=3Dfindgen(nx)-nx/2.0+1.0
> > > x2=3Dfindgen(nx)-nx/2.0+1.0
>
> > > ytest=3Dfltarr(nx,nx)
> > > for i=3D0l,nx-1 do begin
> > > for j=3D0l,nx-1 do begin
> > > =A0if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0 =A0and x2[j] =
ge
> > > 0.0) then begin
> > > =A0 =A0 ytest[i,j]=3D1.0
> > > =A0endif
> > > endfor
> > > endfor
>
> > > ; So the initial image is a squre in the right upper corner
>
> > > FFTtest=3DFFT(ytest)
> > > sh_FFTtest=3DSHIFT(FFTtest,nx/2.0-1.0,nx/2.0-1.0)
> > > inv_test=3DFFT(FFTtest,-1)
>
> > > ;The result is the square in the LEFT LOWER corner.
>
> > > I would be very grateful for comments/advices/solutions
>
> > I think you need to read the on-line help for the FFT function. :-)
>
> > Your code should look like this:
>
> > =A0 =A0FFTtest =3D FFT(ytest, -1)
> > =A0 =A0inv_test =3D Real_Part(FFT(FFTtest, 1))
>
> > Now ytest and inv_test are essentially the same.
>
> > Cheers,
>
> > David
>
> > --
> > David Fanning, Ph.D.
> > Fanning Software Consulting, Inc.
> > Coyote's Guide to IDL Programming:http://www.dfanning.com/
> > Sepore ma de ni thui. ("Perhaps thou speakest truth.")
>
> Hello,
> Im working with the FFT also but not directly in IDL, I work in ENVI.
> I wonder how ENVI or IDL can perform a FFT on a rectangular image?
> Theorically the image must be a square of dimension of coefficient of
> 2. (512x512, 1024 x1024 etc... ) So what is the process that make
> possible to do a FFT on a rectangular image? Other Image Processing
> software like PCI Geomatica cant do that.

Taking a DFT (Discrete Fourier Transformation) of an array is possible
for any array size. There is an algorithm called FFT (Fast Fourier
Transformation)
that happens to be very efficient if the size is in the form 2^N for
some N.
However, modern incarnations of FFT can deal with other sizes too,
albeit less
efficiently (the smaller the factors in the prime decomposition of the
size,
the better).

Please don't let what a particular software does or fail to do be your
guide to what is possible or not (from a mathematical standpoint). If
you
want to learn a bit more about the FFT, read for instance the chapter
about
it on the numerical recipes book.

Ciao,
Paolo

>
> Thank you,
> Max

```
 0
Reply Paolo 12/6/2010 3:28:17 PM

```On Dec 6, 4:10=A0pm, alx <lecacheux.al...@wanadoo.fr> wrote:

> Even simpler since IDL 8.0:
>
> ytest[where(x1 le 20.0 and x1 ge 0.0 and x2 le 20.0 and x2 ge 0.0, /
> NULL)]=3D1.0

Or, even simpler, and without a need for v8.0:

ytest =3D (x1 le 20.0 and x1 ge 0.0 and x2 le 20.0 and x2 ge 0.0)

Cheers
Timm

```
 0
Reply Timm 12/6/2010 4:26:36 PM

```On Dec 6, 10:28=A0am, Paolo <pgri...@gmail.com> wrote:
> On Dec 5, 3:05=A0pm, burton449 <burton...@gmail.com> wrote:
>
>
>
> > On Dec 5, 2:06=A0pm, David Fanning <n...@dfanning.com> wrote:
>
> > > Natalya Lyskova writes:
> > > > Hey! I'm a beginner at IDL and have problem with FFT. I'm trying to
> > > > perform 2d-FFT but the code doesn't work properly even on test imag=
es.
> > > > So I create an image, make the Fourier transform, then the inverse
> > > > Fourier transform and finally I expect to get the initial image. Bu=
t
> > > > the resulting image is the initial one, reversed with respect to th=
e
> > > > center.
>
> > > > My code:
> > > > nx=3D256L
> > > > x1=3Dfindgen(nx)-nx/2.0+1.0
> > > > x2=3Dfindgen(nx)-nx/2.0+1.0
>
> > > > ytest=3Dfltarr(nx,nx)
> > > > for i=3D0l,nx-1 do begin
> > > > for j=3D0l,nx-1 do begin
> > > > =A0if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0 =A0and x2[j=
] ge
> > > > 0.0) then begin
> > > > =A0 =A0 ytest[i,j]=3D1.0
> > > > =A0endif
> > > > endfor
> > > > endfor
>
> > > > ; So the initial image is a squre in the right upper corner
>
> > > > FFTtest=3DFFT(ytest)
> > > > sh_FFTtest=3DSHIFT(FFTtest,nx/2.0-1.0,nx/2.0-1.0)
> > > > inv_test=3DFFT(FFTtest,-1)
>
> > > > ;The result is the square in the LEFT LOWER corner.
>
> > > > I would be very grateful for comments/advices/solutions
>
> > > I think you need to read the on-line help for the FFT function. :-)
>
> > > Your code should look like this:
>
> > > =A0 =A0FFTtest =3D FFT(ytest, -1)
> > > =A0 =A0inv_test =3D Real_Part(FFT(FFTtest, 1))
>
> > > Now ytest and inv_test are essentially the same.
>
> > > Cheers,
>
> > > David
>
> > > --
> > > David Fanning, Ph.D.
> > > Fanning Software Consulting, Inc.
> > > Coyote's Guide to IDL Programming:http://www.dfanning.com/
> > > Sepore ma de ni thui. ("Perhaps thou speakest truth.")
>
> > Hello,
> > Im working with the FFT also but not directly in IDL, I work in ENVI.
> > I wonder how ENVI or IDL can perform a FFT on a rectangular image?
> > Theorically the image must be a square of dimension of coefficient of
> > 2. (512x512, 1024 x1024 etc... ) So what is the process that make
> > possible to do a FFT on a rectangular image? Other Image Processing
> > software like PCI Geomatica cant do that.
>
> Taking a DFT (Discrete Fourier Transformation) of an array is possible
> for any array size. There is an algorithm called FFT (Fast Fourier
> Transformation)
> that happens to be very efficient if the size is in the form 2^N for
> some N.
> However, modern incarnations of FFT can deal with other sizes too,
> albeit less
> efficiently (the smaller the factors in the prime decomposition of the
> size,
> the better).
>
> Please don't let what a particular software does or fail to do be your
> guide to what is possible or not (from a mathematical standpoint). If
> you
> want to learn a bit more about the FFT, read for instance the chapter
> about
> it on the numerical recipes book.
>
> Ciao,
> Paolo
>
>
>
> > Thank you,
> > Max
>
>

Hi Paolo,

Thank you for your comment. As a student in Remote Sensing, I have a
lot of basic things to understand. The image I would like to filter in
the frequential domain (using a Butterworth filter) is a side scan
sonar image mosaic of 9166 x 4093 pixels. Would you recommend a FFT
and if yes would you use a special algorithm?

greetings,
Max
```
 0
Reply burton449 12/7/2010 2:33:39 AM

```On Dec 6, 9:33=A0pm, burton449 <burton...@gmail.com> wrote:
> On Dec 6, 10:28=A0am, Paolo <pgri...@gmail.com> wrote:
>
>
>
> > On Dec 5, 3:05=A0pm, burton449 <burton...@gmail.com> wrote:
>
> > > On Dec 5, 2:06=A0pm, David Fanning <n...@dfanning.com> wrote:
>
> > > > Natalya Lyskova writes:
> > > > > Hey! I'm a beginner at IDL and have problem with FFT. I'm trying =
to
> > > > > perform 2d-FFT but the code doesn't work properly even on test im=
ages.
> > > > > So I create an image, make the Fourier transform, then the invers=
e
> > > > > Fourier transform and finally I expect to get the initial image. =
But
> > > > > the resulting image is the initial one, reversed with respect to =
the
> > > > > center.
>
> > > > > My code:
> > > > > nx=3D256L
> > > > > x1=3Dfindgen(nx)-nx/2.0+1.0
> > > > > x2=3Dfindgen(nx)-nx/2.0+1.0
>
> > > > > ytest=3Dfltarr(nx,nx)
> > > > > for i=3D0l,nx-1 do begin
> > > > > for j=3D0l,nx-1 do begin
> > > > > =A0if (x1[i] le 20.0 and x1[i] ge 0.0 and x2[j] le 20.0 =A0and x2=
[j] ge
> > > > > 0.0) then begin
> > > > > =A0 =A0 ytest[i,j]=3D1.0
> > > > > =A0endif
> > > > > endfor
> > > > > endfor
>
> > > > > ; So the initial image is a squre in the right upper corner
>
> > > > > FFTtest=3DFFT(ytest)
> > > > > sh_FFTtest=3DSHIFT(FFTtest,nx/2.0-1.0,nx/2.0-1.0)
> > > > > inv_test=3DFFT(FFTtest,-1)
>
> > > > > ;The result is the square in the LEFT LOWER corner.
>
> > > > > I would be very grateful for comments/advices/solutions
>
> > > > I think you need to read the on-line help for the FFT function. :-)
>
> > > > Your code should look like this:
>
> > > > =A0 =A0FFTtest =3D FFT(ytest, -1)
> > > > =A0 =A0inv_test =3D Real_Part(FFT(FFTtest, 1))
>
> > > > Now ytest and inv_test are essentially the same.
>
> > > > Cheers,
>
> > > > David
>
> > > > --
> > > > David Fanning, Ph.D.
> > > > Fanning Software Consulting, Inc.
> > > > Coyote's Guide to IDL Programming:http://www.dfanning.com/
> > > > Sepore ma de ni thui. ("Perhaps thou speakest truth.")
>
> > > Hello,
> > > Im working with the FFT also but not directly in IDL, I work in ENVI.
> > > I wonder how ENVI or IDL can perform a FFT on a rectangular image?
> > > Theorically the image must be a square of dimension of coefficient of
> > > 2. (512x512, 1024 x1024 etc... ) So what is the process that make
> > > possible to do a FFT on a rectangular image? Other Image Processing
> > > software like PCI Geomatica cant do that.
>
> > Taking a DFT (Discrete Fourier Transformation) of an array is possible
> > for any array size. There is an algorithm called FFT (Fast Fourier
> > Transformation)
> > that happens to be very efficient if the size is in the form 2^N for
> > some N.
> > However, modern incarnations of FFT can deal with other sizes too,
> > albeit less
> > efficiently (the smaller the factors in the prime decomposition of the
> > size,
> > the better).
>
> > Please don't let what a particular software does or fail to do be your
> > guide to what is possible or not (from a mathematical standpoint). If
> > you
> > want to learn a bit more about the FFT, read for instance the chapter
> > about
> > it on the numerical recipes book.
>
> > Ciao,
> > Paolo
>
> > > Thank you,
> > > Max
>
> Hi Paolo,
>
> Thank you for your comment. As a student in Remote Sensing, I have a
> lot of basic things to understand. The image I would like to filter in
> the frequential domain (using a Butterworth filter) is a side scan
> sonar image mosaic of 9166 x 4093 pixels. Would you recommend a FFT
> and if yes would you use a special algorithm?
>
> greetings,
> Max

Well if it's just a single image, then you can certainly go ahead
and implement filtering with the FFT - the array is pretty big
and it will take a little while. If performance becomes an
issue, you can expand it to 9216x4096 and it should run a bit
faster.

Ciao,
Paolo

```
 0
Reply Paolo 12/9/2010 6:58:02 PM

8 Replies
979 Views

Similar Articles

12/6/2013 5:02:47 PM
page loaded in 101313 ms. (0)

 Reply:

Similar Artilces:

inverse of wblstat
Hello, given the mean and variance of a weibull distribution, I need to generate random numbers of this distribution using "wblrnd". However, "wblrnd" takes the scale paramater and shape parameter as input. So I have to find out the scale paramater and shape parameter from the mean and variance that are given. --- The "wblstat" can do the inverse, meaning calculating mean and variance from scale and shape paramaters. My question is: Is there a convenience way to calculate scale and shape paramaters from mean and variance for Weibull distribution. Many thanks! Dan

inverse function
Dear, Does someone know if there is any work done to generate an inverse of any given lisp function (if possible). Example: > (defun f (x) (+ x 1)) > (f 2) 3 > (funcall (inverse #'f) 3) 2 > (funcall (inverse #'f) (f 5)) 5 When a lisp function has conditional branchs then the inverse function will have a code to test both paths (eg. choice and fail constructs). This example is very simple and serves only to describe my needs; I would like to use the inverse function for complex lisp defined functions. Thank you for your help On 2010-02-13 17:27:43 +0000, Taoufik said: > Does someone know if there is any work done to generate an inverse of > any given lisp function (if possible). Inverses only exist for functions which are 1-1 (is this an injection? I think it is). So many functions do not have them. Even for those that do, computing the inverse based on the definition is probably intractable in general. Taoufik <taoufik@mazeboard.com> writes: > Dear, > > Does someone know if there is any work done to generate an inverse of > any given lisp function (if possible). > > Example: > >> (defun f (x) (+ x 1

Inverse Gaussian distribution
Hi, I want to use the Inverse Gaussian Distribution. It is included in the distribution fitting tool but pdf, cdf and random number generator don't seem to be available as functions. Is there a possibility to access those functionalities? At least some of them must be available for the internal fitting within the tool. I could write a pdf-function on my own but for efficiency reasons a built-in function would be easier for me. Kind regards, Jan "Jan Müller" <ja.mueller@remove.thisenbw.com> wrote in message <i7cn8d\$r22\$1@fred.mathworks.com>... > Hi, > > I want to use the Inverse Gaussian Distribution. It is included in the distribution fitting tool but pdf, cdf and random number generator don't seem to be available as functions. Is there a possibility to access those functionalities? At least some of them must be available for the internal fitting within the tool. > I could write a pdf-function on my own but for efficiency reasons a built-in function would be easier for me. > > Kind regards, > Jan Assuming you can use the statistics toolbox, see the documentation: doc ProbDistUnivParam PD

inverse of a function and empirical cdf
Hi, I am new to matlab. I am looking for functions or programs in matlab which calculte: 1) a smoothed version of a empirical cumulative distribution 2) the inverse of a function Thank you for your help, Albert A.L wrote: > Hi, > I am new to matlab. I am looking for functions or programs in matlab > which calculte: > > 1) a smoothed version of a empirical cumulative distribution > > 2) the inverse of a function See KSDENSITY in the Statistics Toolbox for (1). For (2), if you mean a smoothed version of an empirical cumulative distribution function, also see KSDENSITY. On May 25, 3:06 pm, Peter Perkins <Peter.PerkinsRemoveT...@mathworks.com> wrote: > A.L wrote: > > Hi, > > I am new to matlab. I am looking for functions or programs in matlab > > which calculte: > > > 1) a smoothed version of a empirical cumulative distribution > > > 2) the inverse of a function > > See KSDENSITY in the Statistics Toolbox for (1). For (2), if you mean a > smoothed version of an empirical cumulative distribution function, also see >

Matrix Inverse Issue
I am having a problem with the matrix inverse for the following matrix in Mathematica 6: A = Table[If[j == i, 1 - i/10, If[j == i + 1, i/10, 0]], {i, 9}, {j, 9}] {{9/10, 1/10, 0, 0, 0, 0, 0, 0, 0}, {0, 4/5, 1/5, 0, 0, 0, 0, 0, 0}, {0, 0, 7/10, 3/10, 0, 0, 0, 0, 0}, {0, 0, 0, 3/5, 2/5, 0, 0, 0, 0}, {0, 0, 0, 0, 1/2, 1/2, 0, 0, 0}, {0, 0, 0, 0, 0, 2/5, 3/5, 0, 0}, {0, 0, 0, 0, 0, 0, 3/10, 7/10, 0}, {0, 0, 0, 0, 0, 0, 0, 1/5, 4/ 5}, {0, 0, 0, 0, 0, 0, 0, 0, 1/10}} A Inverse[A] {{1, -1/72, 0, 0, 0, 0, 0, 0, 0}, {0, 1, -1/14, 0, 0, 0, 0, 0, 0}, {0, 0, 1, -3/14, 0, 0, 0, 0, 0}, {0, 0, 0, 1, -8/15, 0, 0, 0, 0}, {0, 0, 0, 0, 1, -5/4, 0, 0, 0}, {0, 0, 0, 0, 0, 1, -3, 0, 0}, {0, 0, 0, 0, 0, 0, 1, -49/6, 0}, {0, 0, 0, 0, 0, 0, 0, 1, -32}, {0, 0, 0, 0, 0, 0, 0, 0, 1}} I expected the identity matrix here but I get extra terms. Am I doing something wrong? Brian Gladman Brian Gladman wrote: > I am having a problem with the matrix inverse for the following matrix in > Mathematica 6: > > A = Table[If[j == i, 1 - i/10, If[j == i + 1, i/10, 0]], {i, 9}, {j, 9}] > > {{9/10, 1/10, 0, 0, 0, 0, 0, 0, 0}, {0, 4/5, 1/5, 0

Question on inverse filter
Dear all, I want to design an inverse filter, I inverse the spectrum of a chirp and do ifft to get the coefficients. However, the convolution of the coefficients with the chirp is not close to delta function, anyone can help me? Thank you very much! f0=10e6; B =4e6; Tr =6.4e-6; a = 2*pi*B/Tr; fs =200e6; t = [0:1/fs:Tr]; chirps = cos(2*pi*(f0-B/2)*t+a/2*t.^2); fftc = fft(chirps); inversef = ifft(1./fftc) figure; plot(conv(chirps,inversef));

Inverse of Matrix crashes Matlab
I am attempting to take an inverse of a 6x6 matrix. Upon execution Matlab crashes. Even a smaller 2x2 matrix it crashes. I have had this problem on a Windows XP version 7.8.0 (R2009a), but not with the Mac version Matlab. The error at the top is: Unknown Windows exception of type=c000001cd was not caught. "Scott " <zagorski.2@osu.edu> wrote in message <hi61do\$pn7\$1@fred.mathworks.com>... > I am attempting to take an inverse of a 6x6 matrix. Upon execution Matlab crashes. Even a smaller 2x2 matrix it crashes. I have had this problem on a Windows XP... > <hi61do\$pn7\$1@fred.mathworks.com>... >> I am attempting to take an inverse of a 6x6 matrix. Upon execution >> Matlab crashes. Even a smaller 2x2 matrix it crashes. I have had this >> problem on a Windows XP version 7.8.0 (R2009a), but not with the Mac >> version Matlab. The error at the top is: Unknown Windows exception of >> type=c000001cd was not caught. > > Can you show us the matrix? > > john > "Scott " <zagorski.2@osu.edu> wrote in message <hi61do\$pn7\$1@fred.mathworks.com>... > I am

inverse resolution (CIGOL)
In Tom Mitchell's "Machine Learning" (1997), paragraph 10.7.2 handles first-order inverse resolution. There is an example given in which the conclusion GrandChild(y,x) <- Father(x,z) and Father(z,y) is drawn from training data D = GrandChild(Bob, Shannon) and background information B = {Father(Shannon, Tom), Father(Tom, Bob)}. Also according to this book, the inverted resolution rule forms the basis of the CIGOL program. So I downloaded and installed it from http://cigol.sourceforge.net/. My problem is that there are very few examples of CIGOL code to be found online. How could the same conclusion be drawn as in the example, using CIGOL? -- "Don't worry about people stealing your ideas. If your ideas are any good, you'll have to ram them down people's throats." -- Howard Aiken [ comp.ai is moderated ... your article may take a while to appear. ] Guybrush Threepwood wrote: > In Tom Mitchell's "Machine Learning" (1997), paragraph 10.7.2 handles > first-order inverse resolution. There is an example given in which > the conclusion GrandChild(y,x) <- Father(x,z) and Father(z,y) is drawn > from training data D

Inverse of PCA #2 461337
(say > > PTRANS) Matrix is usually non-square, and hence can not get an inverse for > > it. > > Either use a canned software pseudoinverse, or train one > as indicated above via a NN with linear activation functions. > > Hope this helps. > > Greg > > > Given Pr = PTRANS*Pn (Pn is the data; Pr is the PCA components; and PTRANS > > is the PCA matrix. > > Usually Pn is given, and the Pr is computed. My question is: If I know > > the Pr; how can I find Pn.? > > > > > > "Alaa Ali" <a.i.ali@worldnet.att.net> wrote in message > > news:ro1jb.1810\$Ec1.138324@bgtnsc05-news.ops.worldnet.att.net... > > > Is it possible to convert the PCA values to the original data values. Is > > > there an inverse problem issue here? > > > If it is possible, Is there a utility in MATLAB Neural Network toolbox > > that > > > converts the PCA components to its original data values? > > > thanks > > > a.a. > > > > > > > > > "Alaa Ali" <a.i.ali@worldnet.att.net> wrote in message news:<PJ9pb.203104

inverse laplace transofmr 14346
please help me to give the resolution of the problem A*w0^2/(-w0^2+w^2)*(-(z-cos(w))*z/(z^2-2*z*cos(w)+1)+(z-cos(w0))*z/(z^2-2*z*cos(w0)+1)+ztrans(ilaplace(exp(-s*T)*s/(s^2+w^2),s,t),t,z)-ztrans(ilaplace(exp(-s*T)*s/(s^2+w0^2),s,t),t,z)) the rsult is (-z^(-1)-z^(-2))/(1+z^(-2) but i cant konw how i can give the result???? "zedzzr" <mohamedmohamed@laposte.net> wrote in message news:102878365.61749.1261918550873.JavaMail.root@gallium.mathforum.org... > please help me to give the resolution of the problem > > > > A*w0^2/(-w0^2+w^2)*(-(