25 lines
562 B
Typst

#import "utils.typ": sim-demand-paging
#set document(title: "Demand paging algorithms")
#set page(width: auto, height: auto, margin: 1cm)
#set text(font: "Source Sans 3")
#let requests = (7, 0, 1, 2, 0, 3, 0, 4, 2, 3, 0, 3, 2, 1, 2, 0, 1, 7, 0 , 1)
#align(center, text(size: 1.2em)[*Demand paging algorithms*])
#figure(
sim-demand-paging(requests, "FIFO"),
caption: [Demand Paging: FIFO]
)
#figure(
sim-demand-paging(requests, "OPT"),
caption: [Demand Paging: OPT]
)
#figure(
sim-demand-paging(requests, "LRU"),
caption: [Demand Paging: LRU]
)