zeros()

Returns zeros matrix

Syntax
y = zeros(rows, columns)

Arguments
Name Description Range Type Required
rows number of rows † [i, ∞) integer yes
columns number of columns † [i, ∞) integer yes
† If only one argument is supplied, then a square matrix is returned. If two are supplied, then a matrix of zeros with size rows X cols is returned

Examples

a = zeros(2)
returns 0, 0}, {0, 0
b = zeros(2, 3)
returns 0, 0, 0}, {0, 0, 0

Defined in

Built in

See Also

identity(), ones()

 

Privacy Statement  | Terms of Use  | Legal | Contact Us  | © Agilent 2000-2008 

Contents
Additional Resources