Category: MATLAB

  • 3D Plotting: Meshgrid and Ndgrid; Contour, Mesh, Plot3, and Surface Plots

    Today we will be covering the following topics: 1. Meshgrid and Ndgrid 2. Contour Plots 3. Plot 3 4. Surface Plots – Using Surf 5. Mesh Plots – Using Mesh 6. Changing Color of 3D Plots VIDEO COMING SOON!   Meshgrid and Ndgrid MATLAB uses the commands meshgrid and ndgrid to go from a 1D…

    Read more...

  • Slice; Vector Field Plots

    In today’s lesson, we’re going to be covering the following topics: 1. Slice Function 2. Vector Field Plots video coming soon Slice Function The built-in MATLAB function slice allows you to slice through the x, y, or z plane of a 3D shape. The slice can be orthogonal (perpendicular) to the specified plane, and there…

    Read more...

  • Creating Input Statements

    In today’s lesson, we will be covering how to create input statements. Input statements are used in scripts to get the user to input a specific number rather than assigning one value to a variable. For example, if I wanted to make a code that added together two numbers that someone using my program would…

    Read more...

  • X-Y Plotting; Adding Titles and Axis Labels; Controlling the Axes

    In today’s lesson, we will be covering the following topics: 1. X-Y Plotting 2. Fplot and Ezplot 3. Adding Titles and Axis Labels 4. Controlling the Axes VIDEO COMING SOON X-Y Plotting To make a plot (only in two dimensions for now), we need a matching number of x- and y- values, just like we…

    Read more...

  • Anonymous Functions and Inline Functions

    In today’s lesson, we will be covering the following topics: 1. Anonymous Functions 2. Inline Functions video coming soon Anonymous Functions Anonymous functions aren’t technically “functions” in the sense that they need a special function file, but can be written within a script (check out the lesson on User Defined Functions here). They can accept…

    Read more...

  • Finding Derivatives and Integrals

    In today’s lesson, we will be covering the following topics: 1. Finding Derivatives 2. Finding Anti-Derivatives (Integrals) VIDEO COMING SOON Finding Derivatives If you’re in this course, you probably have already taken a calculus class – if not, check out the Differential and Integral Calculus courses for information on derivatives and integrals! I won’t explain…

    Read more...

  • Overlaying Plots Versus Subplot

    In today’s lesson, we will be covering the following topics: 1. Overlaying Plots 2. Subplots VIDEO COMING SOON Overlaying Plots We learned in a previous lesson how to plot simple X-Y graphs, but what if want to show multiple data sets in one plot? To do this, we can overlay plots. To do this, there…

    Read more...

  • Switchcase

    In today’s lesson, we will be covering the topic of switchcase.

    Read more...

  • Solve a Linear System of Equations; Eigenvalues and Eigenvectors

    In today’s lesson, we will be covering the following topics: 1. Solving a Linear System of Equations 2. Eigenvalues and Eigenvectors VIDEO COMING SOON Solving a Linear System of Equations MATLAB can help you solve a linear system of equations, which means solving for all the unknown variables in a set of equations. This can…

    Read more...

  • Strings and Scripts (aka M-File Scripts)

    In today’s lesson, we will cover the following topics: 1. Scripts (aka Script Files, M Scripts, M-File Scripts) 2. Strings VIDEO COMING SOON! Scripts So far, all the commands I have taught have usually been typed directly into the Command Window where each line of code runs one by one when you hit ‘enter’, and…

    Read more...