44 subroutine cmprlb(n, m, x, g, ws, wy, sy, wt, z, r, wa, index,
45 + theta, col, head, nfree, cnstnd)
48 integer n, m, col, head, nfree, index(n)
49 double precision theta,
50 + x(n), g(n), z(n), r(n), wa(4*m),
51 + ws(n, m), wy(n, m), sy(m, m), wt(m, m)
66 double precision a1,a2
68 if (.not. cnstnd .and. col .gt. 0)
then
75 r(i) = -theta*(z(k) - x(k)) - g(k)
77 call bmv(m,sy,wt,col,wa(2*m+1),wa(1))
81 a2 = theta*wa(col + j)
84 r(i) = r(i) + wy(k,pointr)*a1 + ws(k,pointr)*a2
86 pointr = mod(pointr,m) + 1
subroutine bmv(m, sy, wt, col, v, p)
This subroutine computes the product of the 2m x 2m middle matrix in the compact L-BFGS formula of B ...
subroutine cmprlb(n, m, x, g, ws, wy, sy, wt, z, r, wa, index, theta, col, head, nfree, cnstnd)
This subroutine computes r=-Z'B(xcp-xk)-Z'g by using wa(2m+1)=W'(xcp-x) from subroutine cauchy.