Author Topic: the update of reference configuration at each time step  (Read 3856 times)

leeyongjae89

  • Jr. Member
  • **
  • Posts: 24
the update of reference configuration at each time step
« on: April 10, 2021, 05:51:23 PM »
Dear Professors and FEAP team,

If I know rightly, the variable "xl" contains the reference configuation (t=0), and unchanged throughout the simulation. However, I'd like to modify the code so that the variable "xl" contains the configuration at t=n, instead of the configuration at t=0. So, the variable "xl" that contains the configuration at t=n is used to calculate the configuration at the next time step, "t=n+1". And then the newly calculated configuration at t=n+1 is stored to "xl", which is used to calculate the configuration at t=n+2

So, could you let me know how I can access the variable "xl" in order to replace it with the current geometry?, because I think this is the first step.
Or, could you give me some advice on the approach that I explained above?

Thank you so much in advance.

Prof. R.L. Taylor

  • Administrator
  • FEAP Guru
  • *****
  • Posts: 2649
Re: the update of reference configuration at each time step
« Reply #1 on: April 10, 2021, 07:36:40 PM »
You only need to do this in your element routine where you have both xl(ndm,nen) and ul(ndf,nen,*).  To obtain 'nen' you need to  include 'cdata.h'.   It is best if you add an array to store the coordinates at t_n.  Then set this to:

xn(1:ndm,1:nen) = xl(1:ndm,1:nen) + ul(1:ndm,1:nen,1) - ul(1:ndm,1:nen,2)

You use the 'xn(:,:)' array for your configuration at t_n.

The array ul(:,:,1) has the current solution at t_n+1 and the array ul(:,:,2) has the change in displacement between t_n and t_n+1, thus, the difference of the two displacement arrays will give you displacements at t_n.

Do not make changes outside an element routine, that could cause serious problems.
« Last Edit: April 10, 2021, 11:16:59 PM by Prof. S. Govindjee »