diff options
author | prashantsinalkar | 2020-04-14 10:19:27 +0530 |
---|---|---|
committer | prashantsinalkar | 2020-04-14 10:23:54 +0530 |
commit | 476705d693c7122d34f9b049fa79b935405c9b49 (patch) | |
tree | 2b1df110e24ff0174830d7f825f43ff1c134d1af /Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra | |
parent | abb52650288b08a680335531742a7126ad0fb846 (diff) | |
download | all-scilab-tbc-books-ipynb-476705d693c7122d34f9b049fa79b935405c9b49.tar.gz all-scilab-tbc-books-ipynb-476705d693c7122d34f9b049fa79b935405c9b49.tar.bz2 all-scilab-tbc-books-ipynb-476705d693c7122d34f9b049fa79b935405c9b49.zip |
Initial commit
Diffstat (limited to 'Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra')
8 files changed, 3077 insertions, 0 deletions
diff --git a/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/1-Temperature.ipynb b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/1-Temperature.ipynb new file mode 100644 index 0000000..c55f88b --- /dev/null +++ b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/1-Temperature.ipynb @@ -0,0 +1,303 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 1: Temperature" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 1.1: Temperature_Conversion.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 1.1, page no-53\n", +"clear\n", +"clc\n", +"\n", +"c=-40\n", +"k=c+273\n", +"printf('\nK=%d°K', k)\n", +"F=((9/5)*c)+32\n", +"printf('\nF=%d°F',F)\n", +"R=((9/5)*c)+492\n", +"printf('\nR=%d°R',R)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 1.2: percentage_Accuracy_and_Error.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 1.2, page no-53\n", +"clear\n", +"clc\n", +"\n", +"span=1000\n", +"accuracy=1/100\n", +"err=span*accuracy\n", +"printf('(a)\nAs error can be either positive or negative ,\n the probable error at any point on the scale = %d°C',err)\n", +"max_scale=1200\n", +"Range_instr=max_scale+span\n", +"printf('\n(b)\nRange of the Instrument = %d°C',Range_instr)\n", +"meter_reading=700\n", +"per_of_err=(err/meter_reading)*100\n", +"printf('\n(c)\nPercentage of Error = ± %.2f%% ',per_of_err)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 1.3: Two_wire_RTD.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 1.3, page no-54\n", +"clear\n", +"clc\n", +"resi_per_leg=5\n", +"temp_coeff=0.385\n", +"R_due_to_leadwires=2*resi_per_leg\n", +"err=R_due_to_leadwires/temp_coeff\n", +"err=ceil(err)\n", +"printf('(a)\nThe contribution of 10 ohms lead wire resistance \nto the measurement error = %d°C',err)\n", +"temp_obj=200\n", +"temp_measured=temp_obj+err\n", +"per_of_err=((temp_measured-temp_obj)/temp_obj)*100\n", +"printf('\n(b)\nPercentage of Error = %d%%',per_of_err)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 1.4: Thermocouple_temperature_measurement.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 1.4, page no-54\n", +"clear\n", +"clc\n", +"\n", +"temp=2.022\n", +"millivolt_cor=37.325\n", +"op=millivolt_cor-temp\n", +"printf('Millivolt output available=% .3f',op)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 1.5: Hot_junction_temperature_of_thermocouple.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 1.5, page no-54\n", +"clear\n", +"clc\n", +"millivolt_cor=2.585\n", +"pot_reading=30.511\n", +"corrected_millivolt=pot_reading+millivolt_cor\n", +"printf('Temperature correspond to %.3f mV from the table = 600°C',corrected_millivolt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 1.6: Caliberation_of_an_instrument.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 1.6, page no-54\n", +"clear\n", +"clc\n", +"ref_jun=100\n", +"mV_100=0.645\n", +"mV_1000=9.585\n", +"mV_1200=11.947\n", +"op1=mV_1000-mV_100\n", +"op2=mV_1200-mV_100\n", +"printf('Millivolt to be fed checking 1000 C = %.3f mV',op1)\n", +"printf('\nMillivolt to be fed checking 1200 C = %.3f mV',op2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 1.7: Wall_temperature_measurement.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 1.7, page no-55\n", +"clear\n", +"clc\n", +"E_rec_pyro=0.95*0.85\n", +"T=1100/E_rec_pyro\n", +"printf('Pyrometer reading T = %.2f°C',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 1.8: Thermocouple_output.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 1.8, page no-55\n", +"clear\n", +"clc\n", +"//(a)\n", +"hot1_mV=41.29\n", +"cold1_mV=2.022\n", +"op1=hot1_mV-cold1_mV\n", +"\n", +"//(b)\n", +"hot2_mV=33.096\n", +"cold2_mV=2.585\n", +"op2=hot2_mV-cold2_mV\n", +"\n", +"//(c)\n", +"hot3_mV=11.947\n", +"cold3_mV=0.299\n", +"op3=hot3_mV-cold3_mV\n", +"\n", +"printf('(a)\nOutput Millivolt = %.3f',op1)\n", +"printf('\n(b)\nOutput Millivolt = %.3f',op2)\n", +"printf('\n(c)\nAs the wrongly formed thermocouples at J1 and J2 will always oppose\n the main millivolt output, the net output will be lower than normal value.\nOutput mV<%.3f',op3)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 1.9: electtronic_temperature_transmitter.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 1.9, page no-56\n", +"clear\n", +"clc\n", +"\n", +"Rl_ind=250\n", +"Rl_rec=250\n", +"load_connected= Rl_ind+Rl_rec\n", +"load_allowable=600\n", +"max_load_controller=load_allowable-load_connected\n", +"printf('(a)\nThe max load to the controller = %d ohms',max_load_controller)\n", +"\n", +"op_cont=600\n", +"total=Rl_ind+Rl_rec+load_allowable\n", +"extra_load=total-op_cont\n", +"printf('\n(b)\nExtra Load = %d ohms',extra_load)\n", +"\n", +"printf('\nAdditional Power Supply voltage required=10 V')\n", +"\n", +"printf('\nMinimum Power Supply Voltage=34 ')" + ] + } +], +"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 +} diff --git a/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/2-Pressure.ipynb b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/2-Pressure.ipynb new file mode 100644 index 0000000..27d84b3 --- /dev/null +++ b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/2-Pressure.ipynb @@ -0,0 +1,413 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 2: Pressure" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.10: Capacitance_calculation_for_variable_dielectric.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.10, page no-121\n", +"clear\n", +"clc\n", +"\n", +"c=0.57\n", +"\n", +"//(a)\n", +"d=0.1\n", +"di1=100\n", +"di2=1000\n", +"c1=c*di1*10/d\n", +"c1=ceil(c1)\n", +"printf('(a)\nC1=%d pf',c1)\n", +"\n", +"//(b)\n", +"c2=c*di2*10/d\n", +"printf('\n(b)\nC2=%d pf',c2)\n", +"\n", +"//(c)\n", +"ds=0.09\n", +"c11=c*di1*10/ds\n", +"c12=c*di2*10/ds\n", +"printf('\n(c)\nC1 = %.1f pf\nC2 = %d pf',c11,c12)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.11: pressure_gauge_caliberatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.11, page no-121\n", +"clear\n", +"clc\n", +"\n", +"A=1\n", +"p1=10\n", +"W1=A*p1\n", +"printf('W1 = %d kg',W1)\n", +"printf('\nWith the 4 standard weights of 10kg, 20kg, 30kg and 40kg ')" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.12: pressure_calculation_using_McLeod_gauge.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.12, page no-122\n", +"clear\n", +"clc\n", +"\n", +"p1=10^-2\n", +"h1=20\n", +"K=p1/h1^2\n", +"p2=K*30^2\n", +"p2=p2*100\n", +"printf('The unknown pressure p2 = %.2f * 10^-2 torr',p2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.1: Pressure_conversion.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.1, page no-116\n", +"clear\n", +"clc\n", +"\n", +"//(a)\n", +"//1kg/cm^2=10000 mmWG\n", +"x=10000*10\n", +"printf('(a)\n 10kg/cm^2 = %d mmWG',x)\n", +"\n", +"//(b)\n", +"onemm_Hg=13.546\n", +"y=10^5/onemm_Hg\n", +"y=y/10^3\n", +"printf('\n(b)\n10kg/cm^2 = 10^5 mmWG = %.2f * 10^3 mmHg',y)\n", +"\n", +"//(c)\n", +"onebar=1.03 \n", +"z=10/onebar\n", +"printf('\n(c)\n10kg/cm^2 = %.2f bars',z)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.2: Gauge_and_absolute_pressure.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.2, page no-116\n", +"clear\n", +"clc\n", +"\n", +"//(a)\n", +"gamm=1000\n", +"d=35\n", +"dens_Hg=13.546\n", +"press_in_kg_cm=gamm*d*10^-4\n", +"press_in_mmHg=gamm*d/dens_Hg\n", +"press_in_mmHg=press_in_mmHg/10^3\n", +"printf('(a)\nThe pressure at depth of %d meters in a water tank=%.1f kg/cm^2 = %.2f*10^3 mmHg',d,press_in_kg_cm,press_in_mmHg)\n", +"\n", +"//(b)\n", +"press_atm=1.03\n", +"abspress=press_in_kg_cm+press_atm\n", +"abspress_mmHg=press_in_mmHg*1000+760\n", +"abspress_mmHg=abspress_mmHg/1000\n", +"printf('\n(b)\nAbsolute Pressure= %.2f kg/cm^2 Abs = %.2f*10^3 mmHg Abs',abspress,abspress_mmHg)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.3: Gauge_and_absolute_pressure.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.3, page no-116\n", +"clear\n", +"clc\n", +"\n", +"egp=260\n", +"abspress=760-egp\n", +"printf('Absolute Presssure = %d mmHg',abspress)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.4: pressure_measurement_using_U_tube_manometer.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.4, page no-117\n", +"clear\n", +"clc\n", +"\n", +"//(a)\n", +"p_diff=500\n", +"pdiff=p_diff*13.546/10000\n", +"printf('(a)\np1-p2 = %.3f kg/cm^2',pdiff)\n", +"\n", +"//(b)\n", +"p1=6770\n", +"p_atm=10300\n", +"abs_p1=p1+p_atm\n", +"printf('\n(b)If p2 is open to atmosphere:\nAbsolute Pressure P1 = %d mmWG abs.',abs_p1)\n", +"\n", +"//(c)\n", +"P1=500\n", +"P1_gauge=P1-760\n", +"printf('\n(c)If p2 is evacuated and sealed:\np1= %d mmHg gauge Pressure',P1_gauge)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.5: Specific_Gravity_and_weight_density.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.5, page no-117\n", +"clear\n", +"clc\n", +"\n", +"spe_grav_water=1\n", +"spe_grav_X=spe_grav_water*100/50\n", +"wt_dens_water=1000\n", +"wt_dens_X=wt_dens_water*2\n", +"printf('Weight Density of X = %d kg/m^3',wt_dens_X)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.6: water_flow_rate_using_mercury_manometer.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.6, page no-117\n", +"clear\n", +"clc\n", +"\n", +"A=1/20\n", +"p_diff=1500\n", +"printf('(a)\nAs Delta_h=A2/A1*h << h and normally negligiblefor well type manometer\nhence, p1-p2 = h = %d =111 mmHg',p_diff)\n", +"\n", +"printf('\n(b)\nh measured above the oriinal reference will be half of H, i.e. 111/2=55.5 mmHg\n(Since area of both legs are same)')" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.7: readings_and_errors_in_Bourdon_gauge_reading.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.7, page no-119\n", +"clear\n", +"clc\n", +"\n", +"printf('1 kg/cm^2 = 10 mWG\n')\n", +"//(a)\n", +"press=10+2\n", +"printf('\n(a)Bourdon Gauge is mounted 20 meters below water line:\nPressure read by the Gauge = %d kg/cm^2',press)\n", +"\n", +"//(b)\n", +"press2=10-3\n", +"printf('\n\n(b)Bourdon Gauge is located 30 meters above the water line:\nPressure read by the Gauge = %d kg/cm^2',press2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.8: Specific_Gravity_and_density_of_liquid.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.8, page no-120\n", +"clear\n", +"clc\n", +"\n", +"dens_water=1000\n", +"h1=125\n", +"h2=250\n", +"d2=(h1/h2)*dens_water\n", +"printf('(a)\nDensity of Liquid = %d kg/m^3',d2)\n", +"printf('\nSpecific Density of the liquid = %.1f',(h1/h2))\n", +"\n", +"//(b)\n", +"printf('\n\n(b)\nIf Values of water and liquid interchanged:\n')\n", +"d3=(h2/h1)*dens_water\n", +"printf('\nDensity of Liquid = %d kg/m^3',d3)\n", +"printf('\nSpecific Density of the liquid = %.1f',(h2/h1))" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.9: strain_gauge_wire_length_and_cross_section_area.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 2.9, page no-120\n", +"clear\n", +"clc\n", +"\n", +"R=120\n", +"l=122\n", +"a=0.1\n", +"rho=R*a/l\n", +"R1=140\n", +"l1=sqrt(R1*a*l/rho)\n", +"l1=ceil(l1)\n", +"printf('Length l1 = %d meters',l1)\n", +"A1=a*l/l1\n", +"printf('\nArea A1 = %.4f mm^2',A1)" + ] + } +], +"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 +} diff --git a/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/3-Force_Torque_and_Velocity.ipynb b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/3-Force_Torque_and_Velocity.ipynb new file mode 100644 index 0000000..8ad5f37 --- /dev/null +++ b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/3-Force_Torque_and_Velocity.ipynb @@ -0,0 +1,298 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 3: Force Torque and Velocity" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.1: Force_calculatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 3.1, page no-163\n", +"clear\n", +"clc\n", +"m1=20\n", +"a=5\n", +"F=m1*a\n", +"printf('F = %d Newtons',F)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.2: Weight_calculatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 3.2, page no-163\n", +"clear\n", +"clc\n", +"\n", +"m1=50\n", +"g1=9.8\n", +"W2=m1*g1\n", +"printf('W = %d Newtons = %d kgf',W2,m1)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.3: calculation_of_specific_gravity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 3.3, page no-164\n", +"clear\n", +"clc\n", +"wt_material=2500\n", +"wt_water=1000\n", +"spe_grav=wt_material/wt_water\n", +"\n", +"printf('Specific gravity of the material = %.1f',spe_grav)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.4: Estimation_of_uncertainty_due_to_sensitivity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 3.4, page no-164\n", +"clear\n", +"clc\n", +"\n", +"L=20\n", +"W=2000\n", +"db=0.02\n", +"Wb=100\n", +"dG=0.5\n", +"S=L/(2*W*db+Wb*dG)\n", +"printf('S = %.3f rad/g',S)\n", +"\n", +"fi=0.2\n", +"DeltaW=fi*3.14/(180*S)\n", +"printf('\nDeltaW = %.3f g',DeltaW)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.5: Torque_Calculatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 3.5, page no-164\n", +"clear\n", +"clc\n", +"hp=746\n", +"P=5*hp\n", +"N=1500\n", +"n=N/60\n", +"T=P*60/(2*3.14*n)\n", +"printf('T = %d Newton meters',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.6: Force_calculatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 3.6 page no-165\n", +"clear\n", +"clc\n", +"ch_l=0.075\n", +"orig_l=50\n", +"\n", +"S=ch_l/orig_l\n", +"E=9.66*10^5\n", +"stress=E*S\n", +"area=1.5\n", +"f=stress*area\n", +"printf('Strain = %.4f cm/cm\nStress =%d kg/cm^2\nForce = %.1f kg',S,stress,f)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.7: resistance_strain_gauge.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 3.7, page no-165\n", +"clear\n", +"clc\n", +"\n", +"//(a)\n", +"R1=120\n", +"R2=120\n", +"R3=120\n", +"R4=120\n", +"Rg=100\n", +"C=(R1*R2*R4)+(R1*R3*R4)+(R1*R2*R3)+(R2*R3*R4)+(Rg*(R1+R4)*(R2+R3))\n", +"C=C/10^7\n", +"printf('(a)\nC=%.3f*10^7',C)\n", +"E=10\n", +"F=E*R3*R1*2*10^3/(C*10^7)\n", +"printf('\nF = %.1f *10^3 A/mm = %.1f mA/mm',F,F)\n", +"\n", +"//(b)\n", +"Fe=2*10^-4\n", +"E=10\n", +"DeltaE=Fe*E/(4+4*10^-4)\n", +"DeltaE=DeltaE*10^3\n", +"printf('\n(b)\nDeltaEg=%.1f mV',DeltaE)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.8: speed_measurement_using_stroboscope.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 3.8, page no-167\n", +"clear\n", +"clc\n", +"\n", +"//(a)\n", +"r1=2500\n", +"r2=1500\n", +"n=(r1*r2)/(r1-r2)\n", +"printf('(a)\nn = %d rpm',n)\n", +"\n", +"//(b)\n", +"N=5\n", +"r5=n*r1/((r1*(N-1))+n)\n", +"r5=ceil(r5)\n", +"printf('\n(b)\nr5=%d',r5)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.9: speed_measurement_using_proximity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 3.9, page no-167\n", +"clear\n", +"clc\n", +"rpm=1500\n", +"f=200\n", +"N=60*f/rpm\n", +"\n", +"printf('No of teeth on the wheel\nN=%d',N)" + ] + } +], +"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 +} diff --git a/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/4-Acceleration_Vibration_and_Density.ipynb b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/4-Acceleration_Vibration_and_Density.ipynb new file mode 100644 index 0000000..7c940f6 --- /dev/null +++ b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/4-Acceleration_Vibration_and_Density.ipynb @@ -0,0 +1,375 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 4: Acceleration Vibration and Density" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.10: Specific_Gravity_of_unknown_liquid.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.10, page no-212\n", +"clear\n", +"clc\n", +"Ww=12-2\n", +"dw=1000\n", +"v=Ww/dw\n", +"dx=(10-2)/v\n", +"sg=dx/dw\n", +"\n", +"printf('Specific Gravity of X =%.1f',sg)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.11: calculation_of_specific_gravity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.11, page no-213\n", +"clear\n", +"clc\n", +"\n", +"//(a)\n", +"v_obj=2/1000\n", +"wt=1.5\n", +"dx=wt/v_obj\n", +"sg=dx/1000\n", +"printf('(a)\nSpecific Gravity = %.2f',sg)\n", +"\n", +"//(b)\n", +"sgl=0.8\n", +"dens=800\n", +"W1=dens*v_obj-wt\n", +"printf('\n(b)\nW1 = %.1f kg',W1)\n", +"\n", +"//(c)\n", +"sg2=1.2\n", +"dens2=1200\n", +"W2=dens2*v_obj-wt\n", +"printf('\n(c)\nW2 = %.1f kg',W2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.1: mechanical_system_for_a_seismic_instrument.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.1, page no-209\n", +"clear\n", +"clc\n", +"\n", +"//(a)\n", +"k=50\n", +"m=0.005\n", +"wn=sqrt(k/m)\n", +"printf('(a)\nNatural frequency(wn)= %d rad/s',wn)\n", +"//(b)\n", +"Cc=2*sqrt(m*k)\n", +"printf('\n(b)\nCc=%d',Cc)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.2: Frequency_and_phase_angle_of_motion.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.2, page no-209\n", +"clear\n", +"clc\n", +"\n", +"//(a)\n", +"Cc=1.0\n", +"C=0.7*Cc\n", +"m=0.005\n", +"k=50\n", +"w=sqrt((k/m)-(C/(2*m))^2)\n", +"printf('(a)\nw=%.1f rad/s',w)\n", +"//(b)\n", +"w1=250\n", +"theta=C*w1/(k-m*w1^2)\n", +"printf('\ntheta=%f',theta)\n", +"fi=atan(-theta)\n", +"fi=fi*180/%pi\n", +"printf('\nfi = %d°',fi)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.3: time_calculation_for_exponetial_transient_term.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.3, page no-210\n", +"clear\n", +"clc\n", +"m=0.005\n", +"c=0.7\n", +"y=-log(0.01)\n", +"//printf('y=%.2f',y)\n", +"t=y*2*m/c\n", +"printf('t=%.4f Secs',t)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.4: Acceleration_measurement.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.4, page no-210\n", +"clear\n", +"clc\n", +"rg1=1200\n", +"rg2=1200\n", +"rg3=1200\n", +"rg4=1200\n", +"D1=rg1*5/100\n", +"D2=rg2*5/100\n", +"D3=rg3*5/100\n", +"D4=rg4*5/100\n", +"E=12\n", +"v=E*(((rg1+D1)/(rg1+D1+rg2-D2))-((rg4-D4)/(rg3+D3+rg4-D4)))\n", +"v=v*1000\n", +"printf('V0=%d mV',v)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.5: output_voltage_of_quartz_piezoelectric_crystal.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.5, page no-211\n", +"clear\n", +"clc\n", +"g=0.06\n", +"t=2.5*10^-3\n", +"p=20*9.8*10^4\n", +"E=g*t*p\n", +"printf('E=%d V',E)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.6: Differential_values_of_capacitor.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.6, page no-211\n", +"clear\n", +"clc\n", +"\n", +"c0=25\n", +"x0=0.5\n", +"x1=0.05\n", +"c1=c0*x0/(x0-x1)\n", +"c2=c0*x0/(x0+x1)\n", +"printf('C1=%.2f pF\nC2=%.2f pF',c1,c2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.7: Specific_Gravity_Conversion.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.7, page no-211\n", +"clear\n", +"clc\n", +"\n", +"//(a)\n", +"sg_at_60=1.02\n", +"API=(141.5/sg_at_60)-131.5\n", +"printf('(a)\nDegrees API = %.2f°API',API)\n", +"//(b)\n", +"Be=145-145/sg_at_60\n", +"printf('\n(b)\nDegrees Baume(heavy) = %.1f°Be',Be)\n", +"//(c)\n", +"Bk=(sg_at_60-1)*1000\n", +"printf('\n(c)\nDegrees Barkometer = %d°Bk',Bk)\n", +"//(d)\n", +"Q=(sg_at_60-1)*1000\n", +"printf('\n(c)\nDegrees Quevenne = %d°Q',Q)\n", +"//(e)\n", +"Tw=200*(sg_at_60-1.0)\n", +"printf('\n(d)\nDegrees Twaddel = %d°Tw',Tw)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.8: calculation_of_the_volume_of_displacer.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.8, page no-212\n", +"clear\n", +"clc\n", +"T=0.5\n", +"sg1=1.02\n", +"sg2=0.98\n", +"wt=1000*10^-6\n", +"v=T/((sg1-sg2)*wt)\n", +"v=ceil(v)\n", +"printf('V=%d cm^3',v)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.9: Differential_pressure_Sensor.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 4.9, page no-212\n", +"clear\n", +"clc\n", +"sg1=0.85\n", +"sg2=0.8\n", +"span=150\n", +"H=span/(sg1-sg2)\n", +"printf('(a)\nH=%d mm = %dm',H,H/1000)\n", +"span_min=1500\n", +"span2=span_min*(sg1-sg2)\n", +"span2=ceil(span2)\n", +"printf('\n(b)\nD/P span = %d mm',span2)" + ] + } +], +"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 +} diff --git a/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/5-Flow.ipynb b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/5-Flow.ipynb new file mode 100644 index 0000000..94ffb07 --- /dev/null +++ b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/5-Flow.ipynb @@ -0,0 +1,608 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 5: Flow" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.11: detemination_of_flow_velocity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.11, page no-314\n", +"clear\n", +"clc\n", +"dens=1026\n", +"p=25*10^3\n", +"V=sqrt(2*p/dens)\n", +"printf('V=%.2f m/sec =%.3f km/hr',V,V*18/5)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.12: calculation_of_flying_speed_of_aircraft.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.12, page no-314\n", +"clear\n", +"clc\n", +"dens=1.29\n", +"p=12.5*10^3\n", +"V=sqrt(2*p/dens)\n", +"printf('V=%.2f m/sec =%.2f km/hr',V,V*18/5)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.13: Maximum_fluid_handling_capacity_of_Rotameter.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.13, page no-315\n", +"clear\n", +"clc\n", +"Cd=0.6\n", +"Dp=0.05\n", +"Df=0.035\n", +"g=9.8\n", +"rho_f=3.9*10^3\n", +"rho=1000\n", +"Vf=3.36*10^-5\n", +"Q=Cd*((Dp^2-Df^2)/Df)*sqrt(3.14*g*Vf*(rho_f-rho)/(2*rho))\n", +"Q=Q*10000\n", +"printf(' Volumetric flow Q=%.4f *10^-4 m^3/sec',Q)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.14: Determination_of_range_of_flow_for_ratameter.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.14, page no-315\n", +"clear\n", +"clc\n", +"\n", +"Cd=1\n", +"Dp=0.018\n", +"Df=0.015\n", +"g=9.81\n", +"rho_f=2.7\n", +"rho=0.8\n", +"Vf=520*10^-9\n", +"//case 1\n", +"\n", +"Qmin=Cd*((Dp^2-Df^2)/Df)*sqrt(%pi*g*Vf*(rho_f-rho)/(2*rho))\n", +"Qmin=Qmin*100000\n", +"printf('Case 1: When float is at the bottom\n Volumetric flow Qmin=%.3f *10^-5 m^3/sec',Qmin)\n", +"\n", +"//case 2\n", +"Dp2=0.0617\n", +"Qmax=Cd*((Dp2^2-Df^2)/Df)*sqrt(%pi*g*Vf*(rho_f-rho)/(2*rho))\n", +"Qmax=Qmax*100000\n", +"printf('\n\nCase 2: When float is at the bottom\n Volumetric flow Qmax=%.2f *10^-5 m^3/sec',Qmax)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.15: calculation_of_coal_delivery_for_coal_conveyor_system.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.15, page no-316\n", +"clear\n", +"clc\n", +"W=165\n", +"R=328\n", +"L=16\n", +"Q=W*R/L\n", +"printf(' Flow Rate Q=%.2f kg/min =%.1f kg/hour',Q,Q/60)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.16: Fluid_velocity_calculatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.16, page no-316\n", +"clear\n", +"clc\n", +"f=100\n", +"d=300*10^-3\n", +"a=45\n", +"a_rad=45*%pi/180\n", +"v=f*d/(2*cos(a_rad))\n", +"printf(' Fluid Velocity V=%.1f m/sec',v)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.17: volume_flow_rate.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.17, page no-316\n", +"clear\n", +"clc\n", +"\n", +"r=150\n", +"v=120\n", +"Q=4*v*r\n", +"printf(' Volume flow rate Q=%d cm^3/min = %d litres/min',Q,Q/1000)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.18: induced_emf_in_electromagnetic_flow_meter.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.18, page no-317\n", +"clear\n", +"clc\n", +"Q=2500\n", +"d=2.75\n", +"a=(%pi*d^2)/4\n", +"v=Q/(60*a)\n", +"B=60\n", +"e=B*d*10^-2*v*10^-2\n", +"printf(' Induced emf e =%.4f V=%.1f mV',e,e*1000)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.19: velocity_of_flow_in_electromagnetic_flow_meter.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 5.19, page no-317\n", +"clear\n", +"clc\n", +"\n", +"e=0.2*10^-3\n", +"B=0.08\n", +"l=10*10^-2\n", +"v=e/(B*l)\n", +"printf('V = %.3f m/sec = %.2f cm/sec',v,v*100)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.1: flow_rate_calulatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.1, page no-310\n", +"clear\n", +"clc\n", +"//(i)\n", +"d=75*10^-3\n", +"a=3.141*d^2/4\n", +"v=760*10^-3\n", +"Q=v*a\n", +"Q=Q*10^3\n", +"printf('(i)\nVolume Flow Rate Q=%.3f *10^-3 m^3/sec',Q)\n", +"rho=1000\n", +"W=rho*Q*10^-3\n", +"printf('\n(ii)\nMass Flow rate W=%.3f kg/sec',W)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.20: average_velocity_of_flow_in_electromagnetic_flow_meter.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 5.20, page no-317\n", +"clear\n", +"clc\n", +"\n", +"ei=0.15*10^-3\n", +"em=2*ei\n", +"B=0.1\n", +"l=60*10^-3\n", +"v=em/(B*l)\n", +"printf('Velocity of flow V = %.2f m/sec = %.1f cm/sec',v,v*100)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.2: Volumetric_flow_rate_calculatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.2, page no-310\n", +"clear\n", +"clc\n", +"\n", +"D=40\n", +"d=20\n", +"mr=15\n", +"h=(13.6-1)*15*10\n", +"B=d/D\n", +"M=1/sqrt(1-B^4)\n", +"//printf('%f\n',B)\n", +"Cd=0.5999\n", +"x=sqrt(2*9.8*h*10^-3)\n", +"Q=x*Cd*M*(3.14*(20*10^-3)^2)/4\n", +"Q=Q*3600\n", +"printf('Volumetric flow rate Q= %.4f m^3/hr',Q)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.3: Nominal_flow_velocity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.3, page no-310\n", +"clear\n", +"clc\n", +"Re=10^5\n", +"D=40*10^-3\n", +"v=10^-6\n", +"V1=Re*v/D\n", +"A1=(3.14*(40*10^-3)^2)/4\n", +"A2=(3.14*(20*10^-3)^2)/4\n", +"V2=V1*A1/A2\n", +"printf('V2=%.1f m/sec',V2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.4: pressure_difference_calculation.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.4, page no-311\n", +"clear\n", +"clc\n", +"Cd=0.61\n", +"D=40*10^-3\n", +"d=20*10^-3\n", +"M=1/sqrt(1-(d/D)^4)\n", +"//printf('%.4f\n',M)\n", +"V2=10\n", +"rho=1000\n", +"g=9.8\n", +"X=V2*sqrt(rho/(2*g))/(Cd*M)\n", +"p_diff=X^2\n", +"\n", +"p_diff=floor(p_diff/100)\n", +"p_diff=p_diff/100\n", +"printf('P1-P2 = %.2f kg/cm^2',p_diff)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.5: volume_flow_rate_for_orifice_and_venturi_Tubes.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.5, page no-312\n", +"clear\n", +"clc\n", +"Cd=0.6\n", +"D=150*10^-3\n", +"d=75*10^-3\n", +"p=250\n", +"g=9.8\n", +"rho=1000\n", +"s=75*10^-3\n", +"//(a)\n", +"\n", +"Q=Cd*3.14*s^2*sqrt(2*g*p/rho)/(4*sqrt(1-(d/D)^4))\n", +"printf('(a) For orifice plate\nQ=%f m^3/sec = %.3f litres/sec',Q,Q*1000)\n", +"Cd1=0.99\n", +"Q2=Cd1*3.14*s^2*sqrt(2*g*p/rho)/(4*sqrt(1-(d/D)^4))\n", +"printf('\n\n(b)For venturi tube\nQ=%f m^3/sec = %.2f litres/sec',Q2,Q2*1000)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.6: determination_of_Reynolds_number.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.6, page no-312\n", +"clear\n", +"clc\n", +"\n", +"//(i)\n", +"V=0.02\n", +"d=10*10^-2\n", +"A=%pi*d^2/4\n", +"v=V/A\n", +"rho=1000\n", +"Re=rho*v*d/10^-3\n", +"Re=Re/100000\n", +"printf('(i)\nReynolds number(Re) = %.3f * 10^5',Re)\n", +"\n", +"//(ii)\n", +"Cd=0.98\n", +"D=20*10^-2\n", +"d=10*10^-2\n", +"M=1/sqrt(1-(d/D)^4)\n", +"a2=3.14*d^2/4\n", +"Q=0.02\n", +"g=9.8\n", +"X=Q*sqrt(rho)/(M*Cd*a2*sqrt(2*g))\n", +"p_diff=ceil(X^2)\n", +"printf('\n(ii)\nPressur_difference = %d kg/m^2 = %.4f kg/cm^2',p_diff,p_diff/10000)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.7: Fluid_velocity_and_Volumetric_flow_rate.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.7, page no-313\n", +"clear\n", +"clc\n", +"//1kg/m^2=10 meters water head\n", +"g=9.81\n", +"h=20\n", +"v=sqrt(2*g*h)\n", +"d=300*10^-3\n", +"A=(3.14*d^2)/4\n", +"A=floor(A*1000)\n", +"A=A/1000\n", +"Q=A*v\n", +"printf('Q=%.3f m^3/sec',Q)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.8: Fluid_velocity_calculatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.8, page no-313\n", +"clear\n", +"clc\n", +"Cd=0.6\n", +"g=9.8\n", +"h=400*10^-3\n", +"V=Cd*sqrt(2*g*h)\n", +"printf('V = %.2f m/sec',V)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.9: velocity_measurement_using_pilot_tube.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 5.9, page no-314\n", +"clear\n", +"clc\n", +"\n", +"Cd=0.98\n", +"g=9.8\n", +"h=900*10^-3\n", +"V=Cd*sqrt(2*g*h)\n", +"V=floor(V*100)\n", +"V=(V/100)\n", +"printf('V = %.2f m/sec',V)\n", +"" + ] + } +], +"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 +} diff --git a/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/6-Level.ipynb b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/6-Level.ipynb new file mode 100644 index 0000000..6ca6b88 --- /dev/null +++ b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/6-Level.ipynb @@ -0,0 +1,347 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 6: Level" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.10: calculation_of_level_on_the_probe.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.10, page no-375\n", +"clear\n", +"clc\n", +"c2=100*10^-6\n", +"r1=10*10^3\n", +"r2=100*10^3\n", +"r3=50*10^3\n", +"Cx=r1*c2/r3\n", +"Cx=Cx*10^6\n", +"printf('Cx = %d microFarad',Cx)\n", +"c=5\n", +"l=Cx/c\n", +"printf('\nLevel on the probe = %dm',l)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.1: output_current_of_two_wire_pressure_transmitter.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.1, page no-370\n", +"clear\n", +"clc\n", +"//(a)\n", +"p=1.5\n", +"a=4\n", +"b=20\n", +"wh=(((b-a)/2)*p)+a\n", +"printf('(a)just at the bottom level of the tank\nWater head applied to the transmitter =%d mA ',wh)\n", +"//(b)\n", +"wh2=(((b-a)/2)*p)+2*a\n", +"printf('\n\n(b)5m below the bottom of the tank\nWater head applied to the transmitter =%d mA ',wh2)\n", +"//(c)\n", +"wh3=(((b-a)/2)*p)\n", +"printf('\n\n(c)5m above the bottom of the tank\nWater head applied to the transmitter =%d mA ',wh3)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.2: water_level_and_current_at_different_positions.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.2, page no-371\n", +"clear\n", +"clc\n", +"//(a)\n", +"b=20\n", +"a=4\n", +"op=16\n", +"p=(op-a)*2/(b-a)\n", +"p_h=p*10\n", +"h=p_h-2-5\n", +"printf('(a)\nh = %dm',h)\n", +"//(b)\n", +"p1=1\n", +"t_op=((b-a)/2)*p1+4\n", +"printf('\n(b)\nTransmitter output =%d mA',t_op)\n", +"//(c)\n", +"p2=0.5\n", +"t_op1=((b-a)/2)*p2+4\n", +"printf('\n(c)\nTransmitter output =%d mA',t_op1)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.3: Differential_pressure_output_at_different_levels.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.3, page no-372\n", +"clear\n", +"clc\n", +"//(a)\n", +"b=20\n", +"a=4\n", +"op=16\n", +"wt_l1=25\n", +"t_op=((b-a)/100)*(100-75)+4\n", +"printf('(a)\nWater level=+25cm\nTransmitter output = %d mA',t_op)\n", +"\n", +"//(b)\n", +"wt_l2=-25\n", +"t_op2=((b-a)/100)*(100-25)+4\n", +"printf('\n(b)\nWater level=-25cm\nTransmitter output = %d mA',t_op2)\n", +"\n", +"//(c)\n", +"t_op3=12\n", +"H=(100/(b-a))*(12-4)\n", +"printf('\n(c)\nHead Applied = %d cm\nLevel corresponding to 50 cm head =0 cm ',H)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.4: Displacer_with_spring_balance.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.4, page no-373\n", +"clear\n", +"clc\n", +"//(a)\n", +"a=5*10^-4\n", +"l=8\n", +"dens=6*1000\n", +"w=a*l*dens\n", +"printf('(a)\nWeight of the displacer if weighed in air = %d kg',w)\n", +"//(i)\n", +"sbr1=23\n", +"wloss1=w-sbr1\n", +"L1=wloss1/(1000*a)\n", +"printf('\n(i)\tL1=%dm',L1)\n", +"//(ii)\n", +"sbr2=22\n", +"wloss2=w-sbr2\n", +"L2=wloss2/(1000*a)\n", +"printf('\n(ii)\tL2=%dm',L2)\n", +"//(iii)\n", +"sbr3=21\n", +"wloss3=w-sbr3\n", +"L3=wloss3/(1000*a)\n", +"printf('\n(iii)\tL3=%dm',L3)\n", +"\n", +"//(b)\n", +"level=8\n", +"wt=a*level*1000\n", +"spring=w-wt\n", +"printf('\n(b):when the tank is full\nSpring Balance reading = %d kg',spring)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.5: Buoyancy_Force_calculation.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.5, page no-374\n", +"clear\n", +"clc\n", +"rho=1000\n", +"v=3\n", +"Bw=rho*v\n", +"printf('Buoyance Force(Bw) = %d kg',Bw)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.6: Determination_of_displaced_volume_from_Buoyancy_Force.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.6, page no-374\n", +"clear\n", +"clc\n", +"rho=1000\n", +"Bw=5000\n", +"v=Bw/rho\n", +"printf('V = %d m^3',v)\n", +"" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.7: Determination_of_hydrostatic_pressure_in_open_tank.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.7, page no-374\n", +"clear\n", +"clc\n", +"\n", +"rho=1000\n", +"h=10\n", +"P=rho*h\n", +"printf('P = %d kg/m^2 = %d kg/cm^2 ',P,P/10000)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.8: Determination_of_hydrostatic_pressure_in_closed_tank.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.8, page no-374\n", +"clear\n", +"clc\n", +"rho=1000\n", +"h=15\n", +"ex_p=1\n", +"P=(rho*h/10000)+ex_p\n", +"printf('P = %.1f kg/cm^2',P)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.9: Determination_of_height_from_hydrostatic_pressure.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"// Example 6.9, page no-374\n", +"clear\n", +"clc\n", +"rho=1000\n", +"ex_p=0.5*10^4\n", +"P=1.6*10^4//(rho*h/10000)+ex_p\n", +"h=(P-ex_p)/1000\n", +"printf('h = %d m',h)" + ] + } +], +"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 +} diff --git a/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/7-Viscosity_Humidity_and_Moisture.ipynb b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/7-Viscosity_Humidity_and_Moisture.ipynb new file mode 100644 index 0000000..d8e56fc --- /dev/null +++ b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/7-Viscosity_Humidity_and_Moisture.ipynb @@ -0,0 +1,381 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 7: Viscosity Humidity and Moisture" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.10: percentage_relative_humidity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.10, page no-442\n", +"clear\n", +"clc\n", +"pv=30\n", +"ps=60\n", +"Rh=(pv/ps)*100\n", +"printf('%%RH = %d%%',Rh)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.11: percentage_increase_in_moisture_content.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.11, page no-442\n", +"clear\n", +"clc\n", +"\n", +"i1=250\n", +"i2=350\n", +"m=(i2-i1)*100/i1\n", +"printf('%% increase in moisture content = %d%%',m)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.12: calculation_of_moisture_content.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.12, page no-443\n", +"clear\n", +"clc\n", +"\n", +"i2=150\n", +"i1=125\n", +"m=(i2-i1)*100/i1\n", +"printf('Moisture percentage = %d%%',m)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.1: calculation_of_absolute_viscosity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.1, page no-436\n", +"clear\n", +"clc\n", +"f=2*9.8*10^5\n", +"A=100\n", +"V=20\n", +"l=10\n", +"mu=(f/A)/(V/l)\n", +"mu=mu/1000\n", +"printf('The absolute viscosity mu = %.1f*10^5 centipoises',mu)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.2: calculation_of_kinematic_relative_and_absolute_viscosity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.2, page no-437\n", +"clear\n", +"clc\n", +"//(a)\n", +"v=10\n", +"F=1/v\n", +"printf('(a)\nFluidity = %.1f rhe',F)\n", +"\n", +"//(b)\n", +"mu=10\n", +"rho=0.8\n", +"ve=mu/rho\n", +"printf('\n(b)\nKinematic viscosity (v)= %.1f cm^2/sec',ve)\n", +"//(c)\n", +"ab=1000\n", +"abwt=1.002\n", +"rv=ab/abwt\n", +"printf('\n(c)\nRelative viscosity = %d centipoises',rv)\n", +"//(d)\n", +"PAS=10\n", +"printf('\n(c)\nAbsolute viscosity = 1000 centipoises =10 poises = 1PAS')" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.3: Absolute_viscosity_of_the_Newtonian_fluid.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.3, page no-438\n", +"clear\n", +"clc\n", +"//(b)\n", +"R=0.5\n", +"L=5\n", +"p_diff=800\n", +"V=10\n", +"mu=(3.14*R^4)*p_diff/(8*V*L)\n", +"printf('(b)\nmu=%.4f poise =%.2f centipoise',mu,mu*100)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.4: kinematic_viscosity_and_density_calculation.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.4, page no-439\n", +"clear\n", +"clc\n", +"//(a)\n", +"g=980\n", +"h=4\n", +"R=0.5\n", +"t=1\n", +"V=10\n", +"l=5\n", +"v=(3.14*g*h*t*R^4)/(8*l*V)\n", +"printf('(a)\n v = %.2f stokes',v)\n", +"mu=0.3925\n", +"rho=mu/v\n", +"printf('\n(b)\n Density of the fluid rho = %.3f gm/cm^3',rho)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.5: Kinematic_Viscosity_in_Saybolts_Universal_viscometer.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.5, page no-440\n", +"clear\n", +"clc\n", +"//(a)\n", +"A=0.226\n", +"B=195\n", +"t=60\n", +"v=A*t-B/t\n", +"printf('(a) Fluid X\n v = %.2f centipoises',v)\n", +"A1=0.220\n", +"B1=135\n", +"t1=140\n", +"v1=A1*t1-B1/t1\n", +"printf('\n(b)Fluid Y\n v = %.1f centipoises',v1)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.6: calculation_of_absolute_viscosity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.6, page no-441\n", +"clear\n", +"clc\n", +"t=12\n", +"Rsb=7\n", +"Rsf=1.12\n", +"B=1.5\n", +"mu=t*(Rsb-Rsf)*B\n", +"printf('mu= %.2f centipoises = %d centipoises(approx)',mu,ceil(mu))" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.7: calculation_of_relative_humidity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.7, page no-441\n", +"clear\n", +"clc\n", +"//(a)\n", +"B=45\n", +"W=25\n", +"printf('(a)\nPsychromatic differential : %d°C\n Relative humidity is 80%% corresponding to \ntemperature 45°C and psychromatic differential 20°C',(B-W))\n", +"//(b)\n", +"//(a)\n", +"B1=30\n", +"W1=27\n", +"printf('\n(b)\nPsychromatic differential : %d°C\n Relative humidity is 80%% corresponding to \ntemperature 30°C and psychromatic differential 3°C',(B1-W1))" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.8: calculation_of_Relative_Humidity_dew_point_and_moisture_content.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.8, page no-441\n", +"clear\n", +"clc\n", +"D=80\n", +"W=66.5\n", +"//(a)\n", +"printf('(a)\nThe intersection point of DB temperature 80°F and WB temperature 66.5°F \nlines on the relative humidity curve for 50%%.\n RH = 50%% ')\n", +"//(b)\n", +"printf('\n(b)\nFrom the point of intersection of the dry and wet bulb curves, move left \nhorizontally to the dew point temperature curve where it meets at 60°F\nDew Point = 60°F')\n", +"//(c)\n", +"printf('\n(c)\nFrom the point of intersection of the dry and wet bulb curves,\nhorizontally to the right to the moisture content plot where it meets at 76.\nMoisture Content : 76 grains of water per pound of dry air.')" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.9: calculation_of_relative_humidity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 7.9, page no-442\n", +"clear\n", +"clc\n", +"\n", +"wt_vap=500\n", +"wt_vap_to_sat=1500\n", +"total=wt_vap+wt_vap_to_sat\n", +"Rh=(wt_vap/total)*100\n", +"printf('RH = %d%%',Rh)" + ] + } +], +"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 +} diff --git a/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/8-Fundamentals_of_measuring_instruments.ipynb b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/8-Fundamentals_of_measuring_instruments.ipynb new file mode 100644 index 0000000..00944ba --- /dev/null +++ b/Industrial_Instrumentation_by_K_Krishnaswamy_And_S_Vijayachitra/8-Fundamentals_of_measuring_instruments.ipynb @@ -0,0 +1,352 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 8: Fundamentals of measuring instruments" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.10: EX8_10.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.10, page no-512\n", +"clear\n", +"clc\n", +"R=0.15*10/50\n", +"K=1\n", +"tow=15\n", +"deg=K*R*tow\n", +"//(i)\n", +"a=15-deg\n", +"printf('(i)The actual temperature when instrument reads 15°C is %.2f°C\n The true temperature at 5000 metres = %.2f ',a,a)\n", +"\n", +"//(ii)\n", +"alt_red=deg*50/0.15\n", +"h=5000-alt_red\n", +"printf('\n(ii)\nThe true altitude at which 15°C occurs is %d metres',h)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.1: Flux_density_calculation.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.1, page no-507\n", +"clear\n", +"clc\n", +"fi=10*10^-6\n", +"inch=2.54*10^-2\n", +"A=inch^2\n", +"B =fi/A\n", +"printf('Flux Density B= %.1f mT',B*1000)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.2: Power_Dissipation_and_accuracy_of_result.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.2, page no-508\n", +"clear\n", +"clc\n", +"i=10*10^-3\n", +"R=1000\n", +"P=(i^2)*R\n", +"err_R=10\n", +"err_I=(2/100)*25*100/10\n", +"err_I2=2*err_I\n", +"err_p=err_I2+err_R\n", +"printf('%% error in I^2 = ± %d%%\n%% error in Power = ± %d%%',err_I2,err_p)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.3: max_and_min_levels_of_input_supply_current.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.3, page no-508\n", +"clear\n", +"clc\n", +"i1=37\n", +"i2=42\n", +"i3=13\n", +"i4=6.7\n", +"Imax=(i1+i2)+(i1+i2)*(3/100)+(i3+i4)+(i3+i4)*(1/100)\n", +"\n", +"Imin=(i1+i2)-(i1+i2)*(3/100)+(i3+i4)-(i3+i4)*(1/100)\n", +"\n", +"printf('Maximum level of total supply current = %.3f mA\nMinimum level of total supply current = %.3f mA',Imax,Imin)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.4: Time_constant_for_thermometer.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.4, page no-508\n", +"clear\n", +"clc\n", +"//(a)\n", +"T=200\n", +"T0=300\n", +"Ti=70\n", +"t=3\n", +"x=(T-T0)/(Ti-T0)\n", +"tow=-t/log(x)\n", +"printf('(a)\nTime constant tow=%.1f s',tow)\n", +"//(b)\n", +"t1=5\n", +"T5=T0+((Ti-T0)*%e^(-t1/tow))\n", +"printf('\n(b)\nTemperature after 5 seconds T5 = %.2f°C',T5)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.5: Error_calculation_of_second_order_instrument.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.4, page no-509\n", +"clear\n", +"clc\n", +"w=9\n", +"wn=6\n", +"x=w/wn\n", +"dr=0.6\n", +"Ar=1/sqrt(((1-(x)^2)^2)+(2*dr*x)^2)\n", +"printf('A=%.3f',Ar)\n", +"err=(1-Ar)*100\n", +"printf('\nError = %.2f%%',err)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.6: Output_of_first_order_instrument_for_unit_step_input.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.6, page no-510\n", +"clear\n", +"clc\n", +"t=2\n", +"y=1-%e^(-(t-1.5)/0.5)\n", +"printf('y(t)at t=2 will be y(t)=%.3f',y)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.7: Calculation_of_different_parameters_from_given_frequency_distribution.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.7, page no-510\n", +"clear\n", +"clc\n", +"T=[98.5 99 99.5 100 100.5 101 101.5]\n", +"f=[4 13 19 35 17 10 2]\n", +"//(i)\n", +"k=0\n", +"a=0\n", +"for i=1:length(T)\n", +"k=k+(T(i)*f(i))\n", +"a=a+f(i)\n", +"end\n", +"x_bar=k/a\n", +"printf('(i)\nArithmatic Mean x_bar = %.2f°C',x_bar)\n", +"\n", +"//(ii)\n", +"m=0\n", +"n=0\n", +"for i=1:length(T)\n", +"x=(T(i)-x_bar)\n", +"if x<0 then\n", +"x=-x\n", +"end\n", +"m=m+(x*f(i))\n", +"n=n+f(i)\n", +"end\n", +"D=m/a\n", +"printf('\n(ii)\nAverage Deviation D = %.4f°C',D)\n", +"\n", +"//(iii)\n", +"\n", +"m=0\n", +"n=0\n", +"for i=1:length(T)\n", +"x=(T(i)-x_bar)\n", +"m=m+(x^2)*f(i)\n", +"n=n+f(i)\n", +"end\n", +"sigma=sqrt(m/n)\n", +"printf('\n(iii)\nStandard Deviation (Sigma) = %.3f°C',sigma)\n", +"\n", +"//(iv)\n", +"v=sigma^2\n", +"printf('\n(iv)\nVariancce= %.4f°C',v)\n", +"\n", +"//(v)\n", +"err=sigma*0.6745\n", +"printf('\n(v)\nProbable error = %.4f°C',err)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.8: EX8_8.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.8, page no-511\n", +"clear\n", +"clc\n", +"wn=sqrt(3)\n", +"x=3.2/(2*wn)\n", +"printf('Damping coefficient = %.3f\nNatural frequency of Oscillation = %.3f',x,wn)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.9: calculation_of_Amplitude_inaccuracy_and_phase_shift_from_transfer_function.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Example 8.9, page no-512\n", +"clear\n", +"clc\n", +"w=100\n", +"fi=-atan(0.1*w)-atan(0.5*w)\n", +"A=1/(sqrt(1+(0.1*w)^2)*(sqrt(1+(0.5*w)^2)))\n", +"A=1*1000/ceil(1000*A)\n", +"err=(1-1/A)*100\n", +"printf('A=K/%d\n%% error = %.1f%%\nfi=%.2f°',A,err,fi*180/%pi)" + ] + } +], +"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 +} |