I need write the matrix (0 0 0 0 0), (1 0 0 0 0), (1 1 0 0 0), (1 1 1 0 0),..., (1 1 1 1 1) with 32 possibilities of zero and one using the matlab, and don´t hand.
And it´s possible to do the matrix (-1 -1 -1 -1 -1), (-1 -1 -1 -1 1), (-1 -1 -1 1 1), (-1 -1 1 1 1),..., (1 1 1 1 1) with 32 possibilities of one and one minus using the matlab, and don´t hand.
You can also cast to logical if you want a boolean type of variable:
logicalVariable = logical(doubleVariable);
Logical variables are useful in indexing, especially in image processing. In image processing a "binary" variable is usually assumed to be oflogical type ("class").
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
0 Comments
Sign in to comment.