Loren on the Art of MATLAB

Turn ideas into MATLAB

Note

Loren on the Art of MATLAB has been archived and will not be updated.

Posts 21 - 30 of 46

Results for: 2009

Computational Geometry in MATLAB R2009a, Part I 15

I'm pleased to introduce Damian Sheehy as this week's guest blogger. Damian is a geometry developer at The MathWorks, his background is in the area of geometric modeling and... read more >>

A Brief History of polyval 4

When I first started working at MathWorks, there were already a few functions in MATLAB for working with polynomials. One of these, polyval, for polynomial evaluation, used... read more >>

Find Largest Positive Value Next to Zero 19

Recently, Steve wrote a blog discussing code clarity/obscurity in the context of one-line code solutions. Simply stated, the problem he solved is this. Find the largest value in an... read more >>

Rooting Around in MATLAB – Part 3 4

I recently wrote a pair of posts (1 and 2) about finding roots of equations, and how you might use MATLAB to explore this topic with emphasis on the method of fixed point iteration. ... read more >>

Rooting Around in MATLAB – Part 2 2

In a recent post, I started a series of posts about finding roots of equations, and how you might use MATLAB to teach some of this topic. In particular, I will... read more >>

Rooting Around in MATLAB – Part 1 3

I've been interested in teaching for a long time, including ways to use MATLAB. One concept that students might need to understand early in their college careers is that of... read more >>

Hold Everything! 31

Have you ever tried to overlap more than one plot, only to find that you had to fiddle with a few times before it looked right? Perhaps this is because you aren't... read more >>

From struct to dataset 14

When I got to work last Friday, I saw an email discussion, on behalf of a customer, trying to find a good way to add a new field to a struct array.... read more >>

Optional Arguments Using Empty as Placeholder 11

I recently posted about optional input arguments and how to override default values. Gautam mentioned wanting to allow empty inputs as defaults. Contents ... read more >>

Nice Way to Set Function Defaults 40

Last week, I wrote a post on the switch statement in MATLAB. One theme in the comments was about using switch (or not!) for setting default values for input arguments that users didn't initialize. I realized that there is a nice pattern for setting these values that uses some compact, but readable code.... read more >>

Posts 21 - 30 of 46