Transient response of RC and RL circuits