Commits

Jed Brown committed a5ffc9a

ts theta: drop superfluous recomputation of Xdot

Hg-commit: 1b0ae06942b81c85ccdbf43d3a370c754d2ffc56

Comments (0)

Files changed (1)

src/ts/impls/implicit/theta/theta.c

   PetscErrorCode ierr;
 
   PetscFunctionBegin;
-  ierr = VecAXPBYPCZ(th->Xdot,-th->shift,th->shift,0,ts->vec_sol,x);CHKERRQ(ierr);
+  /* th->Xdot has already been computed in TSThetaFunction (SNES guarantees this) */
   ierr = TSComputeIJacobian(ts,th->stage_time,x,th->Xdot,th->shift,A,B,str);CHKERRQ(ierr);
   PetscFunctionReturn(0);
 }