Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • M MathJax
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 304
    • Issues 304
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 15
    • Merge requests 15
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • MathJax
  • MathJax
  • Issues
  • #2991
Closed
Open
Issue created Jan 25, 2023 by Chen Chen@CalaW

Unexpected space between text and number in \operatorname{}

Issue Summary

When rendering

\operatorname{atan2}(y,x)

using MathJax v3, a space was mistakenly inserted between “atan” and “2”.

operatorname

Steps to Reproduce:

Use MathJax v3 to render:

\operatorname{atan2}(y,x)

or

\DeclareMathOperator{\atantwo}{atan2}
\atantwo(y,x)

Below is MathML produced by MathJax v3:

<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
  <mrow data-mjx-texclass="OP">
    <mi>atan</mi>
    <mn>2</mn>
  </mrow>
  <mo stretchy="false">(</mo>
  <mi>y</mi>
  <mo>,</mo>
  <mi>x</mi>
  <mo stretchy="false">)</mo>
</math>

While MathJax v2 generates:

<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
  <mstyle displaystyle="true" scriptlevel="0">
    <mrow class="MJX-TeXAtom-ORD">
      <mi>atan2</mi>
      <mo>&#x2061;<!-- ⁡ --></mo>
      <mo stretchy="false">(</mo>
      <mi>y</mi>
      <mo>,</mo>
      <mi>x</mi>
      <mo stretchy="false">)</mo>
    </mrow>
  </mstyle>
</math>

Technical details:

  • MathJax Version: 3.2.2 (Latest, using official example)
  • Client OS: macOS 13.0 (22A380)
  • Browser: Safari 16.1 (18614.2.9.1.12)

Supporting information:

The result of MathJax v2 was generated by this online demo.

Assignee
Assign to
Time tracking