 " Dream Logic " is the fifth episode of the second season of the American science fiction drama television series Fringe , and the 25th episode overall . It was written by Josh Singer and directed by Paul A. Edwards . The episode follows several people seemingly dreaming while still awake , leading the Fringe team to investigate the dangerous side effects of a sleep study . 
