divergenz matrix computed as vector
I need to compute the following matrix C containing the divergence of trial functions:
C_{ij} = \int_{K_j} div(\psi_i) dx
K_j are the triangles of the trianglulation and \psi_i are the basis functions
of the raviart-thomas function space.
In this definition, C_ij should be a matrix, but when I'm computing this,
I only get a Vector-object and not a matrix.
(I need to compute the QR-decomposition of this matrix)
I implemented:
mesh = Rectangle(
mesh.order()
U = FunctionSpace(mesh, "Raviart-Thomas", 1)
psi = TrialFunction(U)
int_psi = div(psi)*dx
mat_psi = assemble(int_psi)
The code works, but mat_psi is a Vector - object and so it is not possible to compute
the QR-decomposition.
My problem is that I'm note sure if I compute the matrix correctly or if I do have to
specify the TrialFunctions in another way? Perhaps this is a stupid question but
I can't find my mistake!
Any advice would be helpful! Thanks!
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- DOLFIN Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- Marie Rognes
- Solved:
- Last query:
- Last reply: