topotherm.plotting ================== .. py:module:: topotherm.plotting .. autoapi-nested-parse:: Sone standard plotting functions for the district heating network. Functions --------- .. autoapisummary:: topotherm.plotting.district topotherm.plotting.plot_networkx Module Contents --------------- .. py:function:: district(matrices, diameter = [0], isnot_init = False) Plot the district heating network with the given matrices. :param matrices: Matrices of the district heating network with keys: - ``a_i`` : Incidence matrix (rows: nodes, columns: edges). - ``a_p`` : Adjacency matrix for the producers (rows: nodes, columns: supply IDs). - ``a_c`` : Adjacency matrix for the consumers (rows: nodes, columns: consumer IDs). - ``l_i`` : Length of edges. - ``position`` : ``(x, y)`` coordinates of the nodes in the network. :type matrices: dict :param diameter: Inner diameter of the pipes. Default is ``[0]``. :type diameter: list of float, optional :param isnot_init: Whether to plot after optimization (``True``) or before (``False``). Default is ``False``. :type isnot_init: bool, optional :returns: Figure of the district heating network. :rtype: plt.Figure .. py:function:: plot_networkx(n) Plot a NetworkX graph. :param n: Input NetworkX graph. :type n: networkx.Graph :returns: Figure of the NetworkX graph. :rtype: matplotlib.figure.Figure