Variable order matrix with some constant value entry

1 次查看(过去 30 天)
How to make a matrix with all entries of -1 with a desired order. I want to make a matrix L= [-1 ;-1 ;-1], but size of L is another variable. i.e. I want L = -1 of size (x,y)

采纳的回答

Walter Roberson
Walter Roberson 2013-11-10
L = -1 * ones(x, y);

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Matrices and Arrays 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by