diff --git a/latex2mathml/converter.py b/latex2mathml/converter.py index 195830a..39dfd4c 100644 --- a/latex2mathml/converter.py +++ b/latex2mathml/converter.py @@ -31,8 +31,11 @@ r">", r"<", r".", + r"\ast", r"\bigotimes", + r"\cdot", r"\centerdot", + r"\div", r"\dots", r"\dotsc", r"\dotso", @@ -51,6 +54,7 @@ r"\smallint", r"\smallsmile", r"\surd", + r"\times", r"\varsubsetneqq", r"\varsupsetneqq", ) diff --git a/tests/test_converter.py b/tests/test_converter.py index d8f22a2..fcf5a53 100644 --- a/tests/test_converter.py +++ b/tests/test_converter.py @@ -19,6 +19,9 @@ pytest.param("12x", MultiDict([("mn", "12"), ("mi", "x")]), id="numbers-and-identifiers"), pytest.param("+", {"mo": "+"}, id="single-operator"), pytest.param("3-2", MultiDict([("mn", "3"), ("mo", "−"), ("mn", "2")]), id="numbers-and-operators"), + pytest.param(r"3 \times 2", MultiDict([("mn", "3"), ("mo", "×"), ("mn", "2")]), id="numbers-and-operators-times"), + pytest.param(r"3 \cdot 2", MultiDict([("mn", "3"), ("mo", "·"), ("mn", "2")]), id="numbers-and-operators-cdot"), + pytest.param(r"3 \div 2", MultiDict([("mn", "3"), ("mo", "÷"), ("mn", "2")]), id="numbers-and-operators-div"), pytest.param( "3x*2", MultiDict([("mn", "3"), ("mi", "x"), ("mo", "*"), ("mn", "2")]),