% ohp_lit(OHP) is true if the projector OHP's lamp is lit.
ohp_lit(OHP) <-
   projector(OHP) &
   turned_on(OHP) &
   ok(OHP) &
   plugged_into(OHP,Outlet) &
   live(Outlet).

% could_see_trasparency(OHP) is true if you could see a transparency
% that is on projector OHP.
could_see_trasparency(OHP) <-
   projector(OHP) &
   ohp_lit(OHP) &
   mirror_in_place(OHP) &
   focussed(OHP).

% can_see(Tran) is true if you can see tansparency Trans
can_see(Tran) <-
   on(Tran,OHP) &
   could_see_trasparency(OHP).

% projector(OHP) is true if OHP is an overhead projector
% ohp1, ohp2 and ohp3 are overhead projectors
projector(ohp1).
projector(ohp2).
projector(ohp3).

% turned_on(OHP) is true if projector OHP is turned on.
turned_on(ohp1).
turned_on(ohp2).

% ok(OHP) is true of projector OHP isn't broken
ok(ohp1).
ok(ohp2).

% plugged_into(OHP,Outlet) is true if projector OHP is plugged into
% electrical outlet Outlet
plugged_into(ohp1,p1).
plugged_into(ohp2,p2).

% mirror_in_place(OHP) is true if ptojector OHP's mirrir is where it
% should be.
mirror_in_place(ohp1).
mirror_in_place(ohp2).

% focussed(OHP) is true if projector OHP is focussed
focussed(ohp1).

% on(Tran,OHP) is true if transparency Tran is on projector OHP.
on(lect2_3,ohp1).
on(lect2_4,ohp2).

