Tag Archive for 'logical'

Matlab: array of true’s

Ok, now that I know the solution, this sounds really silly. I needed to create an array (of length N) with all entries set to logical true. A quick look in the help files suggested me to use the command ones (produces an array of 1’s) and to specify the class: array = ones(1,N,’logical’). However, Matlab refused to execute that. Looking again in the help, I found the true command which does exactly what I need: creating an array full of true’s. Simple, ain’t it? ;-)

array = true(1,N)

Mijn Intelligentie-ras


Your Dominant Intelligence is Logical-Mathematical Intelligence


You are great at finding patterns and relationships between things.
Always curious about how things work, you love to set up experiments.
You need for the world to make sense - and are good at making sense of it.
You have a head for numbers and math … and you can solve almost any logic puzzle.
You would make a great scientist, engineer, computer programmer, researcher, accountant, or mathematician.

What Kind of Intelligence Do You Have?

Al een geluk dat ik dat dan ook wel degelijk gestudeerd heb ;-)

(via)