Week - 8 Mass Scaling
Aim-
Use mass scaling to reduce the runtime of a model and ensure the stability of mass scaling for the given model.
Objective-
We are to utilize the concept of mass scaling to alter the run time of the provided file by editing the DT and TSSFAC parameters through trial and error using the explicit solver. A histogram is then plotted to compare the run times of said trials. The mass scaling is not supposed to go beyond 8%.
The same model is then run the same model using the implicit solver and the run times are to be compared between explicit and implicit solve cases.
MODEL IMAGE

BACKGROUND
Mass-scaling refers to a technique whereby nonphysical mass is added to a structure in order to achieve a larger explicit timestep.
Any time nonphysical mass is added to increase the timestep in a dynamic analysis, the results are affected. Sometimes the effect is insignificant and in those cases adding nonphysical mass is justifiable. Examples of such cases may include the addition of mass to just a few small elements in a noncritical area or quasi-static simulations where the velocity is low and the kinetic energy is very small relative to the peak internal energy. In the end, it's up to the judgement of the analyst to gauge the effect of mass scaling.
One can employ mass scaling in a selective manner by artificially increasing the material density of the parts you want to mass-scale. The manual form of mass scaling is done independently of the automatic mass scaling invoked with DT2MS in *CONTROL_TIMESTEP.
When DT2MS is less than zero, mass is added only to those elements whose timestep would otherwise be less than |DT2MS|. By adding mass to these elements, their timestep becomes equal to |DT2MS|
When DT2MS is greater than zero, LS-DYNA adds mass to elements whose DT is below |DT2MS| and “removes” mass from elements whose DT is greater than zero.
An infinite number of combinations of TSSFAC and DT2MS will give the same product, i.e., timestep but the added mass will be different for each of those combinations. The trend is that the bigger |DT2MS| (and the smaller TSSFAC while TSSFAC*|DT2MS|=const), the greater the added mass. In return, stability may improve as TSSFAC is reduced (just as in non-mass-scaled solutions). If stability is a problem with the default TSSFAC of 0.9, try 0.8 or 0.7. If TSSFAC is reduced, |DT2MS| can be increased proportionally so that their product, and hence timestep, is unchanged.
PROCEDURE
We shall be using mass scaling to optimize the run time. This is done by trial and error, where we shall be using varying DT2MS and TSSFAC values to ensure that the run time is optimized without crossing the 8% mass increase limit. We shall be carrying this out for both explicit and implicit methods.
To change the DT2MS and TSSFAC values, we shall be accessing the *CONTROL_TIMESTEP card of the keyword file as shown:

Explicit Analysis
We shall first run the file as it is. It has the following values: DT2MS = -3.5E-05 and TSSFAC = 0.9. We shall take note of the time taken as a result.
Trial 1
DT2MS = -3.5E-05 & TSSFAC = 0.9

Simulation time: 231 hours 9 minutes
Percentage increase: 0%
Trial 2

DT2MS = -4.5E-05 & TSSFAC = 0.9

Simulation time: 65 hours 21 minutes
Percentage increase: 0 %
Trial 3

DT2MS = -5.5E-05 & TSSFAC = 0.9

Simulation time: 36 hours 43 mins
Percentage increase: 0.01%
Trial 4

DT2MS = -7.5E-05 & TSSFAC = 0.9

Simulation time: 33 hours 40 mins
Percentage increase: 0.372%
Trial 5

DT2MS = -9.00E-05 & TSSFAC = 0.9

Simulation time: 25 hours 48 mins
Percentage increase: 2.74%
Trial 6

DT2MS = -1.05E-04 & TSSFAC = 0.9

Simulation time: 19 hours 43 mins
Percentage increase: 10.74%
Trial 7

DT2MS = -1.0E-04 & TSSFAC = 0.9

Simulation time: 23 hours 34 mins
Percentage increase: 6.42%
Trial 8

DT2MS = -1.0E-04 & TSSFAC = 0.8

Simulation time: 18 hours 56 mins
Percentage increase: 6.42%
Trial 9

DT2MS = -1.07E-04 & TSSFAC = 0.8

Simulation time: 20 hours 31 mins
Percentage increase: 14.55%
Trial 10

DT2MS = -1.03E-04 & TSSFAC = 0.8

Simulation time: 27 hours 2 mins
Percentage increase: 8.066%
Trial 11

DT2MS = -1.03E-04 & TSSFAC = 0.9

Simulation time: 18 hours 47 mins
Percentage increase: 8.066%
Trial 12

DT2MS = -1.01E-04 & TSSFAC = 0.9

Simulation time: 24 hours 30 mins
Percentage increase: 6.93%
Trial 13

DT2MS = -1.02E-04 & TSSFAC = 0.9

Simulation time: 16 hours 40 mins
Percentage increase: 7.477%
Trial 14

DT2MS = -1.025E-04 & TSSFAC = 0.9

Simulation time: 19 hours 3 mins
Percentage increase: 7.766%
Trial 15

DT2MS = -1.027E-04 & TSSFAC = 0.8

Simulation time: 21 hours 23 mins
Percentage increase: 7.884%
Trial 16

DT2MS = -1.028E-04 & TSSFAC = 0.8

Simulation time: 18 hours 25 mins
Percentage increase: 7.944%
Implicit Analysis
The keywords CONTROL_IMPLICIT_AUTO, CONTROL_IMPLICIT_SOLVER, CONTROL_IMPLICIT_GENERAL, CONTROL_IMPLICIT_SOLUTION are added with the values as follows to initiate implicit analysis.




The DT2MS value in the CONTROL_TIMESTEP card is altered as well, just as we did for the explicit analyses trials, except we shall be running two trials only.
Trial 1
DT2MS = -3.5E-05 and TSSFAC= 0.9

Simulation time: 30 mins 32 seconds
Trial 2
DT2MS = -1.028E-04 and TSSFAC= 0.9

Simulation time: 31 mins 52 seconds
RESULTS
Explicit Trials

The following graph shows how the change in the DT2MS value affected the simulation time:

As we can see, the simulation time for the first trial for a standard DT2MS value of -3.5E-05 was the highest, taking 832000 seconds, or a little over 231 hours which is an extremely large number. Decreasing it to -4.5E-5 drastically reduced the simulation time, and it stabilized from there. Time taken is comparable from trials 3 to 16, with the 13th trial (with a DT2MS of -1.02E-04) taking 60000 seconds (16 hours and 40 minutes). Going by the limited number of trials using TSSFAC 0.8 & 0.9, it seems that TSSFAC 0.8 produces unstable results, considering it produces a lower simulation time for DT2MS -1.0E-04 whereas it increases the simulation time for DT2MS -1.03E-04. So, it's good to stick with the default TSSFAC of 0.9.
The following graph shows the mass increase percentage with the change in DT2MS:

The obvious thing to note is changing the TSSFAC value does not initiate change in mass. To maintain an exact 8% mass increase, the DT2MS values are changed very slightly in the last few trials to get as close as possible to the threshold without affecting the simulation time. It is noted that the optimum value would be around the -1.028E-04 mark, which is taken as the last trial's DT2MS value.
Implicit Trials

The first thing to note is that there is a massive reduction in simulation time in the implicit trials, compared to the explicit ones. The quickest based on the two implicit trials is around 30 minutes and 32 seconds. The simulation time for the next trial was also similar. The difference between the two trials was that the DT2MS values were changed. But they did not have an effect on the simulation time. This is a reiteration of the fact that mass scaling is a concept used in explicit analysis only.
Conclusion-
Mass scaling by varying the values of DT2MS and TSSFAC using a trial and error method was carried out on the provided model. Out of the trials for the explicit analysis, a DT2MS value of -1.028E-04 produced the least simulation time without going past the threshold of an 8% mass increase, at 66,300 seconds (18 hours 25 minutes). The same was done for implicit analysis but it was established that those values have no effect on the simulation time, like in explicit analysis. Furthermore, the implicit analysis trials had much better simulation times, coming at around 30 minutes.
Learning output-
1- In this challenge, I learned about the time step and how we can modify it according to the type of simulation.
2- This challenge, taught me how to use the mass scaling option to reduce the simulation time and the theory behind it.