Optimal page replacement
An optimal page replacement algorithm has the least page fault rate of all algorithms. The algorithm states that a 'replace the page that will not be used for the longest period of time'.
The drawback of this algorithm is that it is very hard to execute as it requires future knowledge of the reference string.
Example Consider the reference string 1,2,3,4,3,1. Here 1,2,3 are inserted as normal however when 4 comes we replace 2 as it isn't used again.