code: def pulse(time, start, duration):
      
      t = time()
      return 1 if start <= t < start + duration else 0
docs: Implements vensim's PULSE function
  
      In range [-inf, start) returns 0
      In range [start, start + duration) returns 1
      In range [start + duration, +inf] returns 0