Hacked By AnonymousFox

Current Path : /opt/imunify360/venv/lib/python3.11/site-packages/docutils/utils/math/__pycache__/
Upload File :
Current File : //opt/imunify360/venv/lib/python3.11/site-packages/docutils/utils/math/__pycache__/latex2mathml.cpython-311.pyc

�

j��f(����dZddlZddlZddlmZmZejZded<dddd	d
ddd
dddd�Zdddddddddd�	Z	e	�
d�dD����ddddd�Zddd d!d"d#d$d%d&d'd(d)d$d*�
Zid+d,�d-d.�d/d0�d1d2�d3d4�d5d6�d7d8�d9d:�d;d<�d=d>�d?d@�dAdB�dCdD�dEdB�dFdD�dGdD�Z
e
�
ej��e
�
ej��e
�
ej��idHdI�dJdK�dLdM�dNdO�dPdQ�dRdS�dTdU�dVdW�dXdY�dZd[�d\d]�d^d_�d`da�dbdc�ddde�dfdc�dgdc�deddhdidjdkdl��Ze�
ej��e�
ej��e�
ej��e�
ej��e�
ej��e�
e
��dmdndo�Zdpdqdrdsdtdudvdw�ZdxZdydzd{d{d|d}d}d~d~ddd�d�d��
Zd�d�d�d�d�d�d�d�d�d�d�d�d��Zd�d�d�d�d�d�d�d��Zd�d�d�d�d�d��Zd�d�d�d��Zd�d�d�d�d�d��Zd�d�d�d�d�d�d�d�d��Z d�dd��d�dd��d�d�d��d�d�d��d��Z!iifd�dd�d��ife!d�ife!d�ifid�dife!d�d�dife!d�d�difd��Z"gd��Z#ddd�d�d�d�d�d�d�d�d��
Z$Gd��d���Z%Gd��d�e%��Z&Gd��d�e%��Z'GdÄd�e%��Z(Gdńd�e(��Z)GdDŽd�e(��Z*GdɄd�e(��Z+Gd˄d�e(��Z,Gd̈́d�e(��Z-Gdτd�e(��Z.Gdфd�e%��Z/Gdӄd�e/��Z0GdՄd�e/��Z1Gdׄd�e/��Z2Gdلd�e/��Z3Gdۄd�e%��Z4Gd݄d�e4��Z5Gd߄d�e4��Z6Gd�d�e4��Z7Gd�d�e5��Z8Gd�d�e6��Z9Gd�d�e7��Z:Gd�d�e4��Z;Gd�d�e%��Z<Gd�d�e%��Z=d�Z>d�Z?d�Z@d�ZAd�ZBd�ZCd��ZDd��ZEd�d��ZFd��ZGd��ZHd��ZId��ZJd�d��ZKdS(z�Convert LaTex maths code into presentational MathML.

This module is provisional:
the API is not settled and may change with any minor Docutils version.
�N)�tex2unichar�
toplevel_codeuℏ�hbaruΦuΞ�ΣuΨuΔuΘuϒ�ΠuΩ�ΓuΛ)�Phi�Xi�Sigma�Psi�Delta�Theta�Upsilon�Pi�Omega�Gamma�Lambdau	lim infu	lim supu	inj limu
proj lim�lim)	�liminf�limsup�injlim�projlim�	varlimsup�	varliminf�
varprojlim�	varinjlim�operatornamec#�K�|]}||fV��	dS�N�)�.0�names  ��/builddir/build/BUILD/imunify360-venv-2.3.5/opt/imunify360/venv/lib/python3.11/site-packages/docutils/utils/math/latex2mathml.py�	<genexpr>r$Bs>����A�A�$�$���A�A�A�A�A�A�)�arccos�arcsin�arctan�arg�cos�cosh�cot�coth�csc�deg�det�dim�exp�gcd�hom�ker�lg�ln�log�Pr�sec�sin�sinh�tan�tanh)TTFz0.278em)FTT�0.444em)FTFz0.667em)FFTr?)�bmod�pmod�mod�pod�bold�italic�	monospace�normalz
sans-serif�scriptzbold-italicz
double-struck�frakturzsans-serif-italiczsans-serif-bold-italic)
�
boldsymbol�mathbf�mathit�mathtt�mathrm�mathsf�mathcal�mathbfit�mathbb�mathfrak�mathsfit�
mathsfbfit�mathscr�	backslash�\�uparrowu↑�	downarrowu↓�updownarrowu↕�Uparrowu⇑�	Downarrowu⇓�Updownarrowu⇕�
lmoustacheu⎰�
rmoustacheu⎱�	arrowvertu⏐�	bracevertu⎪�lvert�|�lVert�‖�rvert�rVert�	Arrowvert�nleqqu≦̸�ngeqqu≧̸�	nleqslantu⩽̸�	ngeqslantu⩾̸�ngtrlessu≹�nlessgtru≸�
nsubseteqqu⫅̸�
nsupseteqqu⫆̸�	centerdotu⬝�
varnothingu⌀�	varproptou∝�triangleu△�triangledownu▽�dotsb�⋯�dotscu…�dotsi�dotsm�sup�inf�max�min)�dotsorr|r}r~ru∼u≈)�thicksim�thickapproxu∣u∥u∤u∦u⌢u⌣u∫)�shortmid�
shortparallel�	nshortmid�nshortparallel�
smallfrown�
smallsmile�smallint)�bigcap�bigcup�bigodot�bigoplus�	bigotimes�bigsqcup�biguplus�bigvee�bigwedge�coprod�intop�ointop�prod�sumrr~rr|r}�2em�1emz0.2778emz0.25emz0.2222emz0.1667emz	-0.1667emz	-0.2222emz	-0.2778em)
�qquad�quad�
thickspace�;� �medspace�:�	thinspace�,�negthinspace�!�negmedspace�
negthickspace)�´ú)uˉū)u˘ŭ)uˇǔ)u˙u̇)�¨ü)rxu⃛)�`ù)uˆû)u˚ů)u˜ũ)�→u⃗)�acute�bar�breve�check�dot�ddot�dddot�grave�hat�mathring�tilde�vec)u⏞皙����ɿ)�←r�)u↔r�)�_r�)r�r�)�^g�)�~g333333ӿ)�	overbrace�
overleftarrow�overleftrightarrow�overline�overrightarrow�widehat�	widetilde)u⏟g�������?)r�g�������)�
underbrace�underleftarrow�underleftrightarrow�	underline�underrightarrowu−u∶� )�-r�r�uℾuℿ�⅀uℽuℼ)rrruγuπ)�r�)�(�))�[�])�{�})rdrd)rfrf)r�r�)�matrix�smallmatrix�pmatrix�bmatrix�Bmatrix�vmatrix�Vmatrix�casesT)�displaystyle�scriptlevelF��)r��	textstyle�scriptstyle�scriptscriptstyle�cfrac)r�r��CLASSr�r��
linethickness)�fracr��dfrac�tfrac�binom�dbinom�tbinom)r�z1.2emz1.623emz2.047emz2.470em��)
�left�right�bigl�bigr�Bigl�Bigr�biggl�biggr�Biggl�Biggrc���eZdZdZdZ	dZ	dZed��ded��ded��d	d
diZdd
d�Z		dZ
	d�Zd�Zd�Z
d�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zdd�Zd�Zdd�Zd�ZdS) �mathz8Base class for MathML elements and root of MathML trees.Nr�<z&lt;�>z&gt;�&z&amp;ia z&ApplyFunction;�true�false)TF�spanc��g|_|�|��i|_|���D]$}|||j|���<�%dS)aSet up node with `children` and `attributes`.

        Attributes are downcased: Use CLASS to set "class" value.
        >>> math(mn(3), CLASS='test')
        math(mn(3), class='test')
        >>> math(CLASS='test').toprettyxml()
        '<math class="test">
</math>'

        N)�children�extend�
attributes�keys�lower)�selfr�r�keys    r#�__init__z
math.__init__Zsd����
����H��������?�?�$�$�	;�	;�C�,6�c�?�D�O�C�I�I�K�K�(�(�	;�	;r%c��d�t|dg��D��}t|d��r'|�t|j����t|t��r|jr|�d��|d�|j�	��D��z
}|j
jdd�|��zzS)Nc�,�g|]}t|����Sr )�repr)r!�items  r#�
<listcomp>z!math.__repr__.<locals>.<listcomp>ns��H�H�H�$�4��:�:�H�H�Hr%r��datazswitch=Truec�&�g|]\}}|�|�d|����S)N�=r �r!�k�vs   r#rz!math.__repr__.<locals>.<listcomp>ss2��&�&�&�t�q�!��}��Q�Q���N�$�}�}r%z(%s)z, )
�getattr�hasattr�appendr	r�
isinstance�
MathSchema�switchr�items�	__class__�__name__�join)r�contents  r#�__repr__z
math.__repr__ms���H�H�'�$�
�B�*G�*G�H�H�H���4�� � �	,��N�N�4��	�?�?�+�+�+��d�J�'�'�	*�D�K�	*��N�N�=�)�)�)��&�&�t��/D�/D�/F�/F�&�&�&�	&���~�&��$�)�)�G�2D�2D�)D�D�Dr%c�*�t|j��Sr)�lenr��rs r#�__len__zmath.__len__xs���4�=�!�!�!r%c��|j|Sr�r)rrs  r#�__getitem__zmath.__getitem__}s����s�#�#r%c��||j|<dSrr#)rrr
s   r#�__setitem__zmath.__setitem__�s��#������r%c�&�|jj|i|��Sr)r�get)r�args�kwargss   r#r(zmath.get�s��"�t��"�D�3�F�3�3�3r%c�D�|jduot|��|jkS)z;Return boolean indicating whether children may be appended.N)�	nchildrenrr s r#�fullz	math.full�s&����d�*�0���I�I���/�	1r%c���|���rtd|z���|j�|��||_|���r|���S|S)z�Append child and return self or first non-full parent.

        If self is full, go up the tree and return first non-full node or
        `None`.
        zNode %s already full!)r-�SyntaxErrorr�r�parent�close)r�childs  r#rzmath.append�sh���9�9�;�;�	>��5��<�=�=�=��
���U�#�#�#�����9�9�;�;�	 ��:�:�<�<���r%c�:�|D]}|�|���|Sr)r)rr�r2s   r#rzmath.extend�s+���	�	�E��K�K�������r%c�z�|j}|�1|���r|j}|�|����|S)z7Close element and return first non-full parent or None.)r0r-)rr0s  r#r1z
math.close�s=������ �V�[�[�]�]� ��]�F�� �V�[�[�]�]� ��
r%c�P�d�|�����S)z,Return XML representation of self as string.r�)r�_xmlr s r#�toprettyxmlzmath.toprettyxml�s���w�w�t�y�y�{�{�#�#�#r%c�z�|���g|�|��zd|jjzgzS)Nz</%s>)�xml_starttag�	_xml_bodyrr�r�levels  r#r6z	math._xml�sB���"�"�$�$�%��.�.��'�'�(��T�^�4�4�5�6�	7r%c��d�|j���D��}dd�|jjg|�R��zS)Nc3�K�|]F\}}|�|�dt|���dd���dd���d�V��GdS)Nz="�Truer��Falser��")�str�replacers   r#r$z$math.xml_starttag.<locals>.<genexpr>�sh����#�#��Q���M� �a�a��Q�������!?�!?�!G�!G��QX�!Y�!Y�!Y�!Y�Z�!�M�M�M�#�#r%z<%s>r�)rrrrr)r�attrss  r#r9zmath.xml_starttag�sW��#�#�!�_�2�2�4�4�#�#�#������$�.�"9�!B�E�!B�!B�C�C�C�Cr%c���g}|jD]J}|�dd|dzzg��|�|�|dz�����K|�dd|zg��|S)N�
z  r�)r�rr6)rr<�xmlr2s    r#r:zmath._xml_body�s}�����]�	,�	,�E��J�J��d�e�A�g�.�/�0�0�0��J�J�u�z�z�%��'�*�*�+�+�+�+��
�
�D�$��,�'�(�(�(��
r%c��	|ddkS#t$r/	|j���cYS#t$rYYdSwxYwwxYw)z;Return true, if `self` or a parent has ``display='block'``.�display�blockF)�KeyErrorr0�is_block�AttributeErrorr s r#rLz
math.is_block�st��	��	�?�g�-�-���	�	�	�
��{�+�+�-�-�-�-�-��!�
�
�
��u�u�u�
����	���s(��
A�4�A�
A�A�A�A�r)r�
__module__�__qualname__�__doc__r,r0�_level�ord�xml_entities�_boolstrings�html_tagnamerrr!r$r&r(r-rrr1r7r6r9r:rLr r%r#r�r�Dsp������B�B��I�-�
�F�)�
�F�	��C���&���C���&���C���'��#��L�!��1�1�L�C��L�+�;�;�;�&	E�	E�	E�"�"�"�
$�$�$�$�$�$�4�4�4�1�1�1�
������
���$�$�$�7�7�7�7�
D�D�D���������r%r�c��eZdZdS)�mtableN�rrOrPr r%r#rXrX���������r%rXc�"��eZdZdZ�fd�Z�xZS)�mrowz*Group sub-expressions as a horizontal row.c���|j}t|t��rU|jdkrJt	|j��|_|j|_|jD]	}||_�
|���St	|��dkre	|jd|j|j�|��<||jd_n$#ttf$r|jdcYSwxYwt�����S)z�Close element and return first non-full parent or None.

        Remove <mrow>, if it is single child and the parent infers an mrow
        or if it has only one child element.
        r�r)r0r�
MathRowSchemar,rr�r1�indexrM�
ValueError�super)rr0r2rs   �r#r1z
mrow.close�s��������f�m�,�,�	"��1A�Q�1F�1F�"�6�?�3�3�F��"�m�F�O���
&�
&��%�����<�<�>�>�!��t�9�9��>�>�
(�?C�}�Q�?O����� 5� 5�d� ;� ;�<�*0��
�a� �'�'��"�J�/�
(�
(�
(��}�Q�'�'�'�'�
(�����w�w�}�}���s�?C�C(�'C()rrOrPrQr1�
__classcell__�rs@r#r\r\�s>�������4�4���������r%r\c��eZdZdZdS)r^zCBase class for elements treating content as a single inferred mrow.N)rrOrPrQr r%r#r^r^
s������M�M�M�Mr%r^c��eZdZdS)�mtrNrYr r%r#rfrfrZr%rfc��eZdZdS)�mtdNrYr r%r#rhrhrZr%rhc��eZdZdZdS)�mencloser�N�rrOrPr,r r%r#rjrj��������I�I�Ir%rjc��eZdZdZdS)�mphantomr�Nrkr r%r#rnrnrlr%rnc��eZdZdZdS)�msqrtr�Nrkr r%r#rprprlr%rpc��eZdZdZdS)�mstyler�Nrkr r%r#rrrrrlr%rrc�.��eZdZdZdZ�fd�Zdd�Z�xZS)�	MathTokenzbToken Element: contains textual data instead of children.

    Base class for mo, mi, and mn.
    rc�H��||_t��jdi|��dS)Nr )rrar)rrrrs   �r#rzMathToken.__init__)s-�����	������&�&�:�&�&�&�&�&r%c�\�t|j���|j��gSr)rBr�	translaterTr;s  r#r:zMathToken._xml_body-s$���D�I���(�(��):�;�;�<�<r%rN)rrOrPrQr,rr:rbrcs@r#rtrt"s]����������I�'�'�'�'�'�=�=�=�=�=�=�=�=r%rtc��eZdZdS)�mtextNrYr r%r#ryry1rZr%ryc��eZdZdS)�miNrYr r%r#r{r{2rZr%r{c��eZdZdS)�moNrYr r%r#r}r}3rZr%r}c��eZdZdS)�mnNrYr r%r#rr4rZr%rc�,��eZdZdZdZd�Z�fd�Z�xZS)rz�Base class for schemata expecting 2 or more children.

    The special attribute `switch` indicates that the last two child
    elements are in reversed order and must be switched before XML-export.
    r�c�f�|�dd��|_tj|g|�Ri|��dS)NrF)�poprr�r)rr�r*s   r#rzMathSchema.__init__Es=���j�j��5�1�1����
�d�0�X�0�0�0��0�0�0�0�0r%c����t���|��}|jrF|���r2|jd|jdc|jd<|jd<d|_|S)N������F)rarrr-r�)rr2�current_noders   �r#rzMathSchema.appendIsg����w�w�~�~�e�,�,���;�	 �4�9�9�;�;�	 �37�=��3D�d�m�TV�FW�0�D�M�"��t�}�R�0��D�K��r%)rrOrPrQr,rrrbrcs@r#rr<sX����������I�1�1�1���������r%rc��eZdZdS)�msubNrYr r%r#r�r�RrZr%r�c��eZdZdS)�msupNrYr r%r#r�r�SrZr%r�c��eZdZdZdS)�msubsupr�Nrkr r%r#r�r�Vrlr%r�c��eZdZdS)�munderNrYr r%r#r�r�arZr%r�c��eZdZdS)�moverNrYr r%r#r�r�brZr%r�c��eZdZdS)�
munderoverNrYr r%r#r�r�srZr%r�c��eZdZdZdS)�mrootr�Nrkr r%r#r�r�vrlr%r�c��eZdZdZdS)�mfracr�Nrkr r%r#r�r�zrlr%r�c��eZdZdZdS)�mspacerNrkr r%r#r�r�~rlr%r�c��tjd|��}|�tjd|��}|�d��|�d��fS)a"Return leading TeX command name and remainder of `string`.

    >>> tex_cmdname('mymacro2') # up to first non-letter
    ('mymacro', '2')
    >>> tex_cmdname('name 2') # strip trailing whitespace
    ('name', '2')
    >>> tex_cmdname('_2') # single non-letter character
    ('_', '2')

    z([a-zA-Z]+) *(.*)Nz(.?)(.*)r�r���re�match�group��string�ms  r#�tex_cmdnamer��sK��	��%�v�.�.�A��y��H�[�&�)�)���7�7�1�:�:�q�w�w�q�z�z�!�!r%c��tjd|��}|�d|fS|�d��|�d��fS)zmReturn leading number literal and remainder of `string`.

    >>> tex_number('123.4')
    ('123.4', '')

    z([0-9.,]*[0-9]+)(.*)Nr�r�r�r�r�s  r#�
tex_numberr��sD��	��(�&�1�1�A��y��6�z���7�7�1�:�:�q�w�w�q�z�z�!�!r%c��tjd|tj��}|�dddd��\}}}}|p|p||fS)z�Return first simple TeX token and remainder of `string`.

    >>> tex_token('\command{without argument}')
    ('\command', '{without argument}')
    >>> tex_token('or first character')
    ('o', 'r first character')

    a%((?P<cmd>\\[a-zA-Z]+)\s* # TeX command, skip whitespace
                      |(?P<chcmd>\\.)          # one-character TeX command
                      |(?P<ch>.?))            # first character (or empty)
                     (?P<remainder>.*$)    # remaining part of string
                 �cmd�chcmd�ch�	remainder)r�r��VERBOSEr�)r�r�r�r�r�r�s      r#�	tex_tokenr��sZ��	����b�j�		*�	*�A�
!"����w��k� J� J��C���I���%��2�y�(�(r%c��d}d}d}|�d��s|dd�|dd�fS|D]4}|dz
}|rd}n |dkrd}n|dkr|dz
}n|dkr|dz}|dkrn�5td	���|d|dz
�||d�fS)
z�Return first TeX group or token and remainder of `string`.

    >>> tex_group('{first group} returned without brackets')
    ('first group', ' returned without brackets')

    rFr�Nr�rXTr�zGroup without closing bracket)�
startswithr/)r��split_index�
nest_level�escape�cs     r#�	tex_groupr��s����K��J�
�F����S�!�!�&��b�q�b�z�6�!�"�"�:�%�%�
�
;�
;���q����	��F�F�
�$�Y�Y��F�F�
�#�X�X��!�O�J�J�
�#�X�X��!�O�J���?�?��E���9�:�:�:��!�K��M�/�"�F�;�<�<�$8�8�8r%c��t|��\}}|dkr$t|�����\}}||fS)a�Return first TeX group or token and remainder of `string`.

    >>> tex_token_or_group('\command{without argument}')
    ('\command', '{without argument}')
    >>> tex_token_or_group('first character')
    ('f', 'irst character')
    >>> tex_token_or_group(' also whitespace')
    (' ', 'also whitespace')
    >>> tex_token_or_group('{first group} keep rest')
    ('first group', ' keep rest')

    r�)r�r��lstrip)r�r)r�s   r#�tex_token_or_groupr�sA���v�&�&�N�C��
�c�z�z�"�6�=�=�?�?�3�3���Y��	�>�r%c��tjd|tj��}|�|�d��sd|fS	|�d��|�d��fS#t
$rt
d|z���wxYw)a$Return optional argument and remainder.

    >>> tex_optarg('[optional argument] returned without brackets')
    ('optional argument', ' returned without brackets')
    >>> tex_optarg('{empty string, if there is no optional arg}')
    ('', '{empty string, if there is no optional arg}')

    z�\s*                            # leading whitespace
                 \[(?P<optarg>(\\]|[^\[\]]|\\])*)\] # [group] without nested groups
                 (?P<remainder>.*$)
                 Nr�r��optargr�z+Could not extract optional argument from %r)r�r�r�r�r�rMr/r�s  r#�
tex_optargr�&s���	����b�j�	*�	*�A�	�y��*�*�3�/�/�y��6�z��R��w�w�x� � �!�'�'�+�"6�"6�6�6���R�R�R��G�&�P�Q�Q�Q�R���s�)A'�'Bc�B�d�|�����}|}t|��dk�ra|d|dd�}}|dkr�-|dkr(t|��\}}t	|||��\}}�n|dvrt||��}�n�|dkr't
��}|�|��|}�n�|dkr|���}�n�|d	kr9t��}|����|��|}�nh|�
��r$|�t|����}�n0|���r8t|��\}}|�t||z����}n�|tvryi}|d
krE|jr>|jd}t#|dd
��d
vs|�d��dkrd|d<|�t't|fi|����}nb|dvr%|�t'|d�����}n9|dvr#|�t'|����}nt)d|z���t|��dk��a|S)u�Append MathML conversion of `string` to `node` and return it.

    >>> parse_latex_math(math(), r'lpha')
    math(mi('α'))
    >>> parse_latex_math(mrow(), r'x_{n}')
    mrow(msub(mi('x'), mi('n')))

    r�rr�NrX�_^r�r�r�r�r�rz([=�class�mathopen�prefix�formz/()[]|F��stretchyz
+*=<>,.!?`';@zUnsupported character: "%s")r�splitrr��
handle_cmd�handle_script_or_limitr\rr1rh�isalphar{�isdigitr�r�anomalous_charsr�rr(r}r/)	�noder��treer��cmdname�new_node�numberr�
previous_nodes	         r#�parse_latex_mathr�Es����X�X�f�l�l�n�n�
%�
%�F��D�

�f�+�+��/�/��1�I�v�a�b�b�z�6����8�8����9�9�)�&�1�1�O�G�V�%�g�t�V�<�<�L�D�&�&�
�$�Y�Y�)�$��2�2�D�D�
�#�X�X��v�v�H��K�K��!�!�!��D�D�
�#�X�X��:�:�<�<�D�D�
�#�X�X��u�u�H��J�J�L�L����)�)�)��D�D�
�Y�Y�[�[�	A��;�;�r�!�u�u�%�%�D�D�
�Y�Y�[�[�	A�'��/�/�N�F�F��;�;�r�!�F�(�|�|�,�,�D�D�
�/�
!�
!��J��C�x�x�D�M�x� $�
�b� 1�
��M�6�3�7�7�5�@�@�$�(�(��1�1�Z�?�?�)1�J�v�&��;�;�r�/�!�"4�C�C�
�C�C�D�D�D�D�
�(�]�]��;�;�r�!�e�4�4�4�5�5�D�D�
�/�
!�
!��;�;�r�!�u�u�%�%�D�D��;�a�?�@�@�@�S�f�+�+��/�/�T�Kr%c�0�|tvrAtt|��}|tvrd|d<|�|��}||fS|tv�r|dkr$t|��\}}t|d���}ntt|��}|dkrt
|td����}nm|dkr t|td	��d
���}nG|dkrt
|td
����}n#|dkrt
|td����}|�|��}|r,|ddvr"|�td����}||fS|tv�r/t|\}}}}|r)|�td||�����}||fS|�
��rd}|�t|�����}|r$|�tdd
�����}|rE|�td����}|�td�����}t|��\}}t||��}|r$|�tdd
�����}||fS|tvr�|dkrddi}	ndt|i}	|dkrd|	d<t|��\}}
|�d��r#t�|dd �|��}|d!krt �||��}|���s|d"kr$|�t|fi|	����}||
fSt%dmi|	��}|�|��||fS|d#kr*|�td$d%d&d'�(����}||fS|d)krt|d*��}||fS|t&vr3|�tt&|d+�,����}||fS|t(vr3|�tt(|d-�.����}||fS|t*vrUi}	|t,vr|r|dd/vrd0|	d1<n	|d2vrd3|	d<|�tt*|fi|	����}||fS|t.v�r i}t0t.|}
t|��\}}|d4vrF	t2|�d��}n$#t6$rt9d5|�d6|�d7����wxYw|
r|
|d8<|
|d9<d0|d:<|d;ks|�d<��r%t=��}|�|��|}|d=kr |�t|fi|����|d>ks|�d?��r|���}||fS|d@kr�tA|��\}}|dAkr|dB|zfS|�d��r7	t*|dd �}n #t6$rt9dC|z���wxYwtCj"dD|dEz��}|�t|����}||fS|dFvr�t|��\}}|�#dG��}tI|��D]W\}}|dHzdkr9tKj&dIdJ|��}|�tO|����}�Gt||���X||fS|tPvr5|�tdKtP|z�����}||fS|dLvrntS|��\}}|�dM��rdNtU|d dO���dPzz}|�tdK|z�����}||fS|dQkr'tW��}|�|��||fS|dRkr)tYdS�T��}|�|��||fS|dUkrt[|��\}}|rDt=��}t]|d0�V��}t||��|���nt_��}|�|��||fS|t`vr�t`|\}}|dWkrHt[|��\}}d;d>dX�}||vr-|�1��}|||dY<dZ||z|d<tedmi|��x}}|�d[��r4t=td��|td��d[�\��}d]|_3|r
t%|fi|��}|�|��||fS|dkrZti��}tk|��}|�������|��||fS|tlvrgtttl|dd
���d0�V��}|d^krd
|j7dd_<||_8|�|��||fS|trvrRtttr|dd0���d0d
�`��}||_8|�|��||fS|dakr)td0�V��}|�|��||fS|ttvrOt
ttt|d��d0�V��}||_8|�|��||fS|dbkr)t
d0�V��}|�|��||fS|dcvr�t[|��\}}tt*dd|dd �z��}|ratw|��}tt=��|��}ty|��dkr
|j7d}|�|��nt|��}|�|��||fS|tzvr�t%dmitz|��}d |_3t}|t<��rLty|��dkr9||j?j7|j?j7�@|��<|j?|_?n8|jAjBdekr|�|��nt9df|z���||fS|�dg��r.tA|��\}}
|dhvr|
}t�|||�i��}||fS|djkrt�||��S|dkkrt�||��St9dl|z���)nujProcess LaTeX command `name` followed by `string`.

    Append result to `node`.
    If needed, parse `string` for command argument.
    Return new current node and remainder of `string`:

    >>> handle_cmd('hbar', math(), r' rac')
    (math(mi('ℏ')), ' \frac')
    >>> handle_cmd('hspace', math(), r'{1ex} (x)')
    (math(mspace(width='1ex')), ' (x)')

    z
capital-greekr�rrG)�mathvariantrr�r�¯F)�accentrr�rr�r)r�r�u⁡rB)�lspace�rspacer�)�widthr�r��0.333emr�rJr�rVrXr�NrRr��colonr��postfix�0z0.28em)r�r�r��idotsintz\int\dotsi\intzfont-weight: bold)�stylez75%)�mathsizez _^T�
movablelimits)rcrer�z()[]/|.zUnsupported "\z
" delimiter "z"!�maxsize�minsize�	symmetricr��l�.r��r�notr�z{\not z\not: Cannot negate: "%s"!�NFCu̸)�text�mbox�textrm�$r�z(^ | $)r�z%s)�hspacer��muz%semr���phantom�boxed�box)�notation�sqrt)rr�)r�r��numalignz	numalign-r�)r�r�r�r�)rr��overset�underset)�
xleftarrow�xrightarrow�longr�z3Declaration "\%s" must be first command in a group.�limitsr�)r��begin�endzUnknown LaTeX command: \r )F�lettersr{�greek_capitalsr�	functionsr�r�r}r��modulo_functionsrLr�r��math_alphabetsr�r(rRr�rr�thick_operators�small_operators�	operatorsr��
bigdelimiters�delimiter_sizes�stretchablesr�rKr/�endswithr\r1r��unicodedata�	normalizer��	enumerater��subry�spacesr��floatrnrjr�r�rp�	fractions�copyr�r,rhrf�accentsr��tex_cmd�over�underr�r�
layout_stylesrr0r_rrr��begin_environment�end_environment)r"r�r�r�r)�binary�named�parentheses�paddingrr�r��delimiter_attributes�size�	delimiter�row�parts�i�part�radix�	indexnode�
style_atts�	frac_attsr��optargsr��entry�	subscript�base�sub_nodes                              r#r�r��s���&�w����g�d�m�$�$���>�!�!�!0�H�W���{�{�8�$�$���V�|���y����>�!�!�-�V�4�4�K�C���#�8�4�4�4�H�H��)�D�/�*�*�H��;����h��3���0�0�H�H�
�[�
 �
 ��X�r�$�x�x��>�>�>�H�H�
�\�
!�
!��h��8���5�5�H�H�
�[�
 �
 ��h��8���5�5�H��{�{�8�$�$���	-�f�Q�i�z�1�1��;�;�r�(�|�|�,�,�D��V�|������0@��0F�-����W��	 ��;�;�r�%���H�H�H�I�I�D���<���=�=�?�?�	��G��{�{�6��0�0�0�1�1���	8��;�;�r�#��6�6�6�7�7�D��	8��;�;�r�%�y�y�)�)�D��;�;�v�I�6�6�6�7�7�D�(��0�0���V���c�*�*���	8��;�;�r�#��6�6�6�7�7�D��V�|���~����<���!�<�0�J�J�'���)=�>�J��9���"+�J�w��+�F�3�3���Y��>�>�$���	,��+�+�c�!�"�"�g�s�+�+�C��8����*�*�S�#�&�&�C��;�;�=�=�	#�C�8�O�O��;�;�r�#�4�4��4�4�5�5�D���?�"��$�$��$�$�����E�����f�}���w����{�{�2�c�	�#�h�O�O�O�P�P���V�|���z�����&7�8�8���V�|�������{�{�2�o�d�3�;N�O�O�O�P�P���V�|�������{�{�2�o�d�3�e�D�D�D�E�E���V�|���y����
��=� � �V� ��q�	�U�0B�0B�*.�J��'�'�
�'�
'�
'�",�J�w���{�{�2�i��o�<�<��<�<�=�=���V�|���}���!���}�T�2�3��.�v�6�6��	�6��I�%�%�
7�(��)9�)9�$�)?�)?�@�	�	���
7�
7�
7�!�k�%)�T�T�9�9�9�#6�7�7�7�
7�����	5�.2� ��+�.2� ��+�04� ��-��6�>�>�T�]�]�3�/�/�>��&�&�C��K�K������D������K�K��9�=�=�(<�=�=�>�>�>��7�?�?�d�m�m�C�0�0�?��:�:�<�<�D��V�|���u�}�}���'�'���V��#�:�:���V�+�+�+��>�>�$���	E�
E���A�B�B��(�����
E�
E�
E�!�"?��"C�D�D�D�
E�����#�E�3�x�<�8�8���{�{�2�c�7�7�#�#���V�|���)�)�)�(��0�0���V��	�	�#���� ��'�'�	-�	-�G�A�t��1�u��z�z��v�i��4�8�8���{�{�5��;�;�/�/��� ��t�,�,�,�,��V�|���v�~�~��{�{�6��V�D�\�(9�:�:�:�;�;���V�|���#�#�#���'�'���V��<�<����	0��E�#�c�r�c�(�O�O�B�.�/�C��{�{�6��S��1�1�1�2�2���V�|���y����:�:�����H���������w����U�+�+�+�����H��������
�v�~�~�"�6�*�*�
��v��	����I��Y�t�4�4�4�H��Y��.�.�.��O�O������w�w�H����H���������y���"+�D�/���Y��7�?�?�'��/�/�N�F�F�"��1�1�G��� � �%�N�N�,�,�	�(/���	�*�%�%0�7�6�?�%B�	�'�"��,�,�)�,�,�,��4��=�=��!�!�	#��B�s�G�G�X�r�#�w�w�g�F�F�F�H�!"�H���	6��h�5�5�*�5�5�H����H�����V�|���t�|�|������u�:�:���
�
�������#�#�H�-�-�-��f�}���w�����G�D�M�!�,�u�=�=�=�d�K�K�K���5�=�=�-2�H��a� ��*�������H���������t�|�|���D��J�q�M�$�7�7�7� $�U�4�4�4��������H���������y�����%�%�%�����H���������u�}�}��"�U�4�[��^�,�,�T�:�:�:��������H���������z�����&�&�&�����H���������,�,�,�&�v�.�.��	�6��)�F�4����8�O�,�-�-���	#�!�$�'�'�H�'����	�:�:�H��8�}�}��!�!�#�,�Q�/���O�O�H�%�%�%�%��T�{�{�H����H���������}����0�0�M�$�/�0�0��!����d�D�!�!�	4�c�$�i�i�1�n�n�EM�D�K� ���!5�!;�!;�D�!A�!A�B�"�k�H�O�O�
�^�
$��
.�
.��K�K��!�!�!�!��,�.2�3�4�4�
4������}�}�X����"�6�*�*���Y��$�;�;��F�)�$��D�A�A�A�D��V�|���w��� ��v�.�.�.��u�}�}��t�V�,�,�,�
�1�D�8�
9�
9�9s� T"�"!U�+Y�Yr�c��|j���}|dkrd|d<n#|dkst|dd��tvrd|d<|dkr�t	|t
��rt
|jddi�}n�t	|t��rt|jddi�}n�|d	vs|dkr&|�	dd
��rt|��}n�t|��}n�|dkr�t	|t��rt
|j�}nct	|t��rt|j�}n?|d	vs|dkr&|�	dd
��rt|��}nt|��}|�|��|S)z)Append script or limit element to `node`.r�Fr�rr�Tr�r)r�r�Nr�)
r�r�rr�rr�r�r�r�r(r�r�r)r�r�r�r2r�s     r#r�r��s����M�����E�
����!&��o���
�O�
#�
#�
�U�F�B�
'�
'�=�
8�
8�!%��o���C�x�x��e�U�#�#�	#�!�5�>�?�$�?�?�H�H�
��t�
$�
$�	#����<�t�<�<�H�H��3�3�3��2���%�)�)�O�T�"B�"B���e�}�}�H�H��E�{�{�H�H�	
�c����e�V�$�$�	#�!�5�>�2�H�H�
��t�
$�
$�	#����/�H�H��3�3�3��2���%�)�)�O�T�"B�"B���U�|�|�H�H��E�{�{�H��K�K������Or%c�0�t|��\}}|tvr�t|d}i}|r]tt|����}|dkr#tt|d�����}d|d<|�|��|}n7|dkr1d|d	<d
|d<td�
��}|�|��|}t
��}|�tt|��fi|����|}ntd���||fS)Nrr�z0.17em)r�r��columnalignr�z0.02em�
rowspacingr��
columnspacing�1)r��Environment not supported!)
r��matricesr\r}rrrrhrXrfr/)r�r�r"�left_delimiterr�wrapperr$s       r#rrs-���V�$�$�L�D�&��x���!�$���*���
��	��2�n�-�-�.�.�G��w����r�.��B�B�B�C�C��,2�
�=�)��K�K�� � � ��D�D�
�]�
"�
"�'/�J�|�$�*3�J��'���-�-�-�G��K�K�� � � ��D��������F�3�u�:�:�4�4��4�4�5�5�5�����6�7�7�7���<�r%c��t|��\}}|tvr�|���������}t|d}|r7|�t	|����}|���}n*|dkr|���}ntd���||fS)Nr�r�r.)r�r/r1rr}r/)r�r�r"�right_delimiters    r#rr6s����V�$�$�L�D�&��x����z�z�|�|�!�!�#�#�)�)�+�+��"�4�.��+���	 ��;�;�r�/�2�2�3�3�D��:�:�<�<�D�D�
�W�_�_��:�:�<�<�D���6�7�7�7���<�r%c�n�td�|D����}|dkrdSt|dzdz��S)Nc3�lK�|]/}|�d��|�d��z
V��0dS�r�z\&N��count�r!rs  r#r$z'tex_equation_columns.<locals>.<genexpr>H�=����A�A�S�s�y�y��~�~��	�	�%� 0� 0�0�A�A�A�A�A�Ar%rr�r�)r~�int)�rows�tabss  r#�tex_equation_columnsr>Gs@���A�A�D�A�A�A�A�A�D��q�y�y��q��t�A�v��z�?�?�r%c���ddd�}td�|D����}|rQddg|z}ddg|z}d	�|d|d
z���|d<d	�|d|���|d<|S)
N�alignT)r�r�c3�lK�|]/}|�d��|�d��z
V��0dSr6r7r9s  r#r$z#align_attributes.<locals>.<genexpr>[r:r%r�r�r�r�r�r�r*r,)r~r)r<�attsr=�aligns�spacings     r#�align_attributesrEXs���� �"�"�D��A�A�D�A�A�A�A�A�D��9��6�"�T�)����,��%��!�h�h�v�g�t�A�v�g��7�7��]�� #�����$��� 8� 8��_���Kr%c	�v�td���}|}|s�d|d<t|���d��}t|��dkrHt	��}|�t
t|��fit|������t||��|�
��S)zoReturn string with MathML code corresponding to `tex_math`.

    Set `inline` to False for displayed math.
    z"http://www.w3.org/1998/Math/MathML)�xmlnsrJrIz\\r�)r�rr�rrhrrXrfrEr�r7)�tex_math�inline�	math_treer�r<s     r#�
tex2mathmlrKms����?�@�@�@�I��D��?�&�	�)���X�&�&�,�,�U�3�3���t�9�9�q�=�=��5�5�D����V�C��I�I�>�>�&6�t�&<�&<�>�>�
?�
?�
?��T�8�$�$�$�� � �"�"�"r%)r�)T)LrQr�r�docutils.utils.mathrr�	mathalphar�r�r��updater�r�r�	mathfencer��	mathcloser�mathbin�mathrel�mathord�	mathpunct�mathopr�r�r�r	r
rrr�rRr/rrrrr�rXr\r^rfrhrjrnrprrrtryr{r}rrr�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�rrr>rErKr r%r#�<module>rVsL
�� ��
�	�	�	�����:�:�:�:�:�:�:�:��
������
�8�h��h���x�(�
��	+�+�����������

�

�	�
���A�A�@�A�A�A�A�A�A�
-�,�,�,������������!��%�*�����.��4���8���8�	�
�8���8�
��8���8���8���8���8���8���#���(���#�� �(�!�"�(�#��&
���K�)�*�*�*����K�(�)�)�)����K�)�*�*�*�

��.�
��.�
��.�	
�
�.�
��.�

��.�
��.�
��.�
���
��(�
���
���
��H�
�"�X�#
�$�X�%
�&�X�'
�(�X�)
�*������7
�
�
�	�:
����$�%�%�%�	����$�%�%�%�	����$�%�%�%�	����&�'�'�'�	����#�$�$�$�	�������������������	�	��4�
�!� �%�%�#�%�%�%�%�&�&�&�&�
�
��$!� � � � � �!�� � � �!����(-�,�,�,�,�,�,�	�	��!1� 0� 0� 0� 0�		�	��!� � ���������	
�
��������#��
�
��+/��B�B�*/��B�B�*/��B�B�*/��B�B�	��
��2�h� $�a� �"�"�#%�'��^�,�b�1��[�)�2�.��O�Q�'�(��^�,���.B�C��[�)�O�Q�+?�@�

�

�	�A�@�@������������
�
�
� @�@�@�@�@�@�@�@�|�����T���������4����>N�N�N�N�N�D�N�N�N������-���������-���������}���������}���������M���������]����=�=�=�=�=��=�=�=������I����������������������������������������,�����:���������:���������j���������T���������D����" ��������������J���������D���������T����"�"�"�:
"�
"�
"�6)�)�)�>9�9�9�b���,R�R�R�>7�7�7�f{:�{:�{:�B����B���8���"���"	�	�	�*#�#�#�#�#�#r%

Hacked By AnonymousFox1.0, Coded By AnonymousFox