see this question from gate 2018.
Consider a process executing on an operating system that uses demand paging. The average
time for a memory access in the system is M units if the corresponding memory page is
available in memory, and D units if the memory access causes a page fault. It has been
experimentally measured that the average time taken for a memory access in the process is
Which one of the following is the correct expression for the page fault rate experienced by
(A) (D – M) / (X – M) (B) (X – M) / (D – M)
(C) (D – X) / (D – M) (D) (X – M) / (D – X)
here if we try to solve by adding extra M unit of time during page fault, then none of the options matches, and also nothing has been given about the actual value of the service times, so that we would compare for large or small.
these type of questions are confusing... but after solving a bunch of questions, what i concluded is IF THEY HAVE DIRECTLY GIVEN THE PAGE FAULT SERVICE TIME, THEN NO NEED TO INCLUDE MEMORY ACCESS TIME AGAIN, AS THEY HAVE ALREADY TAKEN CARE OF THAT. INSTEAD IF THEY GAVE US THE EXPLICIT DATA LIKE, LOADING FROM HARD DISK TO MAIN MEMORY TAKES THIS MUCH AMOUNT OF TIME, OR ACCESSING PAGE TABLE TAKES THIS TIME, AND SO ON, BUT NOT GIVEN THE PAGE FAULT SERVICE TIME DIRECTLY, THEN WE HAVE TO INCLUDE THE MEORY ACCESS TIME TOO.