{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Chapter 3: Diode Circuits and Rectifiers" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.10: to_determine_the_effect_of_reverse_recovery_time_on_the_avg_output_voltage.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_s=230;//V;\n", "t_rr=40*10^-6;//s reverde recovery time\n", "V_o=2*sqrt(2)*V_s/%pi;\n", "V_m=sqrt(2)*V_s;\n", "disp('when f=50Hz');\n", "f=50;\n", "V_r=(V_m/%pi)*(1-cosd(2*%pi*f*t_rr*180/%pi));\n", "v_avg=V_r*100/V_o*10^3; printf('percentage reduction in avg o/p voltage=%.3fx10^-3',v_avg);\n", "\n", "disp('when f=2500Hz');\n", "f=2500;\n", "V_r=(V_m/%pi)*(1-cosd(2*%pi*f*t_rr*180/%pi));\n", "v_avg=V_r*100/V_o; printf('percentage reduction in avg o/p voltage=%.3f',v_avg);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.11: EX3_11.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_s=230;//V\n", "R=10;//ohm\n", "V_m=sqrt(2)*V_s;\n", "V_o=2*V_m/%pi; printf('avg value of o/p voltage=%.2f V',V_o);\n", "I_o=V_o/R; printf('\navg value of o/p current=%.3f A',I_o);\n", "I_DA=I_o/2; printf('\navg value of diode current=%.3f A',I_DA);\n", "I_Dr=I_o/sqrt(2); printf('\nrms value of diode current=%.3f A',I_Dr);\n", "\n", "printf('\nrms value of o/p current=%.3f A',I_o);\n", "printf('\nrms value of i/p current=%.3f A',I_o);\n", "pf=(V_o/V_s); printf('\nsupply pf=%.2f',pf);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.12: EX3_12.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_s=230;//V\n", "R=1000;//ohm\n", "R_D=20;//ohm\n", "V_m=sqrt(2)*V_s;\n", "I_om=V_m/(R+R_D); printf('peak load current=%.4f A',I_om);\n", "I_o=I_om/%pi; printf('\ndc load current=%.5f A',I_o);\n", "V_D=I_o*R_D-V_m/%pi; printf('\ndc diode voltage=%.1f V',V_D);\n", "V_on=V_m/%pi; printf('\nat no load, load voltage=%.3f V',V_on);\n", "V_o1=I_o*R; printf('\nat given load, load voltage=%.3f V',V_o1);\n", "vr=(V_on-V_o1)*100/V_on; printf('\nvoltage regulation(in percent)=%.3f',vr);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.13: to_design_a_zener_voltage_regulator_to_meet_given_specifications.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_L=6.8;//V\n", "V_smax=20*1.2;//V\n", "V_smin=20*.8;//V\n", "I_Lmax=30*1.5;//mA\n", "I_Lmin=30*.5;//mA\n", "I_z=1;//mA\n", "\n", "R_smax=(V_smax-V_L)/((I_Lmin+I_z)*10^-3); printf('max source resistance=%.0f ohm',R_smax);\n", "R_smin=(V_smin-V_L)/((I_Lmax+I_z)*10^-3); printf('\nmin source resistance=%.0f ohm',R_smin);//in book solution, error is committed in putting the values in formulea(printing error) but solution is correct\n", "R_Lmax=V_L*1000/I_Lmin; printf('\nmax load resistance=%.1f ohm',R_Lmax);\n", "R_Lmin=V_L*1000/I_Lmax; printf('\nmin load resistance=%.1f ohm',R_Lmin);\n", "\n", "V_d=.6;//V\n", "V_r=V_L-V_d; printf('\nvoltage rating of zener diode=%.1f V',V_r);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.14: to_find_R1_and_R2.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "I2=200*10^-6;//A\n", "V_z=20;//V\n", "R_G=500;//ohm\n", "R2=(V_z/I2)-R_G; printf('R2=%.1f kilo-ohm',R2/1000);\n", "\n", "V_v=25;//V\n", "I1=I2;\n", "R1=(V_v-V_z)/I1; printf('\nR1=%.0f kilo-ohm',R1/1000);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.15: to_find_the_VA_rating_of_the_transformer.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_s=2*230;//V\n", "V_o=(sqrt(2)*V_s)/%pi;\n", "R=60;//ohm\n", "P_dc=(V_o)^2/R;\n", "TUF=0.2865;\n", "VA=P_dc/TUF; printf('kVA rating of the transformer=%.1f kVA',VA/1000);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.16: EX3_16.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "tr=0.5; //turns ratio\n", "I_o=10;\n", "V=230;\n", "V_s=V/tr;\n", "V_m=sqrt(2)*V_s;\n", "V_o=2*V_m/%pi; printf('o/p voltage=%.2f V',V_o);\n", "phi1=0; //displacemnt angle=0 as fundamnetal component of i/p source current in phase with source voltage\n", "DF=cosd(phi1); printf('\ndistortion factor=%.0f',DF);\n", "I_s1=4*I_o/(sqrt(2)*%pi);\n", "I_s=sqrt(I_o^2*%pi/%pi);\n", "CDF=I_s1/I_o; printf('\ncurrent displacent factor=%.1f',CDF);\n", "pf=CDF*DF; printf('\ni/p pf=%.2f',pf);\n", "HF=sqrt((I_s/I_s1)^2-1); printf('\nharmonic factor=%.2f',HF);\n", "CF=I_o/I_s; printf('\ncreast factor=%.2f',CF);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.17: to_determine_diode_rating_and_transformer_rating.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_o=230;\n", "R=10;\n", "V_s=V_o*%pi/(2*sqrt(2));\n", "I_o=V_o/R;\n", "I_m=sqrt(2)*V_s/R; printf('peak diode current=%.2f A',I_m);\n", "I_DAV=I_m/%pi; printf('\nI_DAV=%.2f A',I_DAV); //avg value of diode current\n", "I_Dr=I_m/2; printf('\nI_Dr=%.2f A',I_Dr); //rms value of diode current\n", "PIV=sqrt(2)*V_s; printf('\nPIV=%.1f V',PIV);\n", "I_s=I_m/sqrt(2);\n", "TF=V_s*I_s; printf('\ntransformer rating=%.2f kVA',TF/1000);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.18: EX3_18.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "tr=5;\n", "V=1100;\n", "R=10;\n", "disp('in case of 3ph-3pulse type');\n", "V_ph=V/tr;\n", "V_mp=sqrt(2)*V_ph;\n", "V_o=3*sqrt(3)*V_mp/(2*%pi); printf('avg o/p voltage=%.1f V',V_o);\n", "I_mp=V_mp/R;\n", "I_D=(I_mp/%pi)*sin(%pi/3); printf('\navg value of diode current=%.3f A',I_D);\n", "I_Dr=I_mp*sqrt((1/(2*%pi))*(%pi/3+.5*sin(2*%pi/3))); printf('\nrms value of diode current=%.2f A',I_Dr);\n", "V_or=V_mp*sqrt((3/(2*%pi))*(%pi/3+.5*sin(2*%pi/3)));\n", "P=(V_or^2)/R; printf('\npower delivered=%.1f W',P);\n", "\n", "disp('in case of 3ph-M6 type');\n", "V_ph=V_ph/2;\n", "V_mp=sqrt(2)*V_ph;\n", "V_o=3*V_mp/(%pi); printf('avg o/p voltage=%.2f V',V_o);\n", "I_mp=V_mp/R;\n", "I_D=(I_mp/%pi)*sin(%pi/6); printf('\navg value of diode current=%.4f A',I_D);\n", "I_Dr=I_mp*sqrt((1/(2*%pi))*(%pi/6+.5*sin(2*%pi/6))); printf('\nrms value of diode current=%.3f A',I_Dr);\n", "V_or=V_mp*sqrt((6/(2*%pi))*(%pi/6+.5*sin(2*%pi/6)));\n", "P=(V_or^2)/R; printf('\npower delivered=%.0f W',P);\n", "" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.19: determine_the_ratings_of_diodes_and_of_3ph_deltastar_transformer.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_o=400;\n", "R=10;\n", "V_ml=V_o*%pi/3;\n", "V_s=V_ml/(sqrt(2)*sqrt(3));\n", "I_m=V_ml/R;\n", "I_s=.7804*I_m;\n", "tr=3*V_s*I_s; printf('transformer rating=%.1f VA',tr);\n", "\n", "I_Dr=.5518*I_m; printf('\nrms value of diode current=%.3f A',I_Dr);\n", "I_D=I_m/%pi; printf('\navg value of diode current=%.3f A',I_D);\n", "printf('\npeak diode current=%.2f A',I_m);\n", "PIV=V_ml; printf('\nPIV=%.2f V',PIV);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.20: EX3_20.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_l=230;\n", "E=240;\n", "R=8;\n", "V_ml=sqrt(2)*V_l;\n", "V_o=3*V_ml/%pi;\n", "I_o=(V_o-E)/R;\n", "P_b=E*I_o; printf('power delivered to battery=%.1f W',P_b);\n", "P_d=E*I_o+I_o^2*R; printf('\npower delivered to load=%.2f W',P_d);\n", "\n", "phi1=0;\n", "DF=cosd(phi1);\n", "printf('\ndisplacement factor=%.0f',DF);\n", "I_s1=2*sqrt(3)*I_o/(sqrt(2)*%pi);\n", "I_s=sqrt(I_o^2*2*%pi/(3*%pi));\n", "CDF=I_s1/I_s; printf('\ncurrent distortion factor=%.3f',CDF);\n", "pf=DF*CDF; printf('\ni/p pf=%.3f',pf);\n", "HF=sqrt(CDF^-2-1); printf('\nharmonic factor=%.4f',HF);\n", "tr=sqrt(3)*V_l*I_o*sqrt(2/3); printf('\ntranformer rating=%.2f VA',tr);\n", "//answers have small variations from the book due to difference in rounding off of digits" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.21: design_capaitor_filter_and_avg_value_of_output_voltage_with_and_without_filter.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "f=50; //Hz\n", "V=230;\n", "V_m=sqrt(2)*V;\n", "R=400;\n", "RF=0.05;\n", "C=(1/(4*f*R))*(1+(1/(sqrt(2)*RF))); printf('capacitor value=%.1f uF',C/10^-6);\n", "V_o=V_m*(1-1/(4*f*R*C)); printf('\no/p voltage with filter=%.3f V',V_o);\n", "V_o=2*V_m/%pi; printf('\no/p voltage without filter=%.2f V',V_o);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.22: to_find_the_value_of_L_with_different_R_and_CRF_without_L.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "f=50;\n", "CRF=0.05;\n", "R=300;\n", "L=sqrt((CRF/(.4715*R))^-2-R^2)/(2*2*%pi*f); printf('L=%.4f H',L);\n", "R=30;\n", "L=sqrt((CRF/(.4715*R))^-2-R^2)/(2*2*%pi*f); printf('\nL=%.4f H',L);\n", "L=0;\n", "CRF=.4715*R/sqrt(R^2+(2*2*%pi*f*L)^2); printf('\nCRF=%.4f',CRF);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.23: to_design_LC_filter.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "R=50;\n", "L_L=10*10^-3;\n", "f=50;\n", "w=2*%pi*f;\n", "C=10/(2*w*sqrt(R^2+(2*w*L_L)^2)); printf('C=%.2f uF',C*10^6);\n", "VRF=0.1;\n", "L=(1/(4*w^2*C))*((sqrt(2)/(3*VRF))+1); printf('\nL=%.3f mH',L*10^3);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.2: EX3_2.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_s=400;//V\n", "V_o=100;//V\n", "L=100;//uH\n", "C=30;//uF\n", "t_o=%pi*sqrt(L*C); printf('conduction time of diode=%.2f us',t_o);\n", "//in book solution is t_o=54.77 us. The ans is incorrect as %pi is not muliplied in ans. Formulae mentioned in correct.\n", "I_p=(V_s-V_o)*sqrt(C/L); printf('\npeak current through diode=%.2f A',I_p);\n", "v_D=-V_s+V_o; printf('\nvoltage across diode=%.0f V',v_D);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.6: to_determine_conduction_time_of_diode_and_rate_of_change_of_current.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clc\n", "clear\n", "R=10;//ohm\n", "L=.001;//H\n", "C=5*10^-6;//F\n", "V_s=230;//V\n", "xi=R/(2*L);\n", "w_o=1/sqrt(L*C);\n", "w_r=sqrt((1/(L*C))-(R/(2*L))^2);\n", "t=%pi/w_r; printf('conduction time of diode=%.3f us',t*10^6);\n", "t=0;\n", "//di=di/dt\n", "di=V_s/L; printf('\nrate of change of current at t=0 is %.0f A/s',di);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.7: to_find_the_time_required_to_deliver_a_charge_of_200Ah.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "I_or=100;//A\n", "R=1;//assumption\n", "V_m=I_or*2*R;\n", "I_o=V_m/(%pi*R);\n", "q=200;//Ah\n", "t=q/I_o; printf('time required to deliver charge=%.04f hrs',t);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.8: EX3_8.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_s=230;//V\n", "P=1000;//W\n", "R=V_s^2/P;\n", "V_or=sqrt(2)*V_s/2;\n", "P_h=V_or^2/R; printf('power delivered to the heater=%.0f W',P_h);\n", "V_m=sqrt(2)*230;\n", "I_m=V_m/R; printf('\npeak value of diode current=%.4f A',I_m);\n", "pf=V_or/V_s; printf('\ninput power factor=%.3f',pf);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3.9: EX3_9.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "V_s=230;//V\n", "V_m=V_s*sqrt(2);\n", "E=150;//V\n", "theta1=asind(E/(sqrt(2)*V_s));\n", "R=8;//ohm\n", "f=50;//Hz\n", "I_o=(1/(2*%pi*R))*((2*sqrt(2)*V_s*cosd(theta1))-E*(%pi-2*theta1*%pi/180));\n", "printf('avg value of charging current=%.4f A',I_o);\n", "P_d=E*I_o; printf('\npower delivered to battery=%.2f W',P_d);\n", "I_or=sqrt((1/(2*%pi*R^2))*((V_s^2+E^2)*(%pi-2*theta1*%pi/180)+V_s^2*sind(2*theta1)-4*V_m*E*cosd(theta1))); printf('\nrms value of the load current=%.4f A',I_or);\n", "pf=(E*I_o+I_or^2*R)/(V_s*I_or); printf('\nsupply pf=%.3f',pf);\n", "P_dd=I_or^2*R; printf('\npower dissipated in the resistor=%.2f W',P_dd);\n", "q=1000.00;//Wh\n", "t=q/P_d; printf('\ncharging time=%.3f hr',t);\n", "n=P_d*100/(P_d+P_dd); disp(n,'rectifier efficiency(%)');\n", "PIV=sqrt(2)*V_s+E; printf('PIV of diode=%.2f V',PIV);\n", "//solutions have small variations due to difference in rounding off of digits" ] } ], "metadata": { "kernelspec": { "display_name": "Scilab", "language": "scilab", "name": "scilab" }, "language_info": { "file_extension": ".sce", "help_links": [ { "text": "MetaKernel Magics", "url": "https://github.com/calysto/metakernel/blob/master/metakernel/magics/README.md" } ], "mimetype": "text/x-octave", "name": "scilab", "version": "0.7.1" } }, "nbformat": 4, "nbformat_minor": 0 }