//example 6.9 clc; funcprot(0); // Initialization of Variable Rl=12;//load resistance V1=.8;//voltage V2=2.4;//voltage D=.8;//duty cycle Tj=150;//degreeC Ta=40;//degreeC Vd=28; Vo=.7; I=40;//mA; //calculation k=(Vd-Vo)/I; disp(round(k*1000),"R1+R2 in ohm:") printf('pick R1=330ohm & R2=360ohm as they divide Vd setting 8V