%--------------------------------------------
%--------------------------------------------
% Esta función resuelve el sistema de ecuaciones
% K*x=f mediante el solver directo Cholesky
%--------------------------------------------
%--------------------------------------------

function x  =  MyCholeskySolver(K,f)

%---------------------------------------
% Factorización LU (1er paso)
%---------------------------------------
L             =  MyCholeskyFactorisation(K);
%---------------------------------------
% resolvemos L*y=f (2nd paso)
%---------------------------------------
y             =  MyLowerSubstitution(L,f);             
%---------------------------------------
% resolvemos U*x=y (3rd paso)
%---------------------------------------
x             =  MyUpperSubstitution(transpose(L),y);
  
end
