Show
Ignore:
Timestamp:
05/16/10 23:13:21 (14 years ago)
Author:
smidl
Message:

Doc + new examples

Location:
applications/bdmtoolbox/tutorial/userguide
Files:
3 added
1 modified

Legend:

Unmodified
Added
Removed
  • applications/bdmtoolbox/tutorial/userguide/pdfds_example.m

    r940 r944  
    11clear all 
    22% name random variables 
    3 y = RV({'y'},1); 
    4 u = RV({'u'},1); 
     3x = RV({'x'},2); 
    54 
    6 % create f(y_t| y_{t-3}, u_{t-1}) 
    7 fy.class = 'mlnorm<ldmat>'; 
    8 fy.rv    = y; 
    9 fy.rvc   = RVtimes([y,u], [-3, -1]); 
    10 fy.A     = [0.5, -0.9]; 
    11 fy.const = 0; 
    12 fy.R     = 1e-2; 
    135 
    14 % create f(u_t| ) 
    15 fu.class = 'enorm<ldmat>'; 
    16 fu.rv    = u; 
    17 fu.mu    = 0; 
    18 fu.R     = 1e-1; 
     6fx.class  = 'mgnorm<ldmat>';              
     7fx.rv     = x;              
     8fx.rvc    = RVtimes(x,-1);              
     9fx.g      = 'mexFunction';              % function is evaluated in matlab 
     10fx.g.function = 'test_function';         % name of the matlab function to evaluate 
     11fx.g.dim  = 2;                          % expected dimension of output 
     12fx.g.dimc = 2;                          % expected dimension of input 
     13fx.R      = eye(2);                     % variance R 
     14 
    1915 
    2016% create DS 
    2117DS.class = 'PdfDS'; 
    2218DS.pdf.class  = 'mprod'; 
    23 DS.pdf.pdfs  = {fy, fu}; 
    24 DS.init_rv = RVtimes([y,y,y], [-1,-2,-3]); 
    25 DS.init_values = [0.1, 0.2, 0.3]; 
     19DS.pdf.pdfs  = {fx, fu}; 
     20DS.init_rv = RVtimes([x], [-1]); 
     21DS.init_values = [0.1, 0.2]; 
    2622 
    2723experiment.ndat=100;