xref: /petsc/doc/changes/35.md (revision b11d9968bc79904c690b122f9399be46447eb113)
1*7f296bb3SBarry Smith# Changes: 3.5
2*7f296bb3SBarry Smith
3*7f296bb3SBarry Smith```{rubric} General:
4*7f296bb3SBarry Smith```
5*7f296bb3SBarry Smith
6*7f296bb3SBarry Smith- --download-f-blas-lapack is now --download-fblaslapack.
7*7f296bb3SBarry Smith- PETSc built with --with-precision=\_\_float128 will now by default
8*7f296bb3SBarry Smith  read in binary files that have all 128 bits stored in the file, to
9*7f296bb3SBarry Smith  read in files with 64-bit double use the option
10*7f296bb3SBarry Smith  -binary_read_double
11*7f296bb3SBarry Smith- PETSc options of complex numbers must be passed as
12*7f296bb3SBarry Smith  [+/-][realnumber][+/-]realnumberi with no spaces, you can no
13*7f296bb3SBarry Smith  longer pass the real and complex part with a comma between them
14*7f296bb3SBarry Smith- PetscSynchronizedFlush() takes an additional argument, the file
15*7f296bb3SBarry Smith  pointer on rank 0
16*7f296bb3SBarry Smith- PetscObjectStateQuery() is now corrected with
17*7f296bb3SBarry Smith  PetscObjectStateGet()
18*7f296bb3SBarry Smith- A new PetscObjectState typedef is used by interface; 64-bit int to
19*7f296bb3SBarry Smith  prevent overflow.
20*7f296bb3SBarry Smith- The configure option `--with-dynamic-loading` has been removed
21*7f296bb3SBarry Smith  since this functionality is automatically available on systems
22*7f296bb3SBarry Smith  that support it. Use the runtime option
23*7f296bb3SBarry Smith  `-dynamic_library_preload` for similar functionality.
24*7f296bb3SBarry Smith- Default location of externalpackages is moved from
25*7f296bb3SBarry Smith  `PETSC_DIR/externalpackages` to
26*7f296bb3SBarry Smith  `PETSC_DIR/PETSC_ARCH/externalpackages`
27*7f296bb3SBarry Smith- Added `--with-clean` option to delete the build files in
28*7f296bb3SBarry Smith  `PETSC_DIR/PETSC_ARCH` at the beginning of the build
29*7f296bb3SBarry Smith- The `__SDIR__` macro (and `__INSDIR__`) is no longer used. We
30*7f296bb3SBarry Smith  recommend passing full paths or paths from the project root to the
31*7f296bb3SBarry Smith  compiler so that error messages contain enough context.
32*7f296bb3SBarry Smith- The "type" argument to `PetscMalloc2()` through
33*7f296bb3SBarry Smith  `PetscMalloc7()`, `PetscNew()`, and `PetscNewLog()` have
34*7f296bb3SBarry Smith  been removed. The type is now inferred from the pointer return
35*7f296bb3SBarry Smith  type. `PetscMalloc1()` is now available for allocating arrays,
36*7f296bb3SBarry Smith  and `PetscCalloc1()` through `PetscCalloc7()` have been added
37*7f296bb3SBarry Smith  for when cleared (zeroed) memory is needed.
38*7f296bb3SBarry Smith- Moved MATLAB scripts like PetscBinaryRead.m PetscBinaryWrite.m
39*7f296bb3SBarry Smith  from bin/matlab to share/petsc/matlab
40*7f296bb3SBarry Smith
41*7f296bb3SBarry Smith```{rubric} IS:
42*7f296bb3SBarry Smith```
43*7f296bb3SBarry Smith
44*7f296bb3SBarry Smith- ISLocalToGlobalMappingCreate() now takes a blocksize. Added
45*7f296bb3SBarry Smith  ISLocalToGlobalMappingApplyBlock() removed
46*7f296bb3SBarry Smith  ISLocalToGlobalMappingBlock() and ISLocalToGlobalMappingUnblock()
47*7f296bb3SBarry Smith
48*7f296bb3SBarry Smith```{rubric} PF:
49*7f296bb3SBarry Smith```
50*7f296bb3SBarry Smith
51*7f296bb3SBarry Smith```{rubric} Vec:
52*7f296bb3SBarry Smith```
53*7f296bb3SBarry Smith
54*7f296bb3SBarry Smith```{rubric} VecScatter:
55*7f296bb3SBarry Smith```
56*7f296bb3SBarry Smith
57*7f296bb3SBarry Smith```{rubric} PetscSection:
58*7f296bb3SBarry Smith```
59*7f296bb3SBarry Smith
60*7f296bb3SBarry Smith- Now only the F90 binding for VecSetValuesSection() is present
61*7f296bb3SBarry Smith
62*7f296bb3SBarry Smith```{rubric} Mat:
63*7f296bb3SBarry Smith```
64*7f296bb3SBarry Smith
65*7f296bb3SBarry Smith- Removed third argument to MatNullSpaceRemove(). Use VecDuplicate()
66*7f296bb3SBarry Smith  and VecCopy() if the original Vec must be kept.
67*7f296bb3SBarry Smith- MatGetRedundantMatrix(Mat mat,PetscInt nsubcomm,MPI_Comm
68*7f296bb3SBarry Smith  subcomm,PetscInt mlocal_red,MatReuse reuse,Mat \*matredundant) is
69*7f296bb3SBarry Smith  replaced by MatRedundantMatrix(Mat mat,PetscInt nsubcomm,MPI_Comm
70*7f296bb3SBarry Smith  subcomm,MatReuse reuse,Mat \*matredundant).
71*7f296bb3SBarry Smith- MatGetColoring() has been removed and replaced by the MatColoring
72*7f296bb3SBarry Smith  object.
73*7f296bb3SBarry Smith
74*7f296bb3SBarry Smith```{rubric} PC:
75*7f296bb3SBarry Smith```
76*7f296bb3SBarry Smith
77*7f296bb3SBarry Smith- PCASA has been removed, it never worked properly
78*7f296bb3SBarry Smith- The documented, but semi-private function
79*7f296bb3SBarry Smith  `PCMGResidual_Default()` is now public and named
80*7f296bb3SBarry Smith  `PCMGResidualDefault()`.
81*7f296bb3SBarry Smith- PCGAMG default smoother changed from PCJACOBI to PCSOR.
82*7f296bb3SBarry Smith- Different logic for PCBDDC APIs: added
83*7f296bb3SBarry Smith  PCBDDCSet/GetDirichlet/NeumannBoundariesLocal,
84*7f296bb3SBarry Smith  PCBDDCSetDofsSplittingLocal. Previous call to PCBDDCXXXBoundaries
85*7f296bb3SBarry Smith  should be replaced by PCBDDCXXXBoundariesLocal. The same holds for
86*7f296bb3SBarry Smith  setting the fields split. In all cases, the index sets should have
87*7f296bb3SBarry Smith  the same communicator as the PC.
88*7f296bb3SBarry Smith- Added PCBDDCSetChangeOfBasisLocalMat for user defined change of
89*7f296bb3SBarry Smith  basis
90*7f296bb3SBarry Smith- `PCFieldSplitSchurPrecondition()` deprecated (replaced in
91*7f296bb3SBarry Smith  Fortran) in favor of `PCFieldSplitSetSchurPre()`.
92*7f296bb3SBarry Smith
93*7f296bb3SBarry Smith```{rubric} KSP:
94*7f296bb3SBarry Smith```
95*7f296bb3SBarry Smith
96*7f296bb3SBarry Smith- `KSPSkipConverged()` renamed to `KSPConvergedSkip()`.
97*7f296bb3SBarry Smith- `KSPSetOperators()` no longer has the `MatStructure` argument.
98*7f296bb3SBarry Smith  The Mat objects now track that information themselves. Use
99*7f296bb3SBarry Smith  `KSP/PCSetReusePreconditioner()` to prevent the recomputation of
100*7f296bb3SBarry Smith  the preconditioner if the operator changed in the way that
101*7f296bb3SBarry Smith  `SAME_PRECONDITIONER` did with `KSPSetOperators()`
102*7f296bb3SBarry Smith- `KSPDefaultConverged()`, `KSPDefaultConvergedDestroy()`,
103*7f296bb3SBarry Smith  `KSPDefaultConvergedCreate()`,
104*7f296bb3SBarry Smith  `KSPDefaultConvergedSetUIRNorm()`, and
105*7f296bb3SBarry Smith  `KSPDefaultConvergedSetUMIRNorm()` are now
106*7f296bb3SBarry Smith  `KSPConvergedDefault()`, `KSPConvergedDefaultDestroy()`,
107*7f296bb3SBarry Smith  `KSPConvergedDefaultCreate()`,
108*7f296bb3SBarry Smith  `KSPConvergedDefaultSetUIRNorm()`, and
109*7f296bb3SBarry Smith  `KSPConvergedDefaultSetUMIRNorm()`. for consistency.
110*7f296bb3SBarry Smith
111*7f296bb3SBarry Smith```{rubric} SNES:
112*7f296bb3SBarry Smith```
113*7f296bb3SBarry Smith
114*7f296bb3SBarry Smith- The matrix arguments to the user functions provided with
115*7f296bb3SBarry Smith  `SNESSetJacobian()` and `SNESSetPicard()` are now Mat not
116*7f296bb3SBarry Smith  Mat\*.
117*7f296bb3SBarry Smith- The `MatStructure` argument to the user functions provided with
118*7f296bb3SBarry Smith  `SNESSetJacobian()` and `SNESSetPicard()` are gone.
119*7f296bb3SBarry Smith- `SNESSetInitialFunctionNorm()` is removed as it's not necessary
120*7f296bb3SBarry Smith  given that the norm is cached on the Vec. Use only
121*7f296bb3SBarry Smith  `SNESSetInitialFunction()`.
122*7f296bb3SBarry Smith- `SNESSetFunctionNorm()` and `SNESGetFunctionNorm()` removed.
123*7f296bb3SBarry Smith  `Use SNESGetFunction()` and `VecNorm()` instead.
124*7f296bb3SBarry Smith- `SNESSkipConverged()` renamed to `SNESConvergedSkip()`.
125*7f296bb3SBarry Smith- `SNESGetPC()`/`SNESSetPC()` renamed to
126*7f296bb3SBarry Smith  `SNESGetNPC()`/`SNESSetNPC()`.
127*7f296bb3SBarry Smith- `GS` and \_gs used for nonlinear Gauss-Sidel changed to `NGS`
128*7f296bb3SBarry Smith  and \_ngs to match all the other nonlinear solver names.
129*7f296bb3SBarry Smith
130*7f296bb3SBarry Smith```{rubric} SNESLineSearch:
131*7f296bb3SBarry Smith```
132*7f296bb3SBarry Smith
133*7f296bb3SBarry Smith```{rubric} TS:
134*7f296bb3SBarry Smith```
135*7f296bb3SBarry Smith
136*7f296bb3SBarry Smith- The matrix arguments to the user functions provided with
137*7f296bb3SBarry Smith  `TSSetRHSJacobian()` and `TSSetIJacobian()` are now Mat not
138*7f296bb3SBarry Smith  Mat\*.
139*7f296bb3SBarry Smith- The `MatStructure` argument to the user functions provided with
140*7f296bb3SBarry Smith  `TSSetRHSJacobian()` and `TSSetIJacobian()` are gone.
141*7f296bb3SBarry Smith
142*7f296bb3SBarry Smith```{rubric} DM/DA:
143*7f296bb3SBarry Smith```
144*7f296bb3SBarry Smith
145*7f296bb3SBarry Smith- DMDAGetLocalToGlobalMappingBlock() has been removed, the
146*7f296bb3SBarry Smith  DMDAGetLocalToGlobalMapping() now handles both block and non-block
147*7f296bb3SBarry Smith  cases
148*7f296bb3SBarry Smith- DMDAGetGlobalIndices(DM,PetscInt\*,const PetscInt\*[]) and
149*7f296bb3SBarry Smith  DMDARestoreGlobalIndices(DM,PetscInt\*,const PetscInt\*[]) are
150*7f296bb3SBarry Smith  removed, use DMGetLocalToGlobalMapping() to get this information
151*7f296bb3SBarry Smith- DMADDA has been removed, it never worked correctly
152*7f296bb3SBarry Smith- The MatType argument is removed from DMCreateMatrix(), you can use
153*7f296bb3SBarry Smith  DMSetMatType() to indicate the type you want used with a DM,
154*7f296bb3SBarry Smith  defaults to MATAIJ
155*7f296bb3SBarry Smith- `DMDABoundaryType` has become `DMBoundaryType`, and all the
156*7f296bb3SBarry Smith  enumeration values have also been renamed.
157*7f296bb3SBarry Smith
158*7f296bb3SBarry Smith```{rubric} DMPlex:
159*7f296bb3SBarry Smith```
160*7f296bb3SBarry Smith
161*7f296bb3SBarry Smith```{rubric} PetscViewer:
162*7f296bb3SBarry Smith```
163*7f296bb3SBarry Smith
164*7f296bb3SBarry Smith```{rubric} SYS:
165*7f296bb3SBarry Smith```
166*7f296bb3SBarry Smith
167*7f296bb3SBarry Smith```{rubric} AO:
168*7f296bb3SBarry Smith```
169*7f296bb3SBarry Smith
170*7f296bb3SBarry Smith```{rubric} Sieve:
171*7f296bb3SBarry Smith```
172*7f296bb3SBarry Smith
173*7f296bb3SBarry Smith- Sieve/DMMesh has been removed entirely. Use DMPlex.
174*7f296bb3SBarry Smith
175*7f296bb3SBarry Smith```{rubric} Fortran:
176*7f296bb3SBarry Smith```
177*7f296bb3SBarry Smith
178*7f296bb3SBarry Smith- PETSC_DEFAULT_DOUBLE_PRECISION has been replaced with
179*7f296bb3SBarry Smith  PETSC_DEFAULT_REAL
180*7f296bb3SBarry Smith
181*7f296bb3SBarry Smith```{rubric} ExternalPackages:
182*7f296bb3SBarry Smith```
183*7f296bb3SBarry Smith
184*7f296bb3SBarry Smith- Configure options `--download-umfpack` and
185*7f296bb3SBarry Smith  `--download-cholmod` to download UMFPACK and CHOLMOD have been
186*7f296bb3SBarry Smith  removed. Use `--download-suitesparse` to download these
187*7f296bb3SBarry Smith  packages.
188*7f296bb3SBarry Smith- Added interface to PARDISO solver in Intel MKL. To use
189*7f296bb3SBarry Smith  MKL_Pardiso, PETSc should be configured with
190*7f296bb3SBarry Smith  `--blas-lapack-dir=LOCATION_OF_INTEL_MKL           --with-mkl_pardiso-dir=LOCATION_OF_INTEL_MKL`
191*7f296bb3SBarry Smith  and then run the code with
192*7f296bb3SBarry Smith  `-pc_type lu -pc_factor_mat_solver_package mkl_pardiso`
193