jonswap.m 376 Bytes
function [E] = JONSWAP(Tm,Hs,om)
% Formule http://hmf.enseeiht.fr/travaux/CD0910/bei/beiere/groupe4/node/59

gam = 3.3;
alp = 0.0624/(0.23+0.0336*gam-0.185/(1.9+gam));
fp = 1/Tm;
f = om/(2*pi);
sig = zeros(length(om),1);
sig(f<=fp) = 0.07;
sig(f>fp) = 0.09;

E = alp*Hs^2*fp^4*f.^-5.*exp(-5/4*(fp./f).^4).*gam.^(exp(-(f-fp).^2./(2.*sig.^2.*fp^2)));




end