equilibrium_matrix

compas.numerical.equilibrium_matrix(C, xyz, free, rtype='array')[source]

Construct the equilibrium matrix of a structural system.

Parameters
  • C (array-like) – Connectivity matrix (m x n).

  • xyz (array-like) – Array of vertex coordinates (n x 3).

  • free (list) – The index values of the free vertices.

  • rtype ({‘array’, ‘csc’, ‘csr’, ‘coo’, ‘list’}) – Format of the result.

Returns

array-like – Constructed equilibrium matrix.

Notes

Analysis of the equilibrium matrix reveals some of the properties of the structural system, its size is (2ni x m) where ni is the number of free or internal nodes. It is calculated by

\[\begin{split}\mathbf{E} = \left[ \begin{array}{c} \mathbf{C}^{\mathrm{T}}_{\mathrm{i}}\mathbf{U} \\[0.3em] \hline \\[-0.7em] \mathbf{C}^{\mathrm{T}}_{\mathrm{i}}\mathbf{V} \end{array} \right].\end{split}\]

The matrix of vertex coordinates is vectorised to speed up the calculations.

Examples

>>> C = connectivity_matrix([[0, 1], [0, 2], [0, 3]])
>>> xyz = [[0, 0, 1], [0, 1, 0], [-1, -1, 0], [1, -1, 0]]
>>> equilibrium_matrix(C, xyz, [0], rtype='array')
array([[ 0.,  1., -1.],
       [-1.,  1.,  1.]])