<div dir="ltr">I am getting errors in code that I thought was working ...<div><br></div><div>I create a PC shell like so:</div><div><div><br></div><div>  ! set shell PC</div><div>  call SNESGetKSP(solver%snes,innerksp,ierr)</div><div>  call KSPGetPC(innerksp,spc,ierr)  </div><div>  call PCSetType(spc,PCSHELL,ierr) ! overriding opions !!!</div><div>  call PCShellSetApply(spc,PCShermanMorrisonApply,ierr)</div><div>  call PCSetApplicationContext(spc,solver,ierr)</div></div><div><br></div><div>and in PCShermanMorrisonApply I have:</div><div><br></div><div><div>  call PCGetApplicationContext(pc,solver,ierr)</div><div>  call DMCompositeGetAccessArray(solver%da,xin,itwo,PETSC_NULL_INTEGER,Xsub,ierr)</div><div>  call DMCompositeGetAccessArray(solver%da,yout,itwo,PETSC_NULL_INTEGER,Ysub,ierr)</div><div>  call PCFieldSplitGetSubKSP(solver%pc,PETSC_NULL_INTEGER,subksp,ierr)</div><div>  call KSPSolve(subksp(1),Xsub(1),Ysub(1),ierr)</div><div>  call MatMult(solver%Cmat,Ysub(1),Xsub(2),ierr) ! ignoring <> input</div></div><div><br></div><div>I get an error on this last statement about a vector being locked.  There does not seem to be:</div><div><br></div><div>call DMCompositeGetAccessArrayRead( ...<br></div><div><br></div><div>I thought I fixed this problem ... or at least one like it.</div><div><br></div><div>Mark</div></div>