logo       

RE: Transpose operator ~ actually applies ~ to each element: msg#00025

Subject: RE: Transpose operator ~ actually applies ~ to each element
I can't recall. I actually ran into this problem back in September but I
wasn't able to post to the mailing list from the hosted webmail I was using.

Steve


-----Original Message-----
From: Derek Lamb [mailto:derek@xxxxxxxxxxxxxxxx] 
Sent: Wednesday, November 28, 2007 12:43 PM
To: Steve Chapel
Cc: perldl@xxxxxxxxxxxxxxx
Subject: Re: [Perldl] Transpose operator ~ actually applies ~ to each
element

Hi Steve,

I think it's an error in the documentation.  PDL::Ops claims that ~ 
serves as an alias to 'bitnot'.

Is there anywhere else besides PDL::Impatient that you saw a reference 
to ~ as a transpose operator?

cheers,
Derek

Steve Chapel wrote:
>
> Running the following program:
>
> #!/usr/bin/perl
> use PDL;
> my $y = pdl([[1,2,3],[4,5,6],[7,8,9]]);
> print ~$y;
>
> using ActivePerl 5.8.8.820 and PDL 2.4.3 gives the following output:
>
> [
> [ -2 -3 -4]
> [ -5 -6 -7]
> [ -8 -9 -10]
> ]
>
> According to the PDL documentation
> <http://pdl.sourceforge.net/PDLdocs/Impatient.html#matrix_functions>,
> "transpose() does what it says and is a convenient way to turn row vectors
> into column vectors. It is bound to the unary operator '~' for 
> convenience."
> However, transpose() returns the expected result:
>
> [
> [1 4 7]
> [2 5 8]
> [3 6 9]
> ]
>
> Is this a bug in PDL? An error in the documentation?
>
> Thanks,
> Steve
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Perldl mailing list
> Perldl@xxxxxxxxxxxxxxx
> http://mailman.jach.hawaii.edu/mailman/listinfo/perldl
>   


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
science.linguis...    culture.sf.lite...    video.mplayer.c...    yellowdog.gener...    ietf.rfc822/199...    emacs.help/2002...    redhat.release....    kernel.speakup/...    java.openejb.de...    debian.devel.gt...    xfree86.newbie/...    bug-tracking.ma...    pam/2003-05/msg...    games.devel.ope...    user-groups.lin...    music.pancham/2...    network.mq.deve...    web.html.genera...    arklinux.bugs/2...    linux.ecasound/...    qnx.openqnx.dev...    org.user-groups...    file-systems.sf...    trustix.contrib...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe