PolyFEM
Loading...
Searching...
No Matches
L2ProjectionForm.hpp
Go to the documentation of this file.
1
2#pragma once
3
4#include "Form.hpp"
5
7
8namespace polyfem::solver
9{
10
11 class L2ProjectionForm : public Form
12 {
13 public:
15 const StiffnessMatrix &M,
16 const StiffnessMatrix &A,
17 const Eigen::VectorXd &y);
18
19 std::string name() const override { return "L2_projection"; }
20
21 protected:
25 double value_unweighted(const Eigen::VectorXd &x) const override;
26
30 void first_derivative_unweighted(const Eigen::VectorXd &x, Eigen::VectorXd &gradv) const override;
31
35 void second_derivative_unweighted(const Eigen::VectorXd &x, StiffnessMatrix &hessian) const override;
36
38 Eigen::VectorXd rhs_;
39 };
40
41} // namespace polyfem::solver
int y
int x
std::string name() const override
void first_derivative_unweighted(const Eigen::VectorXd &x, Eigen::VectorXd &gradv) const override
Compute the first derivative of the value wrt x.
double value_unweighted(const Eigen::VectorXd &x) const override
Compute the value of the form.
void second_derivative_unweighted(const Eigen::VectorXd &x, StiffnessMatrix &hessian) const override
Compute the second derivative of the value wrt x.
Eigen::SparseMatrix< double, Eigen::ColMajor > StiffnessMatrix
Definition Types.hpp:22