Ë
    ´2Úií_  ã                   ó  — d Z ddlZddlZddlZddlmZ ddlmZ ddl	m
Z ddlmZ  G d„ d«      Z ej                   d	«       G d
„ d«      «       Z G d„ de«      Z G d„ de«      Zd„ Z G d„ de«      Z G d„ de«      Zd„ Z	 dd„Zy)zJ
Helper classes to adjust the positions of multiple axes at drawing time.
é    N)Ú_api)ÚSubplotSpecé   )Ú	axes_sizec                   óî   — e Zd ZdZ	 dd„Zd„ Zd„ Zd„ Zd„ Zd„ Z	d	„ Z
d
„ Zd„ Zd„ Zd„ Zd„ Zdd„Zd„ Zd„ Zd„ Zd„ Zed„ «       Zed„ «       Zd d„Z ej4                  dd¬«      d!d„«       Zd„ Zd„ Zd"d„Zy)#ÚDivideraQ  
    An Axes positioning class.

    The divider is initialized with lists of horizontal and vertical sizes
    (:mod:`mpl_toolkits.axes_grid1.axes_size`) based on which a given
    rectangular area will be divided.

    The `new_locator` method then creates a callable object
    that can be used as the *axes_locator* of the axes.
    Nc                 ó¤   — || _         || _        || _        || _        || _        | j                  |«       || _        d| _        d| _        d| _	        y)aã  
        Parameters
        ----------
        fig : Figure
        pos : tuple of 4 floats
            Position of the rectangle that will be divided.
        horizontal : list of :mod:`~mpl_toolkits.axes_grid1.axes_size`
            Sizes for horizontal division.
        vertical : list of :mod:`~mpl_toolkits.axes_grid1.axes_size`
            Sizes for vertical division.
        aspect : bool, optional
            Whether overall rectangular area is reduced so that the relative
            part of the horizontal and vertical scales have the same scale.
        anchor : (float, float) or {'C', 'SW', 'S', 'SE', 'E', 'NE', 'N', 'NW', 'W'}, default: 'C'
            Placement of the reduced rectangle, when *aspect* is True.
        r   N)
Ú_figÚ_posÚ_horizontalÚ	_verticalÚ_anchorÚ
set_anchorÚ_aspectÚ
_xrefindexÚ
_yrefindexÚ_locator)ÚselfÚfigÚposÚ
horizontalÚverticalÚaspectÚanchors          ú[/var/www/html/acx/venv/lib/python3.12/site-packages/mpl_toolkits/axes_grid1/axes_divider.pyÚ__init__zDivider.__init__   sP   € ð( ˆŒ	ØˆŒ	Ø%ˆÔØ!ˆŒØˆŒØ�‰˜ÔØˆŒØˆŒØˆŒØˆ�ó    c                 óŒ   — t        j                  | j                  «       D �cg c]  }|j                  |«      ‘Œ c}«      S c c}w ©N)ÚnpÚarrayÚget_horizontalÚget_size©r   ÚrendererÚss      r   Úget_horizontal_sizeszDivider.get_horizontal_sizes;   s1   € Ü�x‰x°t×7JÑ7JÓ7LÖM°!˜Ÿ™ HÕ-ÒMÓNÐNùÒMó   ¢Ac                 óŒ   — t        j                  | j                  «       D �cg c]  }|j                  |«      ‘Œ c}«      S c c}w r   )r    r!   Úget_verticalr#   r$   s      r   Úget_vertical_sizeszDivider.get_vertical_sizes>   s1   € Ü�x‰x°t×7HÑ7HÓ7JÖK°!˜Ÿ™ HÕ-ÒKÓLÐLùÒKr(   c                 ó   — || _         y)z¶
        Set the position of the rectangle.

        Parameters
        ----------
        pos : tuple of 4 floats
            position of the rectangle that will be divided
        N©r   )r   r   s     r   Úset_positionzDivider.set_positionA   s   € ð ˆ�	r   c                 ó   — | j                   S )z%Return the position of the rectangle.r-   ©r   s    r   Úget_positionzDivider.get_positionL   s   € à�y‰yÐr   c                 óþ   — t        |t        «      r7t        j                  t        j
                  j                  |¬«       || _        yt        |t        t        f«      rt        |«      dk7  rt        d«      ‚|| _        y)a�  
        Parameters
        ----------
        anchor : (float, float) or {'C', 'SW', 'S', 'SE', 'E', 'NE', 'N', 'NW', 'W'}
            Either an (*x*, *y*) pair of relative coordinates (0 is left or
            bottom, 1 is right or top), 'C' (center), or a cardinal direction
            ('SW', southwest, is bottom left, etc.).

        See Also
        --------
        .Axes.set_anchor
        )r   é   zanchor must be str or 2-tupleN)Ú
isinstanceÚstrr   Úcheck_in_listÚmtransformsÚBboxÚcoefsÚtupleÚlistÚlenÚ	TypeErrorr   )r   r   s     r   r   zDivider.set_anchorP   sa   € ô �fœcÔ"Ü×Ñœ{×/Ñ/×5Ñ5¸fÕEð ˆ�ô ˜F¤U¬D MÔ2´c¸&³kÀQÒ6FÜÐ;Ó<Ð<Øˆ�r   c                 ó   — | j                   S )zReturn the anchor.)r   r0   s    r   Ú
get_anchorzDivider.get_anchord   ó   € à�|‰|Ðr   c                  ó   — y r   © r0   s    r   Úget_subplotspeczDivider.get_subplotspech   s   € Ør   c                 ó   — || _         y)z—
        Parameters
        ----------
        h : list of :mod:`~mpl_toolkits.axes_grid1.axes_size`
            sizes for horizontal division
        N©r   )r   Úhs     r   Úset_horizontalzDivider.set_horizontalk   s   € ð ˆÕr   c                 ó   — | j                   S )zReturn horizontal sizes.rE   r0   s    r   r"   zDivider.get_horizontalt   s   € à×ÑÐr   c                 ó   — || _         y)z•
        Parameters
        ----------
        v : list of :mod:`~mpl_toolkits.axes_grid1.axes_size`
            sizes for vertical division
        N©r   )r   Úvs     r   Úset_verticalzDivider.set_verticalx   s   € ð ˆ�r   c                 ó   — | j                   S )zReturn vertical sizes.rJ   r0   s    r   r*   zDivider.get_vertical�   s   € à�~‰~Ðr   c                 ó   — || _         y)zE
        Parameters
        ----------
        aspect : bool
        N©r   ©r   r   s     r   Ú
set_aspectzDivider.set_aspect…   s   € ð ˆ�r   c                 ó   — | j                   S )zReturn aspect.rO   r0   s    r   Ú
get_aspectzDivider.get_aspect�   r@   r   c                 ó   — || _         y r   ©r   )r   r   s     r   Úset_locatorzDivider.set_locator‘   s	   € Ø ˆ�r   c                 ó   — | j                   S r   rU   r0   s    r   Úget_locatorzDivider.get_locator”   s   € Ø�}‰}Ðr   c                 ór   — | j                   €| j                  «       S | j                  ||«      j                  S r   )r   r1   Úbounds)r   Úaxr%   s      r   Úget_position_runtimezDivider.get_position_runtime—   s2   € Ø�=‰=Ð Ø×$Ñ$Ó&Ð&à—=‘=  XÓ.×5Ñ5Ð5r   c                 óB   — | j                  d«      \  }}|r||z
  |z  S dS )Nr   )Úsum)ÚsizesÚtotalÚrel_sumÚabs_sums       r   Ú_calc_kzDivider._calc_k�   s,   € ð !Ÿ9™9 Q›<Ñˆ�Ù.5�˜‘ 7Ñ*Ð<¸1Ð<r   c                 ó<   — t        j                  dg| |dgz  ¢«      S )Nr   r   )r    Úcumsum)r_   Úks     r   Ú_calc_offsetszDivider._calc_offsets¤   s#   € ô �y‰y˜!Ð/˜u¨¨1 v™~Ð/Ó0Ð0r   c                 óÒ   — |€|dz   }|€|dz   }| j                   }| j                  }t        j                  | j                  ||z
  ||z
  ||z
  ||z
  «      }| j
                  |_        |S )aâ  
        Return an axes locator callable for the specified cell.

        Parameters
        ----------
        nx, nx1 : int
            Integers specifying the column-position of the
            cell. When *nx1* is None, a single *nx*-th column is
            specified. Otherwise, location of columns spanning between *nx*
            to *nx1* (but excluding *nx1*-th column) is specified.
        ny, ny1 : int
            Same as *nx* and *nx1*, but for row positions.
        r   )r   r   Ú	functoolsÚpartialÚ_locaterC   )r   ÚnxÚnyÚnx1Úny1ÚxrefÚyrefÚlocators           r   Únew_locatorzDivider.new_locatorª   sw   € ð ˆ;Ø�q‘&ˆCØˆ;Ø�q‘&ˆCð �‰ˆØ�‰ˆÜ×#Ñ#Ø�L‰L˜"˜t™) R¨$¡Y°°d±
¸CÀ$¹JóHˆà"&×"6Ñ"6ˆÔØˆr   ú3.8z&divider.new_locator(...)(ax, renderer))Úalternativec                 ó’   — | j                   }| j                  }| j                  ||z
  |€|dz   n||z
  ||z
  |€|dz   n||z
  ||«      S )a  
        Implementation of ``divider.new_locator().__call__``.

        Parameters
        ----------
        nx, nx1 : int
            Integers specifying the column-position of the cell. When *nx1* is
            None, a single *nx*-th column is specified. Otherwise, the
            location of columns spanning between *nx* to *nx1* (but excluding
            *nx1*-th column) is specified.
        ny, ny1 : int
            Same as *nx* and *nx1*, but for row positions.
        axes
        renderer
        r   )r   r   rk   )	r   rl   rm   rn   ro   Úaxesr%   rp   rq   s	            r   ÚlocatezDivider.locateÊ   s\   € ð$ �‰ˆØ�‰ˆØ�|‰|Ø�‰I # +˜˜Qš°3¸$Ñ>Ø�‰I # +˜˜Qš°3¸$Ñ>Ø�(óð 	r   c                 óX  — || j                   z  }|| j                   z  }|| j                  z  }|| j                  z  }| j                  j                  j                  | j                  j
                  z  \  }}| j                  ||«      \  }	}
}}| j                  |«      }| j                  |«      }| j                  |||z  «      }| j                  |||z  «      }| j                  «       r¾t        ||«      }| j                  ||«      }| j                  ||«      }|d   |d   z
  |z  }|d   |d   z
  |z  }t        j                  j                  |	|
||«      }t        j                  j                  |	|
||«      }|j!                  | j#                  «       |«      j$                  \  }}n(| j                  ||«      }| j                  ||«      }|	|
}}|€d}|€d}|||   |z  z   ||   ||   z
  |z  }}|||   |z  z   ||   ||   z
  |z  }}t        j                  j                  ||||«      S )a  
        Implementation of ``divider.new_locator().__call__``.

        The axes locator callable returned by ``new_locator()`` is created as
        a `functools.partial` of this method with *nx*, *ny*, *nx1*, and *ny1*
        specifying the requested cell.
        éÿÿÿÿr   )r   r   r
   ÚbboxÚsizeÚdpir\   r'   r+   rc   rS   Úminrg   r7   r8   Úfrom_boundsÚanchoredr?   Úp0)r   rl   rm   rn   ro   rw   r%   Úfig_wÚfig_hÚxÚyÚwrF   ÚhsizesÚvsizesÚk_hÚk_vrf   ÚoxÚoyÚwwÚhhÚpbÚpb1Úx0Úy0Úx1Úw1Úy1Úh1s                                 r   rk   zDivider._locateã   s0  € ð 	ˆd�o‰oÑˆØˆt�‰ÑˆØ
ˆd�o‰oÑˆØˆt�‰Ñˆà—y‘y—~‘~×*Ñ*¨T¯Y©Y¯]©]Ñ:‰ˆˆuØ×.Ñ.¨t°XÓ>‰
ˆˆ1ˆa�à×*Ñ*¨8Ó4ˆØ×(Ñ(¨Ó2ˆØ�l‰l˜6 5¨1¡9Ó-ˆØ�l‰l˜6 5¨1¡9Ó-ˆà�?‰?ÔÜ�C˜“ˆAØ×#Ñ# F¨AÓ.ˆBØ×#Ñ# F¨AÓ.ˆBà�R‘&˜2˜a™5‘. EÑ)ˆBØ�R‘&˜2˜a™5‘. EÑ)ˆBÜ×!Ñ!×-Ñ-¨a°°A°qÓ9ˆBÜ×"Ñ"×.Ñ.¨q°!°R¸Ó<ˆCØ—\‘\ $§/¡/Ó"3°RÓ8×;Ñ;‰FˆB‘ð ×#Ñ# F¨CÓ0ˆBØ×#Ñ# F¨CÓ0ˆBØ˜�ˆBàˆ;ØˆCØˆ;ØˆCà�b˜‘f˜u‘nÑ$ r¨#¡w°°B±Ñ'7¸5Ñ&@ˆBˆØ�b˜‘f˜u‘nÑ$ r¨#¡w°°B±Ñ'7¸5Ñ&@ˆBˆä×Ñ×+Ñ+¨B°°B¸Ó;Ð;r   c                 óŠ  — t        j                  g d¢|¬«       |dk(  r2| j                  j                  d|«       | xj                  dz  c_        y |dk(  r| j                  j                  |«       y |dk(  r2| j                  j                  d|«       | xj                  dz  c_        y | j                  j                  |«       y )N©ÚleftÚrightÚbottomÚtop©Úpositionr™   r   r   rš   r›   )r   r6   r   Úinsertr   Úappendr   r   )r   rž   r|   s      r   Úappend_sizezDivider.append_size  sš   € Ü×ÑÒ=Ø$,õ	.à�vÒØ×Ñ×#Ñ# A tÔ,Ø�OŠO˜qÑ ŽOØ˜Ò Ø×Ñ×#Ñ# DÕ)Ø˜Ò!Ø�N‰N×!Ñ! ! TÔ*Ø�OŠO˜qÑ ŽOà�N‰N×!Ñ! $Õ'r   c                 óp   — |€g d¢}|D ]+  }| j                  |t        j                  ||«      |z   «       Œ- y)a5  
        Add auto-adjustable padding around *use_axes* to take their decorations
        (title, labels, ticks, ticklabels) into account during layout.

        Parameters
        ----------
        use_axes : `~matplotlib.axes.Axes` or list of `~matplotlib.axes.Axes`
            The Axes whose decorations are taken into account.
        pad : float, default: 0.1
            Additional padding in inches.
        adjust_dirs : list of {"left", "right", "bottom", "top"}, optional
            The sides where padding is added; defaults to all four sides.
        Nr˜   )r¡   ÚSizeÚ_AxesDecorationsSize)r   Úuse_axesÚpadÚadjust_dirsÚds        r   Úadd_auto_adjustable_areaz Divider.add_auto_adjustable_area   sB   € ð ÐÚ<ˆKØò 	NˆAØ×Ñ˜Q¤× 9Ñ 9¸(ÀAÓ FÈÑ LÕMñ	Nr   )NÚC)F©NN)NNNN)çš™™™™™¹?N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r'   r+   r.   r1   r   r?   rC   rG   r"   rL   r*   rQ   rS   rV   rX   r\   Ústaticmethodrc   rg   rs   r   Ú
deprecatedrx   rk   r¡   r©   rB   r   r   r   r      sÉ   „ ñ	ð &)óò>OòMò	òòò(òòò òòóòò!òò6ð ñ=ó ð=ð ñ1ó ð1ó
ð@ €T‡_�_ØÐCôEòóEðò.-<ò^(ôNr   r   rt   c                   ó$   — e Zd ZdZdd„Zd„ Zd„ Zy)ÚAxesLocatorzc
    A callable object which returns the position and size of a given
    `.AxesDivider` cell.
    Nc                 óö   — || _         |j                  }|j                  }||z
  ||z
  c| _        | _        |€t        | j                   «      }|€t        | j                   d   «      }||z
  | _        ||z
  | _        y)aì  
        Parameters
        ----------
        axes_divider : `~mpl_toolkits.axes_grid1.axes_divider.AxesDivider`
        nx, nx1 : int
            Integers specifying the column-position of the
            cell. When *nx1* is None, a single *nx*-th column is
            specified. Otherwise, location of columns spanning between *nx*
            to *nx1* (but excluding *nx1*-th column) is specified.
        ny, ny1 : int
            Same as *nx* and *nx1*, but for row positions.
        Nr   )Ú_axes_dividerr   r   Ú_nxÚ_nyr<   Ú_nx1Ú_ny1)r   Úaxes_dividerrl   rm   rn   ro   r   r   s           r   r   zAxesLocator.__init__;  s�   € ð *ˆÔà!×,Ñ,ˆ
Ø!×,Ñ,ˆ
à *™_¨b°:©oÐˆŒ�$”(àˆ;Ü�d×(Ñ(Ó)ˆCØˆ;Ü�d×(Ñ(¨Ñ+Ó,ˆCà˜*Ñ$ˆŒ	Ø˜*Ñ$ˆ�	r   c                 ó  — | j                   j                  }| j                   j                  }| j                   j                  | j                  |z   | j
                  |z   | j                  |z   | j                  |z   ||«      S r   )r¶   r   r   rx   r·   r¸   r¹   rº   )r   rw   r%   r   r   s        r   Ú__call__zAxesLocator.__call__W  sr   € à×'Ñ'×2Ñ2ˆ
Ø×'Ñ'×2Ñ2ˆ
à×!Ñ!×(Ñ(¨¯©°JÑ)>Ø)-¯©°JÑ)>Ø)-¯©°ZÑ)?Ø)-¯©°ZÑ)?Ø)-Ø)1ó3ð 	3r   c                 ó6   — | j                   j                  «       S r   )r¶   rC   r0   s    r   rC   zAxesLocator.get_subplotspecc  s   € Ø×!Ñ!×1Ñ1Ó3Ð3r   r«   )r­   r®   r¯   r°   r   r½   rC   rB   r   r   r´   r´   4  s   „ ñó
%ò8
3ó4r   r´   c                   ó@   ‡ — e Zd ZdZdddddœˆ fd„
Zd„ Zd„ Zd„ Zˆ xZS )	ÚSubplotDividerzT
    The Divider class whose rectangle area is specified as a subplot geometry.
    Nrª   ©r   r   r   r   c                óœ   •— || _         t        ‰| �	  |g d¢|xs g |xs g ||¬«       | j                  t	        j
                  ||«      «       y)a”  
        Parameters
        ----------
        fig : `~matplotlib.figure.Figure`

        *args : tuple (*nrows*, *ncols*, *index*) or int
            The array of subplots in the figure has dimensions ``(nrows,
            ncols)``, and *index* is the index of the subplot being created.
            *index* starts at 1 in the upper left corner and increases to the
            right.

            If *nrows*, *ncols*, and *index* are all single digit numbers, then
            *args* can be passed as a single 3-digit number (e.g. 234 for
            (2, 3, 4)).
        horizontal : list of :mod:`~mpl_toolkits.axes_grid1.axes_size`, optional
            Sizes for horizontal division.
        vertical : list of :mod:`~mpl_toolkits.axes_grid1.axes_size`, optional
            Sizes for vertical division.
        aspect : bool, optional
            Whether overall rectangular area is reduced so that the relative
            part of the horizontal and vertical scales have the same scale.
        anchor : (float, float) or {'C', 'SW', 'S', 'SE', 'E', 'NE', 'N', 'NW', 'W'}, default: 'C'
            Placement of the reduced rectangle, when *aspect* is True.
        )r   r   r   r   rÁ   N)ÚfigureÚsuperr   Úset_subplotspecr   Ú_from_subplot_args)r   r   r   r   r   r   ÚargsÚ	__class__s          €r   r   zSubplotDivider.__init__l  sR   ø€ ð6 ˆŒÜ‰Ñ˜šlØ$.Ò$4°"¸xº~È2Ø &¨vð 	ô 	7ð 	×Ñœ[×;Ñ;¸CÀÓFÕGr   c                 óh   — | j                  «       j                  | j                  «      j                  S )z%Return the bounds of the subplot box.)rC   r1   rÃ   rZ   r0   s    r   r1   zSubplotDivider.get_position�  s&   € à×#Ñ#Ó%×2Ñ2°4·;±;Ó?×FÑFÐFr   c                 ó   — | j                   S )zGet the SubplotSpec instance.)Ú_subplotspecr0   s    r   rC   zSubplotDivider.get_subplotspec‘  s   € à× Ñ Ð r   c                 óf   — || _         | j                  |j                  | j                  «      «       y)zSet the SubplotSpec instance.N)rË   r.   r1   rÃ   )r   Úsubplotspecs     r   rÅ   zSubplotDivider.set_subplotspec•  s'   € à'ˆÔØ×Ñ˜+×2Ñ2°4·;±;Ó?Õ@r   )	r­   r®   r¯   r°   r   r1   rC   rÅ   Ú__classcell__©rÈ   s   @r   rÀ   rÀ   g  s,   ø„ ñð /3¸TØ SöHòBGò!öAr   rÀ   c                   óf   ‡ — e Zd ZdZdˆ fd„	Zddœd„Zdd„Zdd„Zdddœd„Zd	„ Z	d
„ Z
d„ Zd„ Zˆ xZS )ÚAxesDividerz0
    Divider based on the preexisting axes.
    Nc                 ó  •— || _         |€t        j                  |«      | _        n|| _        |€t        j                  |«      | _        n|| _        t        ‰| �  |j                  «       d| j                  g| j
                  gdd¬«       y)zw
        Parameters
        ----------
        axes : :class:`~matplotlib.axes.Axes`
        xref
        yref
        Nrª   )r   r   r   r   r   r   )	Ú_axesr£   ÚAxesXÚ_xrefÚAxesYÚ_yrefrÄ   r   Ú
get_figure)r   rw   rp   rq   rÈ   s       €r   r   zAxesDivider.__init__   sw   ø€ ð ˆŒ
Øˆ<ÜŸ™ DÓ)ˆD�JàˆDŒJØˆ<ÜŸ™ DÓ)ˆD�JàˆDŒJä‰Ñ˜TŸ_™_Ó.°DØ%)§Z¡Z L¸D¿J¹J¸<Ø $¨Sð 	õ 	2r   )Ú
axes_classc                ó„   — | j                   }|€t        |«      } ||j                  «       |j                  d¬«      fi |¤ŽS ©NT)Úoriginal)rÓ   ÚtyperØ   r1   )r   rÙ   Úkwargsrw   s       r   Ú_get_new_axeszAxesDivider._get_new_axes¶  sH   € Ø�z‰zˆØÐÜ˜d›ˆJÙ˜$Ÿ/™/Ó+¨T×->Ñ->ÈÐ->Ó-Mñ $Ø"ñ$ð 	$r   c                 óB  — |€ t         j                  d   | j                  z  }|rdnd}|rMt        |t        j
                  «      s!t	        j                  || j                  ¬«      }| j                  ||«       t        |t        j
                  «      s!t	        j                  || j                  ¬«      }| j                  ||«       | j                  |rdnt        | j                  «      dz
  | j                  ¬«      } | j                  di |¤Ž}|j                  |«       |S )	z³
        Helper method for ``append_axes("left")`` and ``append_axes("right")``.

        See the documentation of `append_axes` for more details.

        :meta private:
        zfigure.subplot.wspacer™   rš   ©Úfraction_refr   r   ©rl   rm   rB   )ÚmplÚrcParamsrÕ   r4   r£   Ú_BaseÚfrom_anyr¡   rs   r<   r   r   rß   Úset_axes_locator©r   r|   r¦   Ú
pack_startrÞ   r   rr   r[   s           r   Únew_horizontalzAxesDivider.new_horizontal½  sî   € ð ˆ;Ü—,‘,Ð6Ñ7¸$¿*¹*ÑDˆCÙ"‰f¨ˆÙÜ˜c¤4§:¡:Ô.Ü—m‘m C°d·j±jÔA�Ø×Ñ˜S #Ô&Ü˜$¤§
¡
Ô+Ü—=‘= °D·J±JÔ?ˆDØ×Ñ˜˜dÔ#Ø×"Ñ"Ù‰q¤C¨×(8Ñ(8Ó$9¸AÑ$=Ø�‰ð #ó  ˆð  ˆT×ÑÑ) &Ñ)ˆØ
×Ñ˜GÔ$Øˆ	r   c                 óB  — |€ t         j                  d   | j                  z  }|rdnd}|rMt        |t        j
                  «      s!t	        j                  || j                  ¬«      }| j                  ||«       t        |t        j
                  «      s!t	        j                  || j                  ¬«      }| j                  ||«       | j                  | j                  |rdnt        | j                  «      dz
  ¬«      } | j                  di |¤Ž}|j                  |«       |S )	z³
        Helper method for ``append_axes("top")`` and ``append_axes("bottom")``.

        See the documentation of `append_axes` for more details.

        :meta private:
        zfigure.subplot.hspacer›   rœ   rá   r   r   rã   rB   )rä   rå   r×   r4   r£   ræ   rç   r¡   rs   r   r<   r   rß   rè   ré   s           r   Únew_verticalzAxesDivider.new_verticalÖ  sì   € ð ˆ;Ü—,‘,Ð6Ñ7¸$¿*¹*ÑDˆCÙ$‰h¨%ˆÙÜ˜c¤4§:¡:Ô.Ü—m‘m C°d·j±jÔA�Ø×Ñ˜S #Ô&Ü˜$¤§
¡
Ô+Ü—=‘= °D·J±JÔ?ˆDØ×Ñ˜˜dÔ#Ø×"Ñ"Ø�‰Ù‰q¤C¨¯©Ó$7¸!Ñ$;ð #ó =ˆð  ˆT×ÑÑ) &Ñ)ˆØ
×Ñ˜GÔ$Øˆ	r   c                óô   — t        j                  | j                  df| j                  df| j                  df| j                  dfdœ|¬«      \  }} |||f||dœ|¤Ž}| j                  j                  |«       |S )am  
        Add a new axes on a given side of the main axes.

        Parameters
        ----------
        position : {"left", "right", "bottom", "top"}
            Where the new axes is positioned relative to the main axes.
        size : :mod:`~mpl_toolkits.axes_grid1.axes_size` or float or str
            The axes width or height.  float or str arguments are interpreted
            as ``axes_size.from_any(size, AxesX(<main_axes>))`` for left or
            right axes, and likewise with ``AxesY`` for bottom or top axes.
        pad : :mod:`~mpl_toolkits.axes_grid1.axes_size` or float or str
            Padding between the axes.  float or str arguments are interpreted
            as for *size*.  Defaults to :rc:`figure.subplot.wspace` times the
            main Axes width (left or right axes) or :rc:`figure.subplot.hspace`
            times the main Axes height (bottom or top axes).
        axes_class : subclass type of `~.axes.Axes`, optional
            The type of the new axes.  Defaults to the type of the main axes.
        **kwargs
            All extra keywords arguments are passed to the created axes.
        TFr˜   r�   )rê   rÙ   )r   Úcheck_getitemrë   rí   r
   Úadd_axes)	r   rž   r|   r¦   rÙ   rÞ   Úcreate_axesrê   r[   s	            r   Úappend_axeszAxesDivider.append_axesï  s˜   € ô. #'×"4Ñ"4Ø×(Ñ(¨$Ð/Ø×)Ñ)¨5Ð1Ø×(Ñ(¨$Ð/Ø×%Ñ% uÐ-ñ	6
ð
 ô#Ñˆ�Zñ Ø�#ðOØ",¸ñOØGMñOˆà�	‰	×Ñ˜2ÔØˆ	r   c                 ót   — | j                   €!| j                  j                  «       }|dk(  ryy| j                   S )NÚautoFT)r   rÓ   rS   rP   s     r   rS   zAxesDivider.get_aspect  s6   € Ø�<‰<ÐØ—Z‘Z×*Ñ*Ó,ˆFØ˜ÒØàà—<‘<Ðr   c                 ó‚   — | j                   €(| j                  j                  d¬«      }|j                  S | j                   S rÛ   )r   rÓ   r1   rZ   )r   r{   s     r   r1   zAxesDivider.get_position  s7   € Ø�9‰9ÐØ—:‘:×*Ñ*°DÐ*Ó9ˆDØ—;‘;Ðà—9‘9Ðr   c                 óf   — | j                   €| j                  j                  «       S | j                   S r   )r   rÓ   r?   r0   s    r   r?   zAxesDivider.get_anchor"  s)   € Ø�<‰<ÐØ—:‘:×(Ñ(Ó*Ð*à—<‘<Ðr   c                 ó6   — | j                   j                  «       S r   )rÓ   rC   r0   s    r   rC   zAxesDivider.get_subplotspec(  s   € Ø�z‰z×)Ñ)Ó+Ð+r   r«   )NFr   )r­   r®   r¯   r°   r   rß   rë   rí   rò   rS   r1   r?   rC   rÎ   rÏ   s   @r   rÑ   rÑ   ›  sB   ø„ ñõ2ð, +/ô $óó2ð2 À$ô  òD òò ö,r   rÑ   c	                 ó¤  — ||z  }	||z  }
t        |«      }|j                  \  }}|j                  \  }}t        j                  g |¢d‘«      }d|d |…df<   ||dd d…f<   g | ¢|	|j	                  «       z
  ‘}t        j
                  j                  ||«      �^ }}||
kD  r|
|z
  |z  }t        j                  dg||z  |z   ¢«      }|d   |d   z
  |z  }|d   \  }}|d   |z  |z   |z  }t        j                  j                  | |||«      }t        j                  j                  | |||«      }|j                  ||«      j                  \  }}||||fS )Nr   rz   )r<   ÚTr    Údiagr^   ÚlinalgÚsolvere   r7   r8   r   r€   r�   )r„   r…   r†   rF   Úsummed_widthsÚequal_heightsr‚   rƒ   r   Útotal_widthÚ
max_heightÚnÚeq_relsÚeq_abssÚsm_relsÚsm_abssÚAÚBÚkarrayÚheightr‹   r�   Úh0_relÚh0_absrŽ   r�   r�   r‘   r’   s                                r   rk   rk   /  s  € à˜!‘)€KØ˜‘€Jô 	ˆMÓ€AØ$—‘Ñ€GˆWØ$—‘Ñ€GˆWÜ
�‰��'�˜1�Ó€AØ€A€b€q€bˆ"€f�IØ€A€bˆ#ˆ2ˆ#€g�JØ2ˆGˆ8Ð2�k G§K¡K£MÑ1Ð2€Aô
 —i‘i—o‘o a¨Ó+�O€VˆVØ�
ÒØ˜wÑ&¨'Ñ1ˆô 
�‰�AÐ5˜ 6Ñ)¨GÑ3Ð5Ó	6€BØ
ˆR‰&�2�a‘5‰.˜EÑ	!€BØ" 1Ñ%�N€FˆFØ
�‰)�FÑ
˜VÑ
# uÑ	,€BÜ	×	Ñ	×	%Ñ	% a¨¨A¨qÓ	1€BÜ
×
Ñ
×
&Ñ
& q¨!¨R°Ó
4€CØ�\‰\˜& "Ó%×(Ñ(�F€Bˆàˆr�2�rˆ>Ðr   c                   ó*   ‡ — e Zd ZdZdˆ fd„	Zd„ Zˆ xZS )ÚHBoxDividerzÆ
    A `.SubplotDivider` for laying out axes horizontally, while ensuring that
    they have equal heights.

    Examples
    --------
    .. plot:: gallery/axes_grid1/demo_axes_hbox_divider.py
    c                 ó(   •— t         ‰| �  |d|d«      S )a‘  
        Create an axes locator callable for the specified cell.

        Parameters
        ----------
        nx, nx1 : int
            Integers specifying the column-position of the
            cell. When *nx1* is None, a single *nx*-th column is
            specified. Otherwise, location of columns spanning between *nx*
            to *nx1* (but excluding *nx1*-th column) is specified.
        r   ©rÄ   rs   )r   rl   rn   rÈ   s      €r   rs   zHBoxDivider.new_locatorZ  s   ø€ ô ‰wÑ" 2 q¨#¨qÓ1Ð1r   c                 óö  — || j                   z  }|| j                   z  }| j                  j                  j                  | j                  j                  z  \  }}| j                  ||«      \  }	}
}}| j                  |«      }| j                  |«      }t        |	|
||||||| j                  «       «	      \  }}}}|€d}|||   |z  z   ||   ||   z
  |z  }}||}}t        j                  j                  ||||«      S ©Nrz   )r   r
   r{   r|   r}   r\   r'   r+   rk   r?   r7   r8   r   )r   rl   rm   rn   ro   rw   r%   r‚   rƒ   r„   r…   r†   rF   Ú	summed_wsÚequal_hsr‘   r’   r‹   rŽ   r“   r”   r•   r–   s                          r   rk   zHBoxDivider._locateh  s  € à
ˆd�o‰oÑˆØˆt�‰ÑˆØ—y‘y—~‘~×*Ñ*¨T¯Y©Y¯]©]Ñ:‰ˆˆuØ×.Ñ.¨t°XÓ>‰
ˆˆ1ˆa�Ø×-Ñ-¨hÓ7ˆ	Ø×*Ñ*¨8Ó4ˆÜ Øˆq�!�Q˜	 8¨U°E¸4¿?¹?Ó;LóN‰ˆˆB��Bàˆ;ØˆCØ�b˜‘f˜u‘nÑ$ r¨#¡w°°B±Ñ'7¸5Ñ&@ˆBˆØ�RˆBˆÜ×Ñ×+Ñ+¨B°°B¸Ó;Ð;r   r   ©r­   r®   r¯   r°   rs   rk   rÎ   rÏ   s   @r   r  r  P  s   ø„ ñõ2ö<r   r  c                   ó*   ‡ — e Zd ZdZdˆ fd„	Zd„ Zˆ xZS )ÚVBoxDividerzm
    A `.SubplotDivider` for laying out axes vertically, while ensuring that
    they have equal widths.
    c                 ó(   •— t         ‰| �  d|d|«      S )a…  
        Create an axes locator callable for the specified cell.

        Parameters
        ----------
        ny, ny1 : int
            Integers specifying the row-position of the
            cell. When *ny1* is None, a single *ny*-th row is
            specified. Otherwise, location of rows spanning between *ny*
            to *ny1* (but excluding *ny1*-th row) is specified.
        r   r  )r   rm   ro   rÈ   s      €r   rs   zVBoxDivider.new_locator  s   ø€ ô ‰wÑ" 1 b¨!¨SÓ1Ð1r   c                 óö  — || j                   z  }|| j                   z  }| j                  j                  j                  | j                  j                  z  \  }}| j                  ||«      \  }	}
}}| j                  |«      }| j                  |«      }t        |
|	||||||| j                  «       «	      \  }}}}|€d}||}}|||   |z  z   ||   ||   z
  |z  }}t        j                  j                  ||||«      S r  )r   r
   r{   r|   r}   r\   r+   r'   rk   r?   r7   r8   r   )r   rl   rm   rn   ro   rw   r%   r‚   rƒ   r„   r…   r†   rF   Ú	summed_hsÚequal_wsr’   r‘   rŒ   r�   r“   r”   r•   r–   s                          r   rk   zVBoxDivider._locate�  s  € à
ˆd�o‰oÑˆØˆt�‰ÑˆØ—y‘y—~‘~×*Ñ*¨T¯Y©Y¯]©]Ñ:‰ˆˆuØ×.Ñ.¨t°XÓ>‰
ˆˆ1ˆa�Ø×+Ñ+¨HÓ5ˆ	Ø×,Ñ,¨XÓ6ˆÜ Øˆq�!�Q˜	 8¨U°E¸4¿?¹?Ó;LóN‰ˆˆB��Bàˆ;ØˆCØ�RˆBˆØ�b˜‘f˜u‘nÑ$ r¨#¡w°°B±Ñ'7¸5Ñ&@ˆBˆÜ×Ñ×+Ñ+¨B°°B¸Ó;Ð;r   r   r  rÏ   s   @r   r  r  y  s   ø„ ñõ
2ö<r   r  c                 ód   — t        | «      }|j                  dd¬«      }| j                  |«       |S )Nr   rã   )rÑ   rs   rè   )rw   Údividerrr   s      r   Úmake_axes_locatabler  ž  s4   € Ü˜$Ó€GØ×!Ñ! Q¨1Ð!Ó-€GØ×Ñ˜'Ô"à€Nr   c                 óV   — |€g d¢}t        | «      }|€| }|j                  |||¬«       y)aG  
    Add auto-adjustable padding around *ax* to take its decorations (title,
    labels, ticks, ticklabels) into account during layout, using
    `.Divider.add_auto_adjustable_area`.

    By default, padding is determined from the decorations of *ax*.
    Pass *use_axes* to consider the decorations of other Axes instead.
    Nr˜   )r¥   r¦   r§   )r  r©   )r[   r¥   r¦   r§   r  s        r   Úmake_axes_area_auto_adjustabler  ¦  s>   € ð ÐÚ8ˆÜ! "Ó%€GØÐØˆØ×$Ñ$¨h¸CØ1<ð %õ >r   )Nr¬   N)r°   ri   Únumpyr    Ú
matplotlibrä   r   Úmatplotlib.gridspecr   Úmatplotlib.transformsÚ
transformsr7   Ú r   r£   r   r²   r´   rÀ   rÑ   rk   r  r  r  r  rB   r   r   ú<module>r&     s¢   ðñó ã ã Ý Ý +Ý +Ý ÷aNñ aNðH	 €‡��Ó÷/4ð /4ó ð/4ôd1A�Wô 1AôhN,�'ô N,òhôB&<�.ô &<ôR"<�.ô "<òJð 15ô>r   