<< NL_F_ForecastXY NL_F: Function NL_F_GridXY >>

NARVAL >> NL_F: Function > NL_F_GammaMatrix

NL_F_GammaMatrix

Perform the gamma matrix used by the ordinary kriging scheme.

Calling Sequence

[G] = NL_F_GammaMatrix(S,K,L,D,N)

Arguments

S :

Slope (least-squares regerssion line).

K :

Index vector (head).

L :

Index vector (tail).

D :

Distance vector.

N :

Dataset size.

G :

Gamma matrix.

Description

NL_F_GammaMatrix performs the gamma matrix (G) used by the ordinary kriging scheme (G(i,j)=S*D). [K,L] provides the source and destination (inter-distance D) of all couples of points where we compute the semi-variance parameter (computed by NL_F_SemiVariogram). The 1 and 0 (G($,:) and G(:,$)) are due to unbiasedness constraints.

Examples

x=[1,3,1,4,5];
y=[5,4,3,5,1];
z=[100,105,105,100,115];
n=length(x);
[k,l,d,s]=NL_F_SemiVariogram(x,y,z);//semi-variogram
ni=0.1;//inter slope increment between 0 and max slope
[os,isl,di]=NL_F_SemiVariogramFit(s,d,ni);//fit
[g]=NL_F_GammaMatrix(os,k,l,d,n);//application of NL_F_GammaMatrix

Report an issue
<< NL_F_ForecastXY NL_F: Function NL_F_GridXY >>