% COMPUTE_LIQUID.M %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% Compute liquid flows for a section
%linearized francis weir
function L = compute_liquid(secnr,L_in,x,LO,xO)

global coldata hydraulic

L=zeros(coldata.Nt(secnr),1);

L(1)=L_in;
i=2:coldata.Nt(secnr);L(i)  = LO + (x(i)-xO(i))*hydraulic.k1 ;

