Bugs item #1573476, was opened at 20061008 21:31
Message generated for change (Comment added) made by willisbl
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=104933&aid=1573476&group_id=4933
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Lisp Core
Group: None
>Status: Closed
Resolution: None
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: abs(x) does not work in vectors
Initial Comment:
As the summary says, the abs function is not working in
vectors.
We all know that abs(x)=sqrt(x^2)
But if x = [x[1],x[2],x[3],...,x[n]] then the abs
function should be
abs(x):= sqrt(x[1]^2 + x[2]^2 + x[3]^2 + ... + x[n]^2)
That's why abs(x + %i*y) returns sqrt(x^2 + y^2),
because x + iy = [x,y]
Mario/Mexico

>Comment By: Barton Willis (willisbl)
Date: 20061010 05:26
Message:
Logged In: YES
user_id=895922
In Maxima, [e1, e2, ... ,en] is a list. A list can be
used to represent a vector, but a list doesn't have to
represent a vector. Although undocumented, the function
abs maps over list members. If you want a vector 2norm,
you'll need to define it yourself: something like
vector_norm(x) := sqrt(x . conjugate(x));
Maybe Maxima should have a vector object. But it
doesn't.

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=104933&aid=1573476&group_id=4933
