Category: Matlab

  • How to plot a function in Matlab

    How to plot a function in Matlab

    If you have chosen to use Matlab to plot a function today, and this happens to be the first time you want to do so, here area quick look at how you can instruct Matlab to plot your function. There are many online systems allowing you to plot function without having to go through “coding”, […]

  • A stability Matlab code

    A stability Matlab code

    If you have ever worked with numerical methods you will know that a major issue with using these methods is not only the exactness of the method but most time, we struggle too with stability of each of the methods. In this post I am simply going to give a Matlab code which you can […]

  • Runge kutta Matlab code

    Runge kutta Matlab code

    This is an exercise which is solved just for the purpose of comparing two numeral methods and see which one of them is more accurate. Here we will be using Matlab to solve the equations with two different methods, which are: Second order Runge Kutta method and the inbuilt matlab function ode45 (which is by […]

  • How to plot a circle in Matlab

    How to plot a circle in Matlab

    Here is  how to plot a circle in Matlab Plot the unity circle in Matlab Code Angles=(0,2*pi,100); plot(cos(angles), sin(angles)) Plot a circle in Matlab with a given radius Angles=(0,2*pi,100); plot(9*cos(angles), 9*sin(angles)) If you need MATLAB homework help from coding experts, you can visit this site.

  • Euler VS Runge kutta – Circle – Matlab code

    Euler VS Runge kutta – Circle – Matlab code

    In the context of this exercise, lets suppose having the two dependent following function: With initial conditions The equation of a circle look like the following where the r is a constant. If we add our equations at 0, the following will be true We are now going to be using Euler methods and the […]

  • How to design a Buck converter in Matlab

    How to design a Buck converter in Matlab

    A Buck Converter is a DC – DC step down voltage converter (can also be considered like step up current converter) . Here is how you can use Matlab to simulate a Buck converter (Note: In this post, we will consider switches as ideal) In order to get this task done in Matlab we will […]

  • RLC simulation in Matlab using Euler method

    RLC simulation in Matlab using Euler method

    Here is a comparison between the Implicit Euler Method and the Explicit Euler method on a given RLC circuit. We will be using the two methods stated above to model the variation of the current in the circuitry below. RLC simulation in Matlab We consider the capacitor voltage to be zero at the zero time. […]

  • Free fall – Modeling using Matlab

    Free fall – Modeling using Matlab

    In this post, we will simulate the fall of an object dropped from a certain height in air. We will be using some numerical technique to find the time at which the speed of the object stop changing and to find out if this speed is reached before the object reach the ground. We will  […]