随着国内各种动力弹塑性的兴起,对动力时程分析中提到的方法多有各种说法,对于设计院的人来说更是云里雾里的多,今天看到一篇文章讲得不错,于是结合下自己的看法大概说说显式和隐式动力分析的差别。

首先简单的解释下:

显式分析:用上一步的结果和当前步的结果计算下一步的计算结果。有条件收敛,要求时间步较小。通常做动力分析用这种方法。

隐式分析:用当前步结果和下一步未知结果反复迭代下一步结果,必须通过迭代得到。无条件收敛。是一种能量平衡的结果。通常做静力分析用这种方法。

两者均是求解动力方程,只是显式求解的每一步不是绝对平衡,而隐式求解是在每一步都是近似绝对平衡的。

显式算法:

显式算法最大优点是有较好的稳定性。

动态显式算法采用动力学方程的一些差分格式(如广泛使用的中心差分法、线性加速度法等),不用直接求解切线刚度,不需要进行平衡迭代,计算速度快,时间步长只要取的足够小,一般不存在收敛性问题。 显式算法不需要迭代,也不需要组集总刚,因此需要的内存也比隐式算法要少。并且数值计算过程可以很容易地进行并行计算,程序编制也相对简单。但显式算法要求质量矩阵为对角矩阵,而且只有在单元级计算尽可能少时速度优势才能发挥, 因而往往采用减缩积分方法,容易激发沙漏模式,影响应力和应变的计算精度。”

静态显式法基于率形式的平衡方程组与Euler向前差分法,不需要迭代求解。由于平衡方程式仅在率形式上得到满足,所以得出的结果会慢慢偏离正确值。为了减少相关误差,必须每步使用很小的增量。这个方法目前应用比较少。

总之显式方法不需要迭代是个利好,每步的时间基本是固定的,可以根据设置的波长和分析步长估算出计算总时间。根据上面论述可以看出,一般多采用动态显式,一般有中心差分法、线加速度法等,也有人列出精细积分法为显式算法。其中中心差分法的变种也非常多,有蛙跳式、向后差分式等。由于其算法上当前步结果只跟上一步结果有关,因此只要对角化质量矩阵和阻尼矩阵即可不需要联立动力方程,可解耦到每个单元的差分公式,大大简化了计算过程。但为了保持好的精度,需要当前步和上两步之间尽量是线性关系,因此需要很小的时间步长,通常算法也就用于高速冲击、碰撞上,这些运动可天然的弥补其步长短的问题,但现在随着计算机硬件的能力提升,也开始用到普通运动求解上。

隐式算法 :

在每一增量步内都需要对静态平衡方程进行迭代求解,并且每次迭代都需要求解大型的线性方程组,这以过程需要占用相当数量的计算资源、磁盘空间和内存。该算法中的增量步可以比较大,至少可以比显式算法大得多,但是实际运算中上要受到迭代次数及非线性程度的限制,需要取一个合理值。通常在一个时间增量下,隐式算法在弹塑性后期此时刚度比较奇异了,难以收敛,也就需要采用二分法把当前的分析步折半继续解方程,并且不断二分下去直到方程求解完成,所以隐式算法时在前面计算速度还不错,但越往后越慢,时间也是不可估量的,可能在地震波20s就算不下去了等等。但是隐式算法有个好处就是只要算了步数其结果一般一定是正确的,不会像显式那样虽然算完了,其结果可能是发散的。

隐式算法在求解运动方程时是当前步结果除了更上一步有关外还跟当前步有关,因此不能解耦大型方程组,需要组集刚度,用得多是newmark法和wilson-theta法,其中的beta、alpha和theta值的确定可改变方法的稳定性、计算效率等。隐式求解法的最大优点是它具有无条件稳定性,即时间步长可以任意大。

计算时间:

上面大致说了下,不过一般经验表明:

使用显式方法,计算成本消耗与单元数量成正比,并且大致与最小单元的尺寸成反比

应用隐式方法,经验表明对于许多问题的计算成本大致与自由度数目的平方成正比,这是在保证能计算完的情况下, 因此如果网格是相对均匀的,随着模型尺寸的增长,显式方法表明比隐式方法更加节省计算成本。

通常认为两者有此区别:

=============================================================

​ 显式算法 隐式算法

-————————————————————

(01)适用问题 动力学(动态) 静力学(静态)

(02)阻尼 人工阻尼 数值阻尼

-————————————————————

(03)每步求解方法 矩阵乘法 线性方程组

(04)大矩阵(总刚) 否 是

(05)数据存贮量 小 大

(06)每步计算速度 快 慢

(07)迭代收敛性 无 有

(08)确定解 有确定解 可能是病态无确定解

-———————————————————–

(09)时步稳定性 有条件 无条件

(10)时间步 小 大

(11)计算精度 低 高

=============================================================

从上面大致可以出,有些认识只是表象而已,其中(1)是明显的错误,因为两种方法都可以用于动力学和静力学问题,只是一种选择而已,(2)也是错误的,阻尼的选择不是算法本身,而是求解需求。(03)是算法的本质,也决定了(04)(05)(06)(07)(08),这是算法的特点所在,04~08并非算法本身的特点而是每一步求解方法的特征。同理(09)是算法的特点,决定了(10)(11)。

过(03)(09)可以得到两种方法的计算特点,显式算法是每一步求解为矩阵乘法,时间步选择为条件稳定;隐式算法是每一步求解为线性方程组求解,时间步选择为无条件稳定。

附加说明:

{1)求解线性静力学问题,虽然求解线性方程组,但是没有时步的关系,所以不应将其看作隐式算法。而是静力学隐式方程求解问题。

(2)求解非线性静力学问题,虽然求解过程需要迭代,或者是增量法,但是没有明显的时步问题,所以不应将其看作隐式算法。仍归结为隐式方程求解问题

3)静态松弛法,可以认为是将动力学问题看作静力学问题来解决,每一步达到静力平衡,需要数值阻尼。

4)动态松弛法,可以认为是将静力学问题或者动力学问题,分为时步动力学问题,采用向后时步迭代的思想计算。对于解决静力学问题时,需要人工阻尼。

最后说下软件:

abaqus中是既有隐式也有显式算法的,隐式采用的是改进的newmark法,是HHT方法,显式采用的是中心差分法。目前来说abaqus吧这两种方法都做到了极致

LS-dyna:显式算法的鼻祖,有隐式算法和显式算法,newmark wilson(这个不确定)和中心差分

sausage:采用中心差分法,没有隐式算法


以下 内容转自abaqus版面的总结:

显式一般用于动态问题的分析, 对于大型问题, 或复杂的接触情况可能需要几百万的增量步的计算, 所用时间可能是几天或更长. 而隐式的增量步长要长得多, 一般用于静态问题的求解.
显式算法别explicit method use direct iterative method, which has small cost in each
time increment but require relatively small increment. Abaqus pre-determine
the time increment based on wave propagation speed and minimum mesh
size. This method could be efficient for highly nonlinear and contact problem.
For quasi-static problem, properly adjust model parameter as density and total
time is important to achieve good computation time.

standard-隐式算法Implicit method use newton method for iteration, which means high cost for
each time increment but could mean large time increment. Convergence
could be a problem in this case. It could be efficient for linear and some nonlinear problem. More materials, elements and procedures are available in standard.

所谓显式和隐式,是指求解方法的不同,即数学上的出发点不一样。并不是说显式只能求动力学问题,隐式只能求静力学问题,只是求解策略不通。
显式求解是对时间进行差分,不存在迭代和收敛问题,最小时间步取决于最小单元的尺寸。过多和过小的时间步往往导致求解时间非常漫长,但总能给出一个计算结果。解题费用非常昂贵。因此在建模划分网格时要非常注意。

隐式求解和时间无关,采用的是牛顿迭代法(线性问题就直接求解线性代数方程组),因此存在一个迭代收敛问题,不收敛就的不到结果。

两者求解问题所耗时间的长短理论上无法比较。实际应用中一般感觉来说显式耗时多些。
由于两者解题的出发点,所以一般来说显式用于求解和时间相关的动力学问题。隐式用来求解和时间无关的静力学问题。但也不是绝对的。比如,用隐式求解时,为了克服迭代不收敛,改用显式算,但是要多给点时间,这样虽然克服了不收敛的问题,但是求解的时间费用也是相当客观的。另外,隐式也可以求解动力学问题。abaqus就有一个用隐式积分求解动力学的选项。

n+1个时间步的量可以由第n个时间步的量直接求得,称为显式
例如:
an+1=bn+cn
bn+1=an+cn
cn+1=an+bn
优点是计算量比较小
缺点是有累积误差

n+1个时间步的量不可以由第n个时间步的量直接求得,称为隐式
例如:
an+1+bn+1=cn
bn+1+cn+1=an
an+1+cn+1=bn
优点是计算量比较大,需要通过方程组求解
缺点是没有累计误差

显示算法不进行刚度矩阵的重新计算,只在开始形成以后不变,是时间的显示积分。而隐式算法没进行一次计算都要重新计算刚度矩阵,然后进行迭代,是无条件收敛的。

Q: What is the difference between implicit and explicit dynamics? (Difference between regular ANSYS and ANSYS/LS-DYNA?)
A:For computers, matrix multiplication isn’t difficult. Matrix inversion is the more computationally expensive operation. The equations we solve in nonlinear, dynamic analyses in ANSYS and in LS-DYNA are:
[M]{a} + [C]{v} + [K]{x} = {F}

Hence, in ANSYS, we need to invert the [K] matrix when using direct solvers (frontal, sparse). Iterative solvers use a different technique from direct solvers which I won’t get into here, but, basically, the inversion of [K] is the CPU-intensive operation for any ‘regular’ ANSYS solver, direct or iterative. We then can solve for displacements {x}. Of course, with nonlinearities, [K(x)] is also a function of {x}, so we need to use Newton-Raphson method to solve for [K] as well. (material nonlinearities and contact get thrown into [K(x)])

In LS-DYNA, on the other hand, we solve for accelerations {a} first. Now, in LS-DYNA, we assume that the mass matrix is lumped. This basically forces us to use lower-order elements – that is why, for all explicit dynamics codes (ANSYS/LS-DYNA, MSC.Dytran, ABAQUS/Explicit), we can only use lower-order elements. Also, the benefit of doing lumped mass is that, if we solve for {a}, then [M], if lumped, is a diagonal mass matrix. This means that inversion of [M] is trivial (diagonal terms only) – another way to view it is that we now have N set of uncoupled equations. Hence, we just have to do matrix multiplication, which isn’t nearly as CPU-intensive. It’s also worthwhile to note that [K] does not need to be inverted, and accounting for material nonlinearties and contact is easier.

Now, as for time integration, the terms ‘implicit’ and ‘explicit’ refer to time integration – for example, if you might recall something like backward Euler method, that is an example of an implicit time integration scheme, whereas central difference or forward Euler are examples of explicit time integration schemes. It relates to when you calculate the quantities – either based on current or previous time step. In any case, this is a very simplified explanation, and the main point is that implicit time integration is unconditionally stable, whereas explicit time integration is not (there is a critical time step your delta(t) needs to be smaller than). As a result, ‘regular’ ANSYS allows for much larger time steps, but LS-DYNA requires much tinier time steps. Also, LS-DYNA requires very tiny steps, so that is why it is usually good for impact/short-duration events, not usually things like maybe creep where the model’s time scale may be on the order of hours or more.

In summary:
‘Regular’ ANSYS uses implicit time integration. This means that {x} is solved for, but we need to invert [K], which means that each iteration is computationally expensive. However, because we solve for {x}, it is implicit, and we don’t need very tiny timesteps (i.e., each iteration is expensive, but we usually don’t need too many iterations total). The overall timescale doesn’t affect us much (although there are considerations of small enough timesteps for proper momentum transfer, capturing dynamic response, etc., but I’m getting ahead of myself).
ANSYS/LS-DYNA uses explicit time integration. This means that {a} is solved for, and inverting [M] is trivial – each iteration is very efficient. However, because we solve for {a}, then determine {x}, it is explicit, and we need very small timesteps (many, many iterations) to ensure stability of solution since we get {x} by calculating {a} first. (i.e., each iteration is cheap, but we usually need many, many iterations total)

Anyways, this is a very simplified (maybe over-simplified) explanation, but I hope it may help clear the distinction between these two methods. For very high-impact, nonlinear events of short duration, ANSYS/LS-DYNA is usually the better choice. For events which are of long duration, ‘regular’ ANSYS is usually the preferred method. For quasi-static events, there are ways in which you can use either solution method (e.g., mass-scaling for explicit). However, you can solve most problems with either method – I’m just referring to which ones are more efficient. [Note that I haven’t talked about mode-superposition transient analyses, which is an efficient subset of ‘regular’ ANSYS for mostly linear behavior, but it is efficient because we uncouple the equations in the frequency domain rather than time domain, but I’ve probably digressed enough already…]

隐式与显示最重要的区别在于是否对于整体刚度矩阵求逆,而这一过程也就决定了两者对于模型的要求,由于隐式算法要求逆,所以计算时要求整体刚度阵不能奇异,而显示就没有这一问题啦。而对于动力学问题来将,从数学上看它属于微分方程中初边值问题,如果采用显示求解,很容易发生总纲奇异的问题,所以很多时候求解动力学问题都采用explicit来做。但是explicit也有自身的问题,由于要对于时间积分,如果时间积分步长取得太长,计算结果很有可能是不精确的,但是太短了,还会使得计算时间大幅度增加,并且动力学问题中还存在应力波效应影响,所以使得显示问题更为复杂,但是abaqus中提供了最小单元尺寸限制时间步长的方法,还是可以很好地解决这问题。

显式和隐式的区别很多人都讲了,说一下计算效率的问题,隐式需要解线性方程组,而对于显式,当我们使用集中质量矩阵时,不需要求解线性方程组,所以对于大规模问题,虽然显式的时间步长较小,但显式会比隐式更有效率。