G+Smo  24.08.0
Geometry + Simulation Modules
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
gsBiharmonicAssembler.hpp
1 
14 #include <gsAssembler/gsVisitorBiharmonic.h>
17 //#include <gsAssembler/gsVisitorNitscheBiharmonic.h>
18 
19 namespace gismo
20 {
21 
22 template <class T, class bhVisitor>
24 {
25  // We use predefined helper which initializes the system matrix
26  // rows and columns using the same test and trial space
27  Base::scalarProblemGalerkinRefresh();
28 }
29 
30 template <class T, class bhVisitor>
32 {
33  GISMO_ASSERT(m_system.initialized(), "Sparse system is not initialized, call refresh()");
34 
35  // Reserve sparse system
36  const index_t nz = gsAssemblerOptions::numColNz(m_bases[0][0],2,1,0.333333);
37  m_system.reserve(nz, this->pde().numRhs());
38 
39  // Compute the Dirichlet Degrees of freedom (if needed by m_options)
40  Base::computeDirichletDofs();
41 
42  // Assemble volume integrals
43  Base::template push<bhVisitor >();
44 
45  // Neumann conditions of first kind
46  Base::template push<gsVisitorNeumann<T> >(
47  m_ppde.bcFirstKind().neumannSides() );
48 
49  // Neumann conditions of second kind
50  Base::template push<gsVisitorNeumannBiharmonic<T> >(
51  m_ppde.bcSecondKind().neumannSides() );
52 
53  if ( m_options.getInt("InterfaceStrategy") == iFace::dg )
54  gsWarn <<"DG option ignored.\n";
55 
56  /*
57  // If requested, force Dirichlet boundary conditions by Nitsche's method
58  this->template push<gsVisitorNitscheBiharmonic<T> >(
59  m_ppde.bcSecondKind().dirichletSides() );
60  */
61 
62  // Assembly is done, compress the matrix
63  Base::finalize();
64 }
65 
66 
67 } // namespace gismo
Neumann conditions visitor for elliptic problems.
void refresh()
Creates the mappers and setups the sparse system. to be implemented in derived classes, see scalarProblemGalerkinRefresh() for a possible implementation.
Definition: gsBiharmonicAssembler.hpp:23
Neumann conditions visitor for 4th order problems.
#define index_t
Definition: gsConfig.h:32
#define GISMO_ASSERT(cond, message)
Definition: gsDebug.h:89
#define gsWarn
Definition: gsDebug.h:50
void assemble()
Main assemble routine, to be implemented in derived classes.
Definition: gsBiharmonicAssembler.hpp:31