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 /Wireless_Communications_by_T_L_Singal/2-Mobile_Communication_Engineering.ipynb | |
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 'Wireless_Communications_by_T_L_Singal/2-Mobile_Communication_Engineering.ipynb')
-rw-r--r-- | Wireless_Communications_by_T_L_Singal/2-Mobile_Communication_Engineering.ipynb | 353 |
1 files changed, 353 insertions, 0 deletions
diff --git a/Wireless_Communications_by_T_L_Singal/2-Mobile_Communication_Engineering.ipynb b/Wireless_Communications_by_T_L_Singal/2-Mobile_Communication_Engineering.ipynb new file mode 100644 index 0000000..183b95e --- /dev/null +++ b/Wireless_Communications_by_T_L_Singal/2-Mobile_Communication_Engineering.ipynb @@ -0,0 +1,353 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 2: Mobile Communication Engineering" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.10: Symbol_rate.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"Vm=96*5/18;\n", +"fc=900*10^6;\n", +"c=3*10^8;\n", +"function [y ]= fround(x,n)\n", +"// fround(x,n)\n", +"// Round the floating point numbers x to n decimal places\n", +"// x may be a vector or matrix// n is the integer number of places to round to\n", +"y=round(x*10^n)/10^n;\n", +"endfunction\n", +"Yc=fround((c/fc),2);\n", +"fdm=fround((Vm/Yc),2);\n", +"Tc=fround((0.423/fdm),5)//coherence time\n", +"Symbolrate=fround((1/Tc),0)//Symbolrate\n", +"printf('Symbol rate is %.f bps',Symbolrate)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.11: Correlative_fading.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"Td=1*10^(-1*6)\n", +"Delf=1*10^6//difference in frequency\n", +"printf('\nDelf= %.f MHz',Delf*10^(-6));\n", +"Bc=1/(2*%pi*Td)//coherence bandwidth\n", +"printf('\ncoherence bandwidth= %.2f kHz',Bc*10^(-3))\n", +"if Delf>Bc then\n", +" disp(,'Correlative fading fading will not be experienced as Delf>Bc')\n", +" else disp(,'Correlative fading fading will be experienced as Delf<Bc')\n", +"end" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.1: change_in_recieved_signal_in_free_space.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"r1=1\n", +"y=20*log10(r1/(2*r1))\n", +"Delc1=round(y)//change in recieved signal strengths\n", +"printf('\ndel when r2=2r1 = %.d dB',Delc1)\n", +"Delc2=20*log10(r1/(10*r1))////change in recieved signal strengths\n", +"printf('\ndel when r2=10r1 = %.f dB',Delc2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.2: change_in_recieved_signal_in_mobile_radio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"r1=1\n", +"y=40*log10(r1/(2*r1))\n", +"Delc1=round(y)//change in recieved signal strengths\n", +"disp(Delc1,'del in db when r2=2r1')\n", +"Delc2=40*log10(r1/(10*r1))//change in recieved signal strengths\n", +"disp(Delc2,'delc in db when r2=10r1')" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.3: amount_of_delay.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"fc=900*10^6 \n", +"c=3*10^8 \n", +"yc=c/fc//wavelength of transmission\n", +"ddir=1000\n", +"dref=1000\n", +"Angle=120\n", +"Q=120/2\n", +"tdir=ddir/c//time taken by direct path\n", +"tref=dref/(c*sin(Q*%pi/180))//time taken by reflected path\n", +"delay=tref-tdir\n", +"disp(delay,'delay in sec')" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.4: time_between_fades.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"Vm=60*5/18//speed of mobile in m/s\n", +"fc1=900*10^6//frequency of operation\n", +"fc2=1900*10^6//frequency of operation\n", +"c=3*10^8//speed of radio waves\n", +"Tf1=c/(2*fc1*Vm)\n", +"Tf2=c/(2*fc2*Vm)\n", +"printf('time between fades in sec at 900 Mhz= %.f ms',Tf1*10^(3));\n", +"printf('\ntime between fades in sec at 1900 Mhz= %.1f ms',Tf2*10^(3));" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.5: doppler_frequency_shift.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"Vm=72*5/18\n", +"fc=900*10^6\n", +"c=3*10^8\n", +"Q1=180*%pi/180\n", +"Q2=0*%pi/180\n", +"Q3=60*%pi/180\n", +"Q4=90*%pi/180\n", +"fd1=fc*Vm*cos(Q1)/c//dopler shift\n", +"fd2=fc*Vm*cos(Q2)/c\n", +"fd3=fc*Vm*cos(Q3)/c\n", +"fd4=fc*Vm*cos(Q4)/c\n", +"fr1=fc+fd1//recieved carrier frequency\n", +"fr2=fc+fd2\n", +"fr3=fc+fd3\n", +"fr4=fc+fd4\n", +"printf('\nrecieved carrier frequency directly away from base station transmitter = %.5f MHz',fr1*10^(-6));\n", +"printf('\nrecieved carrier frequency directly towards from base station transmitter = %.5f MHz',fr2*10^(-6))\n", +"printf('\nrecieved carrier frequency in direction 60 deg to direction of arrival = %.5f MHz',fr3*10^(-6))\n", +"printf('\nrecieved carrier frequency in direction perpendicular to direction of arrival = %.5f MHz',fr4*10^(-6));" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.6: maximum_speed_of_vehicle.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"fc=900*10^6\n", +"c=3*10^8\n", +"fdm=70\n", +"Yc=c/fc\n", +"V=fdm*Yc//max. speed of the vehicle\n", +"Vm=V*18/5//to convert max speed in kmph\n", +"disp(Vm,'maximum speed of the vehicle in kmph')" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.7: mobile_antenna_beamwidth.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"fc=800*10^6\n", +"fd1=10\n", +"fd2=50\n", +"Vm=80*5/18\n", +"c=3*10^8\n", +"Yc=c/fc//wavelength of transmission\n", +"Q1=acosd(Yc*fd1/Vm)//as cosQ=Yc*fd/Vm\n", +"Q2=acosd(Yc*fd2/Vm)\n", +"Beamwidth=Q1-Q2\n", +"disp(Beamwidth,'Beamwidth in degrees')" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.8: doppler_frequency.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"fc=900*10^6//carrier frequency of transmission\n", +"fdm=20//max. doppler frequency\n", +"p=1//normalized specified level\n", +"Nl=2.5*fdm*p*(%e)^(-1*(p^2))//level crossing rate\n", +"c=3*10^8//velocity of light\n", +"V=fdm*c/fc\n", +"Vm=V*18/5//maximum speed\n", +"printf('positive going level crossing rate = %.2f crossings per second',Nl);\n", +"printf('\nmaximum velocity of the mobile for the given doppler frequency= %.f kmph',Vm)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.9: Fade_duratio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"fdm=20\n", +"p1=0.01\n", +"T1=0.4*(((%e)^(p1^2)) -1)/(fdm*p1)//average fade duration T \n", +"p2=0.1\n", +"T2=0.4*(((%e)^(p2^2)) -1)/(fdm*p2)\n", +"p3=0.707\n", +"T3=0.4*(((%e)^(p3^2)) -1)/(fdm*p3)\n", +"p4=1\n", +"T4=0.4*(((%e)^(p4^2)) -1)/(fdm*p4)\n", +"printf('\naverage fade duration T= %.f microsec for p=0.01',((T1*10^6)-1));\n", +"printf('\naverage fade duration T= %.f msec for p=0.01',T2*10^3);\n", +"printf('\naverage fade duration T= %.f msec for p=0.01',T3*10^3);\n", +"printf('\naverage fade duration T= %.f msec for p=0.01',T4*10^3);\n", +"Dr=50\n", +"Bp=1/Dr//Bit period\n", +"printf('\nBit period=%.f msec',Bp*10^(3));\n", +"if Bp>T3 then//for case p=0.707\n", +" \n", +"disp(,'Fast rayleigh fading as Bp>T for p=0.707')\n", +"else \n", +"disp(,'Slow rayleigh fading as Bp<T for p=0.707')\n", +"end\n", +"Nl=2.5*fdm*p2*((%e)^(-1*(p2^2)))//avg. no. of level crossings\n", +"AvgBER=Nl/Dr\n", +"printf('\naverage bit error rate = %.1f',AvgBER)" + ] + } +], +"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 +} |