O'Reilly logo

Matlab: A Practical Introduction to Programming and Problem Solving, 2nd Edition by Stormy Attaway

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 5

Vectorized Code

Contents

Key Terms

vectorizing

scalar operations

array operations

logical vectors

logical indexing

Although loops are extremely useful in most programming applications and necessary in many languages, in the MATLAB® software they are frequently not necessary especially when dealing with vectors or matrices. In this chapter, the concept of vectorizing will be introduced, which is the term used in MATLAB for rewriting code that was written using constructs such as loops in a traditional programming language and instead taking advantage of array ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required