Petri Net
The next Petri net model contains two processes A and B accessing the files F1
and F2. For both processes there are places representing the following states:
- the process has been started .
- the process uses the first file (F1 for the process A, F2 for B) .
- the process uses both files .
For both processes there are transitions representing the following actions:
- the process takes the first file (F1 for the process A, F2 for B),
- the process takes the second file (F2 for the process A, F1 for B),
- the process finishes.
The files are modeled by tokens in places F1 and F2 respectively. The tokens in
places "process starts" represent the fact, that the processes have been started.
At the beginning there are two enabled transitions (both processes may start).
The second step decides whether there will be a deadlock or not. If both
processes take one file, no process can continue. If the process which took the
first file takes also the second one, everything is OK. The next example shows the
solution to this deadlock problem.
model
Thanks

More Related Content

PPT
petri-nets: definition and its application
PPT
Petri Nets financial problems solution with
PPTX
all about petri netis model and simulation
PDF
CS-438 WK13-15LEC25-30 Computer System Modeling.pdf
PPT
INTRODUCTION TO PETRINETS, PROCESS INVOVLED
PPT
petri.ppt
PPT
petri.pptSDGHFJKLDTSRDTYFKHGDSDHFJKJHDSAFGHKFDSASDFJGHKHJG
PPT
Os6
petri-nets: definition and its application
Petri Nets financial problems solution with
all about petri netis model and simulation
CS-438 WK13-15LEC25-30 Computer System Modeling.pdf
INTRODUCTION TO PETRINETS, PROCESS INVOVLED
petri.ppt
petri.pptSDGHFJKLDTSRDTYFKHGDSDHFJKJHDSAFGHKFDSASDFJGHKHJG
Os6

Similar to Petri net (20)

PPT
Os6 2
PPT
Section07-Deadlocks (1).ppt
PPT
Section07-Deadlocks_operating_system.ppt
PDF
Reasoning on Labelled Petri Nets and Their Dynamics in a Stochastic Setting
PPTX
Ch 4 deadlock
PDF
Petri Net.pdf
PPT
Deadlocks
DOC
Deadlock- System model, resource types, deadlock problem, deadlock characteri...
PPT
Process Synchronization And Deadlocks
PDF
Section07-Deadlocks.pdf
PPT
Dead Lock
PPTX
Deadlock iOS topic ppt which goes deep into the deadlock.pptx
PPTX
Deadlocks1
PPTX
Deadlock Detection Algorithm
PPT
Chapter06.ppt
PPTX
OS Presentation 1 (1).pptx
PPTX
Deadlock Avoidance in Operating System
PPT
Deadlock.ppt
PPTX
DeadLock in Operating-Systems
Os6 2
Section07-Deadlocks (1).ppt
Section07-Deadlocks_operating_system.ppt
Reasoning on Labelled Petri Nets and Their Dynamics in a Stochastic Setting
Ch 4 deadlock
Petri Net.pdf
Deadlocks
Deadlock- System model, resource types, deadlock problem, deadlock characteri...
Process Synchronization And Deadlocks
Section07-Deadlocks.pdf
Dead Lock
Deadlock iOS topic ppt which goes deep into the deadlock.pptx
Deadlocks1
Deadlock Detection Algorithm
Chapter06.ppt
OS Presentation 1 (1).pptx
Deadlock Avoidance in Operating System
Deadlock.ppt
DeadLock in Operating-Systems
Ad

More from Mohamed Magdy (7)

PPTX
Kalman Filter
PPTX
Svm classifier
PPTX
Plc (skyscraper glass cleaning robot)
PPTX
Fuzzy logic control (ABS)
PPT
hospital database
PPTX
Dss project
PPTX
Face recognition
Kalman Filter
Svm classifier
Plc (skyscraper glass cleaning robot)
Fuzzy logic control (ABS)
hospital database
Dss project
Face recognition
Ad

Recently uploaded (20)

PPTX
A Brief Introduction to IoT- Smart Objects: The "Things" in IoT
PDF
First part_B-Image Processing - 1 of 2).pdf
PDF
Unit I -OPERATING SYSTEMS_SRM_KATTANKULATHUR.pptx.pdf
PDF
August -2025_Top10 Read_Articles_ijait.pdf
PPTX
Amdahl’s law is explained in the above power point presentations
PPTX
CONTRACTS IN CONSTRUCTION PROJECTS: TYPES
PPTX
Graph Data Structures with Types, Traversals, Connectivity, and Real-Life App...
PDF
Cryptography and Network Security-Module-I.pdf
PDF
Unit1 - AIML Chapter 1 concept and ethics
PPT
Chapter 1 - Introduction to Manufacturing Technology_2.ppt
PPTX
mechattonicsand iotwith sensor and actuator
PPTX
wireless networks, mobile computing.pptx
PDF
Introduction to Power System StabilityPS
PDF
Prof. Dr. KAYIHURA A. SILAS MUNYANEZA, PhD..pdf
PPTX
ASME PCC-02 TRAINING -DESKTOP-NLE5HNP.pptx
PPTX
Petroleum Refining & Petrochemicals.pptx
PPTX
Management Information system : MIS-e-Business Systems.pptx
PPTX
Measurement Uncertainty and Measurement System analysis
PPTX
Software Engineering and software moduleing
PDF
Computer System Architecture 3rd Edition-M Morris Mano.pdf
A Brief Introduction to IoT- Smart Objects: The "Things" in IoT
First part_B-Image Processing - 1 of 2).pdf
Unit I -OPERATING SYSTEMS_SRM_KATTANKULATHUR.pptx.pdf
August -2025_Top10 Read_Articles_ijait.pdf
Amdahl’s law is explained in the above power point presentations
CONTRACTS IN CONSTRUCTION PROJECTS: TYPES
Graph Data Structures with Types, Traversals, Connectivity, and Real-Life App...
Cryptography and Network Security-Module-I.pdf
Unit1 - AIML Chapter 1 concept and ethics
Chapter 1 - Introduction to Manufacturing Technology_2.ppt
mechattonicsand iotwith sensor and actuator
wireless networks, mobile computing.pptx
Introduction to Power System StabilityPS
Prof. Dr. KAYIHURA A. SILAS MUNYANEZA, PhD..pdf
ASME PCC-02 TRAINING -DESKTOP-NLE5HNP.pptx
Petroleum Refining & Petrochemicals.pptx
Management Information system : MIS-e-Business Systems.pptx
Measurement Uncertainty and Measurement System analysis
Software Engineering and software moduleing
Computer System Architecture 3rd Edition-M Morris Mano.pdf

Petri net

  • 2. The next Petri net model contains two processes A and B accessing the files F1 and F2. For both processes there are places representing the following states: - the process has been started . - the process uses the first file (F1 for the process A, F2 for B) . - the process uses both files .
  • 3. For both processes there are transitions representing the following actions: - the process takes the first file (F1 for the process A, F2 for B), - the process takes the second file (F2 for the process A, F1 for B), - the process finishes.
  • 4. The files are modeled by tokens in places F1 and F2 respectively. The tokens in places "process starts" represent the fact, that the processes have been started. At the beginning there are two enabled transitions (both processes may start). The second step decides whether there will be a deadlock or not. If both processes take one file, no process can continue. If the process which took the first file takes also the second one, everything is OK. The next example shows the solution to this deadlock problem.