From f374fbf663a27d6a78c8fda6f160d39d4945e82c Mon Sep 17 00:00:00 2001 From: Vasil Zlatanov Date: Mon, 20 Feb 2017 15:06:24 +0000 Subject: Exact solution hint --- coursework17/ralston.m | 1 + 1 file changed, 1 insertion(+) diff --git a/coursework17/ralston.m b/coursework17/ralston.m index d910442..7ed4ad3 100644 --- a/coursework17/ralston.m +++ b/coursework17/ralston.m @@ -10,6 +10,7 @@ function [time_array, Vout_array] = ralston(R, L, Vin, current_initial, step, t_ % Given the input voltage as a function of time we can express % dI/dt (dcurrent_dt) as a function of time as well (given R and L) + % NOTE we can use the integrating factor to find exact solution dcurrent_dt = @(t, I) (Vin(t) - I*R)/L; % Loop as many times as step allows and: -- cgit v1.2.3