Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Fractional Brownian Motion in Matlab

22 views
Skip to first unread message

Vivas

unread,
Jul 16, 2008, 4:07:10 PM7/16/08
to
Hi, I want simulate Fractional Brownian Motion in Matlab and I'm using
the wavelets toolbox. In this toolbox there is one other function to
calculate the Hurst exponent of series in Matlab. When I use the
functions of matlab (to generate and to estimate) its ok i.e. So when
I use other methods to calculate the hurst exponent of this series
(like DFA) generate in Matlab I had different exponents.
I think that is a problem in a Matlab. So I need a method or software
to generate an precise fBm..

Thanks for any help

Roger Bagula

unread,
Jul 23, 2008, 11:51:19 AM7/23/08
to
Vivas wrote:

http://www.google.com/codesearch?q=brownian+lang%3Amatlab&hl=en&btnG=Search+Code
Datasets/MakeBrownian.m - 4 identical

9: % Outputs
% fBr (pseudo) Fractional Brownian signal
%
% Description
% Uses a Frequency Domain algorithm to get a pseudo Brownian
Motion
% The law is NOT normalized to give unit variance to unit
increments.

www-stat.stanford.edu/~wavelab/ftp/WaveLab802.zip - Unknown - Matlab -
More from WaveLab802.zip »

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47

function fBr = MakeBrownian(n,H,par)
% MakeBrownian -- Create Fractional Brownian Signal
% Usage
% fBr = MakeBrownian(n,H,par)
% Inputs
% n signal length
% H base of digits in expansion
% par optional, degree of extension in algorithm, default =8.
% Outputs
% fBr (pseudo) Fractional Brownian signal
%
% Description
% Uses a Frequency Domain algorithm to get a pseudo Brownian Motion
% The law is NOT normalized to give unit variance to unit increments.
%
if nargin < 3,
par = 8;
end
N = n .*par;

% generate the FT of a real white noise
w = WhiteNoise(zeros(1,N));
what = fft(w);

% formal fractional integral
eta = 2 * pi * [0:(N/2) (-(N/2)+1):(-1)] ./ N;
eta(1) = 1;
bhat = (abs(eta) .^ (-2*H)) .* what;
bhat(1) = 0.;
fBr = ifft(bhat);

% extract a segment that is well away from the edges

start = floor(par/2 .* n);
stop = start+n-1;
fBr = real(fBr(start:stop));

%
% Part of WaveLab Version 802
% Built Sunday, October 3, 1999 8:52:27 AM
% This is Copyrighted Material
% For Copying permissions see COPYING.m
% Comments? e-mail wav...@stat.stanford.edu
%

0 new messages