added formula parsing for the counter in time