Lines Matching refs:U

23 static PetscErrorCode RHSFunctionslow(TS ts, PetscReal t, Vec U, Vec F, AppCtx *ctx)  in RHSFunctionslow()  argument
29 PetscCall(VecGetArrayRead(U, &u)); in RHSFunctionslow()
32 PetscCall(VecRestoreArrayRead(U, &u)); in RHSFunctionslow()
37 static PetscErrorCode RHSFunctionfast(TS ts, PetscReal t, Vec U, Vec F, AppCtx *ctx) in RHSFunctionfast() argument
43 PetscCall(VecGetArrayRead(U, &u)); in RHSFunctionfast()
46 PetscCall(VecRestoreArrayRead(U, &u)); in RHSFunctionfast()
51 static PetscErrorCode IFunctionfast(TS ts, PetscReal t, Vec U, Vec Udot, Vec F, AppCtx *ctx) in IFunctionfast() argument
57 PetscCall(VecGetArrayRead(U, &u)); in IFunctionfast()
62 PetscCall(VecRestoreArrayRead(U, &u)); in IFunctionfast()
67 static PetscErrorCode IJacobianfast(TS ts, PetscReal t, Vec U, Vec Udot, PetscReal a, Mat A, Mat B,… in IJacobianfast() argument
74 PetscCall(VecGetArrayRead(U, &u)); in IJacobianfast()
77 PetscCall(VecRestoreArrayRead(U, &u)); in IJacobianfast()
91 static PetscErrorCode sol_true(PetscReal t, Vec U) in sol_true() argument
96 PetscCall(VecGetArray(U, &u)); in sol_true()
99 PetscCall(VecRestoreArray(U, &u)); in sol_true()
106 Vec U; /* solution will be stored here */ in main() local
140 PetscCall(VecCreate(PETSC_COMM_WORLD, &U)); in main()
141 PetscCall(VecSetSizes(U, n, PETSC_DETERMINE)); in main()
142 PetscCall(VecSetFromOptions(U)); in main()
143 PetscCall(VecDuplicate(U, &Utrue)); in main()
144 PetscCall(VecCopy(U, Utrue)); in main()
159 PetscCall(VecGetArray(U, &u)); in main()
162 PetscCall(VecRestoreArray(U, &u)); in main()
185 PetscCall(TSSetSolution(ts, U)); in main()
198 PetscCall(TSSolve(ts, U)); in main()
199 PetscCall(VecView(U, PETSC_VIEWER_STDOUT_WORLD)); in main()
206 PetscCall(VecAXPY(Utrue, -1.0, U)); in main()
217 PetscCall(VecDestroy(&U)); in main()