Actual source code: petsctao_deprecations.h
1: #pragma once
2: PETSC_DEPRECATED_FUNCTION(3, 17, 0, "TaoSetSolution()", ) static inline PetscErrorCode TaoSetInitialVector(Tao t, Vec v)
3: {
4: return TaoSetSolution(t, v);
5: }
6: PETSC_DEPRECATED_FUNCTION(3, 17, 0, "TaoGetSolution()", ) static inline PetscErrorCode TaoGetInitialVector(Tao t, Vec *v)
7: {
8: return TaoGetSolution(t, v);
9: }
10: PETSC_DEPRECATED_FUNCTION(3, 17, 0, "TaoSetObjective()", ) static inline PetscErrorCode TaoSetObjectiveRoutine(Tao t, PetscErrorCode (*f)(Tao, Vec, PetscReal *, void *), void *c)
11: {
12: return TaoSetObjective(t, f, c);
13: }
14: PETSC_DEPRECATED_FUNCTION(3, 17, 0, "TaoGetGradient()", ) static inline PetscErrorCode TaoGetGradientVector(Tao t, Vec *v)
15: {
16: return TaoGetGradient(t, v, PETSC_NULLPTR, PETSC_NULLPTR);
17: }
18: PETSC_DEPRECATED_FUNCTION(3, 17, 0, "TaoSetGradient()", ) static inline PetscErrorCode TaoSetGradientRoutine(Tao t, PetscErrorCode (*f)(Tao, Vec, Vec, void *), void *c)
19: {
20: return TaoSetGradient(t, PETSC_NULLPTR, f, c);
21: }
22: PETSC_DEPRECATED_FUNCTION(3, 17, 0, "TaoSetObjectiveAndGradient()", ) static inline PetscErrorCode TaoSetObjectiveAndGradientRoutine(Tao t, PetscErrorCode (*f)(Tao, Vec, PetscReal *, Vec, void *), void *c)
23: {
24: return TaoSetObjectiveAndGradient(t, PETSC_NULLPTR, f, c);
25: }
26: PETSC_DEPRECATED_FUNCTION(3, 17, 0, "TaoSetHessian()", ) static inline PetscErrorCode TaoSetHessianRoutine(Tao t, Mat H, Mat P, PetscErrorCode (*f)(Tao, Vec, Mat, Mat, void *), void *c)
27: {
28: return TaoSetHessian(t, H, P, f, c);
29: }
30: PETSC_DEPRECATED_FUNCTION(3, 11, 0, "TaoSetResidualRoutine()", ) static inline PetscErrorCode TaoSetSeparableObjectiveRoutine(Tao tao, Vec res, PetscErrorCode (*func)(Tao, Vec, Vec, void *), void *ctx)
31: {
32: return TaoSetResidualRoutine(tao, res, func, ctx);
33: }
34: PETSC_DEPRECATED_FUNCTION(3, 11, 0, "TaoSetResidualWeights()", ) static inline PetscErrorCode TaoSetSeparableObjectiveWeights(Tao tao, Vec sigma_v, PetscInt n, PetscInt *rows, PetscInt *cols, PetscReal *vals)
35: {
36: return TaoSetResidualWeights(tao, sigma_v, n, rows, cols, vals);
37: }
38: PETSC_DEPRECATED_FUNCTION(3, 11, 0, "TaoComputeResidual()", ) static inline PetscErrorCode TaoComputeSeparableObjective(Tao tao, Vec X, Vec F)
39: {
40: return TaoComputeResidual(tao, X, F);
41: }
42: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorSet()", ) static inline PetscErrorCode TaoSetMonitor(Tao tao, PetscErrorCode (*monitor)(Tao, void *), void *ctx, PetscErrorCode (*destroy)(void **))
43: {
44: return TaoMonitorSet(tao, monitor, ctx, destroy);
45: }
46: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorCancel()", ) static inline PetscErrorCode TaoCancelMonitors(Tao tao)
47: {
48: return TaoMonitorCancel(tao);
49: }
50: PETSC_DEPRECATED_FUNCTION(3, 9, 0, "TaoMonitorDefault()", ) static inline PetscErrorCode TaoDefaultMonitor(Tao tao, void *ctx)
51: {
52: return TaoMonitorDefault(tao, ctx);
53: }
54: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorGlobalization()", ) static inline PetscErrorCode TaoGMonitor(Tao tao, void *ctx)
55: {
56: return TaoMonitorGlobalization(tao, ctx);
57: }
58: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorDefaultShort()", ) static inline PetscErrorCode TaoSMonitor(Tao tao, void *ctx)
59: {
60: return TaoMonitorDefaultShort(tao, ctx);
61: }
62: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorConstraintNorm()", ) static inline PetscErrorCode TaoCMonitor(Tao tao, void *ctx)
63: {
64: return TaoMonitorConstraintNorm(tao, ctx);
65: }
66: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorSolution()", ) static inline PetscErrorCode TaoSolutionMonitor(Tao tao, void *ctx)
67: {
68: return TaoMonitorSolution(tao, ctx);
69: }
70: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorGradient()", ) static inline PetscErrorCode TaoGradientMonitor(Tao tao, void *ctx)
71: {
72: return TaoMonitorGradient(tao, ctx);
73: }
74: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorResidual()", ) static inline PetscErrorCode TaoResidualMonitor(Tao tao, void *ctx)
75: {
76: return TaoMonitorResidual(tao, ctx);
77: }
78: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorStep()", ) static inline PetscErrorCode TaoStepDirectionMonitor(Tao tao, void *ctx)
79: {
80: return TaoMonitorStep(tao, ctx);
81: }
82: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorSolutionDraw()", ) static inline PetscErrorCode TaoDrawSolutionMonitor(Tao tao, void *ctx)
83: {
84: return TaoMonitorGlobalization(tao, ctx);
85: }
86: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorGradientDraw()", ) static inline PetscErrorCode TaoDrawGradientMonitor(Tao tao, void *ctx)
87: {
88: return TaoMonitorGlobalization(tao, ctx);
89: }
90: PETSC_DEPRECATED_FUNCTION(3, 21, 0, "TaoMonitorStepDraw()", ) static inline PetscErrorCode TaoDrawStepDirectionMonitor(Tao tao, void *ctx)
91: {
92: return TaoMonitorGlobalization(tao, ctx);
93: }