SuperDex Physics C++ API
Loading...
Searching...
No Matches
active_shape_targeting_arap_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.
23
24namespace superdex {
25
26/**
27 * @brief Parameters for the Active Shape Targeting ARAP material model.
28 *
29 * @details Active material model based on the concept of "shape targeting". Unlike passive models
30 * that only react to external loads, it introduces an internal actuation mechanism.
31 *
32 * The actuation is defined by the shape target tensor, S_t, which specifies the desired local
33 * shape of the object. The model then resists deformation from this target shape while allowing
34 * rigid rotation.
35 *
36 * This approach is effective for simulating biological phenomena like muscle contraction.
37 *
38 * @note The "activeness" is controlled externally by setting the shape target tensor S_t. The
39 * model itself does not have an intrinsic, self-actuating mechanism without this input.
40 *
41 * @see [Shape Targeting: A Versatile Active Elasticity Constitutive Model (Klár et al.,
42 * 2020)](https://par.nsf.gov/servlets/purl/10230451)
43 * @see SoftMaterialType::ActiveShapeTargetingArap
44 */
46 /**
47 * @brief ARAP stiffness parameter (μ) [Pa].
48 *
49 * @note Must be greater than zero.
50 */
52
53 /**
54 * @brief Shape target tensor (6 values).
55 *
56 * @details Defines the shape target tensor as a symmetric 3x3 matrix added to the identity: S_t =
57 * I + [[s0, s1, s2], [s1, s3, s4], [s2, s4, s5]]. The shape target tensor specifies the desired
58 * local shape of the object. The model then resists deformation from this target shape while
59 * allowing rigid rotation.
60 */
61 Real6 shapeTargetTensor{0_r, 0_r, 0_r, 0_r, 0_r, 0_r};
62
63 /**
64 * @brief Strategy for ensuring positive semi-definite Hessian matrices.
65 *
66 * @see MaterialPsdStrategy
67 */
69
70#if MOCHI_LANGUAGE_CPP20
72#endif
73
79};
80
81} // namespace superdex
MaterialPsdStrategy
Strategy for ensuring positive semi-definite (PSD) Hessian matrices in material models.
@ Projection
Eigenvalue clamping: U * Max(Λ, ε) * U^T.
NdArray< real, 6 > Real6
Definition nd_array.h:109
constexpr real kDefaultArapStiffness
Default ARAP stiffness (μ) [Pa].
#define MOCHI_STRUCT_END()
Definition reflection.h:279
#define MOCHI_FIELD(name)
Definition reflection.h:293
#define MOCHI_STRUCT_BEGIN(name)
Definition reflection.h:278
#define MOCHI_ATTRIBUTE(...)
Definition reflection.h:298
Parameters for the Active Shape Targeting ARAP material model.
MaterialPsdStrategy psdStrategy
Strategy for ensuring positive semi-definite Hessian matrices.
bool operator==(ActiveShapeTargetingArapMaterialParams const &) const =default