32 # define MatExprType auto
43 typedef real_t Scalar;
52 enum{ Space = 0, ScalarValued= 0, ColBlocks= 0};
62 index_t rows()
const {
return _dim; }
63 index_t cols()
const {
return 1; }
70 void print(std::ostream &os)
const { os <<
"uv("<<_dim <<
")";}
83 typedef typename E::Scalar Scalar;
86 typename E::Nested_t _u;
87 typename gsGeometryMap<Scalar>::Nested_t _G;
93 enum{ Space = E::Space, ScalarValued= 0, ColBlocks= 0};
95 var1_expr(
const E & u,
const gsGeometryMap<Scalar> & G) : _u(u), _G(G) { }
97 # define Eigen gsEigen
98 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
111 index_t rows()
const {
return 1; }
112 index_t cols()
const {
return cols_impl(_u); }
116 parse_impl<E>(evList);
121 index_t cardinality_impl()
const {
return _u.cardinality_impl(); }
123 void print(std::ostream &os)
const { os <<
"var1("; _u.print(os); os <<
")"; }
126 template<
class U>
inline
127 typename util::enable_if< util::is_same<U,gsFeSpace<Scalar> >::value,
void>::type
136 template<
class U>
inline
137 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar>>::value || util::is_same<U,gsFeVariable<Scalar>>::value,
void>::type
143 grad(_u).parse(evList);
148 template<
class U>
inline
149 typename util::enable_if< util::is_same<U,gsFeSpace<Scalar> >::value,
const gsMatrix<Scalar> & >::type
150 eval_impl(
const U & u,
const index_t k)
const
152 const index_t A = _u.cardinality()/_u.dim();
153 res.resize(_u.cardinality(), cols());
155 normal = _G.data().normal(k);
158 bGrads = _u.data().values[1].col(k);
159 cJac = _G.data().values[1].reshapeCol(k, _G.data().dim.first, _G.data().dim.second).transpose();
160 const Scalar measure = (cJac.
col3d(0).cross( cJac.
col3d(1) )).norm();
162 for (
index_t d = 0; d!= cols(); ++d)
165 for (
index_t j = 0; j!= A; ++j)
168 m_v.noalias() = (vecFun(d, bGrads.
at(2*j ) ).cross( cJac.
col3d(1) )
169 - vecFun(d, bGrads.
at(2*j+1) ).cross( cJac.
col3d(0) )) / measure;
172 res.row(s+j).noalias() = (m_v - ( normal*m_v.transpose() ) * normal).transpose();
178 template<
class U>
inline
179 typename util::enable_if< util::is_same<U,gsFeVariable<Scalar> >::value,
const gsMatrix<Scalar> & >::type
180 eval_impl(
const U & u,
const index_t k)
const
182 grad_expr<U> vGrad = grad_expr<U>(u);
183 bGrads = vGrad.eval(k);
185 return make_vector(k);
189 template<
class U>
inline
190 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar> >::value,
const gsMatrix<Scalar> & >::type
191 eval_impl(
const U & u,
const index_t k)
const
193 GISMO_ASSERT(1==_u.data().actives.cols(),
"Single actives expected");
194 grad_expr<gsFeSolution<Scalar>> sGrad = grad_expr<gsFeSolution<Scalar>>(_u);
195 bGrads = sGrad.eval(k);
197 return make_vector(k);
202 res.resize(rows(), cols());
203 normal = _G.data().normal(k);
206 cJac = _G.data().values[1].reshapeCol(k, _G.data().dim.first, _G.data().dim.second).transpose();
207 const Scalar measure = (cJac.
col3d(0).cross( cJac.
col3d(1) )).norm();
209 m_v.noalias() = ( ( bGrads.
col3d(0) ).cross( cJac.
col3d(1) )
210 - ( bGrads.
col3d(1) ).cross( cJac.
col3d(0) ) ) / measure;
213 res = (m_v - ( normal*m_v.transpose() ) * normal).transpose();
217 template<
class U>
inline
218 typename util::enable_if< util::is_same<U,gsGeometryMap<Scalar> >::value,
index_t >::type
219 cols_impl(
const U & u)
const
221 return _u.data().dim.second;
224 template<
class U>
inline
225 typename util::enable_if<util::is_same<U,gsFeSpace<Scalar> >::value || util::is_same<U,gsFeSolution<Scalar> >::value,
index_t >::type
226 cols_impl(
const U & u)
const
231 template<
class U>
inline
232 typename util::enable_if<util::is_same<U,gsFeVariable<Scalar> >::value,
index_t >::type
233 cols_impl(
const U & u)
const
235 return _u.source().targetDim();
247 template<
class E1,
class E2,
class E3>
251 typedef typename E1::Scalar Scalar;
254 typename E1::Nested_t _u;
255 typename E2::Nested_t _v;
256 typename gsGeometryMap<Scalar>::Nested_t _G;
257 typename E3::Nested_t _Ef;
260 enum{ Space = 3, ScalarValued= 0, ColBlocks= 0 };
262 var2dot_expr(
const E1 & u,
const E2 & v,
const gsGeometryMap<Scalar> & G, _expr<E3>
const& Ef) : _u(u),_v(v), _G(G), _Ef(Ef) { }
267 mutable gsVector<Scalar> m_u, m_v, normal, m_uv, m_u_der, n_der, n_der2, tmp;
268 # define Eigen gsEigen
269 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
282 res.resize(_u.cardinality(), _u.cardinality());
284 normal = _G.data().normal(k);
286 uGrads = _u.data().values[1].col(k);
287 vGrads = _v.data().values[1].col(k);
288 cJac = _G.data().values[1].reshapeCol(k, _G.data().dim.first, _G.data().dim.second).transpose();
290 const index_t cardU = _u.data().values[0].rows();
291 const index_t cardV = _v.data().values[0].rows();
292 const Scalar measure = (cJac.
col3d(0).cross( cJac.
col3d(1) )).norm();
296 for (
index_t j = 0; j!= cardU; ++j)
298 for (
index_t i = 0; i!= cardV; ++i)
300 for (
index_t d = 0; d!= _u.dim(); ++d)
302 m_u.noalias() = ( vecFun(d, uGrads.
at(2*j ) ).cross( cJac.
col3d(1) )
303 -vecFun(d, uGrads.
at(2*j+1) ).cross( cJac.
col3d(0) ))
308 for (
index_t c = 0; c!= _v.dim(); ++c)
311 m_v.noalias() = ( vecFun(c, vGrads.
at(2*i ) ).cross( cJac.
col3d(1) )
312 -vecFun(c, vGrads.
at(2*i+1) ).cross( cJac.
col3d(0) ))
316 n_der.noalias() = (m_v - ( normal*m_v.transpose() ) * normal);
318 m_uv.noalias() = ( vecFun(d, uGrads.
at(2*j ) ).cross( vecFun(c, vGrads.
at(2*i+1) ) )
319 +vecFun(c, vGrads.
at(2*i ) ).cross( vecFun(d, uGrads.
at(2*j+1) ) ))
322 m_u_der.noalias() = (m_uv - ( normal.dot(m_v) ) * m_u);
326 tmp = m_u_der - (m_u.dot(n_der) + normal.dot(m_u_der) ) * normal - (normal.dot(m_u) ) * n_der;
332 res(s + j, r + i ) = result(0,0);
364 void print(std::ostream &os)
const { os <<
"var2("; _u.print(os); os <<
")"; }
374 template<
class E1,
class E2,
class E3>
378 typedef typename E1::Scalar Scalar;
381 typename E1::Nested_t _u;
382 typename E2::Nested_t _v;
383 typename gsGeometryMap<Scalar>::Nested_t _G;
384 typename E3::Nested_t _Ef;
387 enum{ Space = 3, ScalarValued= 0, ColBlocks= 0 };
389 var2deriv2dot_expr(
const E1 & u,
const E2 & v,
const gsGeometryMap<Scalar> & G, _expr<E3>
const& Ef) : _u(u),_v(v), _G(G), _Ef(Ef) { }
394 mutable gsVector<Scalar> m_u, m_v, normal, m_uv, m_u_der, n_der, n_der2, tmp;
395 # define Eigen gsEigen
396 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
409 res.resize(_u.cardinality(), _u.cardinality());
411 normal = _G.data().normal(k);
413 uGrads = _u.data().values[1].col(k);
414 vGrads = _v.data().values[1].col(k);
415 cJac = _G.data().values[1].reshapeCol(k, _G.data().dim.first, _G.data().dim.second).transpose();
416 cDer2 = _G.data().values[2].reshapeCol(k, _G.data().dim.second, _G.data().dim.second);
418 const index_t cardU = _u.data().values[0].rows();
419 const index_t cardV = _v.data().values[0].rows();
420 const Scalar measure = (cJac.
col3d(0).cross( cJac.
col3d(1) )).norm();
424 for (
index_t j = 0; j!= cardU; ++j)
426 for (
index_t i = 0; i!= cardV; ++i)
428 for (
index_t d = 0; d!= _u.dim(); ++d)
430 m_u.noalias() = ( vecFun(d, uGrads.
at(2*j ) ).cross( cJac.
col3d(1) )
431 -vecFun(d, uGrads.
at(2*j+1) ).cross( cJac.
col3d(0) ))
436 for (
index_t c = 0; c!= _v.dim(); ++c)
439 m_v.noalias() = ( vecFun(c, vGrads.
at(2*i ) ).cross( cJac.
col3d(1) )
440 -vecFun(c, vGrads.
at(2*i+1) ).cross( cJac.
col3d(0) ))
444 n_der.noalias() = (m_v - ( normal*m_v.transpose() ) * normal);
446 m_uv.noalias() = ( vecFun(d, uGrads.
at(2*j ) ).cross( vecFun(c, vGrads.
at(2*i+1) ) )
447 +vecFun(c, vGrads.
at(2*i ) ).cross( vecFun(d, uGrads.
at(2*j+1) ) ))
450 m_u_der.noalias() = (m_uv - ( normal.dot(m_v) ) * m_u);
454 tmp = m_u_der - (m_u.dot(n_der) + normal.dot(m_u_der) ) * normal - (normal.dot(m_u) ) * n_der;
462 res(s + j, r + i ) = result(0,0);
494 void print(std::ostream &os)
const { os <<
"var2dot("; _u.print(os), _v.print(os), _G.print(os), _Ef.print(os); os <<
")"; }
498 template<
class E1,
class E2>
502 typedef typename E1::Scalar Scalar;
506 typename E1::Nested_t _u;
507 typename E2::Nested_t _v;
508 typename gsGeometryMap<Scalar>::Nested_t _G;
511 enum{ Space = E1::Space, ScalarValued= 0, ColBlocks= 0 };
513 var2_expr(
const E1 & u,
const E2 & v,
const gsGeometryMap<Scalar> & G) : _u(u),_v(v), _G(G) { }
518 mutable gsVector<Scalar> m_u, m_v, normal, m_uv, m_u_der, n_der, n_der2, tmp;
520 # define Eigen gsEigen
521 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
546 grad(_u).parse(evList);
547 grad(_v).parse(evList);
565 enum{rowSpan = 0, colSpan = 0};
567 void print(std::ostream &os)
const { os <<
"var2("; _u.print(os), _v.print(os), _G.print(os); os <<
")"; }
571 template<
class U,
class V>
inline
572 typename util::enable_if< !(util::is_same<U,gsFeVariable<Scalar> >::value && util::is_same<V,gsFeVariable<Scalar> >::value),
const gsMatrix<Scalar> & >::type
573 eval_impl(
const U & u,
const V & v,
const index_t k)
const
578 template<
class U,
class V>
inline
579 typename util::enable_if< util::is_same<U,gsFeVariable<Scalar> >::value && util::is_same<V,gsFeVariable<Scalar> >::value,
const gsMatrix<Scalar> & >::type
580 eval_impl(
const U & u,
const V & v,
const index_t k)
const
582 grad_expr<U> uGrad = grad_expr<U>(u);
583 uGrads = uGrad.eval(k);
584 grad_expr<V> vGrad = grad_expr<V>(v);
585 vGrads = vGrad.eval(k);
587 res.resize(rows(), cols());
589 normal = _G.data().normal(k);
592 cJac = _G.data().values[1].reshapeCol(k, _G.data().dim.first, _G.data().dim.second).transpose();
593 cDer2 = _G.data().values[2].reshapeCol(k, _G.data().dim.second, _G.data().dim.second);
595 const Scalar measure = (cJac.
col3d(0).cross( cJac.
col3d(1) )).norm();
597 m_u.noalias() = ( ( uGrads.col(0).template head<3>() ).cross( cJac.col(1).template head<3>() )
598 - ( uGrads.col(1).template head<3>() ).cross( cJac.col(0).template head<3>() ) )
601 m_v.noalias() = ( ( vGrads.col(0).template head<3>() ).cross( cJac.col(1).template head<3>() )
602 - ( vGrads.col(1).template head<3>() ).cross( cJac.col(0).template head<3>() ) )
606 n_der.noalias() = (m_v - ( normal*m_v.transpose() ) * normal);
608 m_uv.noalias() = ( ( uGrads.col(0).template head<3>() ).cross( vGrads.col(1).template head<3>() )
609 - ( vGrads.col(1).template head<3>() ).cross( uGrads.col(0).template head<3>() ) )
612 m_u_der.noalias() = (m_uv - ( normal.dot(m_v) ) * m_u);
616 tmp = m_u_der - (m_u.dot(n_der) + normal.dot(m_u_der) ) * normal - (normal.dot(m_u) ) * n_der;
662 typedef typename E::Scalar Scalar;
665 typename E::Nested_t _u;
666 typename gsGeometryMap<Scalar>::Nested_t _G;
673 enum{ Space = E::Space, ScalarValued= 0, ColBlocks= 0};
675 tvar1_expr(
const E & u,
const gsGeometryMap<Scalar> & G) : _u(u), _G(G) { }
677 # define Eigen gsEigen
678 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
690 index_t rows()
const {
return 1; }
691 index_t cols()
const {
return _u.dim(); }
695 parse_impl<E>(evList);
700 index_t cardinality_impl()
const {
return _u.cardinality_impl(); }
702 void print(std::ostream &os)
const { os <<
"tvar("; _G.print(os); os <<
")"; }
705 template<
class U>
inline
706 typename util::enable_if< !util::is_same<U,gsFeSolution<Scalar> >::value,
void>::type
715 template<
class U>
inline
716 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar> >::value,
void>::type
722 grad(_u).parse(evList);
727 template<
class U>
inline
728 typename util::enable_if< !util::is_same<U,gsFeSolution<Scalar> >::value,
const gsMatrix<Scalar> & >::type
729 eval_impl(
const U & u,
const index_t k)
const
731 GISMO_ASSERT(_G.data().dim.second==3,
"Domain dimension should be 3, is "<<_G.data().dim.second);
733 const index_t A = _u.cardinality()/_u.dim();
734 res.resize(_u.cardinality(), cols());
736 cJac = _G.data().jacobian(k);
737 cJac.colwise().normalize();
739 onormal = _G.data().outNormal(k);
741 tmp = cJac.transpose() * onormal;
742 tmp.colwise().normalize();
756 gsInfo<<
"warning: choice unknown\n";
760 tangent = tan_expr.eval(k);
761 utangent = tangent.normalized();
766 Scalar dot = tangent.dot(cJac.col(colIndex));
767 sign = (Scalar(0) < dot) - (dot < Scalar(0));
771 gsWarn<<
"No suitable tangent and outer normal vector found for point "<<_G.data().values[0].transpose()<<
"\n";
776 bGrads = _u.data().values[1].col(k);
777 for (
index_t d = 0; d!= cols(); ++d)
780 for (
index_t j = 0; j!= A; ++j)
784 dtan = sign*vecFun(d, bGrads.
at(2*j+colIndex));
785 res.row(s+j).noalias() = (1 / tangent.norm() * ( dtan - ( utangent.transpose() * dtan ) * utangent ) ).transpose();
791 template<
class U>
inline
792 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar> >::value,
const gsMatrix<Scalar> & >::type
793 eval_impl(
const U & u,
const index_t k)
const
795 GISMO_ASSERT(1==_u.data().actives.cols(),
"Single actives expected");
796 res.resize(rows(), cols());
799 cJac = _G.data().jacobian(k);
800 cJac.colwise().normalize();
802 onormal = _G.data().outNormal(k);
804 tmp = cJac.transpose() * onormal;
805 tmp.colwise().normalize();
820 gsInfo<<
"warning: choice unknown\n";
824 tangent = tan_expr.eval(k);
830 Scalar dot = tangent.dot(cJac.col(colIndex));
831 sign = (Scalar(0) < dot) - (dot < Scalar(0));
835 gsWarn<<
"No suitable tangent and outer normal vector found for point "<<_G.data().values[0].transpose()<<
"\n";
839 bGrads = _u.data().values[1].col(k);
840 dtan = sign*bGrads.col(colIndex);
841 res.noalias() = (1 / tangent.norm() * ( dtan - ( tangent * dtan ) * tangent / (tangent.norm() * tangent.norm()) )).transpose();
856 typedef typename E::Scalar Scalar;
859 typename E::Nested_t _u;
860 typename gsGeometryMap<Scalar>::Nested_t _G;
867 enum{ Space = E::Space, ScalarValued= 0, ColBlocks= 0};
869 ovar1_expr(
const E & u,
const gsGeometryMap<Scalar> & G) : _u(u), _G(G) { }
871 # define Eigen gsEigen
872 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
885 index_t rows()
const {
return 1; }
886 index_t cols()
const {
return _u.dim(); }
890 parse_impl<E>(evList);
895 index_t cardinality_impl()
const {
return _u.cardinality_impl(); }
897 void print(std::ostream &os)
const { os <<
"ovar("; _G.print(os); os <<
")"; }
900 template<
class U>
inline
901 typename util::enable_if< !util::is_same<U,gsFeSolution<Scalar> >::value,
void>::type
909 tv(_G).parse(evList);
910 tvar1(_u,_G).parse(evList);
911 var1(_u,_G).parse(evList);
914 template<
class U>
inline
915 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar> >::value,
void>::type
921 grad(_u).parse(evList);
922 tv(_G).parse(evList);
927 template<
class U>
inline
928 typename util::enable_if< !util::is_same<U,gsFeSolution<Scalar> >::value,
const gsMatrix<Scalar> & >::type
929 eval_impl(
const U & u,
const index_t k)
const
931 GISMO_ASSERT(_G.data().dim.second==3,
"Domain dimension should be 3, is "<<_G.data().dim.second);
932 const index_t A = _u.cardinality()/_u.dim();
933 res.resize(_u.cardinality(), cols());
936 tangent = tan_expr.eval(k);
940 normal = _G.data().normal(k);
944 tvarMat = tvar_expr.eval(k);
947 snvarMat = snvar_expr.eval(k);
949 for (
index_t d = 0; d!= cols(); ++d)
952 for (
index_t j = 0; j!= A; ++j)
954 tvar = tvarMat.row(s+j);
955 snvar= snvarMat.row(s+j);
958 res.row(s+j).noalias() = tvar.cross(normal) + tangent.cross(snvar);
964 template<
class U>
inline
965 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar> >::value,
const gsMatrix<Scalar> & >::type
966 eval_impl(
const U & u,
const index_t k)
const
968 GISMO_ASSERT(_G.data().dim.second==3,
"Domain dimension should be 3, is "<<_G.data().dim.second);
969 res.resize(rows(), cols());
972 tangent = tan_expr.eval(k);
976 normal = _G.data().normal(k);
980 tvar = tvar_expr.eval(k);
983 snvar = snvar_expr.eval(k);
987 res.noalias() = tvar.cross(normal) + tangent.cross(snvar);
1000 template<
class E1,
class E2,
class E3>
1004 typedef typename E1::Scalar Scalar;
1007 typename E1::Nested_t _u;
1008 typename E2::Nested_t _v;
1009 typename gsGeometryMap<Scalar>::Nested_t _G;
1010 typename E3::Nested_t _C;
1012 mutable gsVector<Scalar,3> normal, onormal, tangent, utangent, dtanu, dtanv, tvaru, tvarv, tvar2,
1013 mu, mv, muv, mu_der, snvaru, snvarv, snvar2, nvar2;
1018 enum{ Space = 3, ScalarValued= 0, ColBlocks= 0 };
1020 ovar2dot_expr(
const E1 & u,
const E2 & v,
const gsGeometryMap<Scalar> & G, _expr<E3>
const& C) : _u(u), _v(v), _G(G), _C(C) { }
1022 # define Eigen gsEigen
1023 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
1036 GISMO_ASSERT(_G.data().dim.second==3,
"Domain dimension should be 3, is "<<_G.data().dim.second);
1037 GISMO_ASSERT(_C.cols()*_C.rows()==3,
"Size of vector is incorrect");
1038 res.resize(_u.cardinality(), _u.cardinality());
1044 cJac = _G.data().values[1].reshapeCol(k, _G.data().dim.first, _G.data().dim.second).transpose();
1045 cJac.colwise().normalize();
1047 onormal = _G.data().outNormal(k);
1048 onormal.normalize();
1049 tmp = cJac.transpose() * onormal;
1050 tmp.colwise().normalize();
1065 gsInfo<<
"warning: choice unknown\n";
1071 normal = _G.data().normal(k);
1073 uGrads = _u.data().values[1].col(k);
1074 vGrads = _v.data().values[1].col(k);
1076 const index_t cardU = _u.data().values[0].rows();
1077 const index_t cardV = _v.data().values[0].rows();
1078 const Scalar measure = (cJac.
col3d(0).cross( cJac.
col3d(1) )).norm();
1081 tangent = tan_expr.eval(k);
1082 utangent = tangent.normalized();
1087 Scalar dot = tangent.dot(cJac.col(colIndex));
1088 sign = (Scalar(0) < dot) - (dot < Scalar(0));
1092 gsWarn<<
"No suitable tangent and outer normal vector found for point "<<_G.data().values[0].transpose()<<
"\n";
1105 for (
index_t j = 0; j!= cardU; ++j)
1107 for (
index_t i = 0; i!= cardV; ++i)
1109 for (
index_t d = 0; d!= _u.dim(); ++d)
1116 dtanu = sign*vecFun(d, uGrads.
at(2*j+colIndex));
1117 tvaru = 1 / tangent.norm() * ( dtanu - ( utangent.dot(dtanu) ) * utangent );
1120 mu.noalias() = ( vecFun(d, uGrads.
at(2*j ) ).cross( cJac.
col3d(1) )
1121 -vecFun(d, uGrads.
at(2*j+1) ).cross( cJac.
col3d(0) ))
1123 snvaru.noalias() = (mu - ( normal.dot(mu) ) * normal);
1125 for (
index_t c = 0; c!= _v.dim(); ++c)
1132 dtanv = sign*vecFun(c, vGrads.
at(2*i+colIndex));
1133 tvarv = 1 / tangent.norm() * ( dtanv - ( utangent.dot(dtanv) ) * utangent );
1136 mv.noalias() = ( vecFun(c, vGrads.
at(2*i ) ).cross( cJac.
col3d(1) )
1137 -vecFun(c, vGrads.
at(2*i+1) ).cross( cJac.
col3d(0) ))
1139 snvarv.noalias() = (mv - ( normal.dot(mv) ) * normal);
1145 tvar2 = -1 / tangent.norm() * (
1146 ( tvarv.dot(dtanu) * utangent )
1147 + ( utangent.dot(dtanv) * tvaru )
1148 + ( utangent.dot(dtanu) * tvarv )
1152 muv.noalias() = ( vecFun(d, uGrads.
at(2*j ) ).cross( vecFun(c, vGrads.
at(2*i+1) ) )
1153 +vecFun(c, vGrads.
at(2*i ) ).cross( vecFun(d, uGrads.
at(2*j+1) ) ))
1156 mu_der.noalias() = (muv - ( normal.dot(mv) ) * mu);
1158 snvar2 = mu_der - (mu.dot(snvarv) + normal.dot(mu_der) ) * normal - (normal.dot(mu) ) * snvarv;
1161 nvar2 = tvar2.cross(normal) + tvaru.cross(snvarv) + tvarv.cross(snvaru) + utangent.cross(snvar2);
1163 res(s + j, r + i ) = (eC * nvar2).value();
1171 index_t rows()
const {
return 1; }
1173 index_t cols()
const {
return 1; }
1189 void print(std::ostream &os)
const { os <<
"nvar2("; _u.print(os); os <<
")"; }
1198 template<
class E1,
class E2>
1201 typename E1::Nested_t _u;
1202 typename E2::Nested_t _v;
1205 enum{ Space = (E1::Space == 1 || E2::Space == 1) ? 1 : 0,
1210 typedef typename E1::Scalar Scalar;
1225 return cols_impl(_u);
1230 parse_impl<E1>(evList);
1235 if (E1::Space == 1 && E2::Space == 0)
1237 else if (E1::Space == 0 && E2::Space == 1)
1240 return gsNullExpr<Scalar>::get();
1245 if (E1::Space == 1 && E2::Space == 0)
1247 else if (E1::Space == 0 && E2::Space == 1)
1250 return gsNullExpr<Scalar>::get();
1253 void print(std::ostream &os)
const { os <<
"deriv2("; _u.print(os); _v.print(os); os <<
")"; }
1256 template<
class U>
inline
1257 typename util::enable_if< util::is_same<U,gsGeometryMap<Scalar> >::value,
void>::type
1269 template<
class U>
inline
1270 typename util::enable_if< util::is_same<U,gsFeSpace<Scalar> >::value,
void>::type
1282 template<
class U>
inline
1283 typename util::enable_if< util::is_same<U,gsFeVariable<Scalar> >::value,
void>::type
1295 template<
class U>
inline
1296 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar> >::value,
void>::type
1300 hess(_u).parse(evList);
1306 template<
class U>
inline
1307 typename util::enable_if< util::is_same<U,gsGeometryMap<Scalar> >::value,
const gsMatrix<Scalar> & >::type
1308 eval_impl(
const U & u,
const index_t k)
const
1321 tmp =_u.data().values[2].reshapeCol(k, cols(), _u.data().dim.second );
1323 res = vEv * tmp.transpose();
1327 template<
class U>
inline
1328 typename util::enable_if<util::is_same<U,gsFeSpace<Scalar> >::value,
const gsMatrix<Scalar> & >::type
1329 eval_impl(
const U & u,
const index_t k)
const
1337 const index_t numAct = u.data().values[0].rows();
1338 const index_t cardinality = u.cardinality();
1339 res.resize(rows()*cardinality, cols() );
1340 tmp.transpose() =_u.data().values[2].reshapeCol(k, cols(), numAct );
1343 for (
index_t i = 0; i!=_u.dim(); i++)
1344 res.block(i*numAct, 0, numAct, cols() ) = tmp * vEv.
at(i);
1348 template<
class U>
inline
1349 typename util::enable_if<util::is_same<U,gsFeVariable<Scalar> >::value,
const gsMatrix<Scalar> & >::type
1350 eval_impl(
const U & u,
const index_t k)
const
1363 tmp = u.data().values[2].col(k);
1364 index_t nDers = _u.source().domainDim() * (_u.source().domainDim() + 1) / 2;
1365 index_t dim = _u.source().targetDim();
1366 tmp2.resize(nDers, dim);
1367 for (
index_t comp = 0; comp != u.source().targetDim(); comp++)
1368 tmp2.col(comp) = tmp.block(comp * nDers, 0, nDers, 1);
1371 res = vEv * tmp2.transpose();
1375 template<
class U>
inline
1376 typename util::enable_if<util::is_same<U,gsFeSolution<Scalar> >::value,
const gsMatrix<Scalar> & >::type
1377 eval_impl(
const U & u,
const index_t k)
const
1389 hess_expr<gsFeSolution<Scalar>> sHess = hess_expr<gsFeSolution<Scalar>>(_u);
1390 tmp = sHess.eval(k);
1396 template<
class U>
inline
1397 typename util::enable_if< util::is_same<U,gsGeometryMap<Scalar> >::value ||
1398 util::is_same<U,gsFeVariable<Scalar> >::value,
index_t >::type
1399 cols_impl(
const U & u)
const
1401 return _u.targetDim();
1404 template<
class U>
inline
1405 typename util::enable_if< util::is_same<U,gsFeSpace<Scalar> >::value ||
1406 util::is_same<U,gsFeSolution<Scalar> >::value,
index_t >::type
1407 cols_impl(
const U & u)
const
1443 typename E::Nested_t _u;
1447 enum{ Space = E::Space, ScalarValued= 0, ColBlocks = (1==E::Space?1:0) };
1449 typedef typename E::Scalar Scalar;
1459 return rows_impl(_u);
1464 return cols_impl(_u);
1476 index_t cardinality_impl()
const {
return _u.cardinality_impl(); }
1478 void print(std::ostream &os)
const { os <<
"deriv2("; _u.print(os); os <<
")"; }
1481 template<
class U>
inline
1482 typename util::enable_if< util::is_same<U,gsGeometryMap<Scalar> >::value,
const gsMatrix<Scalar> & >::type
1483 eval_impl(
const U & u,
const index_t k)
const
1495 res = _u.data().values[2].reshapeCol(k, cols(), _u.data().dim.second );
1499 template<
class U>
inline
1500 typename util::enable_if< util::is_same<U,gsFeVariable<Scalar> >::value,
const gsMatrix<Scalar> & >::type
1501 eval_impl(
const U & u,
const index_t k)
const
1513 tmp = _u.data().values[2];
1514 res.resize(rows(),cols());
1515 for (
index_t comp = 0; comp != _u.source().targetDim(); comp++)
1516 res.col(comp) = tmp.block(comp*rows(),0,rows(),1);
1520 template<
class U>
inline
1521 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar> >::value,
const gsMatrix<Scalar> & >::type
1522 eval_impl(
const U & u,
const index_t k)
const
1534 hess_expr<gsFeSolution<Scalar>> sHess = hess_expr<gsFeSolution<Scalar>>(_u);
1535 res = sHess.eval(k).transpose();
1540 template<
class U>
inline
1541 typename util::enable_if<util::is_same<U,gsFeSpace<Scalar> >::value,
const gsMatrix<Scalar> & >::type
1561 const index_t numAct = u.data().values[0].rows();
1562 const index_t cardinality = u.cardinality();
1564 res.resize(rows(), _u.dim() *_u.cardinality());
1567 tmp = _u.data().values[2].reshapeCol(k, cols(), numAct );
1568 for (
index_t d = 0; d != cols(); ++d)
1570 const index_t s = d*(cardinality + 1);
1571 for (
index_t i = 0; i != numAct; ++i)
1572 res.col(s+i*_u.cols()) = tmp.col(i);
1578 template<
class U>
inline
1579 typename util::enable_if< util::is_same<U,gsFeVariable<Scalar> >::value || util::is_same<U,gsGeometryMap<Scalar> >::value || util::is_same<U,gsFeSpace<Scalar> >::value,
index_t >::type
1580 rows_impl(
const U & u)
const
1582 return _u.source().domainDim() * ( _u.source().domainDim() + 1 ) / 2;
1585 template<
class U>
inline
1586 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar> >::value,
index_t >::type
1587 rows_impl(
const U & u)
const
1589 return _u.parDim() * ( _u.parDim() + 1 ) / 2;
1593 template<
class U>
inline
1594 typename util::enable_if< util::is_same<U,gsFeVariable<Scalar> >::value || util::is_same<U,gsGeometryMap<Scalar> >::value,
index_t >::type
1595 cols_impl(
const U & u)
const
1597 return u.source().targetDim();
1600 template<
class U>
inline
1601 typename util::enable_if< util::is_same<U,gsFeSolution<Scalar> >::value || util::is_same<U,gsFeSpace<Scalar> >::value,
index_t >::type
1602 cols_impl(
const U & u)
const
1616 template<
class E1,
class E2,
class E3>
1620 typedef typename E1::Scalar Scalar;
1623 typename E1::Nested_t _A;
1624 typename E2::Nested_t _B;
1625 typename E3::Nested_t _C;
1629 enum {Space = 3, ScalarValued = 0, ColBlocks = 0};
1633 flatdot_expr(_expr<E1>
const& A, _expr<E2>
const& B, _expr<E3>
const& C) : _A(A),_B(B),_C(C)
1640 const index_t An = _A.cardinality();
1642 const index_t Bn = _B.cardinality();
1648 GISMO_ASSERT(Bc==_A.rows(),
"Dimensions: "<<Bc<<
","<< _A.rows()<<
"do not match");
1649 GISMO_STATIC_ASSERT(E1::Space==1,
"First entry should be rowSpan" );
1650 GISMO_STATIC_ASSERT(E2::Space==2,
"Second entry should be colSpan.");
1655 for (
index_t i = 0; i!=An; ++i)
1656 for (
index_t j = 0; j!=Bn; ++j)
1658 tmp.noalias() = eB.middleCols(i*Bc,Bc) * eA.middleCols(j*Ac,Ac);
1660 tmp(0,0) *= eC.
at(0);
1661 tmp(0,1) *= eC.
at(2);
1662 tmp(1,0) *= eC.
at(2);
1663 tmp(1,1) *= eC.
at(1);
1664 res(i,j) = tmp.sum();
1669 index_t rows()
const {
return 1; }
1670 index_t cols()
const {
return 1; }
1673 { _A.parse(evList);_B.parse(evList);_C.parse(evList); }
1677 index_t cardinality_impl()
const {
return _A.cardinality_impl(); }
1679 void print(std::ostream &os)
const { os <<
"flatdot("; _A.print(os);_B.print(os);_C.print(os); os<<
")"; }
1691 template<
class E1,
class E2,
class E3>
1695 typedef typename E1::Scalar Scalar;
1698 typename E1::Nested_t _A;
1699 typename E2::Nested_t _B;
1700 typename E3::Nested_t _C;
1704 enum {Space = E1::Space, ScalarValued = 0, ColBlocks = 0};
1706 flatdot2_expr(_expr<E1>
const& A, _expr<E2>
const& B, _expr<E3>
const& C) : _A(A),_B(B),_C(C)
1713 const index_t An = _A.cardinality();
1714 const index_t Bn = _B.cardinality();
1720 GISMO_ASSERT(_B.rows()==_A.cols(),
"Dimensions: "<<_B.rows()<<
","<< _A.cols()<<
"do not match");
1721 GISMO_STATIC_ASSERT(E1::Space==1,
"First entry should be rowSpan");
1722 GISMO_STATIC_ASSERT(E2::Space==2,
"Second entry should be colSpan.");
1723 GISMO_ASSERT(_C.cols()==_B.rows(),
"Dimensions: "<<_C.rows()<<
","<< _B.rows()<<
"do not match");
1726 for (
index_t i = 0; i!=An; ++i)
1727 for (
index_t j = 0; j!=Bn; ++j)
1729 tmp = eA.middleCols(i*Ac,Ac) * eB.col(j);
1731 res(i,j) = (eC.row(0) * tmp.col(0)).value();
1736 index_t rows()
const {
return 1; }
1737 index_t cols()
const {
return 1; }
1740 { _A.parse(evList);_B.parse(evList);_C.parse(evList); }
1744 index_t cardinality_impl()
const {
return _A.cardinality_impl(); }
1746 void print(std::ostream &os)
const { os <<
"flatdot2("; _A.print(os);_B.print(os);_C.print(os); os<<
")"; }
1756 class cartcov_expr :
public _expr<cartcov_expr<T> >
1758 typename gsGeometryMap<T>::Nested_t _G;
1763 enum {Space = 0, ScalarValued = 0, ColBlocks = 0};
1765 cartcov_expr(
const gsGeometryMap<T> & G) : _G(G) { }
1774 if (_G.targetDim()==3)
1777 normal = _G.data().normals.col(k);
1779 covBasis.resize(3,3);
1780 covBasis.leftCols(2) = _G.data().jacobian(k);
1781 covBasis.col(2) = normal;
1783 else if (_G.targetDim()==2)
1786 covBasis.resize(2,2);
1787 covBasis = _G.data().jacobian(k);
1792 a1 = covBasis.col(0);
1793 a2 = covBasis.col(1);
1795 e1 = a1.normalized();
1796 e2 = (a2-(a2.dot(e1)*e1)).normalized();
1798 result(0,0) = (e1.dot(a1))*(a1.dot(e1));
1799 result(0,1) = (e1.dot(a2))*(a2.dot(e1));
1800 result(0,2) = 2*(e1.dot(a1))*(a2.dot(e1));
1802 result(1,0) = (e2.dot(a1))*(a1.dot(e2));
1803 result(1,1) = (e2.dot(a2))*(a2.dot(e2));
1804 result(1,2) = 2*(e2.dot(a1))*(a2.dot(e2));
1806 result(2,0) = (e1.dot(a1))*(a1.dot(e2));
1807 result(2,1) = (e1.dot(a2))*(a2.dot(e2));
1808 result(2,2) = (e1.dot(a1))*(a2.dot(e2)) + (e1.dot(a2))*(a1.dot(e2));
1812 cartcovinv_expr<T> inv()
const
1814 GISMO_ASSERT(rows() == cols(),
"The Jacobian matrix is not square");
1815 return cartcovinv_expr<T>(_G);
1818 index_t rows()
const {
return 3; }
1820 index_t cols()
const {
return 3; }
1822 static const gsFeSpace<Scalar> & rowVar() {
return gsNullExpr<Scalar>::get(); }
1823 static const gsFeSpace<Scalar> & colVar() {
return gsNullExpr<Scalar>::get(); }
1825 void parse(gsExprHelper<Scalar> & evList)
const
1832 void print(std::ostream &os)
const { os <<
"cartcov("; _G.print(os); os <<
")"; }
1836 class cartcovinv_expr :
public _expr<cartcovinv_expr<T> >
1838 typename gsGeometryMap<T>::Nested_t _G;
1843 enum {Space = 0, ScalarValued = 0, ColBlocks = 0};
1845 cartcovinv_expr(
const gsGeometryMap<T> & G) : _G(G) { }
1847 mutable gsMatrix<T> temp;
1849 gsMatrix<T> eval(
const index_t k)
const
1851 cartcov_expr<Scalar> cartcov = cartcov_expr<Scalar>(_G);
1852 temp = (cartcov.eval(k)).
reshape(3,3).inverse();
1856 index_t rows()
const {
return 3; }
1858 index_t cols()
const {
return 3; }
1860 static const gsFeSpace<Scalar> & rowVar() {
return gsNullExpr<Scalar>::get(); }
1861 static const gsFeSpace<Scalar> & colVar() {
return gsNullExpr<Scalar>::get(); }
1863 void parse(gsExprHelper<Scalar> & evList)
const
1866 cartcov(_G).parse(evList);
1872 void print(std::ostream &os)
const { os <<
"cartcovinv("; _G.print(os); os <<
")"; }
1881 class cartcon_expr :
public _expr<cartcon_expr<T> >
1883 typename gsGeometryMap<T>::Nested_t _G;
1888 enum {Space = 0, ScalarValued = 0, ColBlocks = 0};
1890 cartcon_expr(
const gsGeometryMap<T> & G) : _G(G) { }
1892 mutable gsMatrix<Scalar> covBasis, conBasis, covMetric, conMetric, cartBasis;
1899 if (_G.targetDim()==3)
1902 normal = _G.data().normals.col(k);
1905 covBasis.resize(3,3);
1906 conBasis.resize(3,3);
1907 covBasis.leftCols(2) = _G.data().jacobian(k);
1908 covBasis.col(2) = normal;
1909 covMetric = covBasis.transpose() * covBasis;
1911 conMetric = covMetric.inverse();
1913 conBasis.col(0) = conMetric(0,0)*covBasis.col(0)+conMetric(0,1)*covBasis.col(1)+conMetric(0,2)*covBasis.col(2);
1914 conBasis.col(1) = conMetric(1,0)*covBasis.col(0)+conMetric(1,1)*covBasis.col(1)+conMetric(1,2)*covBasis.col(2);
1916 else if (_G.targetDim()==2)
1922 covBasis.resize(2,2);
1923 conBasis.resize(2,2);
1925 covBasis = _G.data().jacobian(k);
1926 covMetric = covBasis.transpose() * covBasis;
1928 conMetric = covMetric.inverse();
1930 conBasis.col(0) = conMetric(0,0)*covBasis.col(0)+conMetric(0,1)*covBasis.col(1);
1931 conBasis.col(1) = conMetric(1,0)*covBasis.col(0)+conMetric(1,1)*covBasis.col(1);
1936 a1 = covBasis.col(0);
1937 a2 = covBasis.col(1);
1939 e1 = a1.normalized();
1940 e2 = (a2-(a2.dot(e1)*e1)).normalized();
1942 ac1 = conBasis.col(0);
1943 ac2 = conBasis.col(1);
1945 result(0,0) = (e1.dot(ac1))*(ac1.dot(e1));
1946 result(0,1) = (e1.dot(ac2))*(ac2.dot(e1));
1947 result(0,2) = 2*(e1.dot(ac1))*(ac2.dot(e1));
1949 result(1,0) = (e2.dot(ac1))*(ac1.dot(e2));
1950 result(1,1) = (e2.dot(ac2))*(ac2.dot(e2));
1951 result(1,2) = 2*(e2.dot(ac1))*(ac2.dot(e2));
1953 result(2,0) = (e1.dot(ac1))*(ac1.dot(e2));
1954 result(2,1) = (e1.dot(ac2))*(ac2.dot(e2));
1955 result(2,2) = (e1.dot(ac1))*(ac2.dot(e2)) + (e1.dot(ac2))*(ac1.dot(e2));
1960 cartconinv_expr<T> inv()
const
1962 GISMO_ASSERT(rows() == cols(),
"The Jacobian matrix is not square");
1963 return cartconinv_expr<T>(_G);
1966 index_t rows()
const {
return 3; }
1968 index_t cols()
const {
return 3; }
1970 static const gsFeSpace<Scalar> & rowVar() {
return gsNullExpr<Scalar>::get(); }
1971 static const gsFeSpace<Scalar> & colVar() {
return gsNullExpr<Scalar>::get(); }
1973 void parse(gsExprHelper<Scalar> & evList)
const
1980 void print(std::ostream &os)
const { os <<
"cartcon("; _G.print(os); os <<
")"; }
1984 class cartconinv_expr :
public _expr<cartconinv_expr<T> >
1987 typename gsGeometryMap<T>::Nested_t _G;
1988 mutable gsMatrix<T> temp;
1993 enum {Space = 0, ScalarValued = 0, ColBlocks = 0};
1995 cartconinv_expr(
const gsGeometryMap<T> & G) : _G(G) { }
1997 gsMatrix<T> eval(
const index_t k)
const
1999 cartcon_expr<Scalar> cartcon = cartcon_expr<Scalar>(_G);
2000 temp = (cartcon.eval(k)).
reshape(3,3).inverse();
2004 index_t rows()
const {
return 3; }
2006 index_t cols()
const {
return 3; }
2008 static const gsFeSpace<Scalar> & rowVar() {
return gsNullExpr<Scalar>::get(); }
2009 static const gsFeSpace<Scalar> & colVar() {
return gsNullExpr<Scalar>::get(); }
2011 void parse(gsExprHelper<Scalar> & evList)
const
2013 cartcon(_G).parse(evList);
2020 void print(std::ostream &os)
const { os <<
"cartconinv("; _G.print(os); os <<
")"; }
2024 unitVec_expr uv(
const index_t index,
const index_t dim) {
return unitVec_expr(index,dim); }
2026 template<
class E> EIGEN_STRONG_INLINE
2027 var1_expr<E> var1(
const E & u,
const gsGeometryMap<typename E::Scalar> & G) {
return var1_expr<E>(u, G); }
2029 template<
class E1,
class E2> EIGEN_STRONG_INLINE
2030 var2_expr<E1,E2> var2(
const E1 & u,
const E2 & v,
const gsGeometryMap<typename E1::Scalar> & G)
2031 {
return var2_expr<E1,E2>(u,v, G); }
2033 template<
class E1,
class E2,
class E3> EIGEN_STRONG_INLINE
2034 var2dot_expr<E1,E2,E3> var2(
const E1 & u,
const E2 & v,
const gsGeometryMap<typename E1::Scalar> & G,
const E3 & Ef)
2035 {
return var2dot_expr<E1,E2,E3>(u,v, G, Ef); }
2037 template<
class E1,
class E2,
class E3> EIGEN_STRONG_INLINE
2038 var2deriv2dot_expr<E1,E2,E3> var2deriv2(
const E1 & u,
const E2 & v,
const gsGeometryMap<typename E1::Scalar> & G,
const E3 & Ef)
2039 {
return var2deriv2dot_expr<E1,E2,E3>(u,v, G, Ef); }
2041 template<
class E> EIGEN_STRONG_INLINE
2042 tvar1_expr<E> tvar1(
const E & u,
const gsGeometryMap<typename E::Scalar> & G) {
return tvar1_expr<E>(u, G); }
2044 template<
class E> EIGEN_STRONG_INLINE
2045 ovar1_expr<E> ovar1(
const E & u,
const gsGeometryMap<typename E::Scalar> & G) {
return ovar1_expr<E>(u, G); }
2047 template<
class E1,
class E2,
class E3> EIGEN_STRONG_INLINE
2048 ovar2dot_expr<E1,E2,E3> ovar2(
const E1 & u,
const E2 & v,
const gsGeometryMap<typename E1::Scalar> & G,
const E3 & C)
2049 {
return ovar2dot_expr<E1,E2,E3>(u,v, G, C); }
2054 template<
class E> EIGEN_STRONG_INLINE
2055 deriv2_expr<E> deriv2(
const E & u) {
return deriv2_expr<E>(u); }
2057 template<
class E1,
class E2> EIGEN_STRONG_INLINE
2058 deriv2dot_expr<E1, E2> deriv2(
const E1 & u,
const E2 & v) {
return deriv2dot_expr<E1, E2>(u,v); }
2060 template<
class E1,
class E2,
class E3> EIGEN_STRONG_INLINE
2061 flatdot_expr<E1,E2,E3> flatdot(
const E1 & u,
const E2 & v,
const E3 & w)
2062 {
return flatdot_expr<E1,E2,E3>(u, v, w); }
2064 template<
class E1,
class E2,
class E3> EIGEN_STRONG_INLINE
2065 flatdot2_expr<E1,E2,E3> flatdot2(
const E1 & u,
const E2 & v,
const E3 & w)
2066 {
return flatdot2_expr<E1,E2,E3>(u, v, w); }
2068 template<
class E> EIGEN_STRONG_INLINE
2069 cartcov_expr<E> cartcov(
const gsGeometryMap<E> & G) {
return cartcov_expr<E>(G); }
2071 template<
class E> EIGEN_STRONG_INLINE
2072 cartcon_expr<E> cartcon(
const gsGeometryMap<E> & G) {
return cartcon_expr<E>(G); }
Computes the second derivative of an expression.
Definition: gsThinShellUtils.h:1441
#define GISMO_NO_IMPLEMENTATION
Definition: gsDebug.h:129
Definition: gsExpressions.h:96
Gradient of the object.
Definition: gsForwardDeclarations.h:73
#define short_t
Definition: gsConfig.h:35
Col3DType col3d(index_t c)
Returns column c as a fixed-size 3D vector.
Definition: gsMatrix.h:244
Defines different expressions.
Simple expression for the unit vector of length dim and with value 1 on index.
Definition: gsThinShellUtils.h:40
Outward normal on the boundary.
Definition: gsForwardDeclarations.h:86
Second variation of the surface normal times the second derivative of the geometry map times a vector...
Definition: gsThinShellUtils.h:375
EIGEN_STRONG_INLINE tangent_expr< T > tv(const gsGeometryMap< T > &u)
The tangent boundary vector of a geometry map in 2D.
Definition: gsExpressions.h:4513
Expression for the first variation of the surface normal.
Definition: gsThinShellUtils.h:80
Provides declaration of Basis abstract interface.
Second derivatives.
Definition: gsForwardDeclarations.h:80
#define index_t
Definition: gsConfig.h:32
Provides assembler and solver options.
Computes the product of expressions E1 and E2 and multiplies with a vector E3 in voight notation...
Definition: gsThinShellUtils.h:1617
#define GISMO_ASSERT(cond, message)
Definition: gsDebug.h:89
Provides the gsDofMapper class for re-indexing DoFs.
T at(index_t i) const
Returns the i-th element of the vectorization of the matrix.
Definition: gsMatrix.h:211
#define gsWarn
Definition: gsDebug.h:50
Normal vector of the object.
Definition: gsForwardDeclarations.h:85
Second variation of the normal.
Definition: gsThinShellUtils.h:499
util::enable_if< util::is_same< U, gsFeSpace< Scalar > >::value, const gsMatrix< Scalar > & >::type eval_impl(const U &u, const index_t k) const
Spexialization for a space.
Definition: gsThinShellUtils.h:1542
Expression for the first variation of the outer normal.
Definition: gsThinShellUtils.h:853
Expression that takes the second derivative of an expression and multiplies it with a row vector...
Definition: gsThinShellUtils.h:1199
#define gsInfo
Definition: gsDebug.h:43
Active function ids.
Definition: gsForwardDeclarations.h:84
Computes the product of expressions E1 and E2 and multiplies with a vector E3 in voight notation...
Definition: gsThinShellUtils.h:1692
T at(index_t i) const
Returns the i-th element of the vector.
Definition: gsVector.h:177
Expression for the second variation of the outer normal times a vector.
Definition: gsThinShellUtils.h:1001
EIGEN_STRONG_INLINE reshape_expr< E > const reshape(E const &u, index_t n, index_t m)
Reshape an expression.
Definition: gsExpressions.h:1925
Definition: gsThinShellUtils.h:1878
Value of the object.
Definition: gsForwardDeclarations.h:72
EIGEN_STRONG_INLINE grad_expr< E > grad(const E &u)
The gradient of a variable.
Definition: gsExpressions.h:4490
Provides functions to generate structured point data.
Provides gsBoundaryConditions class.
Definition: gsThinShellUtils.h:1753
#define GISMO_ERROR(message)
Definition: gsDebug.h:118
This is the main header file that collects wrappers of Eigen for linear algebra.
EIGEN_STRONG_INLINE abs_expr< E > abs(const E &u)
Absolute value.
Definition: gsExpressions.h:4486
Second variation of the surface normal times a vector.
Definition: gsThinShellUtils.h:248
Expression for the first variation of the outer tangent.
Definition: gsThinShellUtils.h:659
This object is a cache for computed values from an evaluator.
Definition: gsExpressions.h:3080