function v=compute_ekman_surge_cetn(vmax,rmax,r35,vt,phi,phi_in,w,a,n,lat)
% Computes ekman_surge_cetn
% Script automatically generated by fit_ekman_surge_cetn.m
% Inputs : 
% vmax           = Vmax (km/h)
% rmax           = Rmax (km)
% r35            = R35 (km)
% vt             = forward speed (km/h)
% phi            = track angle (deg)
% phi_in         = inflow angle (deg)
% w              = shelf width (km)
% a              = Dean slope a (-)
% n              = Mannings n
% lat            = latitude (deg)

% R2    = 0.51797
% RMSE  = 1.7942
% MEAN  = 6.5241
% RANGE = 1.6445 - 12.4664

beta( 1 )= 0.0000e+00 ;
beta( 2 )= 7.3627e-02 ;
beta( 3 )= 1.0000e+00 ;
beta( 4 )= -7.0783e-01 ;
beta( 5 )= 3.7318e+00 ;
beta( 6 )= 7.9959e+02 ;
beta( 7 )= 1.5299e-01 ;
beta( 8 )= 1.0000e+00 ;
beta( 9 )= -6.8978e+01 ;
beta( 10 )= 2.0321e+02 ;
beta( 11 )= 3.2821e+01 ;
beta( 12 )= -1.4180e+01 ;

v = (beta(1) + beta(2)*r35.^beta(3) + beta(4)*lat + beta(5).*vt + beta(6)*a.^beta(8) + beta(7)*w + beta(9).*tanh(vmax/beta(10)) + beta(11)*cos((phi-beta(12))*pi/180) ) ./ ((cos(phi*pi/180).*vt));
