Generating random numbers from Alpha-stable pdf which expends in time (in a loop)
조회 수: 4 (최근 30일)
이전 댓글 표시
I asked first on another site, decided to ask here because I go no answers.
The following line of Matlab code generates 100000 random numbers from an Alpha-stable pdf (here Alpha=0.5):
Rand = random('Stable',0.5,0,1,0,[1,100000]);
The distribution of Rand exactly matches the the 'theoretical' curve generated by
PDF = makedist('Stable','alpha',0.5,'beta',0,'gam',1,'delta',0);
x = -5:.1:5;
PDF = pdf(PDF,x);
figure
plot(x,PDF,'r-.');
(to check, use, e.g.:)
Data=Rand;
Middle=0.01;
PosBinsUP=10.^(log10(Middle):0.05:log10(max(abs(Data))));
PosBinsDown=10.^(log10(Middle):0.05:log10(abs(min(Data))));
xbins=[-flip(PosBinsDown) -Middle:0.2:Middle PosBinsUP];
[xpdf ypdf]= plotpdfc(Data, xbins);
plot(xpdf(1:end-1),ypdf(1:end-1),'Or');
xlim([-5,5]);
My question is:
How do I generate these Rands in a loop over 't', such that their distribution will expand in time, namely P(Rand) = t^(-1/Alpha) W(Rand/ t^(1/Alpha))?
댓글 수: 4
Jeff Miller
2020년 4월 16일
Sorry, I don't really understand this distribution, so I don't have anything useful to contribute. It just seems that if you want a random number from the stable distribution at each t, then your only option is to adjust the stable's parameter values to be whatever you want for each t.
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Logical에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!