|
|
@ -1,64 +1,77 @@
|
|
|
|
%% CHAPTER4 contains the commands used in Chapter 4 of the tutorial
|
|
|
|
import numpy as np
|
|
|
|
%
|
|
|
|
from scipy import *
|
|
|
|
% CALL: Chapter4
|
|
|
|
from pylab import *
|
|
|
|
%
|
|
|
|
|
|
|
|
% Some of the commands are edited for fast computation.
|
|
|
|
#! CHAPTER4 contains the commands used in Chapter 4 of the tutorial
|
|
|
|
% Each set of commands is followed by a 'pause' command.
|
|
|
|
#!=================================================================
|
|
|
|
%
|
|
|
|
#!
|
|
|
|
% This routine also can print the figures;
|
|
|
|
#! CALL: Chapter4
|
|
|
|
% For printing the figures on directory ../bilder/ edit the file and put
|
|
|
|
#!
|
|
|
|
% printing=1;
|
|
|
|
#! Some of the commands are edited for fast computation.
|
|
|
|
|
|
|
|
#! Each set of commands is followed by a 'pause' command.
|
|
|
|
% Tested on Matlab 5.3
|
|
|
|
#!
|
|
|
|
% History
|
|
|
|
#! This routine also can print the figures;
|
|
|
|
% Revised pab sept2005
|
|
|
|
#! For printing the figures on directory ../bilder/ edit the file and put
|
|
|
|
% Added sections -> easier to evaluate using cellmode evaluation.
|
|
|
|
#! printing=1;
|
|
|
|
% revised pab Feb2004
|
|
|
|
|
|
|
|
% updated call to lc2sdat
|
|
|
|
#! Tested on Matlab 5.3
|
|
|
|
% Created by GL July 13, 2000
|
|
|
|
#! History
|
|
|
|
% from commands used in Chapter 4
|
|
|
|
#! Revised pab sept2005
|
|
|
|
%
|
|
|
|
#! Added sections -> easier to evaluate using cellmode evaluation.
|
|
|
|
|
|
|
|
#! revised pab Feb2004
|
|
|
|
|
|
|
|
#! updated call to lc2sdat
|
|
|
|
|
|
|
|
#! Created by GL July 13, 2000
|
|
|
|
|
|
|
|
#! from commands used in Chapter 4
|
|
|
|
|
|
|
|
#!
|
|
|
|
|
|
|
|
|
|
|
|
%% Chapter 4 Fatigue load analysis and rain-flow cycles
|
|
|
|
#! Chapter 4 Fatigue load analysis and rain-flow cycles
|
|
|
|
|
|
|
|
#!------------------------------------------------------
|
|
|
|
pstate = 'off';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
printing=0;
|
|
|
|
printing=0;
|
|
|
|
%set(0,'DefaultAxesFontSize',15')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.3.1 Crossing intensity
|
|
|
|
|
|
|
|
xx_sea = load('sea.dat');
|
|
|
|
|
|
|
|
tp_sea = dat2tp(xx_sea);
|
|
|
|
|
|
|
|
lc_sea = tp2lc(tp_sea);
|
|
|
|
|
|
|
|
T_sea = xx_sea(end,1)-xx_sea(1,1);
|
|
|
|
|
|
|
|
lc_sea(:,2) = lc_sea(:,2)/T_sea;
|
|
|
|
|
|
|
|
clf
|
|
|
|
|
|
|
|
subplot(221), plot(lc_sea(:,1),lc_sea(:,2))
|
|
|
|
|
|
|
|
title('Crossing intensity, (u, \mu(u))')
|
|
|
|
|
|
|
|
subplot(222), semilogx(lc_sea(:,2),lc_sea(:,1))
|
|
|
|
|
|
|
|
title('Crossing intensity, (log \mu(u), u)')
|
|
|
|
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
|
|
|
|
disp('Block 1'), pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
m_sea = mean(xx_sea(:,2));
|
|
|
|
|
|
|
|
f0_sea = interp1(lc_sea(:,1),lc_sea(:,2),m_sea,'linear')
|
|
|
|
#! Section 4.3.1 Crossing intensity
|
|
|
|
extr_sea = length(tp_sea)/(2*T_sea);
|
|
|
|
#!~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
|
|
|
|
|
|
import wafo.data as wd
|
|
|
|
|
|
|
|
import wafo.objects as wo
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
xx_sea = wd.sea()
|
|
|
|
|
|
|
|
ts = wo.mat2timeseries(xx_sea)
|
|
|
|
|
|
|
|
tp = ts.turning_points()
|
|
|
|
|
|
|
|
mM = tp.cycle_pairs(kind='min2max')
|
|
|
|
|
|
|
|
lc = mM.level_crossings()
|
|
|
|
|
|
|
|
lci = lc.copy()
|
|
|
|
|
|
|
|
T_sea = lci.args[-1]-lci.args[0]
|
|
|
|
|
|
|
|
lci.data = lci.data/T_sea
|
|
|
|
|
|
|
|
lci.labels.ylab='Crossing intensity'
|
|
|
|
|
|
|
|
subplot(2,2,1)
|
|
|
|
|
|
|
|
lci.plot()
|
|
|
|
|
|
|
|
subplot(2,2,2)
|
|
|
|
|
|
|
|
lci.setplotter(plotmethod='step')
|
|
|
|
|
|
|
|
show()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
m_sea = ts.data.mean()
|
|
|
|
|
|
|
|
f0_sea = interp(m_sea, lci.args,lci.data)
|
|
|
|
|
|
|
|
extr_sea = len(tp.data)/(2*T_sea)
|
|
|
|
alfa_sea = f0_sea/extr_sea
|
|
|
|
alfa_sea = f0_sea/extr_sea
|
|
|
|
disp('Block 2'),pause(pstate)
|
|
|
|
print('alfa = %g ' % alfa_sea )
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.3.2 Extraction of rainflow cycles
|
|
|
|
#! Section 4.3.2 Extraction of rainflow cycles
|
|
|
|
%% Min-max and rainflow cycle plots
|
|
|
|
#!~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
|
|
RFC_sea=tp2rfc(tp_sea);
|
|
|
|
#!#! Min-max and rainflow cycle plots
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mM_rfc=tp.cycle_pairs(h=0.3)
|
|
|
|
mM_sea=tp2mm(tp_sea);
|
|
|
|
mM_sea=tp2mm(tp_sea);
|
|
|
|
clf
|
|
|
|
clf
|
|
|
|
subplot(122), ccplot(mM_sea);
|
|
|
|
subplot(122),
|
|
|
|
|
|
|
|
mM.plot()
|
|
|
|
title('min-max cycle count')
|
|
|
|
title('min-max cycle count')
|
|
|
|
subplot(121), ccplot(RFC_sea);
|
|
|
|
subplot(121),
|
|
|
|
|
|
|
|
mM_rfc.plot()
|
|
|
|
title('Rainflow cycle count')
|
|
|
|
title('Rainflow cycle count')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
|
|
|
|
disp('Block 3'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%% Min-max and rainflow cycle distributions
|
|
|
|
#!#! Min-max and rainflow cycle distributions
|
|
|
|
ampmM_sea=cc2amp(mM_sea);
|
|
|
|
ampmM_sea=cc2amp(mM_sea);
|
|
|
|
ampRFC_sea=cc2amp(RFC_sea);
|
|
|
|
ampRFC_sea=cc2amp(RFC_sea);
|
|
|
|
clf
|
|
|
|
clf
|
|
|
@ -69,8 +82,8 @@ title('Rainflow amplitude distribution')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 4'),pause(pstate)
|
|
|
|
disp('Block 4'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.3.3 Simulation of rainflow cycles
|
|
|
|
#!#! Section 4.3.3 Simulation of rainflow cycles
|
|
|
|
%% Simulation of cycles in a Markov model
|
|
|
|
#!#! Simulation of cycles in a Markov model
|
|
|
|
n=41; param_m=[-1 1 n]; param_D=[1 n n];
|
|
|
|
n=41; param_m=[-1 1 n]; param_D=[1 n n];
|
|
|
|
u_markov=levels(param_m);
|
|
|
|
u_markov=levels(param_m);
|
|
|
|
G_markov=mktestmat(param_m,[-0.2 0.2],0.15,1);
|
|
|
|
G_markov=mktestmat(param_m,[-0.2 0.2],0.15,1);
|
|
|
@ -84,8 +97,8 @@ wafostamp([],'(ER)')
|
|
|
|
disp('Block 5'),pause(pstate)
|
|
|
|
disp('Block 5'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%% Rainflow cycles in a transformed Gaussian model
|
|
|
|
#!#! Rainflow cycles in a transformed Gaussian model
|
|
|
|
%% Hermite transformed wave data and rainflow filtered turning points, h = 0.2.
|
|
|
|
#!#! Hermite transformed wave data and rainflow filtered turning points, h = 0.2.
|
|
|
|
me = mean(xx_sea(:,2));
|
|
|
|
me = mean(xx_sea(:,2));
|
|
|
|
sa = std(xx_sea(:,2));
|
|
|
|
sa = std(xx_sea(:,2));
|
|
|
|
Hm0_sea = 4*sa;
|
|
|
|
Hm0_sea = 4*sa;
|
|
|
@ -98,10 +111,10 @@ param_h = [-1.5 2 51];
|
|
|
|
spec_norm = spec;
|
|
|
|
spec_norm = spec;
|
|
|
|
spec_norm.S = spec_norm.S/sa^2;
|
|
|
|
spec_norm.S = spec_norm.S/sa^2;
|
|
|
|
xx_herm = spec2sdat(spec_norm,[2^15 1],0.1);
|
|
|
|
xx_herm = spec2sdat(spec_norm,[2^15 1],0.1);
|
|
|
|
% ????? PJ, JR 11-Apr-2001
|
|
|
|
#! ????? PJ, JR 11-Apr-2001
|
|
|
|
% NOTE, in the simulation program spec2sdat
|
|
|
|
#! NOTE, in the simulation program spec2sdat
|
|
|
|
%the spectrum must be normalized to variance 1
|
|
|
|
#!the spectrum must be normalized to variance 1
|
|
|
|
% ?????
|
|
|
|
#! ?????
|
|
|
|
h = 0.2;
|
|
|
|
h = 0.2;
|
|
|
|
[dtp,u_herm,xx_herm_1]=dat2dtp(param_h,xx_herm,h);
|
|
|
|
[dtp,u_herm,xx_herm_1]=dat2dtp(param_h,xx_herm,h);
|
|
|
|
clf
|
|
|
|
clf
|
|
|
@ -112,7 +125,7 @@ title('Rainflow filtered wave data')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 6'),pause(pstate)
|
|
|
|
disp('Block 6'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Rainflow cycles and rainflow filtered rainflow cycles in the transformed Gaussian process.
|
|
|
|
#!#! Rainflow cycles and rainflow filtered rainflow cycles in the transformed Gaussian process.
|
|
|
|
tp_herm=dat2tp(xx_herm);
|
|
|
|
tp_herm=dat2tp(xx_herm);
|
|
|
|
RFC_herm=tp2rfc(tp_herm);
|
|
|
|
RFC_herm=tp2rfc(tp_herm);
|
|
|
|
mM_herm=tp2mm(tp_herm);
|
|
|
|
mM_herm=tp2mm(tp_herm);
|
|
|
@ -129,7 +142,7 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 7'),pause(pstate)
|
|
|
|
disp('Block 7'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.3.4 Calculating the rainflow matrix
|
|
|
|
#!#! Section 4.3.4 Calculating the rainflow matrix
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Grfc_markov=mctp2rfm({G_markov []});
|
|
|
|
Grfc_markov=mctp2rfm({G_markov []});
|
|
|
@ -139,13 +152,13 @@ subplot(122), cmatplot(u_markov,u_markov,Grfc_markov), axis('square')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 8'),pause(pstate)
|
|
|
|
disp('Block 8'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%%
|
|
|
|
#!#!
|
|
|
|
clf
|
|
|
|
clf
|
|
|
|
cmatplot(u_markov,u_markov,{G_markov Grfc_markov},3)
|
|
|
|
cmatplot(u_markov,u_markov,{G_markov Grfc_markov},3)
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 9'),pause(pstate)
|
|
|
|
disp('Block 9'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Min-max-matrix and theoretical rainflow matrix for test Markov sequence.
|
|
|
|
#!#! Min-max-matrix and theoretical rainflow matrix for test Markov sequence.
|
|
|
|
cmatplot(u_markov,u_markov,{G_markov Grfc_markov},4)
|
|
|
|
cmatplot(u_markov,u_markov,{G_markov Grfc_markov},4)
|
|
|
|
subplot(121), axis('square'), title('min2max transition matrix')
|
|
|
|
subplot(121), axis('square'), title('min2max transition matrix')
|
|
|
|
subplot(122), axis('square'), title('Rainflow matrix')
|
|
|
|
subplot(122), axis('square'), title('Rainflow matrix')
|
|
|
@ -154,7 +167,7 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 10'),pause(pstate)
|
|
|
|
disp('Block 10'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Observed and theoretical rainflow matrix for test Markov sequence.
|
|
|
|
#!#! Observed and theoretical rainflow matrix for test Markov sequence.
|
|
|
|
n=length(u_markov);
|
|
|
|
n=length(u_markov);
|
|
|
|
Frfc_markov=dtp2rfm(xxD_markov,n);
|
|
|
|
Frfc_markov=dtp2rfm(xxD_markov,n);
|
|
|
|
clf
|
|
|
|
clf
|
|
|
@ -166,7 +179,7 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 11'),pause(pstate)
|
|
|
|
disp('Block 11'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Smoothed observed and calculated rainflow matrix for test Markov sequence.
|
|
|
|
#!#! Smoothed observed and calculated rainflow matrix for test Markov sequence.
|
|
|
|
tp_markov=dat2tp(xx_markov);
|
|
|
|
tp_markov=dat2tp(xx_markov);
|
|
|
|
RFC_markov=tp2rfc(tp_markov);
|
|
|
|
RFC_markov=tp2rfc(tp_markov);
|
|
|
|
h=1;
|
|
|
|
h=1;
|
|
|
@ -180,16 +193,16 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 12'),pause(pstate)
|
|
|
|
disp('Block 12'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Rainflow matrix from spectrum
|
|
|
|
#!#! Rainflow matrix from spectrum
|
|
|
|
clf
|
|
|
|
clf
|
|
|
|
%GmM3_herm=spec2mmtpdf(spec,[],'Mm',[],[],2);
|
|
|
|
#!GmM3_herm=spec2mmtpdf(spec,[],'Mm',[],[],2);
|
|
|
|
GmM3_herm=spec2cmat(spec,[],'Mm',[],param_h,2);
|
|
|
|
GmM3_herm=spec2cmat(spec,[],'Mm',[],param_h,2);
|
|
|
|
pdfplot(GmM3_herm)
|
|
|
|
pdfplot(GmM3_herm)
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 13'),pause(pstate)
|
|
|
|
disp('Block 13'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%% Min-max matrix and theoretical rainflow matrix for Hermite-transformed Gaussian waves.
|
|
|
|
#!#! Min-max matrix and theoretical rainflow matrix for Hermite-transformed Gaussian waves.
|
|
|
|
Grfc_herm=mctp2rfm({GmM3_herm.f []});
|
|
|
|
Grfc_herm=mctp2rfm({GmM3_herm.f []});
|
|
|
|
u_herm=levels(param_h);
|
|
|
|
u_herm=levels(param_h);
|
|
|
|
clf
|
|
|
|
clf
|
|
|
@ -201,7 +214,7 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 14'),pause(pstate)
|
|
|
|
disp('Block 14'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%%
|
|
|
|
#!#!
|
|
|
|
clf
|
|
|
|
clf
|
|
|
|
Grfc_direct_herm=spec2cmat(spec,[],'rfc',[],[],2);
|
|
|
|
Grfc_direct_herm=spec2cmat(spec,[],'rfc',[],[],2);
|
|
|
|
subplot(121), pdfplot(GmM3_herm), axis('square'), hold on
|
|
|
|
subplot(121), pdfplot(GmM3_herm), axis('square'), hold on
|
|
|
@ -212,8 +225,8 @@ wafostamp([],'(ER)')
|
|
|
|
disp('Block 15'),pause(pstate)
|
|
|
|
disp('Block 15'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%% Observed smoothed and theoretical min-max matrix,
|
|
|
|
#!#! Observed smoothed and theoretical min-max matrix,
|
|
|
|
%% (and observed smoothed and theoretical rainflow matrix for Hermite-transformed Gaussian waves).
|
|
|
|
#!#! (and observed smoothed and theoretical rainflow matrix for Hermite-transformed Gaussian waves).
|
|
|
|
tp_herm=dat2tp(xx_herm);
|
|
|
|
tp_herm=dat2tp(xx_herm);
|
|
|
|
RFC_herm=tp2rfc(tp_herm);
|
|
|
|
RFC_herm=tp2rfc(tp_herm);
|
|
|
|
mM_herm=tp2mm(tp_herm);
|
|
|
|
mM_herm=tp2mm(tp_herm);
|
|
|
@ -233,10 +246,10 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 16'),pause(pstate)
|
|
|
|
disp('Block 16'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.3.5 Simulation from crossings and rainflow structure
|
|
|
|
#!#! Section 4.3.5 Simulation from crossings and rainflow structure
|
|
|
|
|
|
|
|
|
|
|
|
%% Crossing spectrum (smooth curve) and obtained spectrum (wiggled curve)
|
|
|
|
#!#! Crossing spectrum (smooth curve) and obtained spectrum (wiggled curve)
|
|
|
|
%% for simulated process with irregularity factor 0.25.
|
|
|
|
#!#! for simulated process with irregularity factor 0.25.
|
|
|
|
clf
|
|
|
|
clf
|
|
|
|
cross_herm=dat2lc(xx_herm);
|
|
|
|
cross_herm=dat2lc(xx_herm);
|
|
|
|
alpha1=0.25;
|
|
|
|
alpha1=0.25;
|
|
|
@ -258,8 +271,8 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 16'),pause(pstate)
|
|
|
|
disp('Block 16'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Crossing spectrum (smooth curve) and obtained spectrum (wiggled curve)
|
|
|
|
#!#! Crossing spectrum (smooth curve) and obtained spectrum (wiggled curve)
|
|
|
|
%% for simulated process with irregularity factor 0.75.
|
|
|
|
#!#! for simulated process with irregularity factor 0.75.
|
|
|
|
xx_herm_sim2=lc2sdat(cross_herm,500,alpha2);
|
|
|
|
xx_herm_sim2=lc2sdat(cross_herm,500,alpha2);
|
|
|
|
cross_herm_sim2=dat2lc(xx_herm_sim2);
|
|
|
|
cross_herm_sim2=dat2lc(xx_herm_sim2);
|
|
|
|
subplot(211)
|
|
|
|
subplot(211)
|
|
|
@ -277,15 +290,15 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 17'),pause(pstate)
|
|
|
|
disp('Block 17'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.4 Fatigue damage and fatigue life distribution
|
|
|
|
#!#! Section 4.4 Fatigue damage and fatigue life distribution
|
|
|
|
%% Section 4.4.1 Introduction
|
|
|
|
#!#! Section 4.4.1 Introduction
|
|
|
|
beta=3.2; gam=5.5E-10; T_sea=xx_sea(end,1)-xx_sea(1,1);
|
|
|
|
beta=3.2; gam=5.5E-10; T_sea=xx_sea(end,1)-xx_sea(1,1);
|
|
|
|
d_beta=cc2dam(RFC_sea,beta)/T_sea;
|
|
|
|
d_beta=cc2dam(RFC_sea,beta)/T_sea;
|
|
|
|
time_fail=1/gam/d_beta/3600 %in hours of the specific storm
|
|
|
|
time_fail=1/gam/d_beta/3600 #!in hours of the specific storm
|
|
|
|
disp('Block 18'),pause(pstate)
|
|
|
|
disp('Block 18'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.4.2 Level crossings
|
|
|
|
#!#! Section 4.4.2 Level crossings
|
|
|
|
%% Crossing intensity as calculated from the Markov matrix (solid curve) and from the observed rainflow matrix (dashed curve).
|
|
|
|
#!#! Crossing intensity as calculated from the Markov matrix (solid curve) and from the observed rainflow matrix (dashed curve).
|
|
|
|
clf
|
|
|
|
clf
|
|
|
|
mu_markov=cmat2lc(param_m,Grfc_markov);
|
|
|
|
mu_markov=cmat2lc(param_m,Grfc_markov);
|
|
|
|
muObs_markov=cmat2lc(param_m,Frfc_markov/(T_markov/2));
|
|
|
|
muObs_markov=cmat2lc(param_m,Frfc_markov/(T_markov/2));
|
|
|
@ -297,8 +310,8 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 19'),pause(pstate)
|
|
|
|
disp('Block 19'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.4.3 Damage
|
|
|
|
#!#! Section 4.4.3 Damage
|
|
|
|
%% Distribution of damage from different RFC cycles, from calculated theoretical and from observed rainflow matrix.
|
|
|
|
#!#! Distribution of damage from different RFC cycles, from calculated theoretical and from observed rainflow matrix.
|
|
|
|
beta = 4;
|
|
|
|
beta = 4;
|
|
|
|
Dam_markov = cmat2dam(param_m,Grfc_markov,beta)
|
|
|
|
Dam_markov = cmat2dam(param_m,Grfc_markov,beta)
|
|
|
|
DamObs1_markov = cc2dam(RFC_markov,beta)/(T_markov/2)
|
|
|
|
DamObs1_markov = cc2dam(RFC_markov,beta)/(T_markov/2)
|
|
|
@ -318,24 +331,24 @@ wafostamp([],'(ER)')
|
|
|
|
disp('Block 21'),pause(pstate)
|
|
|
|
disp('Block 21'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%%
|
|
|
|
#!#!
|
|
|
|
%Damplus_markov = lc2dplus(mu_markov,beta)
|
|
|
|
#!Damplus_markov = lc2dplus(mu_markov,beta)
|
|
|
|
pause(pstate)
|
|
|
|
pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.4.4 Estimation of S-N curve
|
|
|
|
#!#! Section 4.4.4 Estimation of S-N curve
|
|
|
|
|
|
|
|
|
|
|
|
%% Load SN-data and plot in log-log scale.
|
|
|
|
#!#! Load SN-data and plot in log-log scale.
|
|
|
|
SN = load('sn.dat');
|
|
|
|
SN = load('sn.dat');
|
|
|
|
s = SN(:,1);
|
|
|
|
s = SN(:,1);
|
|
|
|
N = SN(:,2);
|
|
|
|
N = SN(:,2);
|
|
|
|
clf
|
|
|
|
clf
|
|
|
|
loglog(N,s,'o'), axis([0 14e5 10 30])
|
|
|
|
loglog(N,s,'o'), axis([0 14e5 10 30])
|
|
|
|
%if (printing==1), print -deps ../bilder/fatigue_?.eps end
|
|
|
|
#!if (printing==1), print -deps ../bilder/fatigue_?.eps end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 22'),pause(pstate)
|
|
|
|
disp('Block 22'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%% Check of S-N-model on normal probability paper.
|
|
|
|
#!#! Check of S-N-model on normal probability paper.
|
|
|
|
|
|
|
|
|
|
|
|
normplot(reshape(log(N),8,5))
|
|
|
|
normplot(reshape(log(N),8,5))
|
|
|
|
if (printing==1), print -deps ../bilder/fatigue_17.eps
|
|
|
|
if (printing==1), print -deps ../bilder/fatigue_17.eps
|
|
|
@ -343,7 +356,7 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 23'),pause(pstate)
|
|
|
|
disp('Block 23'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Estimation of S-N-model on linear scale.
|
|
|
|
#!#! Estimation of S-N-model on linear scale.
|
|
|
|
clf
|
|
|
|
clf
|
|
|
|
[e0,beta0,s20] = snplot(s,N,12);
|
|
|
|
[e0,beta0,s20] = snplot(s,N,12);
|
|
|
|
title('S-N-data with estimated N(s)','FontSize',20)
|
|
|
|
title('S-N-data with estimated N(s)','FontSize',20)
|
|
|
@ -353,7 +366,7 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 24'),pause(pstate)
|
|
|
|
disp('Block 24'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Estimation of S-N-model on log-log scale.
|
|
|
|
#!#! Estimation of S-N-model on log-log scale.
|
|
|
|
clf
|
|
|
|
clf
|
|
|
|
[e0,beta0,s20] = snplot(s,N,14);
|
|
|
|
[e0,beta0,s20] = snplot(s,N,14);
|
|
|
|
title('S-N-data with estimated N(s)','FontSize',20)
|
|
|
|
title('S-N-data with estimated N(s)','FontSize',20)
|
|
|
@ -363,8 +376,8 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 25'),pause(pstate)
|
|
|
|
disp('Block 25'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Section 4.4.5 From S-N curve to fatigue life distribution
|
|
|
|
#!#! Section 4.4.5 From S-N curve to fatigue life distribution
|
|
|
|
%% Damage intensity as function of $\beta$
|
|
|
|
#!#! Damage intensity as function of $\beta$
|
|
|
|
beta = 3:0.1:8;
|
|
|
|
beta = 3:0.1:8;
|
|
|
|
DRFC = cc2dam(RFC_sea,beta);
|
|
|
|
DRFC = cc2dam(RFC_sea,beta);
|
|
|
|
dRFC = DRFC/T_sea;
|
|
|
|
dRFC = DRFC/T_sea;
|
|
|
@ -375,7 +388,7 @@ end
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
wafostamp([],'(ER)')
|
|
|
|
disp('Block 26'),pause(pstate)
|
|
|
|
disp('Block 26'),pause(pstate)
|
|
|
|
|
|
|
|
|
|
|
|
%% Fatigue life distribution with sea load.
|
|
|
|
#!#! Fatigue life distribution with sea load.
|
|
|
|
dam0 = cc2dam(RFC_sea,beta0)/T_sea;
|
|
|
|
dam0 = cc2dam(RFC_sea,beta0)/T_sea;
|
|
|
|
[t0,F0] = ftf(e0,dam0,s20,0.5,1);
|
|
|
|
[t0,F0] = ftf(e0,dam0,s20,0.5,1);
|
|
|
|
[t1,F1] = ftf(e0,dam0,s20,0,1);
|
|
|
|
[t1,F1] = ftf(e0,dam0,s20,0,1);
|
|
|
|