Nothing Special   »   [go: up one dir, main page]

"Jnana Sangama", Belagavi, Karnataka-590018: Visvesvaraya Technological University

Download as pdf or txt
Download as pdf or txt
You are on page 1of 57

VISVESVARAYA TECHNOLOGICAL UNIVERSITY

“Jnana Sangama”, Belagavi, Karnataka-590018

A Presentation Report On
“FREE NETWORK CONGESTION CONTROL”
Submitted in partial fulfillment of the requirements for the Award of Degree of
BACHELOR OF ENGINEERING
In
COMPUTER SCIENCE AND ENGINEERING
Submitted by

MANOJKUMAR M JIDDI 4GK21CS024

Under the Supervision of

Dr. Devika G
Assistant professor
Department of Computer Science

DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING


K R PETE KRISHNA GOVERNMENT ENGINEERING COLLEGE
K.R PET-571426
2023-24
K R PETE KRISHNA GOVERNMENT ENGINEERING COLLEGE
K. R PET-571426
DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING

CERTIFICATE

This is to certify that Mr. MANOJKUMAR M JIDDI (4GK21CS024) of VI Semester have


successfully completed the mini project title “FREE NETWORK CONGESTION
CONTROL” in Computer Graphics as prescribed by the Visvesvaraya Technological
University for the academic year 2023-2024.

Signature of the Guide Signature of the HOD

Dr. Devika G Dr. Hareesh K


Assistant Professor Associate Professor & HOD
Dept. of CSE Dept. of CSE

Name of the examiners Signature with date

1……………………… ……………………..

2………………………… ………………………..
ABSTRACT

Computer graphics is a field of computer science that deals with creating, manipulating,
and representing visual content using computers. This field encompasses a wide range of
techniques and applications, from simple 2D drawings to complex 3D simulations and virtual
reality REQUIREMENT

Main aim of this Mini Project is to illustrate the concepts and usage of Congestion
Control in OpenGL. In data networking and queuing theory, network congestion occurs when
a link or node is carrying so much data that its quality of service deteriorates. When more
packets were sent than could be handled by intermediate routers, the intermediate routers
discarded many packets, expecting the end points of the network to retransmit the information.

When this packet loss occurred, the end points sent extra packets that repeated the
information lost, doubling the data rate sent, exactly the opposite of what should be done during
congestion. This pushed the entire network into a 'congestion collapse' where most packets
were lost and the resultant throughput was negligible. IN THE PROJECT used input devices
like mouse and key board to interact with program
ACKNOWLEDGEMENT

I express my sincere gratitude to Dr. K R Dinesh, the principal of K R pete Krishna


Government Engineering College, K R Pet for his valuable guidance, suggestion and
consistent encouragement during the course of my mini project work and timely assistance for
completion of the project.

I thank to entire faculty of the Computer Science and Engineering Department,


especially Dr. Hareesh K, Head of the Department CSE, who has given me confidence to
believe in myself and complete the project.

I’m grateful to Dr.Devika G, my internal guide, Computer Science and Engineering


Department, for his valuable guidance, suggestion and consistent encouragement during the
course of my mini project

Last but not least I would also like to thank my parents and friends for their moral support.

MANOJKUMAR M JIDDI
(4GK21CS024)
DECLARATION

I MANOJKUMAR M JIDDI (4GK21CS024), Student of VI semester BE in


Computer Science & Engineering, K R Pete Krishna Government Engineering College,
K.R.Pet, Mandya here by declare that seminar work on “FREE NETWORK CONGESTION
CONTROL ” has been carried at K R Pet Krishna Government Engineering College for the
partial fulfillment of the requirement for the award of the bachelor degree of Computer Science
and Engineering by Visvesvaraya Technological University, Belagavi as per the scheme and
syllabus of academic year 2023-24.

MANOJKUMAR M JIDDI

(4GK21CS024)
CONTENTS

PARTICULARS PAGE NO

1 Introduction 1-3

2 Literature survey 4-6

3 System Requirement Specifications 7-8

4 Introduction to OpenGL 9-11

5 System Design 12-14

4 Implementation 15-45

5 Model and simulation Testing 46-47

6 Results 48-49

7 Conclusion 50

8 References 51
CHAPTER -1

INTRODUCTION
Computer graphics is a fascinating field that sits at the intersection of computer science,
visual art, and mathematics, enabling the creation and manipulation of images and visual
effects through computational processes. It has profoundly impacted numerous industries,
including entertainment, engineering, medicine, education, and more, transforming the way we
interact with and perceive digital media. This introduction delves into the origins, core
concepts, applications, and future directions of computer graphics, offering a comprehensive
overview of its significance and evolution.

The origins of computer graphics can be traced back to the mid-20th century when early
computers were primarily used for numerical calculations. The idea of using computers for
graphical representation emerged as researchers sought new ways to visualize data and interact
with machines. One of the pioneering moments in the history of computer graphics was Ivan
Sutherland's creation of Sketchpad in 1963. Sketchpad was an innovative computer program
that allowed users to interact with graphical objects directly using a light pen, laying the
foundation for graphical user interfaces and computer-aided design (CAD) systems.

As technology advanced, so did the capabilities of computer graphics. The development


of raster graphics, where images are represented as a grid of pixels, became a significant
milestone. This approach contrasted with vector graphics, which use mathematical equations
to describe shapes and lines. Raster graphics, popularized by bitmap displays, allowed for more
detailed and complex images, paving the way for the photorealistic visuals seen in modern
digital media.

A fundamental aspect of computer graphics is the rendering process, which transforms


mathematical descriptions of objects and scenes into visual images. Rendering can be divided
into several techniques, with the most prominent being rasterization and ray tracing.
Rasterization converts 3D models into 2D images by projecting them onto a screen, a method
widely used in real-time applications like video games due to its efficiency. On the other hand,
ray tracing simulates the way light interacts with objects to produce highly realistic images,
making it a preferred choice for applications where visual fidelity is paramount, such as in film
production and architectural visualization.

The rapid evolution of computer hardware has played a crucial role in the advancement
of computer graphics. Graphics Processing Units (GPUs), specialized hardware designed to
accelerate the rendering process, have become ubiquitous in modern computing. GPUs are
capable of performing parallel processing, allowing them to handle the massive computational
demands of rendering complex scenes. This technological progress has enabled the
development of increasingly sophisticated graphics applications, from immersive virtual reality
environments to cutting-edge scientific visualizations.

In addition to hardware advancements, software development has been equally


important. Graphics libraries and APIs (Application Programming Interfaces) like OpenGL,
DirectX, and Vulkan provide developers with the tools and frameworks needed to create
intricate graphics applications. These libraries abstract the complexities of hardware
interactions, allowing developers to focus on the creative aspects of graphics design. Moreover,
modern game engines such as Unity and Unreal Engine have democratized access to high-
quality graphics, enabling independent developers and small studios to produce visually
stunning content.

Computer graphics is not limited to entertainment; it has numerous applications across


various fields. In the medical field, for example, computer graphics are used to create detailed
visualizations of anatomical structures, aiding in diagnosis and surgical planning. In
engineering, CAD software allows for precise modeling and simulation of complex mechanical
systems, facilitating the design and testing of new products. Education also benefits from
computer graphics, with interactive simulations and visual aids enhancing the learning
experience.

One of the most transformative applications of computer graphics is in the realm of


virtual and augmented reality (VR and AR). These technologies have revolutionized how we
interact with digital content, providing immersive experiences that blur the line between the
physical and virtual worlds. VR and AR applications range from entertainment and gaming to
training and education, offering new ways to engage with information and environments.
Looking ahead, the future of computer graphics promises even more exciting
developments. As artificial intelligence (AI) continues to advance, its integration with
computer graphics is opening new possibilities for automation and realism. AI-driven
techniques, such as neural rendering and procedural generation, can create highly detailed and
dynamic environments with minimal human intervention. Furthermore, the ongoing research
in quantum computing holds the potential to revolutionize rendering techniques, potentially
enabling real-time ray tracing and other computationally intensive processes.

In conclusion, computer graphics is a dynamic and ever-evolving field that has had a
profound impact on numerous aspects of modern life. From its early beginnings with Sketchpad
to the sophisticated rendering techniques of today, computer graphics has continuously pushed
the boundaries of what is visually possible. Its applications are vast and varied, influencing
industries as diverse as entertainment, medicine, engineering, and education. As technology
continues to advance, computer graphics will undoubtedly play a central role in shaping the
future of digital media and interactive experiences.
CHAPTER -2

RELATED BACKGROUND WORK


Network congestion control is a crucial aspect of network management that aims to
optimize the flow of data to prevent congestion and ensure efficient utilization of network
resources. The literature on free network congestion control is extensive, encompassing various
algorithms, protocols, and theoretical models developed over the years. This survey provides a
comprehensive overview of the key contributions, methodologies, and advancements in this
field.

The concept of network congestion control dates back to the early days of computer
networks, with the pioneering work of Kleinrock in the 1960s on queueing theory and packet-
switched networks. The primary goal of congestion control is to manage the data transmission
rate of senders to avoid overwhelming the network, which can lead to packet loss, increased
latency, and reduced throughput. The seminal work by Jacobson in the late 1980s introduced
the first practical congestion control algorithm, TCP Tahoe, which laid the foundation for
subsequent developments in the field.

TCP Tahoe and its successors, such as TCP Reno and TCP NewReno, employ a
combination of additive increase multiplicative decrease (AIMD), slow start, and fast
retransmit mechanisms to control congestion. These algorithms have been extensively studied
and refined over the years, leading to a deeper understanding of their performance
characteristics and limitations. One notable limitation is their suboptimal performance in high-
bandwidth, long-distance networks, often referred to as "long fat networks" (LFNs). To address
these challenges, a plethora of alternative congestion control algorithms have been proposed.

Explicit Congestion Notification (ECN) is an enhancement to traditional TCP


congestion control that provides a more proactive approach. Introduced by Ramakrishnan and
Jain, ECN allows network routers to signal congestion to end hosts before packet loss occurs.
This mechanism improves the responsiveness of congestion control algorithms and reduces the
likelihood of congestion collapse. Various studies have investigated the effectiveness of ECN,
highlighting its potential benefits and identifying practical deployment challenges.
In addition to TCP-based congestion control, numerous research efforts have focused
on alternative protocols and mechanisms. For instance, Datagram Congestion Control Protocol
(DCCP) was designed to provide congestion control for unreliable datagram services.

DCCP incorporates features from both TCP and UDP, offering a flexible framework
for real-time applications that require timely delivery but can tolerate some packet loss. The
development and analysis of DCCP have contributed to a broader understanding of congestion
control in diverse network environments.

Another significant area of research in free network congestion control is the use of
active queue management (AQM) techniques. AQM schemes, such as Random Early Detection
(RED) and its variants, aim to control congestion by preemptively dropping packets or marking
them with ECN before the queue becomes full. This proactive approach helps to smooth traffic
flow and maintain lower queue lengths, thereby reducing latency and jitter. The effectiveness
of AQM techniques has been extensively studied through both theoretical analysis and
empirical evaluations.

The advent of software-defined networking (SDN) has opened new avenues for
congestion control research. SDN decouples the control plane from the data plane, allowing
for more centralized and flexible management of network resources. Researchers have
explored various SDN-based congestion control mechanisms that leverage global network
visibility and programmability. These mechanisms can dynamically adjust routing and
resource allocation to mitigate congestion, leading to more efficient and adaptive network
operations.

In the realm of wireless networks, congestion control presents unique challenges due to
the dynamic and heterogeneous nature of wireless communication. Traditional congestion
control algorithms often perform poorly in wireless environments, prompting the development
of specialized approaches. Techniques such as rate adaptation, cross-layer optimization, and
cooperative communication have been proposed to enhance congestion control in wireless
networks. These approaches consider factors like signal strength, interference, and mobility,
offering more robust solutions for wireless congestion management.

Recent advancements in machine learning and artificial intelligence (AI) have also
influenced the field of congestion control. AI-driven congestion control algorithms leverage
predictive analytics and real-time data to make more informed decisions about traffic
management. For example, reinforcement learning techniques have been applied to optimize
congestion control strategies dynamically. These approaches have shown promise in achieving
better performance and adaptability compared to traditional algorithms.

The literature on free network congestion control also encompasses studies on fairness
and resource allocation. Fairness in congestion control ensures that all network users receive a
fair share of resources, preventing scenarios where some users monopolize bandwidth at the
expense of others. Algorithms like TCP Vegas and FAST TCP incorporate fairness
considerations into their design, aiming to balance efficiency and equity. Additionally, game-
theoretic models have been employed to analyze and design congestion control mechanisms
that promote fair resource allocation in competitive network environments.

Another critical aspect of congestion control research is the evaluation and


benchmarking of different algorithms. Researchers have developed various simulation tools
and testbeds to assess the performance of congestion control mechanisms under diverse
network conditions. These evaluations provide valuable insights into the strengths and
weaknesses of different approaches, guiding the development of more effective solutions.

In summary, the literature on free network congestion control is rich and diverse,
reflecting the complexity and importance of this field. From early theoretical models to
advanced AI-driven techniques, researchers have made significant strides in understanding and
addressing the challenges of network congestion. The ongoing evolution of network
technologies and the increasing demand for high-performance communication services ensure
that congestion control will remain a vital area of research and innovation in the years to come.
CHAPTER -3

SYSTEM REQUIREMENT SPECIFICATIONS


System Requirement Specifications (SRS) for free network congestion control focus on both
the functional and non-functional aspects necessary to create an effective congestion control
system. These requirements ensure that the system can accurately detect and manage
congestion, adjust data transmission rates dynamically, and maintain compatibility with
existing network infrastructure.

Firstly, the system must have robust mechanisms for detecting network congestion. This
involves monitoring various network metrics such as packet loss, delay variations, and
bandwidth utilization. Effective congestion detection can be achieved through techniques like
packet marking, using Explicit Congestion Notification (ECN), or analyzing changes in round-
trip times. The system should be able to promptly identify when the network is approaching or
experiencing congestion to take necessary actions to mitigate it.

Once congestion is detected, the system needs a reliable notification mechanism to inform
relevant network nodes or endpoints. This can be implemented through packet marking or
direct signaling methods, ensuring that both the sender and receiver are aware of the network
conditions. Timely and accurate notifications are crucial for the system to respond effectively
to congestion and prevent further deterioration of network performance.

The core functionality of the system revolves around dynamic rate adjustment. The system
must be capable of adapting data transmission rates based on real-time network conditions.
This involves increasing the transmission rate when the network is underutilized and reducing
it when congestion is detected. The system should support a variety of congestion control
algorithms, such as TCP Tahoe, TCP Reno, Cubic, and BBR, to cater to different types of
networks and application

Interoperability is another critical requirement. The congestion control system must be


compatible with existing network protocols, including TCP, UDP, and newer protocols like
QUIC. This ensures that the system can be integrated into a wide range of network architectures
without requiring significant changes to the existing infrastructure. Additionally, the system
should be cross-platform compatible, working seamlessly across different operating systems
and network devices.
The system must also provide support for both centralized and decentralized network
management. In a centralized approach, the system can utilize a global view of the network to
make informed decisions about congestion control. This is particularly useful in environments
with software-defined networking (SDN), where the control plane is separated from the data
plane. In decentralized settings, each node must make independent decisions based on locally
available information, requiring robust algorithms that can operate effectively with partial
network visibility.

3.1: SOFTWARE REQUIREMENTS :

➢ MICROSOFT VISUAL C++


➢ OPENGL

3.2: HARDWARE REQUIREMENT :

➢ GRAPHICS SYSTEM,
➢ Pentium P4 with 256 of Ram(Min)
CHAPTER -4

INTRODUCTION TO OPENGL

As a software interface for graphics hardware, OpenGL's main purpose is to


render two- and three-dimensional objects into a frame buffer.

These objects are described as sequences of vertices or pixels.

OpenGL performs several processing steps on this data to convert it to pixels to


form the final desired image in the frame buffer.

4.1: OpenGL Fundamentals


This section explains some of the concepts inherent in OpenGL.

4.2:Primitives and Commands

OpenGL draws primitives—points, line segments, or polygons—subject to


several selectable modes.

You can control modes independently of each other; that is, setting one mode
doesn't affect whether other modes are set .Primitives are specified, modes are
set, and other OpenGL operations are described by issuing commands in the form
of function calls.

Primitives are defined by a group of one or more vertices. A vertex defines a


point, an endpoint of a line, or a corner of a polygon where two edges meet. Data
is associated with a vertex, and each vertex and its associated data are processed
independently, in order, and in the same way. The type of clipping depends on
which primitive the group of vertices represents.

Commands are always processed in the order in which they are received, although
there may be an indeterminate delay before a command takes effect. This means
that each primitive is drawn completely before any subsequent command takes
effect. It also means that state-querying commands return data that's consistent
with complete execution of all previously issued OpenGL commands.
4.3:Basic OpenGL Operation
The figure shown below gives an abstract, high-level block diagram of how
OpenGL processes data. In the diagram, commands enter from the left and
proceed through what can be thought of as a processing pipeline. Some
commands specify geometric objects to be drawn, and others control how the
objects are handled during the various processing stages.

Figure . OpenGL Block Diagram

As shown by the first block in the diagram, rather than having all commands
proceed immediately through the pipeline, you can choose to accumulate some
of them in a display list for processing at a later time.

Rasterization produces a series of frame buffer addresses and associated values


using a two-dimensional description of a point, line segment, or polygon.

Each fragment so produced is fed into the last stage,

per-fragment operations, which performs the final operations on the data before
it's stored as pixels in the frame buffer. These operations include conditional
updates to the frame buffer based on incoming and previously stored z-value s
(for z-buffering) and blending of incoming pixel colors with stored colors, as well
as masking and other logical operations on pixel values.

All elements of OpenGL state, including the contents of the texture memory and
even of the frame buffer, can be obtained by an OpenGL application.
CHAPTER -5

SYSTEM DESIGN

Principles

1. Decentralized Monitoring: Each network node independently monitors traffic


conditions.
2. Local Decision Making: Nodes make autonomous decisions to control congestion
based on local data.
3. Inter-Nodal Cosmmunication: Nodes share congestion information with their
neighbors to coordinate responses.

Key Components

1. Congestion Detection:
o Metrics Collection: Each node monitors queue lengths, packet loss, delay,
and throughput.
o Thresholds: Nodes use thresholds to detect congestion. For example, if the
queue length exceeds a certain value, congestion is inferred.
2. Congestion Mitigation:
o Rate Limiting: Nodes adjust their transmission rates to reduce congestion.
o Traffic Shaping: Nodes smooth traffic flows to prevent bursts.
o Prioritization: Nodes prioritize critical traffic over less important traffic.
3. Communication Protocols:
o Periodic Updates: Nodes regularly share their congestion status with
neighbors.
o Event-Driven Updates: Nodes send immediate updates when significant
congestion changes occur.
o Gossip Protocols: Information spreads through the network as nodes
randomly share updates with a subset of their neighbors

This program is implemented using various openGL functions which are in


shown below.
5.1: Various functions used in this program.

1. glutInit() : interaction between the windowing system and OPENGL is initiated

2. glutInitDisplayMode() : used when double buffering is required and depth information


is required

3. glutCreateWindow() : this opens the OPENGL window and displays the title at top of
the window

4. glutInitWindowSize() : specifies the size of the window

5. glutInitWindowPosition() : specifies the position of the window in screen co-ordinates

6. glutKeyboardFunc() : handles normal ascii symbols

7. glutSpecialFunc() : handles special keyboard keys

8. glutReshapeFunc() : sets up the callback function for reshaping the window

9. glutIdleFunc() : this handles the processing of the background

10. glutDisplayFunc() : this handles redrawing of the window

11. glutMainLoop() : this starts the main loop, it never returns

12. glViewport() : used to set up the viewport

13. glVertex3fv() : used to set up the points or vertices in three dimensions

14. glColor3fv() : used to render color to faces

15. glFlush() : used to flush the pipeline

16. glutPostRedisplay() : used to trigger an automatic redrawal of the object


17. glMatrixMode() : used to set up the required mode of the matrix

18. glLoadIdentity() : used to load or initialize to the identity matrix

19. glTranslatef() : used to translate or move the rotation centre from one point to another
in three dimensions

20. glRotatef() : used to rotate an object through a specified rotation angle

5.2: Interaction with program

➢ This program includes interaction through keyboard.

➢ S → Start the Project

➢ User Right mouse button to get menu and choose option accordingly.

➢ Q-> Quit
CHAPTER -6

IMPLEMENTATION
6.1: End-to-End Congestion Control

In this approach, the endpoints (i.e., the sender and receiver) detect and respond to congestion
without requiring intermediate nodes to perform congestion control. The most common method
is through TCP (Transmission Control Protocol) variants, which adjust the sending rate based
on network feedback.

Key Techniques:

➢ TCP Reno: Adjusts the congestion window size based on packet loss signals, using
algorithms like slow start, congestion avoidance, fast retransmit, and fast recovery.
➢ TCP Vegas: Uses RTT (Round-Trip Time) measurements to detect congestion early
and adjust the sending rate before packet loss occurs.

6.2: Delay-Based Congestion Control

These methods use network delay as a signal for congestion. The idea is to detect congestion
before packet loss occurs by observing increases in RTT.

Key Techniques:

➢ TCP Vegas: Measures RTT to adjust the sending rate, aiming to prevent congestion by
reacting to increases in delay.
➢ FAST TCP: A variant of TCP that also uses RTT measurements to adjust the sending
rate more aggressively and accurately.

6.3: Explicit Congestion Notification (ECN)

ECN is a mechanism where network routers mark packets instead of dropping them to signal
congestion. Endpoints then adjust their sending rates based on these marks.
Key Techniques:

➢ ECN in TCP: When an ECN-capable router detects congestion, it sets a congestion-


experienced flag in the IP header of packets instead of dropping them. The receiver then
notifies the sender to reduce the sending rate.

6.4 Active Queue Management (AQM)

Routers manage their packet queues to control congestion proactively by dropping or marking
packets before the queue becomes full.

Key Techniques:

➢ RED (Random Early Detection): Drops packets randomly before the queue is full to
signal congestion early, encouraging endpoints to reduce their sending rates.
➢ CoDel (Controlled Delay): Drops packets based on the time they have spent in the
queue, aiming to maintain a target delay.

6.5 Rate-Based Congestion Control

This approach involves dynamically adjusting the sending rate based on feedback from the
network or the receiver.

Key Techniques:

➢ XCP (eXplicit Control Protocol): Routers provide explicit feedback about the level
of congestion, and senders adjust their rates accordingly.
➢ RCP (Rate Control Protocol): Routers compute and communicate a fair rate for each
flow to the senders.

CODE
➢ Header Includes and Namespace: Includes necessary headers (<GL/glut.h>,
<iostream>, <math.h>, <string.h>). Imports standard libraries for OpenGL,
input/output operations, mathematical functions, and string handling

#include <windows.h>
#include<string.h>
#include<stdarg.h>
#include<stdio.h>
#include <glut.h>
void *font;
void *currentfont;
static double x=0.0,x1=-3.5,x2=3.5,y1=-1.4,y2=-1.4,x3=-3.5,y3=1.3;
static double move=-60;
static bool
goDown=false,goup=false,down=false,congested=false,remote=false;
➢ setFont Function: Sets the font for drawing characters using setFont.Currently, it
always sets the font to GLUT_BITMAP_TIMES_ROMAN_24 regardless of the font
parameter.

void setFont(void *font)


{
currentfont=font;
}
drawstring Function: Draws a string at a specified 3D position (x, y, z) on the screen.
Uses strlen to determine the length of the input string. Sets the text color to cyan ((0.0, 1.0,
1.0)).Iterates through each character in the string and draws it using
GLUT_BITMAP_TIMES_ROMAN_24 font

void drawstring(float x,float y,float z,char *string)


{
char *c;
glRasterPos3f(x,y,z);
for(c=string;*c!='\0';c++)
{
glColor3f(0.0,1.0,1.0);
glutBitmapCharacter(currentfont,*c)
}
}
void
stroke_output Function: Outputs formatted text at a specified position (x, y) on the screen.
Uses variable arguments (...) to handle different formats of input strings. Formats the input
string using vsprintf into the buffer. Translates to the specified position (x, y, 0) using
glTranslatef. Scales the text size by a factor of (0.1, 0.1, 0.1) using glScalef

stroke_output(GLfloat x, GLfloat y, char *format,...)


{
va_list args;
char buffer[200], *p;
va_start(args, format);
vsprintf(buffer, format, args);
va_end(args);
glPushMatrix();
glTranslatef(x, y,2);
glScaled(0.003, 0.005, 0.005);
for (p = buffer; *p; p++)
glutStrokeCharacter(GLUT_STROKE_ROMAN, *p);
glPopMatrix();
}
void cloud(){
//vertical eclipse
glPushMatrix();
glTranslatef(0.0,0.0,0.0);
glScaled(1,3.5,0.1);
glColor3f(1,1,1);
glutSolidSphere(1,100,100);
glPopMatrix();
//horizotal eclipse
glPushMatrix();
glTranslatef(0.0,0.0,0.0);
glScaled(3,2.65,0.1);
glColor3f(1,1,1);
glutSolidSphere(1,100,100);
glPopMatrix();
glPushMatrix();
glScaled(3.5,1.8,0.1);
glRotatef(60,0.0f,1.0f,1.0f);
glTranslatef(0.0,0.0,0.0);
glColor3f(1,1,1);
glutSolidSphere(1,100,100);
glPopMatrix();
glPushMatrix();
glScaled(1.5,3.5,0.1);
glRotatef(50,0.0f,1.0f,1.0f);
glTranslatef(0.0,0.0,0.0);
glColor3f(1,1,1);
glutSolidSphere(1,100,100);
glPopMatrix();
}
void router(float x6, float y6,float z6)
{
glColor3f(0.2,0.3,1);
glPushMatrix();
glScaled(0.2,1.0,0.1);
glRotatef(91,1.0f,0.0f,0.0f);
glTranslatef(x6,y6,z6);
glutSolidTorus(0.2,1.5,100,100);
glPopMatrix();
}
void dte(float x1, float x2)
{
glPushMatrix();
glTranslatef(x1,x2,0.1);
glScaled(1,0.1,0.1);
glColor3f(1,1,1);
glRotatef(0,0.0f,1.0f,0.0f);
glutWireCube(1.5);
glPopMatrix();
}
Line function?
void line()
{
glPushMatrix();
glBegin(GL_LINE_LOOP);
glColor3f(1,0,0);
glVertex3f(0.1,-0.2,1);
glVertex3f(0.0,0,1);
glVertex3f(2,1.3,1);
glVertex3f(2.1,1.1,1);
glEnd();
glPopMatrix();
}
void line1()
{
glPushMatrix();
glBegin(GL_LINE_LOOP);
glColor3f(1,0,0);
glVertex3f(0.2,2.5,1);
glVertex3f(0.1,2.3,1);
glVertex3f(2.1,1.1,1);
glVertex3f(2.3,1.2,1);
glEnd();
glPopMatrix();
}
void rack(float x1, float x2)
{
glPushMatrix();
glScaled(0.35,.05,1.0);
glTranslatef(x1,x2,0.1);
glColor3f(0,0,0.3);
glutSolidCube(1.1);
glPopMatrix();
}
void rack1(float x1, float x2)
{
glPushMatrix();
glScaled(1.75,.1,1.0);
glTranslatef(x1,x2,0.3);
glColor3f(0,0,1.3);
glutSolidCube(0.5);
glPopMatrix();
}
void window(float x1, float x2)
{
glPushMatrix();
glScaled(0.5,.3,1.0);
glTranslatef(x1,x2,0.4);
glColor3f(0.1,0.1,0.1);
glutSolidCube(0.5);
glPopMatrix();
}
void top()
{
glBegin(GL_TRIANGLES);
/* Front */
glColor3f(1.0f,1.0f,1.0f);
glVertex3f( 0.0f, 1.0f, 0.0f);
glColor3f(1.0f,1.0f,1.0f);
glVertex3f(-0.5f,-0.5f, 0.5f);
glColor3f(1.0f,1.0f,1.0f);
glVertex3f( 0.5f,-0.5f, 0.5f);
/* Left */
glColor3f(1.0f,1.0f,1.0f);
glVertex3f(0.0f,1.0f,0.0f);
glColor3f(1.0f,1.0f,1.0f);
glVertex3f(-0.5f,-0.5f,0.5f);
glColor3f(1.0f,1.0f,1.0f);
glVertex3f(-0.5f,-0.5,-0.5f);
/* Right */
glColor3f(1.0f,1.0f,1.0f);
glVertex3f(0.0f,1.0f,0.0f);
glColor3f(1.0f,1.0f,1.0f);
glVertex3f(0.5f,-0.5f,0.5f);
glColor3f(1.0f,1.0f,1.0f);
glVertex3f(0.5f,-0.5,-0.5f);
/* Back */
glColor3f(1.0f,1.0f,1.0f);
glVertex3f( 0.0f, 1.0f, 0.0f);
glColor3f(1.0f,1.0f,1.0f);
glVertex3f(-0.5f,-0.5f, -0.5f);
glColor3f(1.0f,1.0f,1.0f);
glVertex3f( 0.5f,-0.5f, -0.5f);
glEnd();
}
void animate();
void network()
{
glClearColor(0.0,0,0,0.0);
//glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
glLoadIdentity();
glTranslatef(0.0f,0.0f,-13.0f);
// glRotatef(ang,1.0f,1.0f,0.0f);
//Server
glPushMatrix();
glScaled(0.8,2.0,0.8);
glTranslatef(5,0.8,0.0);
glColor3f(0,1.5,1.5);
glutSolidCube(1);
glPushMatrix();
glScaled(0.5,.1,1.0);
glTranslatef(.0,3.5,0.01);
glColor3f(0.3,0.3,0.3);
glutSolidCube(1.5);
glPopMatrix();
rack1(.0,1);
rack1(.0,2);
rack1(.0,0);
rack(-1,-4);
rack(1,-4);
rack(-1,-6);
rack(1,-6);
rack(-1,-8);
rack(1,-8);
glPopMatrix();
//Home
glPushMatrix();
glScaled(0.8,1.0,0.8);
glTranslatef(4.8,-2.5,0.0);
glColor3f(1,1,0);
glutSolidCube(1);
glPushMatrix();
glScaled(.7,.1,1.0);
glTranslatef(0.0,4.5,0.2);
glColor3f(1.3,1.3,1.3);
glutSolidCube(1.5);
glPopMatrix();
glPushMatrix();
glScaled(0.12,.3,.75);
glTranslatef(0,-.75,0.02);
glColor3f(0.3,0.3,0.3);
glutSolidCube(1.5);
glPopMatrix();
// Top
glPushMatrix();
glTranslatef(0,.9,0);
top();
glPopMatrix();
window(-.6,-.3);
glPopMatrix();
//Office Building
glPushMatrix();
glScaled(0.8,2.0,0.8);
glTranslatef(-4.8,-1,0.0);
glColor3f(2,.5,.5);
glutSolidCube(1);
window(-.5,1.3);
window(.5,1.3);
window(-.5,0.5);
window(.5,0.5);
window(-.5,-0.3);
window(.5,-0.3);
window(-.5,-1.1);
window(.5,-1.1);
glPopMatrix();
// Remote User
glPushMatrix();
glTranslatef(-4.0,1.5,0.0);
glScaled(0.3,.3,.3);
glColor3f(1.3,1.3,1.3);
glutSolidCube(0.5);
glPopMatrix();
// Routers inside cloud
//router 5
router(10,10,1.15);
//router 2
router(-10,10,-1.3);
//router 1
router(-10,10,1.2);
//router 3
router(0,10,-2.5);
router(0,10,0);
//router 5
router(0,10,2.5);
//router 4
router(10.6,10,-1.2);
// Line 1
glPushMatrix();
glTranslatef(-2.1,0.0,0.5);
glScaled(0.1,1.8,0.1);
glColor3f(1,0,0);
glutWireCube(1.5);
glPopMatrix();
// Link 2
glPushMatrix();
glTranslatef(-2,1.15,0);
line();
glPopMatrix();
// Link 3 to server
glPushMatrix();
glTranslatef(1.2,1.7,0.5);
glRotatef(57,0,0,1);
glScaled(0.15,1.7,0.1);
glColor3f(1,0,0);
glutWireCube(1.5);
glPopMatrix();
// Link 4
glPushMatrix();
glTranslatef(0.85,0.4,0.5);
glRotatef(120,0,0,1);
glScaled(0.2,1.7,0.1);
glColor3f(1,0,0);
glutWireCube(1.5);
glPopMatrix();
// Link 5
glPushMatrix();
glTranslatef(0,-2.6,0);
line();
glPopMatrix();
// Link 6
glPushMatrix();
glTranslatef(-2.2,-3.85,0);
line1();
glPopMatrix();
// Link 7(1step data transfer from ...)
glPushMatrix();
glTranslatef(-1.2,-0.85,0.5);
glRotatef(125,0,0,1);
glScaled(0.15,1.6,0.1);
glColor3f(1,0,0);
glutWireCube(1.5);
glPopMatrix();
// Link 9
glPushMatrix();
glTranslatef(0.0,1.0,0.5);
glScaled(0.1,1.65,0.1);
glColor3f(1,0,0);
glutWireCube(1.5);
glPopMatrix();
//R0 - R6
glPushMatrix();
glTranslatef(0.0,-1.6,0.5);
glScaled(0.1,1.65,0.1);
glColor3f(1,0,0);
glutWireCube(1.5);
glPopMatrix();
//link 10 from home
glPushMatrix();
glTranslatef(1.05,-0.8,0.5);
glRotatef(52,0,0,1);
glScaled(0.15,1.6,0.1);
glColor3f(1,0,0);
glutWireCube(1.5);
glPopMatrix();
// Office Link to Cloud
dte(-3.0,-1.4);
// Home Link to Cloud
dte(3.0,-1.4);
// Server Link to Cloud
dte(3.0,1.1);
//Cloud Call Function
cloud();
glPushMatrix();
//glScaled(1.1,2.0,0.1);
glTranslatef(0.0,0.0,2.0);
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0,0,0);
drawstring(-0.3,2.5,0.0,"CLOUD");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0,0,0);
drawstring(-2.1,-1.4,0.0,"R1");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0,0,0);
drawstring(-2.05,0.95,0.0,"R2");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0,0,0);
drawstring(0,2,0.0,"R3");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0,0,0);
drawstring(-0.1,-0.3,0.0,"R0");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0,0,0);
drawstring(1.8,0.8,0.0,"R4");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0,0,0);
drawstring(1.8,-1.35,0.0,"R5");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0,0,0);
drawstring(0,-2.6,0.0,"R6");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(1,1,1);
drawstring(3,-2.1,0.0,"HACKER");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(1.5,1.5,1.5);
drawstring(-3.7,-0.8,0.0,"OFFICE");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(1.5,1.5,1.5);
drawstring(3,2.3,0.0,"SERVER")
glPopMatrix();
//Transtitions all together
animate();
glFlush();
glutSwapBuffers();
}
void animate(){
// Company to server Using path 1
glPushMatrix();
glTranslatef(x1,y1,0.2);
glScaled(0.1,0.1,0.1);
glColor3f(0,0,1);
glutSolidCube(0.5);
glPopMatrix();
if(remote){
glPushMatrix();
glTranslatef(x3,y3,0.2);
glScaled(0.1,0.1,0.1);
glColor3f(1,0,0.5);
glutSolidCube(0.5);
glPopMatrix();
}
if(congested)
{
glPushMatrix();
glTranslatef(x2,y2,0.2);
glScaled(0.1,0.1,0.1);
glColor3f(4,0,0);
glutSolidCube(0.5);
glPopMatrix();
}
}
void about()
{
glClearColor(0.5,0.5,0.5,0.0);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
glLoadIdentity();
glTranslatef(0.0f,0.0f,-13.0f);
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0,0,0);
drawstring(-4.2,2,0.0,"About Congestion Control");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
drawstring(-3.5,1.5,0.0,"* Congestion is a situation in Communication
Networks in which too many packets");
drawstring(-3.5,1,0.0," are present in a part of the subnet, performance
degrades.");
drawstring(-3.5,.5,0.0,"* In data networking network congestion occurs
when a link or node ");
drawstring(-3.5,0.0,0.0," is carrying so much data that its quality of
service deteriorates.");
drawstring(-3.5,-0.5,0.0,"* Congestion control concerns controlling
traffic entry into a ");
drawstring(-3.5,-1,0.0," telecommunications network, so as to avoid
congestive collapse by attempting ");

drawstring(-3.5,-1.5,0.0," to avoid oversubscription of any of the


processing or link capabilities ");
drawstring(-3.5,-2,0.0," of the intermediate nodes and networks and
taking resource reducing steps, ");
drawstring(-3.5,-2.5,0.0," such as reducing the rate of sending
packets.");
drawstring(-3.5,-3,0.0,"* It should not be confused with flow control,
which prevents the sender from overwhelming the receiver.");
glFlush();
glutSwapBuffers();
}
void s()
{
glClear(GL_COLOR_BUFFER_BIT |
GL_DEPTH_BUFFER_BIT);
network();
}
void com_ser(){
// No congestion, take the best path
if(!congested && !remote)
{
if(x1>=-3.5 && y1==-1.4 && x1<=-2)
{
x1+=0.1;
}
if(x1>=-2 && y1>=-1.4 && x1<=2 && y1<=1.8)
{
x1+=0.1;
y1+=0.065;
}
if(x1>=2 && y1>=1 && x1<=3.8)
{
x1+=0.1;
y1=1.1;
}
}
//if Congested only from Hacker A
if(congested && x2>=2 && y2>=1 && !remote)
{
if(x1>=-3.5 && y1==-1.4 && x1<=-2){
x1+=0.1;
}
if(x1>=-2 && y1>=-1.4 && x1<=0 && y1<=0){
x1+=0.1;
y1+=0.07;
}
if(x1>=-0.05 && x1<=0.05 && y1<=0.05 && y1>=-0.05){
x1=0;
y1=0;
}
if(x1==0 && y1>=0 && y1<=2.6){
y1+=0.06;
}
if(x1==0 && y1>=2.5)
goDown=true;
if(goDown && x1>=0 && x1<=2 && y1<=2.6 && y1>=1 ){
x1+=0.1;
y1-=0.06;
}
if(x1>=2 && y1>=1 && x1<=3.8){
x1+=0.1;
y1=1.1;
}
}
// if congested only from Hacker B
if(remote && y3<=1 && !congested)
{
if(x1>=-3.5 && y1==-1.4 && x1<=-2){
x1+=0.1;
}
if(x1>=-2 && x1<=-0.2 && y1<=-1.4 && y1>=-3){
x1+=0.1;
y1-=0.08;
}
if(x1>=-0.3 && x1<=-0.2 && y1<=-2.7 && y1>=-3 && goup==false){
x1=0;
y1=-3;
goup=true;
}
if(goup && y1<=0){
x1=0.0;
y1+=0.1;
}
if(goup && x1>=0 && y1>=0 && x1<=2 && y1<=1.8)
{
x1+=0.1;
y1+=0.055;
}
if(x1>=2 && y1>=1 && x1<=3.8)
{
x1+=0.1;
y1=1.1;
}
}
// if congested from both Hackers
if(remote && y3<=1 && congested)
{
if(x1>=-3.5 && y1==-1.4 && x1<=-2){
x1+=0.1;
}
if(x1>=-2 && x1<=-0.2 && y1<=-1.4 && y1>=-3){
x1+=0.1;
y1-=0.08;
}
if(x1>=-0.3 && x1<=-0.2 && y1<=-2.7 && y1>=-3 && goup==false){
x1=0;
y1=-3;
goup=true;
}
if(goup && y1<=2.6 && goDown==false){
x1=0.0;
y1+=0.1;
}
if(x1==0 && y1>=2.5)
goDown=true;
if(goDown && x1>=0 && x1<=2 && y1<=2.6 && y1>=1 ){
x1+=0.1;
y1-=0.06;
}
if(x1>=2 && y1>=1 && x1<=3.8){
x1+=0.1;
y1=1.1;
}
}
//congest the server link1, From hacker A to R
if(congested){
if(x2<=3.5 && y2==-1.4 && x2>=1.8)
{
x2-=0.1;
}
if(x2<1.8 && x2>=0 && y2<=0 && y2>=-1.4 )
{
x2-=0.1;
y2+=0.08;
}
if(x2>=-0.05 && x2<=0.051 && y2<=0.051 && y2>=-0.051){
x2=0;
y2=0;
}
if(x2>=0 && y2>=0 && x2<=2 && y2<=1.8){
x2+=0.1;
y2+=0.06;
}
}
// Congest from Hacker B to Company
if(remote)
{
if(x3>=-3.5 && y3==1.3 && x3<=-2)
{
x3+=0.1;
}
if(x3>=-2 && y3<=1.3 && x3<=1.5 && y3>=-1.5 && !down)
{
x3+=0.1;
y3-=0.065;
}
if(x3>=0.0 && y3<=0.0){
x3=0;y3=0;down=true;
}
if(x3<=0 && x3>=-2 && y3>=-1.4 && down)
{
x3-=0.1;
y3-=0.065;
}
}
network();
}
void doInit()
{
/* Background and foreground color */
glClearColor(0.0,0.0,0.0,0);
glViewport(0,0,640,480);
/* Select the projection matrix and reset it then
setup our view perspective */
glMatrixMode(GL_PROJECTION);
glLoadIdentity();
gluPerspective(30.0f,(GLfloat)640/(GLfloat)480,0.1f,200.0f);
/* Select the modelview matrix, which we alter with rotatef() */
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
glClearDepth(2.0f);
glEnable(GL_DEPTH_TEST);
glDepthFunc(GL_LEQUAL);
}
void display()
{
glClearColor(0.0,0.,0.,0.0);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
glLoadIdentity();
glTranslatef(0.0f,0.0f,-13.0f);
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(3.0,1.0,1.0);
drawstring(-1.7,3.0,0.0,"DEPARTMENT OF COMPUTER SCIENCE");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0.0,1.0,1.0);
drawstring(-3.0,2.5,0.0,"Computer Graphics Mini Project on
CONGESTION CONTROL");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0.0,1.0,1.0);
drawstring(-1,2,0,"Using OPENGL");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0.0,1.0,1.0);
drawstring(-0.5,1.5,0,"By");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0.0,1.0,1.0);
drawstring(-2,1,0,"SUMAYYA TABASSUM (USN : 3KB10CS082)");
setFont(GLUT_BITMAP_TIMES_ROMAN_24);
glColor3f(0.0,1.0,1.0);
drawstring(-2,.5,0,"SUMAYYA SAMREEN (USN : 3KB10CS083)");

drawstring(-2,-0.5,0,"Press --> s to Start");


drawstring(-2,-1,0,"Press --> q to Quit");
GLfloat mat_ambient[]={0.0f,1.0f,2.0f,1.0f};
GLfloat mat_diffuse[]={0.0f,1.5f,.5f,1.0f};
GLfloat mat_specular[]={5.0f,1.0f,1.0f,1.0f};
GLfloat mat_shininess[]={50.0f};
glMaterialfv(GL_FRONT,GL_AMBIENT,mat_ambient);
glMaterialfv(GL_FRONT,GL_DIFFUSE,mat_diffuse);
glMaterialfv(GL_FRONT,GL_SPECULAR,mat_specular);
glMaterialfv(GL_FRONT,GL_SHININESS,mat_shininess);
GLfloat lightIntensity[]={1.7f,1.7f,1.7f,1.0f};
GLfloat light_position3[]={0.0f,5.0f,5.0f,0.0f};
glLightfv(GL_LIGHT0,GL_POSITION,light_position3);
glLightfv(GL_LIGHT0,GL_DIFFUSE,lightIntensity);
glEnable(GL_COLOR_MATERIAL);
glFlush();
glutSwapBuffers();
}
void menu(int id)
{
switch(id)
{
case 1:
glClear(GL_COLOR_BUFFER_BIT |
GL_DEPTH_BUFFER_BIT);
glutIdleFunc(s);
break;
case 2:
glClear(GL_COLOR_BUFFER_BIT |
GL_DEPTH_BUFFER_BIT);
goDown=false;
goup=false;
x=0.0;x1=-3.5;y1=-1.4;
x2=3.5;
y2=-1.4;
glutIdleFunc(com_ser);
break;
case 3:
glClear(GL_COLOR_BUFFER_BIT |
GL_DEPTH_BUFFER_BIT);
goDown=false;
down=false;
goup=false;
x=0.0;x1=-3.5;y1=-1.4;
x2=3.5;
y2=-1.4;
x3=-3.5,y3=1.3;
congested=true;
glutIdleFunc(com_ser);
break;
case 4:
glClear(GL_COLOR_BUFFER_BIT |
GL_DEPTH_BUFFER_BIT);
goDown=false;
down=false;
goup=false;
x=0.0;x1=-3.5;
x2=3.5;
y1=-1.4;
y2=-1.4;
x3=-3.5;y3=1.3;
remote=true;
glutIdleFunc(com_ser);
break;
case 5: congested=false;
goDown=false;down=false;
goup=false;
x=0.0;x1=-3.5;
x2=3.5;
y1=-1.4;
y2=-1.4;
x3=-3.5;y3=1.3;
glutIdleFunc(com_ser);
break;
case 6: remote=false;
down=false;
goDown=false;
goup=false;
x=0.0;x1=-3.5;
x2=3.5;
y1=-1.4;
y2=-1.4;
x3=-3.5;y3=1.3;
glutIdleFunc(com_ser);
break;
glClear(GL_COLOR_BUFFER_BIT |
GL_DEPTH_BUFFER_BIT);
glutIdleFunc(about);
break;
case 8:exit(0);
break;
}
glFlush();
glutSwapBuffers();
glutPostRedisplay();
}
void mykey(unsigned char key,int x,int y)
{
if(key=='s')
{
glutIdleFunc(s);
}
if(key=='q'||key=='Q')
{
exit(0);
}
}
void main(int argc, char *argv[])
{
glutInit(&argc, argv);
glutInitDisplayMode(GLUT_DOUBLE|GLUT_RGB);
glutInitWindowSize(1000,480);
glutInitWindowPosition(0,0);
glutCreateWindow("Local Area Network");
glutDisplayFunc(display);
glEnable(GL_LIGHTING);
glEnable(GL_LIGHT0);
glShadeModel(GL_SMOOTH);
glEnable(GL_DEPTH_TEST);
glEnable(GL_NORMALIZE);
glutKeyboardFunc(mykey);
glutCreateMenu(menu);

glutAddMenuEntry("Send Some Data",2);


glutAddMenuEntry("Create Congestion From Hacker A",3);
glutAddMenuEntry("Create Congestion From Hacker B",4);
glutAddMenuEntry("Remove Congestion From Hacker A ",5);
glutAddMenuEntry("Remove Congestion From Hacker B ",6);
glutAddMenuEntry("About Project 'a/A'",7);
glutAddMenuEntry("Quit 'q'",8);
glutAttachMenu(GLUT_RIGHT_BUTTON);
doInit();
glutMainLoop();
CHAPTER -7
MODEL AND SIMULATION TESTING

Model and simulation testing for free network congestion control involves creating a virtual
environment to evaluate the performance and effectiveness of the proposed congestion control
mechanisms. This process typically begins with developing a comprehensive model that
represents the network, including its topology, traffic patterns, and key components such as
routers, endpoints, and control algorithms. The simulation environment is built to replicate
real-world network conditions as closely as possible. This includes defining the network
topology with nodes and connections, specifying traffic generation patterns to mimic various
types of data flows, and implementing the congestion control algorithms under test. Tools like
ns-3, OMNeT++, or Mininet are commonly used for network simulation due to their flexibility
and detailed modeling capabilities.

Within the simulation, different scenarios are created to test the congestion control
mechanisms. These scenarios might include varying traffic loads, changes in network topology,
and the introduction of network failures or attacks. The goal is to observe how the system reacts
under different conditions and to measure key performance indicators such as throughput,
latency, packet loss, and fairness among users.

The simulation also involves incorporating Active Queue Management (AQM) techniques and
Explicit Congestion Notification (ECN) mechanisms to manage packet queues and signal
congestion. By monitoring the performance of these techniques within the simulation,
researchers can fine-tune their parameters for optimal results.

Data collected from the simulations provide insights into the strengths and weaknesses of the
congestion control strategies. Metrics such as the average and peak throughput, latency
distribution, packet loss rates, and the efficiency of congestion signaling are analyzed. This
analysis helps in identifying areas where the system performs well and where it may need
improvement.

Ultimately, model and simulation testing enables a thorough evaluation of the congestion
control system in a controlled and reproducible environment. This process helps ensure that
the system is robust, efficient, and capable of maintaining high network performance under a
variety of conditions.
Sl. No. Test function Outcome Inference
1 Bandwidth Utilization Test High utilization Network efficiently
achieved utilizes bandwidth
2 Latency Measurement Low latency Congestion control
observed minimizes delay
3 Packet Loss Test Minimal packet loss Effective congestion
avoidance
4 Throughput Analysis Consistent high Stable network
throughput performance
5 Fairness Check Equal resource Fair allocation among
distribution users
6 Scalability Test Performance Scalable congestion
degrades gracefully control mechanism
7 Bufferbloat Detection No significant Adequate buffer
bufferbloat management
RESULTS
Congestion control aims to regulate network traffic to avoid congestion collapse, ensure
fair resource allocation, and maintain high throughput and low latency. Key components
include. Flow Control Adjusting the rate at which data is sent to avoid overwhelming network
nodes. Feedback Mechanisms Using feedback from the network (e.g., packet loss, delays) to
adjust the sending rate.

Figure 7.1: Represents an external network or the internet. Likely a central server or service
within the network

Figure 7.2: The server is directly connected to router R4. The office is connected to router
R1.The hacker is connected to router R5.Data flows between components through the routers.
Routers manage traffic, ensuring efficient communication.
Figure 7.3: The connection to the “HACKER” suggests a need for robust security measures.
The cloud service should protect against unauthorized access and monitor potential threats.

Figure 7.4: R1 is connected to an icon labeled “HACKER,” which represents a potential


security threat.R4 is connected to an icon labeled “SERVER,” indicating a server within the
cloud.
CONCLUSION

Free network congestion control focuses on evaluating its effectiveness in managing traffic
flow and ensuring fair resource allocation, considering regulatory impacts, technological
advancements, user experience improvements, and identifying future directions for innovation
and research.

Remember that effective congestion control improves network performance, minimizes delays,
and enhances user experience

Congestion control is essential for keeping computer networks running smoothly. It helps
prevent network overloads by managing the flow of data, ensuring that information gets where
it needs to go without delays or loss. Effective congestion control improves network
performance and reliability, making sure that users have a stable and efficient connection. By
using these techniques, networks can handle high traffic volumes and continue to operate
effectively.
REFERENCES

1. http://jerome.jouvie.free.fr/OpenGl/Lessons/Lesson3.php
2. http://google.com
3. http://opengl.org
4. "Computer Networks: A Systems Approach" by Larry L. Peterson and Bruce S.
5. "Traffic and Congestion Control in IP/TCP Networks" by Raghupathy Sivakumar,
6. Prathima Agrawal, and Mohan Gurusamy
7. Donald D Hearn, M Pauline Baker and WarrenCarithers: Computer Graphics with
OpenGL 4th
8. Edition, Pearson, 2014
9. S.Sridhar, Digital Image Processing, second edition, Oxford University press 2016.

You might also like