plot contours of joint return period

3 visualizzazioni (ultimi 30 giorni)
soheil radfar
soheil radfar il 4 Gen 2020
Commentato: Smit Doshi il 11 Ago 2022
Hi everybody,
I am trying to plot contours for variable "T" and something like this figure should be obtained:
Capture.JPG
T itself is a function of WL and Hs. Below is my code:
clc
clear all
WL = gevrnd(-0.4176,0.6703,1.4837,100000,1);
Hs = gprnd(-0.0960,0.2152,1.7001,100000,1);
U = cdf('generalized extreme value',WL,-0.4176,0.6703,1.4837);
V = cdf('Generalized Pareto',Hs,-0.0960,0.2152,1.7001);
mu = 0.08;
for i=1:length(WL)
for j=1:length(Hs)
Cc(i,j) = exp(1-((((1-log(U(i))).^0.9838-1).^1.0075+((1-log(V(j))).^0.9838-1)...
.^1.0075).^0.9926+1).^1.0165);
test(i,j)=1-U(i)-V(j)+Cc(i,j);
T(i,j)=mu/test(i,j);%year
end
end
v=[1 25];
[C,h]=contour(WL,Hs,T,v);
clabel(C,h);
Anyone had experience about such analyses?
  1 Commento
Smit Doshi
Smit Doshi il 11 Ago 2022
Hello, were you able to find the solution. If yes it would be nice of you if you could share the script I am also looking to plot something similar to this.

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Contour Plots in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by