Hi I'm currently going through some questions, basically studying up one bits for my operating systems unit and my particular weakness is algorithms and 'working out' type questions such as this one below.
Consider the following snapshot of the system, with 4 types of resources and 3 processes, P1,
P2 and P3.
Available resources vector A: [4 1 0 1]
Current allocation matrix
P1 [3 1 0 0]
P2 [0 0 1 2]
Maximum request matrix
P1 [3 4 4 0]
P2 [0 0 1 3]
P3 [0 2 3 4] P3 [3 3 4 6]
What is the existing resource vector for this system?
Using bankers algorithm prove what is the current state of the system: safe, unsafe or
Process P1 requests the following resources [0 1 0 0], and this request is granted. What
is the new state of the system: safe, unsafe or deadlocked?
I am not looking for answers but I'm looking for help or methods to find
A) the existing resource vector
B) if the system is deadlocked or not (basically it's state)
C) for part c i have no idea where to begin but I am guessing it is similar in method to B.
Any help is greatly appreciated.
apologies if this is the incorrect place to post this question. I was unsure whether to place it in the C forum or not since it isn't really coding
Edited by BryantFury