comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Help with Idl+Envi
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: help with idl [message #83194 is a reply to message #71738] Thu, 07 February 2013 06:26 Go to previous message
Helder Marchetto is currently offline  Helder Marchetto
Messages: 520
Registered: November 2011
Senior Member
On Thursday, February 7, 2013 3:13:36 PM UTC+1, fd_...@mail.com wrote:
> Does anyone know how to create a Toeplitz matrix in idl??
>
>
>
> Best Wishes
>
> Mar

Well, I'm not sure that this is what you are looking for and I don't think that this is the the "IDL" way, however it does the job:

IDL> n = 5
IDL> a = make_array(n,n)
IDL> OneLine = findgen(2*n)
IDL> FOR I=0,n-1 DO a[*,I] = (shift(OneLine,I))[0:4]
IDL> print, a
0.000000 1.00000 2.00000 3.00000 4.00000
8.00000 0.000000 1.00000 2.00000 3.00000
7.00000 8.00000 0.000000 1.00000 2.00000
6.00000 7.00000 8.00000 0.000000 1.00000
5.00000 6.00000 7.00000 8.00000 0.000000

Hope it helps.

Cheers,
h
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: New IDL 8.2.2 Workbench
Next Topic: Kronecker product reversal, or division

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 17:29:22 PDT 2025

Total time taken to generate the page: 0.00480 seconds