Quaternion Function Reference

sum

Sum of array elements
(Quaternion and octonion overloadings of standard MATLAB® function)

Syntax

Y = sum(X, dim)

Description

sum(X, dim) computes the sum of the elements of the quaternion array X along dimension dim.

Examples

>>  sum([qi, qj, qk])
 
ans = 1 * I + 1 * J + 1 * K

See Also

QTFM function: prod
MATLAB® function: sum

© 2008-2013 Stephen J. Sangwine and Nicolas Le Bihan

License terms.