MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: How to reverse sign on the y's in a list of (x, y)'s?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg61258] Re: [mg61231] How to reverse sign on the y's in a list of (x, y)'s?
  • From: "David Park" <djmp at earthlink.net>
  • Date: Fri, 14 Oct 2005 05:53:49 -0400 (EDT)
  • Sender: owner-wri-mathgroup at wolfram.com

test = {{a1, a2}, {b1, b2}, {c1, c2}};

#{1, -1} & /@ test
{{a1, -a2}, {b1, -b2}, {c1, -c2}}

David Park
djmp at earthlink.net
http://home.earthlink.net/~djmp/ 


From: sherifffruitfly at gmail.com [mailto:sherifffruitfly at gmail.com]
To: mathgroup at smc.vnet.net


Hi all,

This is really dumb, but I just don't know how to do it...

Import from excel gives me a list of ordered pairs, and I want the 2nd
element of each pair to be of opposite sign. Sticking the negative sign
in front of the entire Import statement reverses both the 1st and the
2nd elements (duh). How do I get just the second item to reverse sign?

thanks!



  • Prev by Date: NMinimize ignores constraints and crashes
  • Next by Date: Re: TagSet and the listability of Plus[ ]
  • Previous by thread: Re: How to reverse sign on the y's in a list of (x, y)'s?
  • Next by thread: Re: How to reverse sign on the y's in a list of (x, y)'s?