[oXygen-user] Word equations to oXygen Equation editor

leipold at comcast.net leipold at comcast.net
Wed Aug 12 10:37:23 CDT 2020


Hello, 

 

I have an extremely large document to convert from Word to Oxygen DITA. One of the biggest problems is equations, and there are thousands of them.

I found a way to export the equation to from word MathML and get this:
<mml:math xmlns:mml=" <http://www.w3.org/1998/Math/MathML> http://www.w3.org/1998/Math/MathML" xmlns:m=" <http://schemas.openxmlformats.org/officeDocument/2006/math%22%3E%3Cmml:msub%3E%3Cmml:mrow%3E%3Cmml:mi%3EC%3C/mml:mi%3E%3C/mml:mrow%3E%3Cmml:mrow%3E%3Cmml:mn%3E1%3C/mml:mn%3E%3Cmml:mi%3E%CF%95%3C/mml:mi%3E%3C/mml:mrow%3E%3C/mml:msub%3E%3Cmml:mtext> http://schemas.openxmlformats.org/offic ... <mml:mtext> </mml:mtext><mml:mo>=</mml:mo><mml:mtext> </mml:mtext><mml:msub><mml:mrow><mml:mi>C</mml:mi></mml:mrow><mml:mrow><mml:mi>d</mml:mi></mml:mrow></mml:msub><mml:mtext> </mml:mtext><mml:msub><mml:mrow><mml:mi>A</mml:mi></mml:mrow><mml:mrow><mml:mi>p</mml:mi><mml:mi>i</mml:mi><mml:mi>p</mml:mi><mml:mi>e</mml:mi></mml:mrow></mml:msub><mml:mtext> </mml:mtext><mml:msqrt><mml:mfrac><mml:mrow><mml:mn>2</mml:mn></mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:msub><mml:mrow><mml:mi>P</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mtext> </mml:mtext><mml:mo>-</mml:mo><mml:mtext> </mml:mtext><mml:msub><mml:mrow><mml:mi>P</mml:mi></mml:mrow><mml:mrow><mml:mi>p</mml:mi><mml:mi>s</mml:mi></mml:mrow></mml:msub><mml:mo>)</mml:mo><mml:mtext> </mml:mtext><mml:msub><mml:mrow><mml:mi>v</mml:mi></mml:mrow><mml:mrow><mml:mi>w</mml:mi><mml:mo>,</mml:mo><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:mfrac></mml:msqrt></mml:math>

I insert that into the equation editor and get this:
<p>MathML inline: <equation-inline>
<mml:math xmlns:mml=" <http://www.w3.org/1998/Math/MathML> http://www.w3.org/1998/Math/MathML" xmlns:m=" <http://schemas.openxmlformats.org/officeDocument/2006/math> http://schemas.openxmlformats.org/offic ... /2006/math">
<mml:mi>W</mml:mi><mml:mtext> 
</mml:mtext><mml:mo>=</mml:mo><mml:mtext> </mml:mtext><mml:msub><mml:mrow><mml:mi>C</mml:mi></mml:mrow><mml:mrow><mml:mi>d</mml:mi></mml:mrow></mml:msub><mml:mtext> </mml:mtext><mml:msub><mml:mrow><mml:mi>A</mml:mi></mml:mrow><mml:mrow><mml:mi>p</mml:mi><mml:mi>i</mml:mi><mml:mi>p</mml:mi><mml:mi>e</mml:mi></mml:mrow></mml:msub><mml:mtext> </mml:mtext><mml:msqrt><mml:mfrac><mml:mrow><mml:mn>2</mml:mn><mml:mtext> </mml:mtext><mml:mfenced open="[" close="]" separators="|"><mml:mrow><mml:msub><mml:mrow><mml:mi>P</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mtext> </mml:mtext><mml:mo>-</mml:mo><mml:mtext> </mml:mtext><mml:msub><mml:mrow><mml:mi>P</mml:mi></mml:mrow><mml:mrow><mml:mi>p</mml:mi><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:mfenced></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>v</mml:mi></mml:mrow><mml:mrow><mml:mi>w</mml:mi><mml:mo>,</mml:mo><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:mfrac></mml:msqrt></mml:math>
</equation-inline></p>

It looks fine in Author, but has element errors that MMM:Ml must be declared. It will not transform using the DITA Map PDF - based on HTML & CSS scenario.

I have gotten to the point where I just do not know how to fix this. I realize that the syntax isn't the same as:

<m:math display='inline'>
<m:semantics>
<m:mrow>
<m:msqrt>
...
But with thousands of these, I need the quickest way possible to get these equations in a format that can transform. I thought I had it because it finally looked right in Author, but I need to know how to add the correct element type to get it to transform.

Sorry if this topic has been addressed before. I didn't find it.

Thanks,

Debbi

 

Debbi Leipold | Mobile (410) 905-7948

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.oxygenxml.com/pipermail/oxygen-user/attachments/20200812/6cc69abf/attachment.html>


More information about the oXygen-user mailing list