Share

JMathLib - Octave, Matlab clone in java

Tracker: Bugs

5 ^ should work on vectors - ID: 2007227
Last Update: Comment added ( st_mueller )


It should be true that

[1,2,3]^2 == [1,4,9]

An example of usage of this is computation of an approximately Gaussian
filtering window:

w = sin([0:255]*pi/256)^4


Ted Dunning ( tedunning ) - 2008-06-30 23:50

5

Closed

None

Stefan Mueller

None

None

Public


Comment ( 1 )




Date: 2008-07-06 12:52
Sender: st_muellerProject Admin


> [1,2,3]^2
??? [1,2,3]^2
ERROR: DoubleNumberToken: mPower: [n*m]^[o*p] not supported

The error message is correct. The power of vectors can only be computed
elementwise. [1,2,3].^ -> [1^2,2^2,3^2]

Please us .^ instead of ^



Log in to comment.

Attached File

No Files Currently Attached

Changes ( 5 )

Field Old Value Date By
data_type 382791 2008-07-06 12:52 st_mueller
status_id Open 2008-07-06 12:52 st_mueller
close_date - 2008-07-06 12:52 st_mueller
assigned_to nobody 2008-07-06 12:50 st_mueller
summary ^ shoudl work on vectors 2008-06-30 23:57 tedunning