Program for calculation of the slide gates.