Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #5670

Re: How to create this kind of list

From "Oleksandr Rasputinov" <oleksandr_rasputinov@hmamail.com>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: How to create this kind of list
Date 2011-10-16 11:11 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <j7ee4a$ein$1@smc.vnet.net> (permalink)
References <j7bm30$35r$1@smc.vnet.net>

Show all headers | View raw


On Sat, 15 Oct 2011 11:08:32 +0100, Szymon Roziewski  
<szymon.roziewski@gmail.com> wrote:

> Hello there,
> I am thinking about creating such a list.
> I have 2 lists with the same number of elements.
> The idea is to create one list which was taken from these previous two  
> ones
> in the following way:
> Take one element of the first list and one from another and put it into
> result list {{x1,y1},{x2,y2},...,{xn,yn}}.
> Input lists:
> A={x1,x2,...,xn}
> B={y1,y2,...,yn}
>
> All best,
> Szymon Roziewski

a = Array[x, 5];
b = Array[y, 5];

lst = Transpose[{a,b}]

gives

{{x[1], y[1]}, {x[2], y[2]}, {x[3], y[3]}, {x[4], y[4]}, {x[5], y[5]}}

Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

How to create this kind of list Szymon Roziewski <szymon.roziewski@gmail.com> - 2011-10-15 10:08 +0000
  Re: How to create this kind of list Helen Read <readhpr@gmail.com> - 2011-10-16 11:08 +0000
  Re: How to create this kind of list "Oleksandr Rasputinov" <oleksandr_rasputinov@hmamail.com> - 2011-10-16 11:11 +0000
  Re: How to create this kind of list "Dr. Wolfgang Hintze" <weh@snafu.de> - 2011-10-16 11:16 +0000
  Re: How to create this kind of list dimitris <dimmechan@yahoo.com> - 2011-10-16 11:17 +0000

csiph-web