本文整理汇总了Python中src.ooxml_to_latex.OOXMLtoLatexParser类的典型用法代码示例。如果您正苦于以下问题:Python OOXMLtoLatexParser类的具体用法?Python OOXMLtoLatexParser怎么用?Python OOXMLtoLatexParser使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了OOXMLtoLatexParser类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。
示例1: test_fractions_without_bar_must_be_a_binom
def test_fractions_without_bar_must_be_a_binom(self):
xml_string = read_xml(
"fractions_without_bar_must_be_a_binom.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r"\binom{{\ n}}{{\ 0}}", ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例2: test_sum
def test_sum(self):
xml_string = read_xml("sum.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertEquals(r"\bigcap _{}^{}{\ l=}\bigcap _{{\ i\in I}}^{}{\ S}_{{\ i}}{\ =}"
r"\left \{{\ x/ x\in }{\ S}_{{\ i}}{\ para\ cada\ i\in I}\right \}", ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例3: test_expansao_de_taylor
def test_expansao_de_taylor(self):
xml_string = read_xml("expansao_de_taylor.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r'{\ e}^{{\ x}}{\ =1+}\frac{{\ x}}{{\ 1\text{!} }}{\ +}\frac{{\ x}^{{\ 2}}}{{\ '
r'2\text{!} }}{\ +}'
r'\frac{{\ x}^{{\ 3}}}{{\ 3\text{!} }}{\ +\ldots ,}{\ -\infty <x<\infty }',
ooxml_to_latex.result)
开发者ID:qmagico,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例4: test_insert_parenthesis_in_superscript
def test_insert_parenthesis_in_superscript(self):
xml_string = read_xml(
"insert_parenthesis_in_superscript.xml", bug_fixes_path)
xml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertEquals(r"\left ({\ a+b}\right )^{{\ n}}", xml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例5: test_radius_of_the_circle
def test_radius_of_the_circle(self):
xml_string = read_xml('radius_of_the_circle.xml', fixtures_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertEquals(r'{\ C}{\ =}{\ \pi }{\ \cdot }{\ d}{\ =}{\ 2}{\ \cdot '
r'}{\ \pi }{\ \cdot }{\ r}', ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例6: test_identidade_trigonometrica1
def test_identidade_trigonometrica1(self):
xml_string = read_xml("identidade_trigonometrica1.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r'{\ sin}{\ \alpha }{\ \pm }{\ sin}{\ \beta }{\ =2}{\ sin}\frac{{\ 1}}{{\ 2}}'
r'\left ({\ \alpha \pm \beta }\right ){\ cos}\frac{{\ 1}}{{\ 2}}\left ({\ \alpha '
r'\mp \beta }\right )',
ooxml_to_latex.result)
开发者ID:qmagico,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例7: test_expansao_de_uma_soma
def test_expansao_de_uma_soma(self):
xml_string = read_xml("expansao_de_uma_soma.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r'\left ({\ 1+x}\right )^{{\ n}}{\ =1+}\frac{{\ nx}}{{\ 1\text{!} }}{\ +}'
r'\frac{{\ n}\left '
r'({\ n-1}\right ){\ x}^{{\ 2}}}{{\ 2\text{!} }}{\ +\ldots }',
ooxml_to_latex.result)
开发者ID:qmagico,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例8: test_serie_de_fourier
def test_serie_de_fourier(self):
xml_string = read_xml("serie_de_Fourier.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r'{\ f}\left ({\ x}\right ){\ =}{\ a}_{{\ 0}}{\ +}\sum _{{\ n=1}}^{{\ \infty }}'
r'\left ({\ a}_{{\ n}}{\ cos}\frac{{\ n\pi x}}{{\ L}}{\ +}{\ b}_{{\ n}}{\ sin}'
r'\frac{{\ n\pi x}}{{\ L}}\right )',
ooxml_to_latex.result)
开发者ID:qmagico,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例9: test_integral_de_bloqueio_de_modo
def test_integral_de_bloqueio_de_modo(self):
xml_string = read_xml("integral_de_bloqueio_de_modo.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r'\frac{{\ 1}}{{\ 2}{\ \pi }}\int_{{\ 0}}^{{\ 2}{\ \pi }}\frac{{\ \mathscr{d} }'
r'{\ \theta }}{{\ a}{\ +}{\ b}{\ sin}{\ \theta }}{\ =}\frac{{\ 1}}{\sqrt{{\ a}^'
r'{{\ 2}}{\ -}{\ b}^{{\ 2}}}}',
ooxml_to_latex.result)
开发者ID:qmagico,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例10: test_integral_gaussiano
def test_integral_gaussiano(self):
xml_string = read_xml("integral_gaussiano.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r'\int_{{\ -\infty }}^{{\ \infty }}{\ e}^{{\ -}{\ x}^{{\ 2}}}{\ dx}{\ =}\left '
r'[\int_{{\ -\infty }}^{{\ \infty }}{\ e}^{{\ -}{\ x}^{{\ 2}}}{\ dx}\int_{{\ '
r'-\infty }}^{{\ \infty }}{\ e}^{{\ -}{\ y}^{{\ 2}}}{\ dy}\right ]^{{\ 1}{\ / }{\ 2}}',
ooxml_to_latex.result)
开发者ID:qmagico,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例11: test_bigcup_bug_fix
def test_bigcup_bug_fix(self):
xml_string = read_xml("bigcup.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertEquals(r'\left (\bigcup _{{\ i\in I}}^{}{\ S}_{{\ i}}\right )^{{\ c}}{\ =}\bigcap'
r' _{{\ i\in I}}^{}\left ({\ S}_{{\ i}}^{{\ c}}\right )', ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例12: test_underset_is_not_a_limit
def test_underset_is_not_a_limit(self):
xml_string = read_xml("underset_is_not_limit.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r'\underbrace{{\ 7}^{{\ k}}}_{{\ n\ digitos}}<{\ 7}^{{\ k+1}}{\ =7}\left ({\ 7}^'
r'{{\ k}}\right )<\underbrace{{\ 10}\left ({\ 7}^{{\ k}}\right )}_{{\ n+1'
r'\ digitos}}', ooxml_to_latex.result)
开发者ID:qmagico,项目名称:ooxml_to_latex_parser,代码行数:7,代码来源:tests.py
示例13: test_function
def test_function(self):
xml_string = read_xml('function.xml', fixtures_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertEquals(r'{\ f}\left ({\ x}\right ){\ =}\sum _{{\ i}{\ =}{\ 0}}^{{\ '
r'\infty }}\frac{{\ f}^{\left ({\ i}\right )}\left ({\ 0}\right )}{{\ i}'
r'{\ !}}{\ x}^{{\ i}}', ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:8,代码来源:tests.py
示例14: test_multiple_fractions
def test_multiple_fractions(self):
xml_string = read_xml("multiple_fractions.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r"{\ S}_{{\ n}}{\ :}\frac{{\ 1}}{\sqrt{{\ 1}}}{\ +}\frac{{\ 1}}"
r"{\sqrt{{\ 2}}}{\ +\cdots +}\frac{{\ 1}}{\sqrt"
r"{{\ n}}}{\ \geq }\sqrt{{\ n}}", ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:8,代码来源:tests.py
示例15: test_laplaciano_em_cartesiano_e_esfera
def test_laplaciano_em_cartesiano_e_esfera(self):
xml_string = read_xml("laplaciano_em_cartesiano_e_esfera.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r'{\ \nabla }{\ \cdot }{\ \nabla }{\ \psi }{\ =}\frac{{\ \partial }^{{\ 2}}'
r'{\ \psi }}{{\ \partial }{\ x}^{{\ 2}}}{\ +}\frac{{\ \partial }^{{\ 2}}'
r'{\ \psi }}{{\ \partial }{\ y}^{{\ 2}}}{\ +}\frac{{\ \partial }^{{\ 2}}'
r'{\ \psi }}{{\ \partial }{\ z}^{{\ 2}}}{\ =}\frac{{\ 1}}{{\ r}^{{\ 2}}{\ sin}'
r'{\ \theta }}\left [{\ sin}{\ \theta }\frac{{\ \partial }}{{\ \partial }{\ r}}'
r'\left ({\ r}^{{\ 2}}\frac{{\ \partial }{\ \psi }}{{\ \partial }{\ r}}\right )'
r'{\ +}\frac{{\ \partial }}{{\ \partial }{\ \theta }}\left ({\ sin}{\ \theta }'
r'\frac{{\ \partial }{\ \psi }}{{\ \partial }{\ \theta }}\right ){\ +}\frac'
r'{{\ 1}}{{\ sin}{\ \theta }}\frac{{\ \partial }^{{\ 2}}{\ \psi }}{{\ \partial }'
r'{\ \varphi }^{{\ 2}}}\right ]',
ooxml_to_latex.result)
开发者ID:qmagico,项目名称:ooxml_to_latex_parser,代码行数:14,代码来源:tests.py
示例16: test_sup_does_not_work
def test_sup_does_not_work(self):
xml_string = read_xml("sup_does_not_work.xml", bug_fixes_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(xml_string, math_symbols=unicode_to_latex)
self.assertMultiLineEqual(r'{\ l=}\left \{{\ S}_{{\ k}}\right \}_{{\ k=1}}^{{\ 5}}', ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:5,代码来源:tests.py
示例17: test_frac
def test_frac(self):
xml_string = read_xml('frac.xml', fixtures_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertEquals(r'\frac{{\ 2}}{{\ 2}}', ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:6,代码来源:tests.py
示例18: test_ast
def test_ast(self):
xml_string = read_xml('ast.xml', fixtures_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertEquals('{\\ \\ast }', ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:6,代码来源:tests.py
示例19: test_times
def test_times(self):
xml_string = read_xml('times.xml', fixtures_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertEquals(r'{\ 1}{\ \cdot }{\ 2}', ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:6,代码来源:tests.py
示例20: test_supseteq
def test_supseteq(self):
xml_string = read_xml('supseteq.xml', fixtures_path)
ooxml_to_latex = OOXMLtoLatexParser.parse(
xml_string, math_symbols=unicode_to_latex)
self.assertEquals(r'{\ 2}{\ \supseteq }{\ 2}', ooxml_to_latex.result)
开发者ID:LuoZijun,项目名称:ooxml_to_latex_parser,代码行数:6,代码来源:tests.py
注:本文中的src.ooxml_to_latex.OOXMLtoLatexParser类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论