**2. FEM/FDM model**

MEMS typically involve multiple energy domains such as kinetic energy, elastic deformation, electrostatic or magneto static stored energy and fluidic interactions. The difficulty in the modeling of MEMS devices is mainly caused by the tight coupling between the multiple energy domains. Individual physical effects are governed by partial differential equations (PDE), typically nonlinear. When these equations become coupled, the computational challenges of highly meshed numerical simulation become formidable.

FEM relies on highly localized interpolation functions (or *mesh element functions*) for approximation of the solution of PDE. These mesh element functions are generated by meshing the domain of interest and parameterize the desired solution locally on each mesh element. This parameterized solution converts a continuous (PDE) problem to a coupled system of ordinary differential equations (ODE) that can be integrated in time. The resulting ODE system usually has many degrees of freedom (perhaps **several variables per mesh element**). If a fine mesh is required, the problem size grows rapidly, with a corresponding rapid growth in computational cost for explicit dynamic simulation. Consequently, it is very expensive to use FEM model in system-level simulations during MEMS iterative design*.* As a result, FEM models are mostly used to analyze the performance of MEMS components and to couple their multiphysics effects.

By reading ANSYS binary FULL file it is possible to assemble a MEMS component statespace model in the form of first order systems or second order ordinary differential equations (ODE)

$$E\_r z' + A\_r z = B\_\eta f \,, \qquad \text{Y} = \text{C}\_r z \tag{1}$$

$$\mathbf{M}\mathbf{x}^{\prime\prime} + \mathbf{D}\mathbf{x}^{\prime} + \mathbf{K}\mathbf{x} = \mathbf{B}\mathbf{f} \quad \text{,} \quad \mathbf{Y} = \mathbf{Q}^{\mathrm{\mathrm{tr}}}\mathbf{x} + \mathbf{R}^{\mathrm{\mathrm{tr}}}\mathbf{x}^{\prime} \tag{2}$$

where *Ar, Er ,Cr, Br, M ,D, K, B, C-* are the system matrices, *Br, B* are the input and the *Cr, C* output matrices, *f* is input force. In mechanics matrices *M, D* and *K* are known as the *mass, damping* and *stiffness* matrices correspondingly. Usually damping is included in the model as Rayleigh damping. The damping matrix *D* is computed as a linear combination of the stiffness *K* and the mass *M* matrices:

$$\mathbf{D} \mathbf{=} \mathbf{u} \mathbf{M} + \boldsymbol{\beta} \,\, \mathbf{K}\_{\prime}$$

where *α, β* are constant coefficients*.*

In (1) the state space vector *z* is defined through the unknowns deflections *u*(*x,t)* and pressures *p(x,y,t)* into the node points being automatically generated in MEMS structure*:*

$$z = [\boldsymbol{u}\_1 \dots \boldsymbol{u}\_N \frac{\partial \boldsymbol{u}\_1}{\partial t} \dots \frac{\partial \boldsymbol{u}\_N}{\partial t} \ \boldsymbol{p}\_{11} \dots \boldsymbol{p}\_{MN}]^T \tag{3}$$

By defining

$$E\_r = \begin{bmatrix} D & M \\ M & 0 \end{bmatrix} \quad A\_r = \begin{bmatrix} K & 0 \\ 0 & -M \end{bmatrix} \quad B\_r = \begin{vmatrix} B \\ 0 \end{vmatrix} \quad C\_r = \begin{vmatrix} \mathcal{Q} \\ R \end{vmatrix} \quad z = \begin{vmatrix} \mathbf{x'} \\ \mathbf{x''} \end{vmatrix} \tag{4}$$

second equations (2) can be transfer to the first (1).

The FULL file contains all the information about the system: the system element matrices, Dirichlet boundary conditions, equation constrain and the load vector. It is generated using ANSYS partial solver, which enables to assemble system element matrices for the desired analysis without solving them and it therefore computationally fast. The speed of the reading operation has been optimized taking into account that the element matrices are sparse. The load vector directly gives the matrix-vector product *Bf* and thus describes the distribution of all loads being applied. In order to obtain the *B* matrix, and thus being able to modify the inputs singularly, it is necessary to repeat the partial solution for each input of interest.
