summaryrefslogtreecommitdiff
path: root/Wireless_Communications_and_Networking_by_V._Garg/ch12.ipynb
blob: 8234bb5bc8f3ba0d20a66ebb2ce514c271b009c7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
{
 "metadata": {
  "name": "",
  "signature": "sha256:5a8dcdff9c441023f41d39cb4ab911bae195c143982b35aa0ceb85309af37715"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 12: Mobility Management in Wireless Networks"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 12.1, Page 374"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "#Variable declaration\n",
      "P=10000;  #Mobile density(mobiles/km**2)\n",
      "R=500*10**-3; #km\n",
      "V=10;  #Average moving velocity of a mobile in Kmph\n",
      "Nc=10.; #No of cells per LA\n",
      "N_LA=5; #Number of LAs per MSC/VLR \n",
      "\n",
      "\n",
      "#Calculations&Results\n",
      "#Number of transactions and duration of each transaction to MSC/VLR per LU for different LU types are given in Table 12.1.(page no.374)\n",
      "\n",
      "\n",
      "# L=length (km) of the cell exposed perimeter in an LA\n",
      "L=6*R*(1./3+1./(2*math.sqrt(Nc)-3));   #Km\n",
      "# lamdaLU=number of transactions processed by MSC/VLR in an LA perimeter of the jth cell per hour\n",
      "LamdaLu=V*P*L/math.pi;  #Lus per hour\n",
      "\n",
      "\n",
      "# case(1)\n",
      "print \"Case-1\"\n",
      "R1_LU=LamdaLu/3600*(1*600./1000); #resource occupancy from Table 12.1\n",
      "print 'The resource occupancy in the jth cell due to MS LUs is  %.1f Erlangs'%R1_LU;\n",
      "\n",
      " \n",
      "#case(2)\n",
      "print \"\\nCase-2\"\n",
      "R2_LU=LamdaLu/3600*(0.8*3500/1000+0.2*4000/1000);  #from Table 12.1\n",
      "print 'The resource occupancy in the jth cell due to MS LUs is  %.2f Erlangs'%R2_LU;\n",
      "Np=6*math.sqrt(Nc/3)-3;#Number of cells located on perimeter of an LA\n",
      "print 'Number of cells where inter-VLR LUs occur will be: %d'%(round(0.5*Np*4));\n",
      "print 'Number of cells where intra-VLR LUs occur will be: %d'%(4*Nc-16);\n",
      "TNLU=LamdaLu*(2*24+16*(0.8*14+0.2*16));  #from table 12.1\n",
      "print 'The MSC/VLR transaction load using the \ufb02uid \ufb02ow model is %.2e transactions at peak hour'%TNLU;"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Case-1\n",
        "The resource occupancy in the jth cell due to MS LUs is  10.1 Erlangs\n",
        "\n",
        "Case-2\n",
        "The resource occupancy in the jth cell due to MS LUs is  60.55 Erlangs\n",
        "Number of cells where inter-VLR LUs occur will be: 16\n",
        "Number of cells where intra-VLR LUs occur will be: 24\n",
        "The MSC/VLR transaction load using the \ufb02uid \ufb02ow model is 1.69e+07 transactions at peak hour\n"
       ]
      }
     ],
     "prompt_number": 1
    }
   ],
   "metadata": {}
  }
 ]
}