SuperDex Physics C++ API
Loading...
Searching...
No Matches
integration_params.h
Go to the documentation of this file.
1/*
2 * Copyright (c) Meta Platforms, Inc. and affiliates.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#pragma once
18
19// PLEASE DO NOT ADD OTHER INCLUDES HERE. This header is included in the mochi_physics public API.
22
23namespace superdex {
24/** @brief Time integration methods. */
25enum struct IntegrationMethod {
26 /**
27 * @brief Backward Euler: 1 step, 1 stage, 1st order, L-stable. Also known as BDF1 and DIRK11.
28 */
30
31 /** @brief BDF2: 2 steps, 1 stage, 2nd order, A-stable. */
33
34 /** @brief BDF3: 3 steps, 1 stage, 3rd order. */
36
37 /** @brief DIRK(2,2): 1 step, 2 stages, 2nd order, L-stable. */
39
40 /**
41 * @brief [Experimental] DIRK(2,3): 1 step, 2 stages, 3rd order.
42 *
43 * @warning This is an experimental feature. It may be changed or removed in the future. Use at
44 * your own risk.
45 *
46 * @note Its step does not end at its last stage, so its steps use velocity-regularized friction
47 * for all contacts (see @ref ContactParams::preferElastoPlasticFriction). Queries refreshed
48 * without a step approximate it with one BackwardEuler stage, which may use elasto-plastic
49 * friction.
50 */
52
53 /** @brief DIRK(3,3): 1 step, 3 stages, 3rd order, L-stable. */
55
56 /**
57 * @brief [Experimental] Symplectic DIRK(1,2): 1 step, 1 stage, 2nd order, A-stable. Also known as
58 * Gauss and implicit midpoint.
59 *
60 * @warning This is an experimental feature. It may be changed or removed in the future. Use at
61 * your own risk.
62 *
63 * @note Its step does not end at its last stage, so its steps use velocity-regularized friction
64 * for all contacts (see @ref ContactParams::preferElastoPlasticFriction). Queries refreshed
65 * without a step approximate it with one BackwardEuler stage, which may use elasto-plastic
66 * friction.
67 */
69
70 /**
71 * @brief [Experimental] Symplectic DIRK(2,2): 1 step, 2 stages, 2nd order, A-stable.
72 *
73 * @warning This is an experimental feature. It may be changed or removed in the future. Use at
74 * your own risk.
75 *
76 * @note Its step does not end at its last stage, so its steps use velocity-regularized friction
77 * for all contacts (see @ref ContactParams::preferElastoPlasticFriction). Queries refreshed
78 * without a step approximate it with one BackwardEuler stage, which may use elasto-plastic
79 * friction.
80 */
82
83 /** @brief Number of time integration method enum values. */
85
86 /** @brief Default time integration method. */
88};
89} // namespace superdex
90
92MOCHI_ENUM_ITEM(BackwardEuler)
95MOCHI_ENUM_ITEM(DIRK22)
96MOCHI_ENUM_ITEM(DIRK23)
97MOCHI_ENUM_ITEM(DIRK33)
98MOCHI_ENUM_ITEM(SymplecticDIRK12)
99MOCHI_ENUM_ITEM(SymplecticDIRK22)
100MOCHI_ENUM_COUNT(Count)
IntegrationMethod
Time integration methods.
@ BackwardEuler
Backward Euler: 1 step, 1 stage, 1st order, L-stable.
@ DIRK23
[Experimental] DIRK(2,3): 1 step, 2 stages, 3rd order.
@ DIRK33
DIRK(3,3): 1 step, 3 stages, 3rd order, L-stable.
@ SymplecticDIRK12
[Experimental] Symplectic DIRK(1,2): 1 step, 1 stage, 2nd order, A-stable.
@ SymplecticDIRK22
[Experimental] Symplectic DIRK(2,2): 1 step, 2 stages, 2nd order, A-stable.
@ BDF2
BDF2: 2 steps, 1 stage, 2nd order, A-stable.
@ BDF3
BDF3: 3 steps, 1 stage, 3rd order.
@ DIRK22
DIRK(2,2): 1 step, 2 stages, 2nd order, L-stable.
@ Count
Number of actor type enum values.
Definition mochi_enums.h:38
#define MOCHI_ENUM_COUNT(name)
Definition reflection.h:329
#define MOCHI_ENUM_END()
Definition reflection.h:330
#define MOCHI_ENUM_BEGIN(name)
Definition reflection.h:327
#define MOCHI_ENUM_ITEM(name)
Definition reflection.h:328