Added end conditions for FEMA.