sgio.plot_model_matrix#
- sgio.plot_model_matrix(model, kind: str = 'stiffness', fig=None, ax=None, cmap: str = 'RdBu_r', annotate: bool = True, font_size: int = 8, symlog: bool = True, title: str | None = None, **kwargs)#
Plot the stiffness / compliance matrix of a structural model.
High-level convenience wrapper that resolves the requested matrix and its physical row/column labels from
modeland renders it viaplot_matrix(). Supports linear-elastic (solid), beam, and plate/shell models.- Parameters:
model (object) – A linear-elastic, beam, or plate/shell model instance.
kind ({'stiffness', 'compliance'}, optional) – Which matrix to plot. Default
'stiffness'.fig (matplotlib.figure.Figure, optional) – Figure to draw on. A new one is created when omitted.
ax (matplotlib.axes.Axes, optional) – Axes to draw on. A new one is created when omitted.
cmap (str, optional) – Colormap name. Default
'coolwarm'(diverging, neutral at 0).annotate (bool, optional) – Annotate each cell with its value. Default
True.font_size (int, optional) – Annotation font size. Default
8.symlog (bool, optional) – Use a symmetric-log color scale. Default
True.title (str, optional) – Axes title. Defaults to a description built from the model/kind.
**kwargs – Forwarded to
plot_matrix().
- Returns:
The figure and axes containing the heatmap.
- Return type:
(matplotlib.figure.Figure, matplotlib.axes.Axes)