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 1992

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

Search the Archive

Re: Vector multiplication??

  • To: mathgroup at
  • Subject: Re: Vector multiplication??
  • From: "Paul N. Schatz" <pns at>
  • Date: Wed, 2 Dec 92 14:14:50 -0500

On Nov 29, 15:48, "Katherine (Williams) Derbyshire" wrote:
> Subject: Vector multiplication??
> I have an arbitrary vector
>    A = Array[a,3] = {a[1], a[2], a[3]}
> The dot product of this vector with itself, is evaluated correctly by
> Mathematica:
>    a[1]^2 + a[2]^2 + a[3]^2
> The 'ordinary' product of this vector with itself, A^2, should be
> equivalent to the dot product.  It is, in fact, conventional in
> mechanical engineering to interpret A^2 as the square of the magnitude
> of A, (i. e.  as a dot product).  My linear algebra text doesn't offer
> any definition for this expression at all. Unfortunately, Mathematica
> (2.0 for Windows) interprets A^2 as
>    {a[1]^2, a[2]^2, a[3]^2}
> which isn't the same at all.  
> What's going on here?  I know I could fix this by writing a
> transformation rule, but it would be nice if Mathematica didn't give
> wrong answers in the first place.
> -- 
> Katherine (Williams) Derbyshire
> kewms at
>  Are we having fun, yet?
> -- End of excerpt from "Katherine (Williams) Derbyshire" <kewms at>

        I would like to point out that this is NOT a wrong
answer.  The product in question is called the Hadamard product.
It in fact is EXCEEDINGLY useful in many Mathematica

Paul N. Schatz
Chemistry Department
University of Virginia
McCormick Road
Charlottesville, VA 22901, USA
phone: 804-924-3249
email: pns at

  • Prev by Date: What should Mma be?
  • Next by Date: Difference equations
  • Previous by thread: What should Mma be?
  • Next by thread: Vector multiplication??