MFEM  v3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
bilininteg.hpp
Go to the documentation of this file.
1 // Copyright (c) 2010, Lawrence Livermore National Security, LLC. Produced at
2 // the Lawrence Livermore National Laboratory. LLNL-CODE-443211. All Rights
3 // reserved. See file COPYRIGHT for details.
4 //
5 // This file is part of the MFEM library. For more information and source code
6 // availability see http://mfem.googlecode.com.
7 //
8 // MFEM is free software; you can redistribute it and/or modify it under the
9 // terms of the GNU Lesser General Public License (as published by the Free
10 // Software Foundation) version 2.1 dated February 1999.
11 
12 #ifndef MFEM_BILININTEG
13 #define MFEM_BILININTEG
14 
15 #include "../config/config.hpp"
16 #include "nonlininteg.hpp"
17 
18 namespace mfem
19 {
20 
23 {
24 protected:
26 
28  { IntRule = ir; }
29 
30 public:
32  virtual void AssembleElementMatrix(const FiniteElement &el,
33  ElementTransformation &Trans,
34  DenseMatrix &elmat);
39  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
40  const FiniteElement &test_fe,
41  ElementTransformation &Trans,
42  DenseMatrix &elmat);
43  virtual void AssembleFaceMatrix(const FiniteElement &el1,
44  const FiniteElement &el2,
46  DenseMatrix &elmat);
49  virtual void AssembleFaceMatrix(const FiniteElement &trial_face_fe,
50  const FiniteElement &test_fe1,
51  const FiniteElement &test_fe2,
53  DenseMatrix &elmat);
55  virtual void AssembleElementVector(const FiniteElement &el,
57  const Vector &elfun, Vector &elvect);
58  virtual void AssembleElementGrad(const FiniteElement &el,
60  const Vector &elfun, DenseMatrix &elmat)
61  { AssembleElementMatrix(el, Tr, elmat); }
62  virtual void ComputeElementFlux(const FiniteElement &el,
63  ElementTransformation &Trans,
64  Vector &u,
65  const FiniteElement &fluxelem,
66  Vector &flux, int wcoef = 1) { }
67  virtual double ComputeFluxEnergy(const FiniteElement &fluxelem,
68  ElementTransformation &Trans,
69  Vector &flux) { return 0.0; }
70 
71  void SetIntRule(const IntegrationRule *ir) { IntRule = ir; }
72 
74 };
75 
77 {
78 private:
79  int own_bfi;
81 
82  DenseMatrix bfi_elmat;
83 
84 public:
85  TransposeIntegrator (BilinearFormIntegrator *_bfi, int _own_bfi = 1)
86  { bfi = _bfi; own_bfi = _own_bfi; }
87 
88  virtual void AssembleElementMatrix(const FiniteElement &el,
89  ElementTransformation &Trans,
90  DenseMatrix &elmat);
91  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
92  const FiniteElement &test_fe,
93  ElementTransformation &Trans,
94  DenseMatrix &elmat);
96  virtual void AssembleFaceMatrix(const FiniteElement &el1,
97  const FiniteElement &el2,
99  DenseMatrix &elmat);
100  virtual ~TransposeIntegrator() { if (own_bfi) delete bfi; }
101 };
102 
104 {
105 private:
106  int own_bfi;
108 
109 public:
110  LumpedIntegrator (BilinearFormIntegrator *_bfi, int _own_bfi = 1)
111  { bfi = _bfi; own_bfi = _own_bfi; }
112 
113  virtual void AssembleElementMatrix(const FiniteElement &el,
114  ElementTransformation &Trans,
115  DenseMatrix &elmat);
116 
117  virtual ~LumpedIntegrator() { if (own_bfi) delete bfi; }
118 };
119 
122 {
123 private:
124  int own_integrator;
125  BilinearFormIntegrator *integrator;
126 
127 public:
128  InverseIntegrator(BilinearFormIntegrator *integ, int own_integ = 1)
129  { integrator = integ; own_integrator = own_integ; }
130 
131  virtual void AssembleElementMatrix(const FiniteElement &el,
132  ElementTransformation &Trans,
133  DenseMatrix &elmat);
134 
135  virtual ~InverseIntegrator() { if (own_integrator) delete integrator; }
136 };
137 
140 {
141 private:
142  int own_integrators;
143  DenseMatrix elem_mat;
144  Array<BilinearFormIntegrator*> integrators;
145 
146 public:
147  SumIntegrator(int own_integs = 1) { own_integrators = own_integs; }
148 
150  { integrators.Append(integ); }
151 
152  virtual void AssembleElementMatrix(const FiniteElement &el,
153  ElementTransformation &Trans,
154  DenseMatrix &elmat);
155 
156  virtual ~SumIntegrator();
157 };
158 
162 {
163 private:
164  Vector vec, pointflux, shape;
165 #ifndef MFEM_THREAD_SAFE
166  DenseMatrix dshape, dshapedxt, invdfdx, mq;
167  DenseMatrix te_dshape, te_dshapedxt;
168 #endif
169  Coefficient *Q;
170  MatrixCoefficient *MQ;
171 
172 public:
174  DiffusionIntegrator() { Q = NULL; MQ = NULL; }
175 
177  DiffusionIntegrator (Coefficient &q) : Q(&q) { MQ = NULL; }
178 
180  DiffusionIntegrator (MatrixCoefficient &q) : MQ(&q) { Q = NULL; }
181 
184  virtual void AssembleElementMatrix(const FiniteElement &el,
185  ElementTransformation &Trans,
186  DenseMatrix &elmat);
189  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
190  const FiniteElement &test_fe,
191  ElementTransformation &Trans,
192  DenseMatrix &elmat);
194  virtual void AssembleElementVector(const FiniteElement &el,
196  const Vector &elfun, Vector &elvect);
197  virtual void ComputeElementFlux(const FiniteElement &el,
198  ElementTransformation &Trans,
199  Vector &u,
200  const FiniteElement &fluxelem,
201  Vector &flux, int wcoef);
202  virtual double ComputeFluxEnergy(const FiniteElement &fluxelem,
203  ElementTransformation &Trans,
204  Vector &flux);
205 };
206 
209 {
210 private:
211  Vector shape, te_shape;
212  Coefficient *Q;
213 
214 public:
215  MassIntegrator(const IntegrationRule *ir = NULL)
216  : BilinearFormIntegrator(ir) { Q = NULL; }
219  : BilinearFormIntegrator(ir), Q(&q) { }
220 
223  virtual void AssembleElementMatrix(const FiniteElement &el,
224  ElementTransformation &Trans,
225  DenseMatrix &elmat);
226  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
227  const FiniteElement &test_fe,
228  ElementTransformation &Trans,
229  DenseMatrix &elmat);
230 };
231 
233 {
234 public:
236 };
237 
240 {
241 private:
242  DenseMatrix dshape, adjJ, Q_ir;
243  Vector shape, vec2, BdFidxT;
245  double alpha;
246 
247 public:
249  : Q(q) { alpha = a; }
250  virtual void AssembleElementMatrix(const FiniteElement &,
252  DenseMatrix &);
253 };
254 
257 {
258 private:
259  DenseMatrix dshape, adjJ, Q_nodal, grad;
260  Vector shape;
262  double alpha;
263 
264 public:
266  : Q(q) { alpha = a; }
267  virtual void AssembleElementMatrix(const FiniteElement &,
269  DenseMatrix &);
270 };
271 
276 {
277 private:
278  Vector shape, te_shape, vec;
279  DenseMatrix partelmat;
280  DenseMatrix mcoeff;
281  Coefficient *Q;
282  VectorCoefficient *VQ;
283  MatrixCoefficient *MQ;
284 
285  int Q_order;
286 
287 public:
290  { Q = NULL; VQ = NULL; MQ = NULL; Q_order = 0; }
296  : Q(&q) { VQ = NULL; MQ = NULL; Q_order = qo; }
298  : BilinearFormIntegrator(ir), Q(&q)
299  { VQ = NULL; MQ = NULL; Q_order = 0; }
302  : VQ(&q) { Q = NULL; MQ = NULL; Q_order = qo; }
305  : MQ(&q) { Q = NULL; VQ = NULL; Q_order = qo; }
306 
307  virtual void AssembleElementMatrix(const FiniteElement &el,
308  ElementTransformation &Trans,
309  DenseMatrix &elmat);
310  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
311  const FiniteElement &test_fe,
312  ElementTransformation &Trans,
313  DenseMatrix &elmat);
314 };
315 
316 
325 {
326 private:
327  Coefficient *Q;
328 #ifndef MFEM_THREAD_SAFE
329  Vector divshape, shape;
330 #endif
331 public:
334  virtual void AssembleElementMatrix(const FiniteElement &el,
335  ElementTransformation &Trans,
336  DenseMatrix &elmat) { }
337  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
338  const FiniteElement &test_fe,
339  ElementTransformation &Trans,
340  DenseMatrix &elmat);
341 };
342 
343 
346 {
347 private:
348  Coefficient *Q;
349 #ifndef MFEM_THREAD_SAFE
350  DenseMatrix curlshapeTrial;
351  DenseMatrix vshapeTest;
352  DenseMatrix curlshapeTrial_dFT;
353 #endif
354 public:
355  VectorFECurlIntegrator() { Q = NULL; }
357  virtual void AssembleElementMatrix(const FiniteElement &el,
358  ElementTransformation &Trans,
359  DenseMatrix &elmat) { }
360  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
361  const FiniteElement &test_fe,
362  ElementTransformation &Trans,
363  DenseMatrix &elmat);
364 };
365 
366 
369 {
370 private:
371  Coefficient & Q;
372  int xi;
373  DenseMatrix dshape, dshapedxt, invdfdx;
374  Vector shape, dshapedxi;
375 public:
376  DerivativeIntegrator(Coefficient &q, int i) : Q(q), xi(i) { }
377  virtual void AssembleElementMatrix(const FiniteElement &el,
378  ElementTransformation &Trans,
379  DenseMatrix &elmat)
380  { AssembleElementMatrix2(el,el,Trans,elmat); }
381  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
382  const FiniteElement &test_fe,
383  ElementTransformation &Trans,
384  DenseMatrix &elmat);
385 };
386 
389 {
390 private:
391 #ifndef MFEM_THREAD_SAFE
392  DenseMatrix Curlshape, Curlshape_dFt;
393 #endif
394  Coefficient *Q;
395 
396 public:
397  CurlCurlIntegrator() { Q = NULL; }
400 
401  /* Given a particular Finite Element, compute the
402  element curl-curl matrix elmat */
403  virtual void AssembleElementMatrix(const FiniteElement &el,
404  ElementTransformation &Trans,
405  DenseMatrix &elmat);
406 };
407 
411 {
412 private:
413 #ifndef MFEM_THREAD_SAFE
414  DenseMatrix dshape_hat, dshape, curlshape, Jadj, grad_hat, grad;
415 #endif
416  Coefficient *Q;
417 
418 public:
419  VectorCurlCurlIntegrator() { Q = NULL; }
420 
422 
424  virtual void AssembleElementMatrix(const FiniteElement &el,
425  ElementTransformation &Trans,
426  DenseMatrix &elmat);
428  virtual double GetElementEnergy(const FiniteElement &el,
430  const Vector &elfun);
431 };
432 
435 {
436 private:
437  Coefficient *Q;
438  VectorCoefficient *VQ;
439  MatrixCoefficient *MQ;
440  void Init(Coefficient *q, VectorCoefficient *vq, MatrixCoefficient *mq)
441  { Q = q; VQ = vq; MQ = mq; }
442 
443 #ifndef MFEM_THREAD_SAFE
444  Vector shape;
445  Vector D;
446  DenseMatrix K;
447  DenseMatrix vshape;
448 #endif
449 
450 public:
451  VectorFEMassIntegrator() { Init(NULL, NULL, NULL); }
452  VectorFEMassIntegrator(Coefficient *_q) { Init(_q, NULL, NULL); }
453  VectorFEMassIntegrator(Coefficient &q) { Init(&q, NULL, NULL); }
454  VectorFEMassIntegrator(VectorCoefficient *_vq) { Init(NULL, _vq, NULL); }
455  VectorFEMassIntegrator(VectorCoefficient &vq) { Init(NULL, &vq, NULL); }
456  VectorFEMassIntegrator(MatrixCoefficient *_mq) { Init(NULL, NULL, _mq); }
457  VectorFEMassIntegrator(MatrixCoefficient &mq) { Init(NULL, NULL, &mq); }
458 
459  virtual void AssembleElementMatrix(const FiniteElement &el,
460  ElementTransformation &Trans,
461  DenseMatrix &elmat);
462  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
463  const FiniteElement &test_fe,
464  ElementTransformation &Trans,
465  DenseMatrix &elmat);
466 };
467 
472 {
473 private:
474  Coefficient *Q;
475 
476  Vector shape;
477  Vector divshape;
478  DenseMatrix dshape;
479  DenseMatrix gshape;
480  DenseMatrix Jadj;
481 
482 public:
486 
487  virtual void AssembleElementMatrix2(const FiniteElement &trial_fe,
488  const FiniteElement &test_fe,
489  ElementTransformation &Trans,
490  DenseMatrix &elmat);
491 };
492 
495 {
496 private:
497  Coefficient *Q;
498 
499 #ifndef MFEM_THREAD_SAFE
500  Vector divshape;
501 #endif
502 
503 public:
504  DivDivIntegrator() { Q = NULL; }
506 
507  virtual void AssembleElementMatrix(const FiniteElement &el,
508  ElementTransformation &Trans,
509  DenseMatrix &elmat);
510 };
511 
515 {
516 private:
517  Coefficient *Q;
518 
519  DenseMatrix Jinv;
520  DenseMatrix dshape;
521  DenseMatrix gshape;
522  DenseMatrix pelmat;
523 
524 public:
527 
528  virtual void AssembleElementMatrix(const FiniteElement &el,
529  ElementTransformation &Trans,
530  DenseMatrix &elmat);
531 };
532 
539 {
540 private:
541  double q_lambda, q_mu;
542  Coefficient *lambda, *mu;
543 
544 #ifndef MFEM_THREAD_SAFE
545  DenseMatrix dshape, Jinv, gshape, pelmat;
546  Vector divshape;
547 #endif
548 
549 public:
551  { lambda = &l; mu = &m; }
554  ElasticityIntegrator(Coefficient &m, double q_l, double q_m)
555  { lambda = NULL; mu = &m; q_lambda = q_l; q_mu = q_m; }
556 
557  virtual void AssembleElementMatrix(const FiniteElement &,
559  DenseMatrix &);
560 };
561 
571 {
572 private:
573  Coefficient *rho;
575  double alpha, beta;
576 
577  Vector shape1, shape2;
578 
579 public:
581  DGTraceIntegrator(VectorCoefficient &_u, double a, double b)
582  { rho = NULL; u = &_u; alpha = a; beta = b; }
583 
585  double a, double b)
586  { rho = &_rho; u = &_u; alpha = a; beta = b; }
587 
589  virtual void AssembleFaceMatrix(const FiniteElement &el1,
590  const FiniteElement &el2,
592  DenseMatrix &elmat);
593 };
594 
608 {
609 protected:
612  double sigma, kappa;
613 
614  // these are not thread-safe!
617 
618 public:
619  DGDiffusionIntegrator(const double s, const double k)
620  : Q(NULL), MQ(NULL), sigma(s), kappa(k) { }
621  DGDiffusionIntegrator(Coefficient &q, const double s, const double k)
622  : Q(&q), MQ(NULL), sigma(s), kappa(k) { }
623  DGDiffusionIntegrator(MatrixCoefficient &q, const double s, const double k)
624  : Q(NULL), MQ(&q), sigma(s), kappa(k) { }
626  virtual void AssembleFaceMatrix(const FiniteElement &el1,
627  const FiniteElement &el2,
629  DenseMatrix &elmat);
630 };
631 
636 {
637 private:
638  Vector face_shape, shape1, shape2;
639 
640 public:
643  virtual void AssembleFaceMatrix(const FiniteElement &trial_face_fe,
644  const FiniteElement &test_fe1,
645  const FiniteElement &test_fe2,
647  DenseMatrix &elmat);
648 };
649 
653 
654 
659 {
660 public:
661  virtual void AssembleElementMatrix2(const FiniteElement &h1_fe,
662  const FiniteElement &nd_fe,
663  ElementTransformation &Trans,
664  DenseMatrix &elmat)
665  { nd_fe.ProjectGrad(h1_fe, Trans, elmat); }
666 };
667 
668 
673 {
674 public:
675  virtual void AssembleElementMatrix2(const FiniteElement &dom_fe,
676  const FiniteElement &ran_fe,
677  ElementTransformation &Trans,
678  DenseMatrix &elmat)
679  { ran_fe.Project(dom_fe, Trans, elmat); }
680 };
681 
682 
687 {
688 public:
689  virtual void AssembleElementMatrix2(const FiniteElement &dom_fe,
690  const FiniteElement &ran_fe,
691  ElementTransformation &Trans,
692  DenseMatrix &elmat)
693  { ran_fe.ProjectCurl(dom_fe, Trans, elmat); }
694 };
695 
696 
706 {
707 public:
708  virtual void AssembleElementMatrix2(const FiniteElement &dom_fe,
709  const FiniteElement &ran_fe,
710  ElementTransformation &Trans,
711  DenseMatrix &elmat)
712  { ran_fe.ProjectDiv(dom_fe, Trans, elmat); }
713 };
714 
715 }
716 
717 #endif
Abstract class for Finite Elements.
Definition: fe.hpp:42
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.hpp:357
VectorFEMassIntegrator(Coefficient &q)
Definition: bilininteg.hpp:453
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.cpp:65
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.hpp:377
Class for integration rule.
Definition: intrules.hpp:63
DGTraceIntegrator(VectorCoefficient &_u, double a, double b)
Construct integrator with rho = 1.
Definition: bilininteg.hpp:581
virtual double ComputeFluxEnergy(const FiniteElement &fluxelem, ElementTransformation &Trans, Vector &flux)
Definition: bilininteg.hpp:67
DGDiffusionIntegrator(Coefficient &q, const double s, const double k)
Definition: bilininteg.hpp:621
Integrator defining a sum of multiple Integrators.
Definition: bilininteg.hpp:139
SumIntegrator(int own_integs=1)
Definition: bilininteg.hpp:147
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
DiffusionIntegrator(Coefficient &q)
Construct a diffusion integrator with a scalar coefficient q.
Definition: bilininteg.hpp:177
virtual void ProjectDiv(const FiniteElement &fe, ElementTransformation &Trans, DenseMatrix &div) const
Definition: fe.cpp:116
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:752
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual void Project(Coefficient &coeff, ElementTransformation &Trans, Vector &dofs) const
Definition: fe.cpp:75
ElasticityIntegrator(Coefficient &l, Coefficient &m)
Definition: bilininteg.hpp:550
VectorFEMassIntegrator(VectorCoefficient *_vq)
Definition: bilininteg.hpp:454
VectorDiffusionIntegrator(Coefficient &q)
Definition: bilininteg.hpp:526
Integrator for (curl u, curl v) for Nedelec elements.
Definition: bilininteg.hpp:388
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
VectorCurlCurlIntegrator(Coefficient &q)
Definition: bilininteg.hpp:421
VectorMassIntegrator(Coefficient &q, const IntegrationRule *ir)
Definition: bilininteg.hpp:297
alpha (q . grad u, v) using the &quot;group&quot; FE discretization
Definition: bilininteg.hpp:256
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.cpp:615
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Data type dense matrix.
Definition: densemat.hpp:22
DivDivIntegrator(Coefficient &q)
Definition: bilininteg.hpp:505
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:82
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.cpp:91
BilinearFormIntegrator(const IntegrationRule *ir=NULL)
Definition: bilininteg.hpp:27
virtual void ComputeElementFlux(const FiniteElement &el, ElementTransformation &Trans, Vector &u, const FiniteElement &fluxelem, Vector &flux, int wcoef=1)
Definition: bilininteg.hpp:62
void AddIntegrator(BilinearFormIntegrator *integ)
Definition: bilininteg.hpp:149
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.hpp:334
virtual void ProjectGrad(const FiniteElement &fe, ElementTransformation &Trans, DenseMatrix &grad) const
Definition: fe.cpp:100
(Q div u, div v) for RT elements
Definition: bilininteg.hpp:494
MatrixCoefficient * MQ
Definition: bilininteg.hpp:611
VectorFEMassIntegrator(VectorCoefficient &vq)
Definition: bilininteg.hpp:455
VectorMassIntegrator()
Construct an integrator with coefficient 1.0.
Definition: bilininteg.hpp:289
VectorMassIntegrator(VectorCoefficient &q, int qo=0)
Construct an integrator with diagonal coefficient q.
Definition: bilininteg.hpp:301
virtual void AssembleElementMatrix2(const FiniteElement &dom_fe, const FiniteElement &ran_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.hpp:675
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:73
Integrator that inverts the matrix assembled by another integrator.
Definition: bilininteg.hpp:121
virtual void ProjectCurl(const FiniteElement &fe, ElementTransformation &Trans, DenseMatrix &curl) const
Definition: fe.cpp:108
ElasticityIntegrator(Coefficient &m, double q_l, double q_m)
Definition: bilininteg.hpp:554
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.cpp:890
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:443
VectorDivergenceIntegrator(Coefficient &q)
Definition: bilininteg.hpp:485
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.cpp:98
Integrator for (curl u, v) for Nedelec and RT elements.
Definition: bilininteg.hpp:345
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.cpp:105
virtual void AssembleElementGrad(const FiniteElement &el, ElementTransformation &Tr, const Vector &elfun, DenseMatrix &elmat)
Assemble the local gradient matrix.
Definition: bilininteg.hpp:58
VectorFEDivergenceIntegrator(Coefficient &q)
Definition: bilininteg.hpp:333
void SetIntRule(const IntegrationRule *ir)
Definition: bilininteg.hpp:71
VectorFECurlIntegrator(Coefficient &q)
Definition: bilininteg.hpp:356
virtual void AssembleElementMatrix2(const FiniteElement &h1_fe, const FiniteElement &nd_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.hpp:661
DiffusionIntegrator()
Construct a diffusion integrator with coefficient Q = 1.
Definition: bilininteg.hpp:174
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
virtual double ComputeFluxEnergy(const FiniteElement &fluxelem, ElementTransformation &Trans, Vector &flux)
Definition: bilininteg.cpp:385
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:681
BoundaryMassIntegrator(Coefficient &q)
Definition: bilininteg.hpp:235
virtual void AssembleElementMatrix(const FiniteElement &, ElementTransformation &, DenseMatrix &)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.cpp:563
virtual void AssembleElementVector(const FiniteElement &el, ElementTransformation &Tr, const Vector &elfun, Vector &elvect)
Perform the local action of the BilinearFormIntegrator.
Definition: bilininteg.cpp:56
virtual void AssembleElementVector(const FiniteElement &el, ElementTransformation &Tr, const Vector &elfun, Vector &elvect)
Perform the local action of the BilinearFormIntegrator.
Definition: bilininteg.cpp:262
Abstract base class BilinearFormIntegrator.
Definition: bilininteg.hpp:22
VectorDivergenceIntegrator(Coefficient *_q)
Definition: bilininteg.hpp:484
DiffusionIntegrator(MatrixCoefficient &q)
Construct a diffusion integrator with a matrix coefficient q.
Definition: bilininteg.hpp:180
virtual void AssembleElementMatrix(const FiniteElement &, ElementTransformation &, DenseMatrix &)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.cpp:519
VectorFEMassIntegrator(MatrixCoefficient &mq)
Definition: bilininteg.hpp:457
Base class Coefficient that may optionally depend on time.
Definition: coefficient.hpp:31
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Given a particular Finite Element computes the element matrix elmat.
Definition: bilininteg.cpp:23
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:791
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:192
DGDiffusionIntegrator(const double s, const double k)
Definition: bilininteg.hpp:619
LumpedIntegrator(BilinearFormIntegrator *_bfi, int _own_bfi=1)
Definition: bilininteg.hpp:110
MassIntegrator(Coefficient &q, const IntegrationRule *ir=NULL)
Construct a mass integrator with coefficient q.
Definition: bilininteg.hpp:218
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:833
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Assemble an element matrix.
Definition: bilininteg.cpp:937
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:39
VectorMassIntegrator(Coefficient &q, int qo=0)
Definition: bilininteg.hpp:295
VectorFEMassIntegrator(Coefficient *_q)
Definition: bilininteg.hpp:452
virtual void AssembleElementMatrix2(const FiniteElement &dom_fe, const FiniteElement &ran_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.hpp:689
VectorFEMassIntegrator(MatrixCoefficient *_mq)
Definition: bilininteg.hpp:456
virtual void ComputeElementFlux(const FiniteElement &el, ElementTransformation &Trans, Vector &u, const FiniteElement &fluxelem, Vector &flux, int wcoef)
Definition: bilininteg.cpp:330
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:480
VectorMassIntegrator(MatrixCoefficient &q, int qo=0)
Construct an integrator with matrix coefficient q.
Definition: bilininteg.hpp:304
virtual void AssembleElementMatrix(const FiniteElement &, ElementTransformation &, DenseMatrix &)
Given a particular Finite Element computes the element matrix elmat.
GroupConvectionIntegrator(VectorCoefficient &q, double a=1.0)
Definition: bilininteg.hpp:265
virtual ~SumIntegrator()
Definition: bilininteg.cpp:118
DGDiffusionIntegrator(MatrixCoefficient &q, const double s, const double k)
Definition: bilininteg.hpp:623
virtual double GetElementEnergy(const FiniteElement &el, ElementTransformation &Tr, const Vector &elfun)
Compute element energy: (1/2) (curl u, curl u)_E.
Definition: bilininteg.cpp:982
Vector data type.
Definition: vector.hpp:29
ConvectionIntegrator(VectorCoefficient &q, double a=1.0)
Definition: bilininteg.hpp:248
virtual void AssembleFaceMatrix(const FiniteElement &el1, const FiniteElement &el2, FaceElementTransformations &Trans, DenseMatrix &elmat)
virtual void AssembleElementMatrix2(const FiniteElement &trial_fe, const FiniteElement &test_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:31
DerivativeIntegrator(Coefficient &q, int i)
Definition: bilininteg.hpp:376
DGTraceIntegrator(Coefficient &_rho, VectorCoefficient &_u, double a, double b)
Definition: bilininteg.hpp:584
CurlCurlIntegrator(Coefficient &q)
Construct a bilinear form integrator for Nedelec elements.
Definition: bilininteg.hpp:399
const IntegrationRule * IntRule
Definition: bilininteg.hpp:25
virtual void AssembleFaceMatrix(const FiniteElement &trial_face_fe, const FiniteElement &test_fe1, const FiniteElement &test_fe2, FaceElementTransformations &Trans, DenseMatrix &elmat)
virtual void AssembleElementMatrix2(const FiniteElement &dom_fe, const FiniteElement &ran_fe, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.hpp:708
virtual void AssembleElementMatrix(const FiniteElement &el, ElementTransformation &Trans, DenseMatrix &elmat)
Definition: bilininteg.cpp:129
MassIntegrator(const IntegrationRule *ir=NULL)
Definition: bilininteg.hpp:215
Integrator for (Q u, v) for VectorFiniteElements.
Definition: bilininteg.hpp:434
TransposeIntegrator(BilinearFormIntegrator *_bfi, int _own_bfi=1)
Definition: bilininteg.hpp:85
Class for integrating (Q D_i(u), v); u and v are scalars.
Definition: bilininteg.hpp:368
InverseIntegrator(BilinearFormIntegrator *integ, int own_integ=1)
Definition: bilininteg.hpp:128
alpha (q . grad u, v)
Definition: bilininteg.hpp:239