Skip to document

B36 Exp1 MADL - To study frequency reuse concept to find the co-channel cells for a particular cell.

MCC Experiment Each cellular base station is allocated a group of radi...
Course

Computer Science, Engineering (CSC502)

41 Documents
Students shared 41 documents in this course
Academic year: 2021/2022
Uploaded by:

Comments

Please sign in or register to post comments.

Preview text

EXPERIMENT No. 1

AIM : To study frequency reuse concept to find the co-channel cells for a particular cell.

SOFTWARE REQUIREMENT: Python

THEORY:

Each cellular base station is allocated a group of radio channels to be used within a small geographic area called a cell. Base stations in adjacent cells are assigned channel groups which contain completely different channels than neighboring cells. Base station antennas are designed to achieve the desired coverage within a particular cell. By limiting the coverage area within the boundaries of a cell, the same group of channels may be used to cover different cells that are separated from one another by geographic distances large enough to keep interference levels within tolerable limits. The design process of selecting and allocating channel groups for

all cellular base stations within a system is called frequency reuse or frequency planning.

The hexagonal cell shape is conceptual and is the simplistic model of the radio coverage for each base station. It has been universally adopted since the hexagon permits easy and manageable analysis of a cellular system. The actual radio coverage of a system is known as the footprint and is determined from old measurements and propagation prediction models. Although the real footprint is amorphous in nature, a regular cell shape is needed for systematic

system design and adaptation for future growth.

Co-channel Cells: A larger cluster size causes the ratio between the cell radius and the distance between co-channel cells to decrease reducing co-channel interference. The value of N is a function of how much interference a mobile or base station can tolerate while maintaining a sufficient quality of communications. Since each hexagonal cell has six equidistant neighbors and the line joining the centers of any cell and each of its neighbors are separated by multiples of 60 degrees, only certain cluster sizes and cell layouts are possible. To connect without gaps between adjacent cells, the geometry of hexagons is such that the number of cells per cluster, N, can only have values that satisfy, N = i 2 + ij + j 2 ;

For N = 19 (i., i = 3, j = 2). Where, i and j are non-negative integers To find the nearest co-channel neighbours of a particular cell, a. move i cells along any chain of hexagons then, b. turn 60 degrees counter-clockwise and move j cells.

Source Code:

#!/usr/bin/python

from math import *

import everything from Tkinter module

from tkinter import *

Base class for Hexagon shape

class Hexagon(object):

def init(self, parent, x, y, length, color, tags):

self = parent

self = x

self = y

self = length

self = color

self = None

self = tags

self_hex()

draw one hexagon

def draw_hex(self):

start_x = self

start_y = self

angle = 60

coords = []

for i in range(6):

end_x = start_x + self * cos(radians(angle * i))

end_y = start_y + self * sin(radians(angle * i))

coords([start_x, start_y])

start_x = end_x

start_y = end_y

self_polygon(coords[0][0],

coords[0][1],

coords[1][0],

coords[1][1],

self_list = []

self_selected = False

self_count = 0

self = []

self_cell_endp = []

self_xy = []

self = Canvas(self,

width=self_WIDTH,

height=self_HEIGHT,

bg="#4dd0e1")

self("<Button-1>", self_back)

self_set()

self('<Shift-R>', self)

self()

self("Frequency reuse and co-channel selection")

self_grid(16, 10)

self_textbox()

self_reuse_calc()

show lines joining all co-channel cells

def show_lines(self):

center(x,y) of first hexagon

approx_center = self_cell_endp[0]

self_ids = []

for k in range(1, len(self_cell_endp)):

end_xx = (self_cell_endp[k])[0]

end_yy = (self_cell_endp[k])[1]

move i^th steps

l_id = self_line(approx_center[0], approx_center[1],

end_xx, end_yy)

if j == 0:

self_ids(l_id)

dist = 0

elif i >= j and j != 0:

self_ids(l_id)

dist = j

rotate counter-clockwise and move j^th step

l_id = self_line(

end_xx, end_yy, end_xx + self_dist * dist *

cos(radians(self_angle - 60)),

end_yy + self_dist * dist *

sin(radians(self_angle - 60)))

self_ids(l_id)

self_angle -= 60

def create_textbox(self):

txt = Text(self,

width=80,

height=1,

font=("Helvatica", 12),

padx=10,

pady=10)

txt_configure("center", justify="center")

txt("1", "Select a Hexagon")

txt_add("center", "1", "end")

self_window((0, 600), anchor='w', window=txt)

create a grid of Hexagons

def create_grid(self, cols, rows):

size = self_len

for c in range(cols):

if c % 2 == 0:

offset = 0

else:

offset = size * sqrt(3) / 2

for r in range(rows):

x = c * (self_len * 1) + 50

y = (r * (self_len * sqrt(3))) + offset + 15

hx = Hexagon(self, x, y, self_len, "#fafafa",

"{},{}".format(r, c))

self(hx)

calculate reuse distance, center distance and radius of the hexagon

def cluster_reuse_calc(self):

self_radius = sqrt(3) / 2 * self_len

self_dist = sqrt(3) * self_radius

self_dist = self_radius * sqrt(3 * self_size)

def write_text(self, text):

self(state=NORMAL)

self('1', END)

self('1', text, "center")

self(state=DISABLED)

#check if the co-channels are within visible canvas

def is_within_bound(self, coords):

if self_LEFT[0] < coords[0] < self_RIGHT[0] \

and self_RIGHT[1] < coords[1] < self_RIGHT[1]:

return True

return False

#gets called when user selects a hexagon

#This function applies frequency reuse logic in order to

#figure out the positions of the co-channels

def call_back(self, evt):

selected_hex_id = self_closest(evt, evt)[0]

hexagon = self[int(selected_hex_id - 1)]

s_x, s_y = hexagon, hexagon

approx_center = (s_x + 15, s_y + 25)

if self_click:

self_click = False

self_text(

"""Now, select another hexagon such

that it should be a co-cell of

the original hexagon."""

)

self_cell_endp(approx_center)

self(hexagon, fill="green")

for _ in range(6):

end_xx = approx_center[0] + self_dist * i * cos(

radians(self_angle))

self(hexagon, fill="green")

self_text("Correct! Cell {} is a co-cell.".format(

hexagon))

if self_count == len(self_list) - 1:

self_text("Great! Press Shift-R to restart")

self_lines()

self_count += 1

else:

self_text("Incorrect! Cell {} is not a co-cell.".format(

hexagon))

self(hexagon, fill="red")

if name == 'main':

print(

"""Enter i & j values. common (i,j) values are:

(1,0), (1,1), (2,0), (2,1), (3,0), (2,2)"""

)

i = int(input("Enter i: "))

j = int(input("Enter j: "))

if i == 0 and j == 0:

raise ValueError("i & j both cannot be zero")

elif j > i:

raise ValueError("value of j cannot be greater than i")

else:

N = (i2 + i * j + j2)

print("N is {}".format(N))

freqreuse = FrequencyReuse(cluster_size=N)

freqreuse()

OUTPUT:

Enter i & j:

I=

J=

INPUT:

E

CONCLUSION: Thus we have studied frequency reuse concept to find co-channel cell.

SIGN GRADE

DATE

Was this document helpful?

B36 Exp1 MADL - To study frequency reuse concept to find the co-channel cells for a particular cell.

Course: Computer Science, Engineering (CSC502)

41 Documents
Students shared 41 documents in this course
Was this document helpful?
EXPERIMENT No. 1
AIM : To study frequency reuse concept to find the co-channel cells for a particular cell.
SOFTWARE REQUIREMENT: Python
THEORY:
Each cellular base station is allocated a group of radio channels to be used within a small
geographic area called a cell. Base stations in adjacent cells are assigned channel groups which
contain completely different channels than neighboring cells. Base station antennas are
designed to achieve the desired coverage within a particular cell. By limiting the coverage area
within the boundaries of a cell, the same group of channels may be used to cover different cells
that are separated from one another by geographic distances large enough to keep interference
levels within tolerable limits. The design process of selecting and allocating channel groups for
all cellular base stations within a system is called frequency reuse or frequency planning.
The hexagonal cell shape is conceptual and is the simplistic model of the radio
coverage for each base station. It has been universally adopted since the hexagon permits easy
and manageable analysis of a cellular system. The actual radio coverage of a system is known
as the footprint and is determined from old measurements and propagation prediction models.
Although the real footprint is amorphous in nature, a regular cell shape is needed for systematic
system design and adaptation for future growth.
Co-channel Cells: A larger cluster size causes the ratio between the cell radius and the
distance between co-channel cells to decrease reducing co-channel interference. The value of
N is a function of how much interference a mobile or base station can tolerate while
maintaining a sufficient quality of communications. Since each hexagonal cell has six
equidistant neighbors and the line joining the centers of any cell and each of its neighbors are
separated by multiples of 60 degrees, only certain cluster sizes and cell layouts are possible.
To connect without gaps between adjacent cells, the geometry of hexagons is such that the
number of cells per cluster, N, can only have values that satisfy,
N = i2 + ij + j2;
For N = 19 (i.e., i = 3, j = 2).
Where,
i and j are non-negative integers
To find the nearest co-channel neighbours of a particular cell,
a. move i cells along any chain of hexagons then,
b. turn 60 degrees counter-clockwise and move j cells.
Source Code:
#!/usr/bin/python
from math import *
# import everything from Tkinter module
from tkinter import *