Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1997

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

Search the Archive

Re: Noah's List

  • To: mathgroup at
  • Subject: [mg5701] Re: Noah's List
  • From: rhall2 at (hall robert)
  • Date: Sat, 11 Jan 1997 14:29:02 -0500
  • Organization: University of Maryland, Baltimore County
  • Sender: owner-wri-mathgroup at

In article <5atsld$ssn at>,
Hans Havermann  <haha at> wrote:
>I have two lists, x and y, each containing n elements. I would like to
>generate a new list, {{x[[1]],y[[1]]}, {x[[2]],y[[2]]},...
>{x[[n]],y[[n]]}}, but have been unable to figure out a shorthand for it.
>Any help would be much appreciated.

   xlist = Array[x, 5]
   ylist = Array[y, 5]
   Transpose[{xlist, ylist}]
   {x[1], x[2], x[3], x[4], x[5]}
   {y[1], y[2], y[3], y[4], y[5]}
   {{x[1], y[1]}, {x[2], y[2]}, {x[3], y[3]}, {x[4], y[4]}, {x[5], y[5]}}

Bob Hall            | "Know thyself? Absurd direction!
rhall2 at  |  Bubbles bear no introspection."  -Khushhal Khan Khatak

  • Prev by Date: FS: Optica + Mathematica for Mac
  • Next by Date: Error in HypergeometricPFQ-package?
  • Previous by thread: Re: Noah's List
  • Next by thread: Re: Noah's List