close all
clear all

Hs = [4 6 8];
Tp = [8 10 12];
fp = 1./Tp
T = 3:.1:18;
f = 1./T;


for i = 1:length(Hs)

    S{i} = ((5/16)*(Hs(i)^2)*(fp(i)^4).*exp(-1.25*(f/fp(i)).^-4))./(f.^5);

end

figure
hold all
for i = 1:length(Hs)
    plot(T,S{i});
    leg_str{i} = ['Hs = ' num2str(Hs(i)) ' m   Tp = ' num2str(Tp(i)) ' s'];
end
legend(leg_str);
grid on
xlabel('Wave Period (s)');
ylabel('S');
