Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
32 lines (31 sloc) 1.47 KB
function [Phi, O] = stblz(Phi, N_wlk, O, N_up, N_par)
% function [Phi, O] = stblz(Phi, N_wlk, O, N_up, N_par)
% Perform the modified Gram-Schmidt orthogonalization to stabilize the walkers
% Inputs:
% Phi: the whole ensemble of walkers
% N_wlk: the number of walkkers
% O: the array of overlaps of all walkers
% N_up: the number of spin up electrons
% N_par: the total number of electrons
% Outputs:
% Phi: the stabilized ensemble of walkers
% O: the updated array of overlaps
% Huy Nguyen, Hao Shi, Jie Xu and Shiwei Zhang
% ©2014 v1.0
% Package homepage:
% Distributed under the <a href="matlab: web('')">Computer Physics Communications Non-Profit Use License</a>
% Any publications resulting from either applying or building on the present package
% should cite the following journal article (in addition to the relevant literature on the method):
% "CPMC-Lab: A Matlab Package for Constrained Path Monte Carlo Calculations" Comput. Phys. Commun. (2014)
%% Perform the QR decomposition on each walker
% Keep only the Q matrices and discard the R matrices
for i_wlk=1:N_wlk
% for the spin up sector:
% for the spin down sector:
% Update the weight of each walker