Failure to validate MathML Schema
Having trouble installing Oxygen? Got a bug to report? Post it all here.
Failure to validate MathML Schema
Post by dsugar »
I'm trying to write an XSD for a project I'm going to be working on. There are going to be MathML islands in this content. When I attempt to validate the MathML Schema (downloaded from http://www.w3.org/Math/XMLSchema/). When I open up my xsd file which imports the mathml2.xsd from the distribution and attempt to vaidate in oxygen I get the error:
- [ constructs.xsd] E cos-nonambig: "http://www.w3.org/1998/Math/MathML":cn and "http://www.w3.org/1998/Math/MathML":cn (or elements from their substitution group) violate "Unique Particle Attribution". (50:32)
It turns out that I can comment out a piece of XSD in constructs.xsd and it then validates - though I'm not sure if the XSD is still correctly describing MathML.
Any suggestions? I don't have anything else to test this with to see if it is a problem in oxygen or a problem with the MathML Schema.
Thanks
Dave Sugar
dsugar at dolphinsoft dot com
- [ constructs.xsd] E cos-nonambig: "http://www.w3.org/1998/Math/MathML":cn and "http://www.w3.org/1998/Math/MathML":cn (or elements from their substitution group) violate "Unique Particle Attribution". (50:32)
It turns out that I can comment out a piece of XSD in constructs.xsd and it then validates - though I'm not sure if the XSD is still correctly describing MathML.
Any suggestions? I don't have anything else to test this with to see if it is a problem in oxygen or a problem with the MathML Schema.
Thanks
Dave Sugar
dsugar at dolphinsoft dot com
-
- Site Admin
- Posts: 2095
- Joined: Thu Jan 09, 2003 2:58 pm
Dear Dave,
The error is reported at:
following to fn.content definition we will find:
Now looking at Content-expr.class and Presentation-expr.class groups we see that they have equivalent content:
Thus the first element reference that will appear in the expanded groups will cause the Unique Particle Attribution (UPA) to fail. This is cn as you can see from the code below:
If you will comment out one of the fn.content entries and have something like:
(this is in file content/constructs.xsd at line 43), then the validation will work.
For more information about the error you can look at:
http://www.w3.org/TR/2001/REC-xmlschema ... s-nonambig
and
http://www.w3.org/TR/2001/REC-xmlschema ... #non-ambig
Basically the problem is if a processor finds the cn element and the model is:
then both choice alternatives can be followed. According with the UPA only one of the choice alternatives should accept cn.
Hope that helps,
George
The error is reported at:
Code: Select all
<xs:complexType name="fn.type">
<xs:group ref="fn.content"/> <!-- here -->
<xs:attributeGroup ref="fn.attlist"/>
</xs:complexType>
Code: Select all
<xs:group name="fn.content">
<xs:choice>
<xs:group ref="Content-expr.class"/>
<xs:group ref="Presentation-expr.class"/>
</xs:choice>
</xs:group>
Code: Select all
<xs:group name="Presentation-expr.class">
<xs:choice>
<xs:group ref="PresExpr.class"/>
<xs:group ref="ContExpr.class"/>
</xs:choice>
</xs:group>
<xs:group name="Content-expr.class">
<xs:choice>
<xs:group ref="ContExpr.class"/>
<xs:group ref="PresExpr.class"/>
</xs:choice>
</xs:group>
Code: Select all
<xs:group name="PresExpr.class">
<xs:choice>
<xs:group ref="Presentation-token.class"/>
<xs:group ref="Presentation-layout.class"/>
<xs:group ref="Presentation-script.class"/>
<xs:group ref="Presentation-table.class"/>
<xs:element ref="mspace"/>
<xs:element ref="maction"/>
<xs:element ref="merror"/>
<xs:element ref="mstyle"/>
</xs:choice>
</xs:group>
<xs:group name="ContExpr.class">
<xs:choice>
<xs:group ref="Content-tokens.class"/><!-- cn is referred here -->
<xs:group ref="Content-arith.class"/>
<xs:group ref="Content-functions.class"/>
<xs:group ref="Content-logic.class"/>
<xs:group ref="Content-constants.class"/>
<xs:group ref="Content-sets.class"/>
<xs:group ref="Content-relations.class"/>
<xs:group ref="Content-elementary-functions.class"/>
<xs:group ref="Content-calculus.class"/>
<xs:group ref="Content-linear-algebra.class"/>
<xs:group ref="Content-vector-calculus.class"/>
<xs:group ref="Content-statistics.class"/>
<xs:group ref="Content-constructs.class"/>
<xs:element ref="semantics"/>
</xs:choice>
</xs:group>
Code: Select all
<xs:group name="Content-tokens.class">
<xs:choice>
<xs:element ref="cn"/>
<xs:element ref="ci"/>
<xs:element ref="csymbol"/>
</xs:choice>
</xs:group>
Code: Select all
<xs:group name="fn.content">
<xs:choice>
<xs:group ref="Content-expr.class"/>
<!--<xs:group ref="Presentation-expr.class"/>-->
</xs:choice>
</xs:group>
For more information about the error you can look at:
http://www.w3.org/TR/2001/REC-xmlschema ... s-nonambig
and
http://www.w3.org/TR/2001/REC-xmlschema ... #non-ambig
Basically the problem is if a processor finds the cn element and the model is:
Code: Select all
<xs:choice>
<xs:group ref="Content-expr.class"/>
<xs:group ref="Presentation-expr.class"/>
</xs:choice>
Hope that helps,
George
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ Artificial Intelligence (AI Positron Assistant add-on)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service