DISPLAY MATH rendering failure with `$$ … $$`

Tanjiro's Avatar

Tanjiro

21 Sep, 2023 11:27 AM

It seems that similar topics have been discussed in the past, but I couldn't find a solution. I would like to ask a question.

I am testing the following steps.

  1. uninstall Marked2
  2. install the latest version of Marked2 (Version 2.6.25 (1046))
  3. do initial settings in "Prose Setting" of Quick Config
  4. Open the following markdown file

The \\[ ... \\] format will display fine, but the $$ ... $$ format may or may not render. It seems to be related to the complexity of the formulas, but I don't know what is causing this.


OK

\[ \sum_{\mathbf{p} \in \mathcal{P}} \sum_{i \in \mathcal{I}(\mathbf{p})}\left(I_{i}\left(\pi_{i}(\mathbf{p})\right)-c(\mathbf{p})\right)^{2} . \]


NG

$$ \sum_{\mathbf{p} \in \mathcal{P}} \sum_{i \in \mathcal{I}(\mathbf{p})}\left(I_{i}\left(\pi_{i}(\mathbf{p})\right)-c(\mathbf{p})\right)^{2} . $$


Verify each component

OK

$$ \sum_{\mathbf{p} \in \mathcal{P}} $$


NG

$$ \sum_{\mathbf{p} \in \mathcal{P}} \sum_{i \in \mathcal{I}(\mathbf{p})} $$


OK

$$ \sum_{i \in \mathcal{I}(\mathbf{p})} $$


NG

$$ \left(I_{i}\left(\pi_{i}(\mathbf{p})\right)-c(\mathbf{p})\right)^{2} . $$


macOS Version 13.5.1 (22G90)

MacBook Pro 16 inch, 2019
2.3 GHz 8-Core Intel Core i9

  1. Support Staff 1 Posted by Brett on 22 Sep, 2023 04:38 PM

    Brett's Avatar

    It's happening on equations that have more than one underscore in them,
    I believe. This is being interpreted as Markdown italics, which then
    breaks the equation. I implemented the $$ syntax myself in Marked, so
    this is likely not a failure of MultiMarkdown. I'll have to dig into why
    these blocks are being processed as Markdown when they should be
    ignored.

    In the meantime, is it ok to use the \\[ syntax for the time being? I'll
    try to have a fix for this in the next update, but I'm rushing to get
    some Sonoma fixes out the door right now.

    -Brett

    On 21 Sep 2023, at 6:29, Tanjiro wrote:

  2. 2 Posted by Tanjiro on 23 Sep, 2023 03:26 AM

    Tanjiro's Avatar

    Hi Brett,

    Thank you for your response. I see that the problem was regarding the parsing of underscores.

    I use both obsidian and marked2 and it is not practical to use the \\[ syntax. I will use obsidian only for a while and look forward to the fix of the problem and the release of a new version.

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Already uploaded files

  • Screenshot_2023-09-21_at_20.21.16.png 259 KB

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac