|
PolyFEM
|
#include <SplineParametrizations.hpp>
Public Member Functions | |
| BSplineParametrization1DTo2D (const Eigen::MatrixXd &initial_control_points, const Eigen::VectorXd &knots, const int num_vertices, const bool exclude_ends=true) | |
| int | inverse_size (int y_size) const override |
| Compute DOF of x given DOF of y. | |
| Eigen::VectorXd | inverse_eval (const Eigen::VectorXd &y) const override |
| Eval x = f^-1 (y). | |
| int | size (const int x_size) const override |
| Compute DOF of y given DOF of x. | |
| Eigen::VectorXd | eval (const Eigen::VectorXd &x) const override |
| Eval y = f(x). | |
| Eigen::VectorXd | apply_jacobian (const Eigen::VectorXd &grad_full, const Eigen::VectorXd &x) const override |
| Apply jacobian for chain rule. | |
Public Member Functions inherited from polyfem::solver::Parametrization | |
| virtual | ~Parametrization ()=default |
Private Attributes | |
| const Eigen::MatrixXd | initial_control_points_ |
| const Eigen::VectorXd | knots_ |
| const int | size_ |
| const bool | exclude_ends_ |
| bool | invoked_inverse_eval_ = false |
| std::shared_ptr< BSplineParametrization2D > | spline_ |
Definition at line 19 of file SplineParametrizations.hpp.
|
inline |
Definition at line 22 of file SplineParametrizations.hpp.
|
overridevirtual |
Apply jacobian for chain rule.
Let g(y) = g(f(x)). Given ∂g/∂y, compute ∂g/∂x = ∂g/∂y * ∂y/∂x.
| [in] | grad_full | ∂g/∂y. |
| [in] | x | Where ∂g/∂x is evaluated. |
Implements polyfem::solver::Parametrization.
Definition at line 135 of file SplineParametrizations.cpp.
References exclude_ends_, initial_control_points_, and spline_.
|
overridevirtual |
Eval y = f(x).
| [in] | x | x. |
Implements polyfem::solver::Parametrization.
Definition at line 114 of file SplineParametrizations.cpp.
References exclude_ends_, polyfem::utils::flatten(), initial_control_points_, invoked_inverse_eval_, polyfem::log_and_throw_error(), spline_, polyfem::utils::unflatten(), x, and y.
|
overridevirtual |
Eval x = f^-1 (y).
This is not a strict inverse in mathematical sense, one may choose "reasonable" x even if f is not one-to-one.
| [in] | y | y. |
| std::runtime_error | Throw if inverse not implemented or is impossible. |
Implements polyfem::solver::Parametrization.
Definition at line 103 of file SplineParametrizations.cpp.
References exclude_ends_, polyfem::utils::flatten(), initial_control_points_, invoked_inverse_eval_, knots_, size_, spline_, polyfem::utils::unflatten(), and y.
|
overridevirtual |
Compute DOF of x given DOF of y.
| [in] | y_size | DOF of y. |
| std::runtime_error | Throw if inverse not impossible or y_size is invalid. |
Implements polyfem::solver::Parametrization.
Definition at line 97 of file SplineParametrizations.cpp.
References exclude_ends_, and initial_control_points_.
|
inlineoverridevirtual |
Compute DOF of y given DOF of x.
| [in] | x_size | The DOF of x. |
Implements polyfem::solver::Parametrization.
Definition at line 29 of file SplineParametrizations.hpp.
References size_.
|
private |
Definition at line 41 of file SplineParametrizations.hpp.
Referenced by apply_jacobian(), eval(), inverse_eval(), and inverse_size().
|
private |
Definition at line 37 of file SplineParametrizations.hpp.
Referenced by apply_jacobian(), eval(), inverse_eval(), and inverse_size().
|
mutableprivate |
Definition at line 45 of file SplineParametrizations.hpp.
Referenced by eval(), and inverse_eval().
|
private |
Definition at line 38 of file SplineParametrizations.hpp.
Referenced by inverse_eval().
|
private |
Definition at line 40 of file SplineParametrizations.hpp.
Referenced by inverse_eval(), and size().
|
mutableprivate |
Definition at line 46 of file SplineParametrizations.hpp.
Referenced by apply_jacobian(), eval(), and inverse_eval().