function v = Ahandle(x)

global A0
global B0
global flag_shiftA
global lambdaup
global lambdalow
global vall
global alphall
global MVcount

if flag_shiftA == -1
  v = A0*x - lambdaup*(B0*x) + (vall*(alphall.*(vall'*x))); 
  MVcount = MVcount + 2;
elseif flag_shiftA == 1
  v = A0*x - lambdalow*(B0*x) + (vall*(alphall.*(vall'*x))); 
  MVcount = MVcount + 2;
elseif flag_shiftA == 0
  v = A0*x;
  MVcount = MVcount + 1;
end
