| Server IP : 167.99.254.82 / Your IP : 216.73.216.229 Web Server : Apache System : Linux host.techisquad.com 5.15.0-190-generic #200-Ubuntu SMP Fri Aug 7 15:06:04 UTC 2026 x86_64 User : pawluxera ( 1011) PHP Version : 8.1.34 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/lib/python3/dist-packages/docutils/utils/math/__pycache__/ |
Upload File : |
o
n��_ � @ s\ d dl mZ d dlZdZddd�Zddd�Zdd d
�Zedkr,dZe ee��
d
�� dS dS )� )�print_functionNzP\documentclass{article}
\usepackage{amsmath}
\begin{document}
%s
\end{document}
c
C s& t jg d�t jt jt jdd�}|j�t| �d�� |j�� |j� � }|j
� � �d�}|r<|�d�dks7|s<|�
|� t jg d�t jt jt jdd�}|j�|� |j�� |j� � �d�}|j
� � �d�}|rv|�d�dksq|sv|�
|� |�d�|�d �d
}} ||| � }d|v r�t|��|S )zdConvert LaTeX math code to MathML with LaTeXML_
.. _LaTeXML: http://dlmf.nist.gov/LaTeXML/
)�latexml�-z--inputencoding=utf8T��stdin�stdout�stderr� close_fds�utf8�Errorr )�latexmlpostr z--nonumbersectionsz--format=xhtmlz--�<math�</math>� zclass="ltx_ERROR)�
subprocess�Popen�PIPEr �write�document_template�encode�closer �readr �decode�find�error�SyntaxError)
� math_code�reporter�p�latexml_code�latexml_err�post_p�result�
post_p_err�start�end� r&