The contribution focuses on the design of a control algorithm aimed at the operative control of runoff water from a reservoir during flood situations. Management is based on the stochastically specified forecast of water inflow into the reservoir. From a mathematical perspective, the solved task presents the control of a dynamic system whose predicted hydrological input (water inflow) is characterised by significant uncertainty. The algorithm uses a combination of simulation model data, in which the position of the bottom outlets is sought via nonlinear optimisation methods, and artificial intelligence methods (adaptation and fuzzy model). The task is written in the technical computing language MATLAB using the Fuzzy Logic Toolbox.