# Compute mass matrix in vibrations problem by using finite element method

I have to compute the mass matrix of a Hexahedral mesh.

There are 3 methods to compute mass matrix. I'm interested in one method which consists of dividing the mass of the element by the number of nodes and attributes this mass at each node for each degree of freedoms.

My problems is that: I don't know how to compute the volume of the element and then multiply it by the density to calculate mass.

In 2D, I have the solution, but not in 3D.

I'm open to any help on this subject due to the fact that I don't know any article on this subject.

• How are you computing the element stiffness matrix? If you are using a standard isoparametric formulation, you have to integrate over the element volume to compute the terms so calculating the volume itself is trivial. – Bill Greene Mar 20 at 17:16
• What kind of cells do you have? Arbitrarily shaped hexahedra? Or are they bricks? – Wolfgang Bangerth Mar 20 at 22:46
• arbitrarily shaped hexaedra. anyway, i found a post already existing math.stackexchange.com/questions/1142331/… which answer the question. – Attila90 Mar 21 at 20:00