.. _linear_elasticity-elastodynamic: linear_elasticity/elastodynamic.py ================================== **Description** The linear elastodynamics solution of an iron plate impact problem. Find :math:`\ul{u}` such that: .. math:: \int_{\Omega} \rho \ul{v} \pddiff{\ul{u}}{\ul{v}} + \int_{\Omega} D_{ijkl}\ e_{ij}(\ul{v}) e_{kl}(\ul{u}) = 0 \;, \quad \forall \ul{v} \;, where .. math:: D_{ijkl} = \mu (\delta_{ik} \delta_{jl}+\delta_{il} \delta_{jk}) + \lambda \ \delta_{ij} \delta_{kl} \;. Notes ----- The used elastodynamics solvers expect that the total vector of DOFs contains three blocks in this order: the displacements, the velocities, and the accelerations. This is achieved by defining three unknown variables ``'u'``, ``'du'``, ``'ddu'`` and the corresponding test variables, see the `variables` definition. Then the solver can automatically extract the mass, damping (zero here), and stiffness matrices as diagonal blocks of the global matrix. Note also the use of the ``'dw_zero'`` (do-nothing) term that prevents the velocity-related variables to be removed from the equations in the absence of a damping term. Usage Examples -------------- Run with the default settings (the Newmark method, 3D problem, results stored in ``output/ed/``):: python simple.py examples/linear_elasticity/elastodynamic.py Solve using the Bathe method:: python simple.py examples/linear_elasticity/elastodynamic.py -O "ts='tsb'" View the resulting deformation using: - color by :math:`\ul{u}`:: python postproc.py output/ed/user_block.h5 -b --wireframe --only-names=u -d 'u,plot_displacements,rel_scaling=1e3' - color by :math:`\ull{e}(\ul{u})`:: python postproc.py output/ed/user_block.h5 -b --wireframe --only-names=u -d 'u,plot_displacements,rel_scaling=1e3,color_kind="tensors",color_name="cauchy_strain"' - color by :math:`\ull{\sigma}(\ul{u})`:: python postproc.py output/ed/user_block.h5 -b --wireframe --only-names=u -d 'u,plot_displacements,rel_scaling=1e3,color_kind="tensors",color_name="cauchy_stress"' .. image:: /../gallery/images/linear_elasticity-elastodynamic.png :download:`source code ` .. literalinclude:: /../examples/linear_elasticity/elastodynamic.py