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

Home » Public Forums » archive » Re: Flip Matrix
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: Flip Matrix [message #41993] Thu, 09 December 2004 05:09
Timm Weitkamp is currently offline  Timm Weitkamp
Messages: 66
Registered: August 2002
Member
REVERSE is what you're looking for.

In your example, if the original matrix is called "a", try
b = REVERSE(a,1).

Cheers,
Timm

-------------------------------------------------
Timm Weitkamp <http://people.web.psi.ch/weitkamp>
-------------------------------------------------

Today at 04:55 -0800, Florian Meyer wrote:

> Hi!
>
> Is there an easy way to flip a matrix, i.e. to reverse the column
> indecies??
> example:
> 1.0 2.0 3.0 4.0 5.0
> 1.1 2.1 3.1 4.1 5.1
>
> should come out as
>
> 5.0 4.0 3.0 2.0 1.0
> 5.1 4.1 3.1 2.1 1.1
>
> I'm working now with a FOR Loop and switch each sigle column. Another
> way is a multiplication with a NxN matrix with ones on the second
> diagonal and zeros elsewhere. But I have the strong feeling that there
> must be something more easy and elegant...
>
> Florian
[Message index]
 
Read Message
Previous Topic: Flip Matrix
Next Topic: READ_ASCII - accessing data from structures

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

Current Time: Fri Oct 10 02:45:20 PDT 2025

Total time taken to generate the page: 0.32308 seconds