• Resolved vesnog

    (@vesnog)


    Hello,

    I recently started using LaTeX2HTML plugin in order to publish scientific content on my blog. However, when I use complex equations with split/align environments from amsmath package I have problems referring to these equations later on as instead of an equation number ??? is displayed. This is not the case with single line simple equations and they are correctly referenced with \eqref command.

    I browsed through the PHP files in the hope that I will point me in the right direction, yet failed as I do not know PHP. The way I use split environment is inside a parent equation environment just like I do in regular LaTeX with pdflatex as the compiler.

    \begin{equation}\label{eq:Polarization}<br>\begin{split}<br>P_{induced} &= Np \\<br>&= -Nex \\<br>&= \frac{Ne^2}{m_0}\frac{1}{(\omega_0^2-\omega^2 - i \gamma \omega)} \mathrm{E}<br>\end{split}<br>\end{equation}

    I appreciate your assistance and explanation on this matter. Furthermore, is it normal that Latex comments starting with % are displayed as they are on the output?

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author Van Abel

    (@van-abel)

    1. The LaTeX2HTML plugin of version newer than v2.0.0 do nothing to the labeling/referencing stuff, which is done by MathJax.

    So your problem is related to MathJax, and the bug seems has a workaround as mentioned here, Referring to labels defined in an expression with “split” or “aligned” environments seems broken:

    which is simple, just move your label at the bottom of split:

    
    \begin{equation}
    \begin{split}
    P_{induced} &= Np \\
    &= -Nex \\
    &= \frac{Ne^2}{m_0}\frac{1}{(\omega_0^2-\omega^2 - i \gamma \omega)} \mathrm{E}
    \end{split}
    \label{eq:Polarization}
    \end{equation}
    \eqref{eq:Polarization}
    

    2. Furthermore, is it normal that Latex comments starting with % are displayed as they are on the output?

    Of course not, the lines start with % should understand as comment out, thus

    
    % this is comment out
    % This is comment out too
    

    will be hidden completely on the output. This is what LaTeX2HTML expect and actually do.

    • This reply was modified 6 years, 2 months ago by Van Abel.
    • This reply was modified 6 years, 2 months ago by Van Abel.
Viewing 1 replies (of 1 total)
  • The topic ‘??? with align/split environment’ is closed to new replies.