Latin hypercube sampling coupled with Monte Carlo simulation

Hi I am trying to formulate a Monte carlo simulation for corrosion initiation time and at the same time use Latin Hypercube sampling to come up with a more precise description of data ie to form a curve fitting pdf(probability density function). The relative variables I have are coefficient of variation and mean, however I am struggling to find the code for using Cov as the option provided is for matrix options. Below is some of the code I have managed to formulate: X = normrnd(40, 0.1, 1, 1000); Co = lognrnd(3.5, 0.5, 1, 1000); D = 5*(10^-5); Cth = unifrnd(0.6, 1.2, 1, 1000); E = 1/[erfc(Cth / Co)]; T = X .^ 2 / [4 * D .* E .^ 2]; a=mean(log(T)); b=std(log(T)); To=lognpdf(T,a,b); plot(T,To); grid; xlabel('T'); ylabel('To')
I am still a long way to go but I believe if I can find a code template for the simulation I can be able to progress further into the corrosion modelling.

1 件のコメント

Duc Thanh Tran
Duc Thanh Tran 2022 年 7 月 20 日
Hello sir. I also got the same problem with you now. Have you dealed with it? Hopefully, you could share your experiences with me. Thanks in advance!

サインインしてコメントする。

回答 (0 件)

カテゴリ

質問済み:

2017 年 4 月 18 日

コメント済み:

2022 年 7 月 20 日

Community Treasure Hunt

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

Start Hunting!

Translated by