8 int order, boost::shared_ptr<MatrixDouble> mass_ptr,
9 boost::shared_ptr<EntitiesFieldData> data_l2,
21 "Space should be set to L2");
35 boost::shared_ptr<MatrixDouble> data_ptr,
36 boost::shared_ptr<MatrixDouble> coeffs_ptr,
37 boost::shared_ptr<MatrixDouble> mass_ptr,
38 boost::shared_ptr<EntitiesFieldData> data_l2,
42 dataPtr(data_ptr), coeffsPtr(coeffs_ptr) {}
51 constexpr
auto side_number = 0;
52 auto &ent_data =
dataL2->dataOnEntities[fe_type][side_number];
53 auto nb_base_functions = ent_data.getN(
base).size2();
55 auto nb_data_coeffs =
dataPtr->size1();
59 rhs.resize(nb_base_functions, nb_data_coeffs,
false);
66 auto t_base = ent_data.getFTensor0N(
base, 0, 0);
68 for (
auto gg = 0; gg != nb_integration_pts; ++gg) {
69 Tensor0 t_rhs(&*rhs.data().begin());
70 for (
auto bb = 0; bb != nb_base_functions; ++bb) {
71 double alpha = t_w * t_base;
72 Tensor0 t_data(&trans_data(gg, 0));
73 for (
auto cc = 0; cc != nb_data_coeffs; ++cc) {
74 t_rhs += alpha * t_data;
84 for (
auto cc = 0; cc != nb_data_coeffs; ++cc) {
85 ublas::matrix_column<MatrixDouble> mc(rhs, cc);
93 boost::shared_ptr<MatrixDouble> data_ptr,
94 boost::shared_ptr<MatrixDouble> coeffs_ptr,
95 boost::shared_ptr<EntitiesFieldData> data_l2,
110 "Space should be set to L2");
114 constexpr
auto side_number = 0;
115 auto order =
dataL2->dataOnEntities[fe_type][side_number].getOrder();
122 auto &ent_data =
dataL2->dataOnEntities[fe_type][side_number];
123 const auto nb_base_functions = ent_data.getN(
base).size2();
124 auto nb_data_coeffs =
dataPtr->size1();
125 if (!nb_data_coeffs) {
127 "Number of data coefficients should be set");
133 data.resize(nb_integration_pts, nb_data_coeffs);
138 auto t_base = ent_data.getFTensor0N(
base, 0, 0);
139 for (
auto gg = 0; gg != nb_integration_pts; ++gg) {
140 Tensor0 t_coeffs(&*coeffs.data().begin());
141 for (
auto bb = 0; bb != nb_base_functions; ++bb) {
142 double alpha = t_base;
143 Tensor0 t_data(&data(gg, 0));
144 for (
auto cc = 0; cc != nb_data_coeffs; ++cc) {
145 t_data += alpha * t_coeffs;