Hi,
I am in the case of elastodynamics. I already solving variational form, getting the displacement u_solution and then moving the the mesh doing ALE.move(mesh, u_solution)
at each timestep.
→ I also would like to apply an additional force F to surface vertices, but which is purely numerical and which has a priori nothing to do with the variational form.
This force F has to take a new value at each time step.
How should I apply it correctly to the mesh at each timestep?
To do so, I have tested the following process, at each timestep:
- F = Function(V), with V=VectorFunctionSpace(mesh, “CG”, 1)
- computation of the value of Fsurface for each surface vertex i
- from Fsurface (surface vertex indexation) to volume Function F (volume DOFs indexation):
F.vector()[vertexSurface_to_DOFsVolume_mapping[i]] = Fsurface[i] - moving mesh (this is independant from the u_solution displacement move):
ALE.move(mesh, F)
.
But, it seems that F is not applied to the mesh and I do not understand why. Would you have some ideas about that?
Many thanks for your help,
Anne