diff --git a/Project.toml b/Project.toml index 3849aea1..07e3bb1a 100644 --- a/Project.toml +++ b/Project.toml @@ -10,7 +10,6 @@ MPI = "da04e1cc-30fd-572f-bb4f-1f8673147195" MPIPreferences = "3da0fdf6-3ccc-4f1b-acd9-58baa6c99267" PETSc_jll = "8fa3689e-f0b9-5420-9873-adf6ccf46f2d" SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" -SparseDiffTools = "47a9eef4-7e08-11e9-0b38-333d64bd3804" [compat] MPI = "0.20" diff --git a/test/old_test.jl b/test/old_test.jl index 944ae1c9..0f27e208 100644 --- a/test/old_test.jl +++ b/test/old_test.jl @@ -72,8 +72,8 @@ PETSc.initialize(PETSc.petsclibs[1]) function F!(cfx, cx, a) - x = PETSc.unsafe_localarray(Float64,cx, write=false) - fx = PETSc.unsafe_localarray(Float64,cfx,write=true) + x = PETSc.unsafe_localarray(Float64,cx, write=false, read=true) + fx = PETSc.unsafe_localarray(Float64,cfx,write=true, read=true) fx[1] = x[1]^2 + x[1]*x[2] - 3 fx[2] = x[1]*x[2] + x[2]^2 - 6 Base.finalize(x) @@ -83,7 +83,7 @@ PETSc.initialize(PETSc.petsclibs[1]) J = zeros(2,2) PJ = PETSc.MatSeqDense(J) function updateJ!(cx, args...) - x = PETSc.unsafe_localarray(Float64,cx, write=false) + x = PETSc.unsafe_localarray(Float64,cx, write=false, read=true) J[1,1] = 2x[1] + x[2] J[1,2] = x[1] J[2,1] = x[2]