def calcADotGrad(A, t, tVec, phixVec, phiuVec, phipVec, B, C): phixt = interpM(t, tVec, phixVec) phiut = interpM(t, tVec, phiuVec) phipt = interpM(t, tVec, phipVec) Bt = interpV(t, tVec, B) return phixt.dot(A) + phiut.dot(Bt) + phipt.dot(C)
def calcADotRest(A, t, tVec, phixVec, phiuVec, phipVec, B, C, aux): phixt = interpM(t, tVec, phixVec) phiut = interpM(t, tVec, phiuVec) phipt = interpM(t, tVec, phipVec) auxt = interpV(t, tVec, aux) Bt = interpV(t, tVec, B) return phixt.dot(A) + phiut.dot(Bt) + phipt.dot(C) + auxt
def calcADotRest(A, t, tVec, phixVec, phiuVec, phipVec, B, C, aux): #print("In calcADot!") phixt = interpM(t, tVec, phixVec) phiut = interpM(t, tVec, phiuVec) phipt = interpM(t, tVec, phipVec) auxt = interpV(t, tVec, aux) Bt = interpV(t, tVec, B) #print('phixt =',phixt) #print('phiut =',phiut) #print('Bt =',Bt) return phixt.dot(A) + phiut.dot(Bt) + phipt.dot(C) + auxt
def calcLamDotGrad(lam, t, tVec, fxInv, phixInv): fxt = interpV(t, tVec, fxInv) phixt = interpM(t, tVec, phixInv) return phixt.dot(lam) - fxt
def calcLamDotRest(lam, t, tVec, phixInv): phixt = interpM(t, tVec, phixInv) return phixt.dot(lam)
def calcADotOdeRest(A, t, tVec, phixVec, aux): phixt = interpM(t, tVec, phixVec) auxt = interpV(t, tVec, aux) return phixt.dot(A) + auxt