LINE Solver
MATLAB API documentation
Loading...
Searching...
No Matches
kpcfit_sub_eval_acfit.m
1function [SCVj,acfCoeff]=kpcfit_sub_eval_iat2(SCV,G2,acfLag)
2% function [SCVj,acfCoeff]=kpcfit_sub_eval_iat2(SCV,G2,acfLag)
3%
4% Input:
5% SCV = a vector of squared coefficient of variation for each
6% composing map
7% G2 = a vector of gamma2 for each composing map
8% acfLag
9% = a vector of autocorrelations lags
10%
11% Output:
12% SCVj= the final squared coefficient of variation of J composing
13% maps
14% acfCoeff
15% = a vector of autocorrelation coefficients of J composing maps
16%
17J=length(G2);
18SCVj=SCV(1);
19acfLag=acfLag(:);
20acfCoeff=0.5.*(1-1/SCV(1)).*G2(1).^acfLag;
21for j=2:J
22 SCVj_1=SCVj;
23 SCVj=(1+SCVj)*(1+SCV(j))/2-1;
24 r0j=0.5*(1-1/SCV(j));
25 X=SCV(j)*r0j*G2(j).^acfLag;
26 acfCoeff=(X+SCVj_1.*acfCoeff.*(1+X))./SCVj;
27end
28
29end