Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2000
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2000

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

Search the Archive

Re: How to add a vector to a list of vectors?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg26504] Re: [mg26493] How to add a vector to a list of vectors?
  • From: Ken Levasseur <Kenneth_Levasseur at uml.edu>
  • Date: Sat, 30 Dec 2000 01:55:17 -0500 (EST)
  • References: <200012290231.VAA21344@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Julian:

You can add w to each vector this way:

    Map[(w+#)&, l]


Ken Levasseur
UMass Lowell

Three credit on-line Introduction to Mathematica starts at the end of
January:  http://faculty.uml.edu/klevasseur/courses/m419/m419.html



AGUIRRE ESTIBALEZ Julian wrote:

> Dear Group,
>
>         I have a list of vectors l = {v1,...,vn} and another vector w, all
> of the same length. I wat to get the list {w + v1, ..., w + vn} .
>
>         l + w does not work.
>
> Is there a simpler (or more efficient) way than
>
>         Table[w + l[[i]],{i, Length at l}] ?
>
> Julian Aguirre
> Universidad del Pais Vasco



  • Prev by Date: Re: How to add a vector to a list of vectors?
  • Next by Date: Re: How to add a vector to a list of vectors?
  • Previous by thread: How to add a vector to a list of vectors?
  • Next by thread: Re: How to add a vector to a list of vectors?