Comments (5)
It is global, but you can use
IdentityInterpolator
ector H1 into the RT space.This is done for example in the construction of AMS which needs the similar Nedelec interpolant Π from vector H1 into the NS space as a matrix, see https://github.com/mfem/mfem/blob/master/linalg/hypre.cpp#L5614
Thank you for your help! So IdentityInterpolator
and ParDiscreteLinearOperator
can define a Matrix from H1 space to RT space, is it correct?
The above Pi can be calculate locally, since (18) ensures that pi v\in H(div) spaces when v\in H1. I think the above pi can also be obtained in the help of MFEM locally. Since I'm investigating the postprocessing methods in the HDG branch of MFEM, where a postprocessing method is proposed and implemented element by element. We can solve (18) and (19) element by element for any given v\in [H^1(\Omega)]^d.
from mfem.
It is global, but you can use IdentityInterpolator
ector H1 into the RT space.
This is done for example in the construction of AMS which needs the similar Nedelec interpolant
from mfem.
The below is the RTk projection written by my own code, I will try it in MFEM to implement the similar code.
int RTkprojection(
MESH &Mesh,
int degreeVecSigmah,
Matrix<dataType, 2, 1>(*VecSigma)(const MESH &Mesh, int p_k, int id, int i, int i_face, int i_edge, dataType x, dataType y),
dataType(*curl_VecSigma)(const MESH &Mesh, int p_k, int id, int i, int i_face, int i_edge, dataType x, dataType y),
Matrix<dataType, Dynamic, 1> &coeffVecSigmah)
{
int freedomVecSigmah = FREEDOM_RTK[degreeVecSigmah];
coeffVecSigmah.resize(Mesh.getNumElement() * freedomVecSigmah);
printf("Matrix ");
fflush(stdout);
#pragma omp parallel for
for (int id = 0; id < Mesh.num_Element; id++) {
int m_k = degreeVecSigmah;
Matrix<dataType, Dynamic, 1> Fl(freedomVecSigmah);
Matrix<dataType, Dynamic, Dynamic> Al(freedomVecSigmah, freedomVecSigmah);
Fl.setZero();
Al.setZero();
for (int i = 0; i < 3 * (m_k + 1); i++) {
int face_k = i / (m_k + 1);
int face_i = i;
for (int j = 0; j < FREEDOM_RTK[m_k]; j++) {
Al(i, j) = qf5pE(Mesh, local_RTk, normalVecPkEdge, 1.0, m_k, m_k, id, j, face_i, face_k, face_k, 0, 0, face_k);
}
Fl(i) +=
qf5pE(Mesh, VecSigma, normalVecPkEdge, 1.0, m_k, m_k, id, face_i, face_i, face_k, face_k, 0, 0, face_k);
}
if (m_k >= 1) {
for (int i = 0; i < FREEDOM_VECTORPK[m_k - 1]; i++) {
for (int j = 0; j < FREEDOM_RTK[m_k]; j++) {
Al(i + 3 * (m_k + 1), j) = qf25pT(Mesh, vectorPk, local_RTk, 1.0, m_k - 1, m_k, id, i, j);
}
Fl(i + 3 * (m_k + 1)) = qf25pT(Mesh, vectorPk, VecSigma, 1.0, m_k - 1, m_k, id, i, i);
}
}
coeffVecSigmah.segment(id * freedomVecSigmah, freedomVecSigmah) = Al.inverse() * Fl;
}
return Mesh.getNumElement() * freedomVecSigmah;
}
from mfem.
I have implemented the above RT projection, may I will pull a request to add this new RT projection.
from mfem.
Yes, please feel free to open a PR
from mfem.
Related Issues (20)
- inconformity of DOF for Nedelec Finite Element Space HOT 4
- 【The use of HypreParVector】 HOT 1
- Custom IntegrationRule for VectorFEMassIntegrator HOT 2
- Add device tests of Example 14 (DG diffusion) HOT 3
- How to inverse block opeator matrix
- Possible memory leakage of HypreParMatrix HOT 2
- Evaluating integrals of shape functions in neighboring elements HOT 13
- 【VectorDomainLFIntegrator does not provided enough constructors】 HOT 3
- Changes to `socketbuf` result in `SocketStream` objects returning true even if not connected (e.g., to GLVis) HOT 5
- 【Is PWFunctionCoefficient possible?】 HOT 1
- Strange failure in LOBPCG::Solve() HOT 5
- Coefficient Projection for IGA Spaces HOT 5
- Apply double cross of a function by normal vector for Nedelec space.
- Fix the FMS unit test and the FMS example file `data/star-q3.fms`
- 3D electromagnetic proximity effect
- Implement AssemblePABoundary for VectorFEMassIntegrator HOT 2
- Suggested added feature: OptionsParser taking input from file
- HypreBoomerAMG preconditioner memory leaks HOT 6
- Error calling CUDA mfem::forall() with MFEM as a third party library HOT 3
- Maybe inconsistence of "domain_integes_marker" when construct a bilinearform with existed one
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mfem.