Generally when average access time to access main memory is calculated by doing address translation then we call it Effective memory access time (TLB, Page Table, O.S) and when it involves caching of data then main memory access, we call it Average memory access time (cache, C.O).
Note:- whenever they mention page fault service time they trying to say the collective time "page replacement time if there is page fault + again the memory access time to read the replaced page or desired page" So here 100-time unit includes all this, similarly for 300-time unit. It is the collective time of "dirty page replacement time if the page is dirty + again main memory access to read the desired page".
The only standard formula to calculate Effective memory access time is
EMAT = p (TLB + M) + (1-p) (TLB + K*M + M) where k is the no. of levels of page table.
Simplified formula:-
EMAT= TLB + M.M + (1-p) (k * M)
If we talk about only page fault in main memory (not TLB)
=P∗(TIME to access main memory) + (1−P)*( M.M + time to service page fault & access the page)
Simplified formula:-
EMAT= M.M + (1-p) (page service time)
If there are TLB and Page fault both (Note:- TLB hit can also lead to page fault in main memory for various reasons like dirty page or write access on write-protected page)
= (Virtual address to Physical address translation) + (Fetch the word from the memory)
={p (TLB) + (1-p) (TLB + K*M) } + {(P∗M + (1−P)*( M + page fault service time))}
Simplified formula:-
=TLB + (1-p) (k*M) + M + (1-P)(page service time).
We can extend this concept to cache memory also...
Now coming back to the question
Using extended formula:-
EMAT= (1-p) * M.M + P {(1-p)*(M + service time) + p(M + dirty page time)
3 = (1-p) * 1 + P {(1-p)*(1 + 100) + p(1 + 300)
3 = 1-p+101p-101$p^{2}$+301$p^{2}$
200$p^{2}$+100p-2=0
P=0.0194
Using simplified formula:-
EMAT= M.M + p{ (1-p)*Service + p*Dirty} Note:- we can't further simplify this formula because service time and dirty page time both are disjoint(They do not have anything in common like p(A+B)+(1-p)(A+B+C)).
3= 1+ p{(1-p)*100+p*300}
200$p^{2}$+100p-2=0
P= 0.0194