mml 2.3.0 → 2.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.gitmodules +9 -0
- data/.rubocop.yml +4 -0
- data/.rubocop_todo.yml +83 -18
- data/Gemfile +0 -2
- data/README.adoc +176 -47
- data/Rakefile +16 -1
- data/lib/mml/base/common_attributes.rb +44 -0
- data/lib/mml/base/content/annotation.rb +28 -0
- data/lib/mml/base/content/annotation_xml.rb +31 -0
- data/lib/mml/base/content/apply.rb +27 -0
- data/lib/mml/base/content/arith.rb +243 -0
- data/lib/mml/base/content/bind.rb +27 -0
- data/lib/mml/base/content/bvar.rb +20 -0
- data/lib/mml/base/content/calculus.rb +103 -0
- data/lib/mml/base/content/cbytes.rb +24 -0
- data/lib/mml/base/content/cerror.rb +24 -0
- data/lib/mml/base/content/ci.rb +77 -0
- data/lib/mml/base/content/cn.rb +33 -0
- data/lib/mml/base/content/condition.rb +20 -0
- data/lib/mml/base/content/constants.rb +173 -0
- data/lib/mml/base/content/cs.rb +22 -0
- data/lib/mml/base/content/csymbol.rb +79 -0
- data/lib/mml/base/content/declare.rb +34 -0
- data/lib/mml/base/content/degree.rb +20 -0
- data/lib/mml/base/content/elementary_functions.rb +309 -0
- data/lib/mml/base/content/fn.rb +25 -0
- data/lib/mml/base/content/functions.rb +85 -0
- data/lib/mml/base/content/interval.rb +24 -0
- data/lib/mml/base/content/inverse.rb +25 -0
- data/lib/mml/base/content/lambda.rb +20 -0
- data/lib/mml/base/content/linear_algebra.rb +122 -0
- data/lib/mml/base/content/logic.rb +93 -0
- data/lib/mml/base/content/otherwise.rb +20 -0
- data/lib/mml/base/content/piece.rb +20 -0
- data/lib/mml/base/content/piecewise.rb +20 -0
- data/lib/mml/base/content/relations.rb +113 -0
- data/lib/mml/base/content/reln.rb +19 -0
- data/lib/mml/base/content/semantics.rb +27 -0
- data/lib/mml/base/content/sep.rb +19 -0
- data/lib/mml/base/content/sets.rb +163 -0
- data/lib/mml/base/content/share.rb +22 -0
- data/lib/mml/base/content/statistics.rb +95 -0
- data/lib/mml/base/content/vector_calculus.rb +63 -0
- data/lib/mml/base/content_loader.rb +195 -0
- data/lib/mml/base/maction.rb +1 -0
- data/lib/mml/base/math.rb +47 -0
- data/lib/mml/base/menclose.rb +1 -1
- data/lib/mml/base/mfenced.rb +2 -2
- data/lib/mml/base/mglyph.rb +2 -2
- data/lib/mml/base/mi.rb +9 -6
- data/lib/mml/base/mlabeledtr.rb +2 -6
- data/lib/mml/base/mn.rb +3 -2
- data/lib/mml/base/mo.rb +3 -3
- data/lib/mml/base/mrow.rb +0 -2
- data/lib/mml/base/ms.rb +4 -6
- data/lib/mml/base/mscarries.rb +1 -1
- data/lib/mml/base/mspace.rb +0 -2
- data/lib/mml/base/mstyle.rb +4 -8
- data/lib/mml/base/mtable.rb +8 -0
- data/lib/mml/base/mtd.rb +6 -0
- data/lib/mml/base/mtext.rb +0 -2
- data/lib/mml/base/semantics.rb +4 -2
- data/lib/mml/base/universal_presentation_attributes.rb +46 -0
- data/lib/mml/base/v3_common.rb +16 -0
- data/lib/mml/base/v3_presentation_attributes.rb +15 -0
- data/lib/mml/base/v4_attributes.rb +4 -18
- data/lib/mml/base.rb +11 -0
- data/lib/mml/common_elements.rb +336 -0
- data/lib/mml/context_configuration.rb +29 -0
- data/lib/mml/v2/annotation.rb +9 -0
- data/lib/mml/v2/annotation_xml.rb +9 -0
- data/lib/mml/v2/apply.rb +9 -0
- data/lib/mml/v2/arith.rb +93 -0
- data/lib/mml/v2/bind.rb +9 -0
- data/lib/mml/v2/bvar.rb +9 -0
- data/lib/mml/v2/calculus.rb +33 -0
- data/lib/mml/v2/ci.rb +9 -0
- data/lib/mml/v2/cn.rb +9 -0
- data/lib/mml/v2/common_elements.rb +34 -0
- data/lib/mml/v2/condition.rb +9 -0
- data/lib/mml/v2/configuration.rb +13 -0
- data/lib/mml/v2/constants.rb +65 -0
- data/lib/mml/v2/csymbol.rb +9 -0
- data/lib/mml/v2/degree.rb +9 -0
- data/lib/mml/v2/elementary_functions.rb +121 -0
- data/lib/mml/v2/fn.rb +9 -0
- data/lib/mml/v2/functions.rb +29 -0
- data/lib/mml/v2/interval.rb +9 -0
- data/lib/mml/v2/inverse.rb +9 -0
- data/lib/mml/v2/lambda.rb +9 -0
- data/lib/mml/v2/linear_algebra.rb +41 -0
- data/lib/mml/v2/logic.rb +33 -0
- data/lib/mml/v2/maction.rb +9 -0
- data/lib/mml/v2/maligngroup.rb +9 -0
- data/lib/mml/v2/malignmark.rb +9 -0
- data/lib/mml/v2/math.rb +11 -0
- data/lib/mml/v2/menclose.rb +9 -0
- data/lib/mml/v2/merror.rb +9 -0
- data/lib/mml/v2/mfenced.rb +9 -0
- data/lib/mml/v2/mfrac.rb +9 -0
- data/lib/mml/v2/mfraction.rb +9 -0
- data/lib/mml/v2/mglyph.rb +9 -0
- data/lib/mml/v2/mi.rb +9 -0
- data/lib/mml/v2/mlabeledtr.rb +9 -0
- data/lib/mml/v2/mlongdiv.rb +9 -0
- data/lib/mml/v2/mmultiscripts.rb +9 -0
- data/lib/mml/v2/mn.rb +9 -0
- data/lib/mml/v2/mo.rb +10 -0
- data/lib/mml/v2/mover.rb +9 -0
- data/lib/mml/v2/mpadded.rb +9 -0
- data/lib/mml/v2/mphantom.rb +9 -0
- data/lib/mml/v2/mprescripts.rb +9 -0
- data/lib/mml/v2/mroot.rb +9 -0
- data/lib/mml/v2/mrow.rb +9 -0
- data/lib/mml/v2/ms.rb +9 -0
- data/lib/mml/v2/mscarries.rb +9 -0
- data/lib/mml/v2/mscarry.rb +9 -0
- data/lib/mml/v2/msgroup.rb +9 -0
- data/lib/mml/v2/msline.rb +9 -0
- data/lib/mml/v2/mspace.rb +9 -0
- data/lib/mml/v2/msqrt.rb +9 -0
- data/lib/mml/v2/msrow.rb +9 -0
- data/lib/mml/v2/mstack.rb +9 -0
- data/lib/mml/v2/mstyle.rb +10 -0
- data/lib/mml/v2/msub.rb +9 -0
- data/lib/mml/v2/msubsup.rb +9 -0
- data/lib/mml/v2/msup.rb +9 -0
- data/lib/mml/v2/mtable.rb +9 -0
- data/lib/mml/v2/mtd.rb +9 -0
- data/lib/mml/v2/mtext.rb +9 -0
- data/lib/mml/v2/mtr.rb +9 -0
- data/lib/mml/v2/munder.rb +9 -0
- data/lib/mml/v2/munderover.rb +9 -0
- data/lib/mml/v2/namespace.rb +7 -0
- data/lib/mml/v2/none.rb +9 -0
- data/lib/mml/v2/otherwise.rb +9 -0
- data/lib/mml/v2/piece.rb +9 -0
- data/lib/mml/v2/piecewise.rb +9 -0
- data/lib/mml/v2/relations.rb +41 -0
- data/lib/mml/v2/reln.rb +13 -0
- data/lib/mml/v2/semantics.rb +9 -0
- data/lib/mml/v2/sep.rb +9 -0
- data/lib/mml/v2/sets.rb +57 -0
- data/lib/mml/v2/statistics.rb +33 -0
- data/lib/mml/v2/vector_calculus.rb +21 -0
- data/lib/mml/v2.rb +311 -0
- data/lib/mml/v3/annotation.rb +10 -0
- data/lib/mml/v3/annotation_xml.rb +10 -0
- data/lib/mml/v3/apply.rb +10 -0
- data/lib/mml/v3/arith.rb +115 -0
- data/lib/mml/v3/bind.rb +10 -0
- data/lib/mml/v3/calculus.rb +40 -0
- data/lib/mml/v3/cbytes.rb +10 -0
- data/lib/mml/v3/cerror.rb +10 -0
- data/lib/mml/v3/ci.rb +10 -0
- data/lib/mml/v3/cn.rb +10 -0
- data/lib/mml/v3/common_elements.rb +34 -0
- data/lib/mml/v3/constants.rb +80 -0
- data/lib/mml/v3/constructs.rb +55 -0
- data/lib/mml/v3/cs.rb +10 -0
- data/lib/mml/v3/csymbol.rb +10 -0
- data/lib/mml/v3/deprecated_content.rb +29 -0
- data/lib/mml/v3/elementary_functions.rb +145 -0
- data/lib/mml/v3/functions.rb +35 -0
- data/lib/mml/v3/linear_algebra.rb +50 -0
- data/lib/mml/v3/logic.rb +40 -0
- data/lib/mml/v3/maction.rb +1 -1
- data/lib/mml/v3/math.rb +7 -1
- data/lib/mml/v3/mi.rb +1 -0
- data/lib/mml/v3/mn.rb +1 -0
- data/lib/mml/v3/mo.rb +1 -0
- data/lib/mml/v3/mrow.rb +1 -0
- data/lib/mml/v3/ms.rb +1 -0
- data/lib/mml/v3/mstyle.rb +1 -0
- data/lib/mml/v3/mtext.rb +1 -0
- data/lib/mml/v3/relations.rb +50 -0
- data/lib/mml/v3/sets.rb +70 -0
- data/lib/mml/v3/statistics.rb +40 -0
- data/lib/mml/v3/vector_calculus.rb +25 -0
- data/lib/mml/v3.rb +25 -0
- data/lib/mml/v4/a.rb +4 -3
- data/lib/mml/v4/annotation.rb +10 -0
- data/lib/mml/v4/annotation_xml.rb +14 -0
- data/lib/mml/v4/apply.rb +9 -0
- data/lib/mml/v4/arith.rb +93 -0
- data/lib/mml/v4/calculus.rb +25 -0
- data/lib/mml/v4/cbytes.rb +9 -0
- data/lib/mml/v4/cerror.rb +9 -0
- data/lib/mml/v4/ci.rb +9 -0
- data/lib/mml/v4/cn.rb +9 -0
- data/lib/mml/v4/common_elements.rb +33 -0
- data/lib/mml/v4/constants.rb +65 -0
- data/lib/mml/v4/constructs.rb +49 -0
- data/lib/mml/v4/cs.rb +9 -0
- data/lib/mml/v4/csymbol.rb +9 -0
- data/lib/mml/v4/deprecated_content.rb +25 -0
- data/lib/mml/v4/elementary_functions.rb +118 -0
- data/lib/mml/v4/factorof.rb +9 -0
- data/lib/mml/v4/functions.rb +30 -0
- data/lib/mml/v4/limit.rb +9 -0
- data/lib/mml/v4/linear_algebra.rb +41 -0
- data/lib/mml/v4/logic.rb +33 -0
- data/lib/mml/v4/maction.rb +1 -2
- data/lib/mml/v4/maligngroup.rb +0 -1
- data/lib/mml/v4/malignmark.rb +0 -1
- data/lib/mml/v4/math.rb +1 -1
- data/lib/mml/v4/menclose.rb +0 -1
- data/lib/mml/v4/merror.rb +0 -1
- data/lib/mml/v4/mfenced.rb +0 -1
- data/lib/mml/v4/mfrac.rb +0 -1
- data/lib/mml/v4/mfraction.rb +0 -1
- data/lib/mml/v4/mglyph.rb +0 -1
- data/lib/mml/v4/mi.rb +1 -1
- data/lib/mml/v4/mlabeledtr.rb +0 -1
- data/lib/mml/v4/mlongdiv.rb +0 -1
- data/lib/mml/v4/mmultiscripts.rb +0 -1
- data/lib/mml/v4/mn.rb +1 -1
- data/lib/mml/v4/mo.rb +1 -1
- data/lib/mml/v4/mover.rb +0 -1
- data/lib/mml/v4/mpadded.rb +0 -1
- data/lib/mml/v4/mphantom.rb +0 -1
- data/lib/mml/v4/mprescripts.rb +0 -1
- data/lib/mml/v4/mroot.rb +0 -1
- data/lib/mml/v4/mrow.rb +1 -1
- data/lib/mml/v4/ms.rb +1 -1
- data/lib/mml/v4/mscarries.rb +0 -1
- data/lib/mml/v4/mscarry.rb +0 -1
- data/lib/mml/v4/msgroup.rb +0 -1
- data/lib/mml/v4/msline.rb +0 -1
- data/lib/mml/v4/mspace.rb +0 -1
- data/lib/mml/v4/msqrt.rb +0 -1
- data/lib/mml/v4/msrow.rb +0 -1
- data/lib/mml/v4/mstack.rb +0 -1
- data/lib/mml/v4/mstyle.rb +1 -1
- data/lib/mml/v4/msub.rb +0 -1
- data/lib/mml/v4/msubsup.rb +0 -1
- data/lib/mml/v4/msup.rb +0 -1
- data/lib/mml/v4/mtable.rb +0 -1
- data/lib/mml/v4/mtd.rb +0 -1
- data/lib/mml/v4/mtext.rb +1 -1
- data/lib/mml/v4/mtr.rb +0 -1
- data/lib/mml/v4/munder.rb +0 -1
- data/lib/mml/v4/munderover.rb +0 -1
- data/lib/mml/v4/none.rb +0 -1
- data/lib/mml/v4/relations.rb +37 -0
- data/lib/mml/v4/semantics.rb +0 -1
- data/lib/mml/v4/sets.rb +57 -0
- data/lib/mml/v4/statistics.rb +33 -0
- data/lib/mml/v4/tendsto.rb +9 -0
- data/lib/mml/v4/vector_calculus.rb +21 -0
- data/lib/mml/v4.rb +421 -44
- data/lib/mml/version.rb +1 -1
- data/lib/mml/versioned_parser.rb +1 -1
- data/lib/mml.rb +3 -1
- data/reference-docs/mathml-source/pubtext/mathmlspec.dtd +150 -0
- data/reference-docs/mathml-source/pubtext/xmlspec.dtd +2649 -0
- data/reference-docs/mathml-source/readme.txt +40 -0
- data/reference-docs/mathml-source/run +296 -0
- data/reference-docs/mathml-source/style/html/html2xhtml.xsl +216 -0
- data/reference-docs/mathml-source/style/html/images.xsl +98 -0
- data/reference-docs/mathml-source/style/html/mml6.xsl +1156 -0
- data/reference-docs/mathml-source/style/html/mmldiff.xsl +566 -0
- data/reference-docs/mathml-source/style/html/mmlspec.xsl +2531 -0
- data/reference-docs/mathml-source/style/html/slices-common.xsl +312 -0
- data/reference-docs/mathml-source/style/html/slices.xsl +48 -0
- data/reference-docs/mathml-source/style/html/xmlspec.xsl +2542 -0
- data/reference-docs/mathml-source/style/pdf/mathmlspec.xsl +2510 -0
- data/reference-docs/mathml-source/xml/changes.xml +773 -0
- data/reference-docs/mathml-source/xml/character-set.xml +1011 -0
- data/reference-docs/mathml-source/xml/content-element-def.xml +6143 -0
- data/reference-docs/mathml-source/xml/content-markup.xml +8178 -0
- data/reference-docs/mathml-source/xml/contributors.xml +425 -0
- data/reference-docs/mathml-source/xml/dom-bindings.xml +20 -0
- data/reference-docs/mathml-source/xml/dom-intro.xml +114 -0
- data/reference-docs/mathml-source/xml/fundamentals.xml +1646 -0
- data/reference-docs/mathml-source/xml/glossary.xml +519 -0
- data/reference-docs/mathml-source/xml/interface.xml +1096 -0
- data/reference-docs/mathml-source/xml/introduction.xml +724 -0
- data/reference-docs/mathml-source/xml/mathml-css-sample.xml +304 -0
- data/reference-docs/mathml-source/xml/mathml-dom.xml +3813 -0
- data/reference-docs/mathml-source/xml/mathml-spec.xml +356 -0
- data/reference-docs/mathml-source/xml/mixing.xml +982 -0
- data/reference-docs/mathml-source/xml/operator-dict.xml +551 -0
- data/reference-docs/mathml-source/xml/parsing.xml +2565 -0
- data/reference-docs/mathml-source/xml/presentation-markup.xml +6834 -0
- data/reference-docs/mathml-source/xml/references.xml +323 -0
- data/reference-docs/mathml-source/xml/validation-grammar.xml +877 -0
- data/schemas/README.adoc +17 -0
- data/schemas/mathml2/common/common-attribs.xsd +41 -0
- data/schemas/mathml2/common/math.xsd +126 -0
- data/schemas/mathml2/common/xlink-href.xsd +20 -0
- data/schemas/mathml2/content/CVS/Entries +16 -0
- data/schemas/mathml2/content/CVS/Repository +1 -0
- data/schemas/mathml2/content/CVS/Root +1 -0
- data/schemas/mathml2/content/arith.xsd +90 -0
- data/schemas/mathml2/content/calculus.xsd +146 -0
- data/schemas/mathml2/content/common-attrib.xsd +30 -0
- data/schemas/mathml2/content/constants.xsd +83 -0
- data/schemas/mathml2/content/constructs.xsd +260 -0
- data/schemas/mathml2/content/elementary-functions.xsd +117 -0
- data/schemas/mathml2/content/functions.xsd +73 -0
- data/schemas/mathml2/content/linear-algebra.xsd +173 -0
- data/schemas/mathml2/content/logic.xsd +53 -0
- data/schemas/mathml2/content/relations.xsd +55 -0
- data/schemas/mathml2/content/semantics.xsd +85 -0
- data/schemas/mathml2/content/sets.xsd +236 -0
- data/schemas/mathml2/content/statistics.xsd +136 -0
- data/schemas/mathml2/content/tokens.xsd +120 -0
- data/schemas/mathml2/content/tokens.xsd.~1.3.~ +119 -0
- data/schemas/mathml2/content/vector-calculus.xsd +88 -0
- data/schemas/mathml2/mathml2.xsd +59 -0
- data/schemas/mathml2/presentation/action.xsd +44 -0
- data/schemas/mathml2/presentation/characters.xsd +37 -0
- data/schemas/mathml2/presentation/common-attribs.xsd +113 -0
- data/schemas/mathml2/presentation/common-types.xsd +103 -0
- data/schemas/mathml2/presentation/error.xsd +40 -0
- data/schemas/mathml2/presentation/layout.xsd +195 -0
- data/schemas/mathml2/presentation/scripts.xsd +186 -0
- data/schemas/mathml2/presentation/space.xsd +52 -0
- data/schemas/mathml2/presentation/style.xsd +69 -0
- data/schemas/mathml2/presentation/table.xsd +216 -0
- data/schemas/mathml2/presentation/tokens.xsd +124 -0
- data/schemas/mathml3/mathml3-common.xsd +99 -0
- data/schemas/mathml3/mathml3-content.xsd +684 -0
- data/schemas/mathml3/mathml3-presentation.xsd +2151 -0
- data/schemas/mathml3/mathml3-strict-content.xsd +186 -0
- data/schemas/mathml3/mathml3.xsd +9 -0
- data/schemas/mathml4/mathml4-content.rnc +382 -0
- data/schemas/mathml4/mathml4-core.rnc +361 -0
- data/schemas/mathml4/mathml4-presentation.rnc +358 -0
- data/schemas/mathml4/mathml4-strict-content.rnc +86 -0
- data/schemas/mathml4/mathml4.rnc +21 -0
- data/schemas/mathml4/mathml4.rnc.1 +21 -0
- data/schemas/mathml4/mathml4.rng +37 -0
- metadata +249 -2
data/lib/mml/v3/apply.rb
ADDED
data/lib/mml/v3/arith.rb
ADDED
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Mml
|
|
4
|
+
module V3
|
|
5
|
+
class Abs < Lutaml::Model::Serializable
|
|
6
|
+
include Base::Content::Abs
|
|
7
|
+
end
|
|
8
|
+
Configuration.register_model(Abs, id: :abs)
|
|
9
|
+
|
|
10
|
+
class Conjugate < Lutaml::Model::Serializable
|
|
11
|
+
include Base::Content::Conjugate
|
|
12
|
+
end
|
|
13
|
+
Configuration.register_model(Conjugate, id: :conjugate)
|
|
14
|
+
|
|
15
|
+
class Arg < Lutaml::Model::Serializable
|
|
16
|
+
include Base::Content::Arg
|
|
17
|
+
end
|
|
18
|
+
Configuration.register_model(Arg, id: :arg)
|
|
19
|
+
|
|
20
|
+
class Real < Lutaml::Model::Serializable
|
|
21
|
+
include Base::Content::Real
|
|
22
|
+
end
|
|
23
|
+
Configuration.register_model(Real, id: :real)
|
|
24
|
+
|
|
25
|
+
class Imaginary < Lutaml::Model::Serializable
|
|
26
|
+
include Base::Content::Imaginary
|
|
27
|
+
end
|
|
28
|
+
Configuration.register_model(Imaginary, id: :imaginary)
|
|
29
|
+
|
|
30
|
+
class Floor < Lutaml::Model::Serializable
|
|
31
|
+
include Base::Content::Floor
|
|
32
|
+
end
|
|
33
|
+
Configuration.register_model(Floor, id: :floor)
|
|
34
|
+
|
|
35
|
+
class Ceiling < Lutaml::Model::Serializable
|
|
36
|
+
include Base::Content::Ceiling
|
|
37
|
+
end
|
|
38
|
+
Configuration.register_model(Ceiling, id: :ceiling)
|
|
39
|
+
|
|
40
|
+
class Quotient < Lutaml::Model::Serializable
|
|
41
|
+
include Base::Content::Quotient
|
|
42
|
+
end
|
|
43
|
+
Configuration.register_model(Quotient, id: :quotient)
|
|
44
|
+
|
|
45
|
+
class Divide < Lutaml::Model::Serializable
|
|
46
|
+
include Base::Content::Divide
|
|
47
|
+
end
|
|
48
|
+
Configuration.register_model(Divide, id: :divide)
|
|
49
|
+
|
|
50
|
+
class Rem < Lutaml::Model::Serializable
|
|
51
|
+
include Base::Content::Rem
|
|
52
|
+
end
|
|
53
|
+
Configuration.register_model(Rem, id: :rem)
|
|
54
|
+
|
|
55
|
+
class Minus < Lutaml::Model::Serializable
|
|
56
|
+
include Base::Content::Minus
|
|
57
|
+
end
|
|
58
|
+
Configuration.register_model(Minus, id: :minus)
|
|
59
|
+
|
|
60
|
+
class Plus < Lutaml::Model::Serializable
|
|
61
|
+
include Base::Content::Plus
|
|
62
|
+
end
|
|
63
|
+
Configuration.register_model(Plus, id: :plus)
|
|
64
|
+
|
|
65
|
+
class Times < Lutaml::Model::Serializable
|
|
66
|
+
include Base::Content::Times
|
|
67
|
+
end
|
|
68
|
+
Configuration.register_model(Times, id: :times)
|
|
69
|
+
|
|
70
|
+
class Power < Lutaml::Model::Serializable
|
|
71
|
+
include Base::Content::Power
|
|
72
|
+
end
|
|
73
|
+
Configuration.register_model(Power, id: :power)
|
|
74
|
+
|
|
75
|
+
class Root < Lutaml::Model::Serializable
|
|
76
|
+
include Base::Content::Root
|
|
77
|
+
end
|
|
78
|
+
Configuration.register_model(Root, id: :root)
|
|
79
|
+
|
|
80
|
+
class Max < Lutaml::Model::Serializable
|
|
81
|
+
include Base::Content::Max
|
|
82
|
+
end
|
|
83
|
+
Configuration.register_model(Max, id: :max)
|
|
84
|
+
|
|
85
|
+
class Min < Lutaml::Model::Serializable
|
|
86
|
+
include Base::Content::Min
|
|
87
|
+
end
|
|
88
|
+
Configuration.register_model(Min, id: :min)
|
|
89
|
+
|
|
90
|
+
class Gcd < Lutaml::Model::Serializable
|
|
91
|
+
include Base::Content::Gcd
|
|
92
|
+
end
|
|
93
|
+
Configuration.register_model(Gcd, id: :gcd)
|
|
94
|
+
|
|
95
|
+
class Lcm < Lutaml::Model::Serializable
|
|
96
|
+
include Base::Content::Lcm
|
|
97
|
+
end
|
|
98
|
+
Configuration.register_model(Lcm, id: :lcm)
|
|
99
|
+
|
|
100
|
+
class Sum < Lutaml::Model::Serializable
|
|
101
|
+
include Base::Content::Sum
|
|
102
|
+
end
|
|
103
|
+
Configuration.register_model(Sum, id: :sum)
|
|
104
|
+
|
|
105
|
+
class Product < Lutaml::Model::Serializable
|
|
106
|
+
include Base::Content::Product
|
|
107
|
+
end
|
|
108
|
+
Configuration.register_model(Product, id: :product)
|
|
109
|
+
|
|
110
|
+
class Factorial < Lutaml::Model::Serializable
|
|
111
|
+
include Base::Content::Factorial
|
|
112
|
+
end
|
|
113
|
+
Configuration.register_model(Factorial, id: :factorial)
|
|
114
|
+
end
|
|
115
|
+
end
|
data/lib/mml/v3/bind.rb
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Mml
|
|
4
|
+
module V3
|
|
5
|
+
class Int < CommonElements
|
|
6
|
+
include Base::Content::Int
|
|
7
|
+
end
|
|
8
|
+
Configuration.register_model(Int, id: :int)
|
|
9
|
+
|
|
10
|
+
class Diff < CommonElements
|
|
11
|
+
include Base::Content::Diff
|
|
12
|
+
end
|
|
13
|
+
Configuration.register_model(Diff, id: :diff)
|
|
14
|
+
|
|
15
|
+
class Partialdiff < CommonElements
|
|
16
|
+
include Base::Content::Partialdiff
|
|
17
|
+
end
|
|
18
|
+
Configuration.register_model(Partialdiff, id: :partialdiff)
|
|
19
|
+
|
|
20
|
+
class Limit < CommonElements
|
|
21
|
+
include Base::Content::Limit
|
|
22
|
+
end
|
|
23
|
+
Configuration.register_model(Limit, id: :limit)
|
|
24
|
+
|
|
25
|
+
class Lowlimit < CommonElements
|
|
26
|
+
include Base::Content::Lowlimit
|
|
27
|
+
end
|
|
28
|
+
Configuration.register_model(Lowlimit, id: :lowlimit)
|
|
29
|
+
|
|
30
|
+
class Uplimit < CommonElements
|
|
31
|
+
include Base::Content::Uplimit
|
|
32
|
+
end
|
|
33
|
+
Configuration.register_model(Uplimit, id: :uplimit)
|
|
34
|
+
|
|
35
|
+
class Tendsto < CommonElements
|
|
36
|
+
include Base::Content::Tendsto
|
|
37
|
+
end
|
|
38
|
+
Configuration.register_model(Tendsto, id: :tendsto)
|
|
39
|
+
end
|
|
40
|
+
end
|
data/lib/mml/v3/ci.rb
ADDED
data/lib/mml/v3/cn.rb
ADDED
|
@@ -3,6 +3,40 @@
|
|
|
3
3
|
module Mml
|
|
4
4
|
module V3
|
|
5
5
|
class CommonElements < Mml::CommonElements
|
|
6
|
+
def self.lutaml_default_register
|
|
7
|
+
:mml_v3
|
|
8
|
+
end
|
|
9
|
+
|
|
10
|
+
attribute :cbytes_value, :cbytes, collection: true
|
|
11
|
+
attribute :cerror_value, :cerror, collection: true
|
|
12
|
+
attribute :cs_value, :cs, collection: true
|
|
13
|
+
attribute :factorof_value, :factorof, collection: true
|
|
14
|
+
attribute :limit_value, :limit, collection: true
|
|
15
|
+
attribute :tendsto_value, :tendsto, collection: true
|
|
16
|
+
attribute :annotation_value, :annotation, collection: true
|
|
17
|
+
attribute :fn_value, :fn, collection: true
|
|
18
|
+
attribute :reln_value, :reln, collection: true
|
|
19
|
+
attribute :declare_value, :declare, collection: true
|
|
20
|
+
attribute :share_value, :share, collection: true
|
|
21
|
+
attribute :domainofapplication_value, :domainofapplication,
|
|
22
|
+
collection: true
|
|
23
|
+
attribute :logbase_value, :logbase, collection: true
|
|
24
|
+
|
|
25
|
+
xml do
|
|
26
|
+
map_element "cbytes", to: :cbytes_value
|
|
27
|
+
map_element "cerror", to: :cerror_value
|
|
28
|
+
map_element "cs", to: :cs_value
|
|
29
|
+
map_element "factorof", to: :factorof_value
|
|
30
|
+
map_element "limit", to: :limit_value
|
|
31
|
+
map_element "tendsto", to: :tendsto_value
|
|
32
|
+
map_element "annotation", to: :annotation_value
|
|
33
|
+
map_element "fn", to: :fn_value
|
|
34
|
+
map_element "reln", to: :reln_value
|
|
35
|
+
map_element "declare", to: :declare_value
|
|
36
|
+
map_element "share", to: :share_value
|
|
37
|
+
map_element "domainofapplication", to: :domainofapplication_value
|
|
38
|
+
map_element "logbase", to: :logbase_value
|
|
39
|
+
end
|
|
6
40
|
end
|
|
7
41
|
end
|
|
8
42
|
end
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Mml
|
|
4
|
+
module V3
|
|
5
|
+
class Naturalnumbers < Lutaml::Model::Serializable
|
|
6
|
+
include Base::Content::Naturalnumbers
|
|
7
|
+
end
|
|
8
|
+
Configuration.register_model(Naturalnumbers, id: :naturalnumbers)
|
|
9
|
+
|
|
10
|
+
class Primes < Lutaml::Model::Serializable
|
|
11
|
+
include Base::Content::Primes
|
|
12
|
+
end
|
|
13
|
+
Configuration.register_model(Primes, id: :primes)
|
|
14
|
+
|
|
15
|
+
class Integers < Lutaml::Model::Serializable
|
|
16
|
+
include Base::Content::Integers
|
|
17
|
+
end
|
|
18
|
+
Configuration.register_model(Integers, id: :integers)
|
|
19
|
+
|
|
20
|
+
class Rationals < Lutaml::Model::Serializable
|
|
21
|
+
include Base::Content::Rationals
|
|
22
|
+
end
|
|
23
|
+
Configuration.register_model(Rationals, id: :rationals)
|
|
24
|
+
|
|
25
|
+
class Reals < Lutaml::Model::Serializable
|
|
26
|
+
include Base::Content::Reals
|
|
27
|
+
end
|
|
28
|
+
Configuration.register_model(Reals, id: :reals)
|
|
29
|
+
|
|
30
|
+
class Complexes < Lutaml::Model::Serializable
|
|
31
|
+
include Base::Content::Complexes
|
|
32
|
+
end
|
|
33
|
+
Configuration.register_model(Complexes, id: :complexes)
|
|
34
|
+
|
|
35
|
+
class Emptyset < Lutaml::Model::Serializable
|
|
36
|
+
include Base::Content::Emptyset
|
|
37
|
+
end
|
|
38
|
+
Configuration.register_model(Emptyset, id: :emptyset)
|
|
39
|
+
|
|
40
|
+
class Exponentiale < Lutaml::Model::Serializable
|
|
41
|
+
include Base::Content::Exponentiale
|
|
42
|
+
end
|
|
43
|
+
Configuration.register_model(Exponentiale, id: :exponentiale)
|
|
44
|
+
|
|
45
|
+
class Imaginaryi < Lutaml::Model::Serializable
|
|
46
|
+
include Base::Content::Imaginaryi
|
|
47
|
+
end
|
|
48
|
+
Configuration.register_model(Imaginaryi, id: :imaginaryi)
|
|
49
|
+
|
|
50
|
+
class Pi < Lutaml::Model::Serializable
|
|
51
|
+
include Base::Content::Pi
|
|
52
|
+
end
|
|
53
|
+
Configuration.register_model(Pi, id: :pi)
|
|
54
|
+
|
|
55
|
+
class Eulergamma < Lutaml::Model::Serializable
|
|
56
|
+
include Base::Content::Eulergamma
|
|
57
|
+
end
|
|
58
|
+
Configuration.register_model(Eulergamma, id: :eulergamma)
|
|
59
|
+
|
|
60
|
+
class Mtrue < Lutaml::Model::Serializable
|
|
61
|
+
include Base::Content::True
|
|
62
|
+
end
|
|
63
|
+
Configuration.register_model(Mtrue, id: :true) # rubocop:disable Lint/BooleanSymbol
|
|
64
|
+
|
|
65
|
+
class Mfalse < Lutaml::Model::Serializable
|
|
66
|
+
include Base::Content::False
|
|
67
|
+
end
|
|
68
|
+
Configuration.register_model(Mfalse, id: :false) # rubocop:disable Lint/BooleanSymbol
|
|
69
|
+
|
|
70
|
+
class Infinity < Lutaml::Model::Serializable
|
|
71
|
+
include Base::Content::Infinity
|
|
72
|
+
end
|
|
73
|
+
Configuration.register_model(Infinity, id: :infinity)
|
|
74
|
+
|
|
75
|
+
class Notanumber < Lutaml::Model::Serializable
|
|
76
|
+
include Base::Content::Notanumber
|
|
77
|
+
end
|
|
78
|
+
Configuration.register_model(Notanumber, id: :notanumber)
|
|
79
|
+
end
|
|
80
|
+
end
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Mml
|
|
4
|
+
module V3
|
|
5
|
+
class Bvar < CommonElements
|
|
6
|
+
include Base::Content::Bvar
|
|
7
|
+
end
|
|
8
|
+
Configuration.register_model(Bvar, id: :bvar)
|
|
9
|
+
|
|
10
|
+
class Condition < CommonElements
|
|
11
|
+
include Base::Content::Condition
|
|
12
|
+
end
|
|
13
|
+
Configuration.register_model(Condition, id: :condition)
|
|
14
|
+
|
|
15
|
+
class Interval < CommonElements
|
|
16
|
+
include Base::Content::Interval
|
|
17
|
+
end
|
|
18
|
+
Configuration.register_model(Interval, id: :interval)
|
|
19
|
+
|
|
20
|
+
class Lambda < CommonElements
|
|
21
|
+
include Base::Content::Lambda
|
|
22
|
+
end
|
|
23
|
+
Configuration.register_model(Lambda, id: :lambda)
|
|
24
|
+
|
|
25
|
+
class Inverse < CommonElements
|
|
26
|
+
include Base::Content::Inverse
|
|
27
|
+
end
|
|
28
|
+
Configuration.register_model(Inverse, id: :inverse)
|
|
29
|
+
|
|
30
|
+
class Degree < CommonElements
|
|
31
|
+
include Base::Content::Degree
|
|
32
|
+
end
|
|
33
|
+
Configuration.register_model(Degree, id: :degree)
|
|
34
|
+
|
|
35
|
+
class Piecewise < CommonElements
|
|
36
|
+
include Base::Content::Piecewise
|
|
37
|
+
end
|
|
38
|
+
Configuration.register_model(Piecewise, id: :piecewise)
|
|
39
|
+
|
|
40
|
+
class Piece < CommonElements
|
|
41
|
+
include Base::Content::Piece
|
|
42
|
+
end
|
|
43
|
+
Configuration.register_model(Piece, id: :piece)
|
|
44
|
+
|
|
45
|
+
class Otherwise < CommonElements
|
|
46
|
+
include Base::Content::Otherwise
|
|
47
|
+
end
|
|
48
|
+
Configuration.register_model(Otherwise, id: :otherwise)
|
|
49
|
+
|
|
50
|
+
class Sep < CommonElements
|
|
51
|
+
include Base::Content::Sep
|
|
52
|
+
end
|
|
53
|
+
Configuration.register_model(Sep, id: :sep)
|
|
54
|
+
end
|
|
55
|
+
end
|
data/lib/mml/v3/cs.rb
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Mml
|
|
4
|
+
module V3
|
|
5
|
+
# Fn represents a function applied to arguments (MathML 2 compatibility).
|
|
6
|
+
class Fn < CommonElements
|
|
7
|
+
include Base::Content::Fn
|
|
8
|
+
end
|
|
9
|
+
Configuration.register_model(Fn, id: :fn)
|
|
10
|
+
|
|
11
|
+
# Reln represents a relation (MathML 2 compatibility).
|
|
12
|
+
class Reln < CommonElements
|
|
13
|
+
include Base::Content::Reln
|
|
14
|
+
end
|
|
15
|
+
Configuration.register_model(Reln, id: :reln)
|
|
16
|
+
|
|
17
|
+
# Declare declares a mathematical object (MathML 2 compatibility).
|
|
18
|
+
class Declare < CommonElements
|
|
19
|
+
include Base::Content::Declare
|
|
20
|
+
end
|
|
21
|
+
Configuration.register_model(Declare, id: :declare)
|
|
22
|
+
|
|
23
|
+
# Share enables reuse of subexpressions (MathML 2 compatibility).
|
|
24
|
+
class Share < CommonElements
|
|
25
|
+
include Base::Content::Share
|
|
26
|
+
end
|
|
27
|
+
Configuration.register_model(Share, id: :share)
|
|
28
|
+
end
|
|
29
|
+
end
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Mml
|
|
4
|
+
module V3
|
|
5
|
+
class Exp < Lutaml::Model::Serializable
|
|
6
|
+
include Base::Content::Exp
|
|
7
|
+
end
|
|
8
|
+
Configuration.register_model(Exp, id: :exp)
|
|
9
|
+
|
|
10
|
+
class Ln < Lutaml::Model::Serializable
|
|
11
|
+
include Base::Content::Ln
|
|
12
|
+
end
|
|
13
|
+
Configuration.register_model(Ln, id: :ln)
|
|
14
|
+
|
|
15
|
+
class Log < Lutaml::Model::Serializable
|
|
16
|
+
include Base::Content::Log
|
|
17
|
+
end
|
|
18
|
+
Configuration.register_model(Log, id: :log)
|
|
19
|
+
|
|
20
|
+
class Logbase < CommonElements
|
|
21
|
+
include Base::Content::Logbase
|
|
22
|
+
end
|
|
23
|
+
Configuration.register_model(Logbase, id: :logbase)
|
|
24
|
+
|
|
25
|
+
class Sin < Lutaml::Model::Serializable
|
|
26
|
+
include Base::Content::Sin
|
|
27
|
+
end
|
|
28
|
+
Configuration.register_model(Sin, id: :sin)
|
|
29
|
+
|
|
30
|
+
class Cos < Lutaml::Model::Serializable
|
|
31
|
+
include Base::Content::Cos
|
|
32
|
+
end
|
|
33
|
+
Configuration.register_model(Cos, id: :cos)
|
|
34
|
+
|
|
35
|
+
class Tan < Lutaml::Model::Serializable
|
|
36
|
+
include Base::Content::Tan
|
|
37
|
+
end
|
|
38
|
+
Configuration.register_model(Tan, id: :tan)
|
|
39
|
+
|
|
40
|
+
class Sec < Lutaml::Model::Serializable
|
|
41
|
+
include Base::Content::Sec
|
|
42
|
+
end
|
|
43
|
+
Configuration.register_model(Sec, id: :sec)
|
|
44
|
+
|
|
45
|
+
class Csc < Lutaml::Model::Serializable
|
|
46
|
+
include Base::Content::Csc
|
|
47
|
+
end
|
|
48
|
+
Configuration.register_model(Csc, id: :csc)
|
|
49
|
+
|
|
50
|
+
class Cot < Lutaml::Model::Serializable
|
|
51
|
+
include Base::Content::Cot
|
|
52
|
+
end
|
|
53
|
+
Configuration.register_model(Cot, id: :cot)
|
|
54
|
+
|
|
55
|
+
class Arcsin < Lutaml::Model::Serializable
|
|
56
|
+
include Base::Content::Arcsin
|
|
57
|
+
end
|
|
58
|
+
Configuration.register_model(Arcsin, id: :arcsin)
|
|
59
|
+
|
|
60
|
+
class Arccos < Lutaml::Model::Serializable
|
|
61
|
+
include Base::Content::Arccos
|
|
62
|
+
end
|
|
63
|
+
Configuration.register_model(Arccos, id: :arccos)
|
|
64
|
+
|
|
65
|
+
class Arctan < Lutaml::Model::Serializable
|
|
66
|
+
include Base::Content::Arctan
|
|
67
|
+
end
|
|
68
|
+
Configuration.register_model(Arctan, id: :arctan)
|
|
69
|
+
|
|
70
|
+
class Arccot < Lutaml::Model::Serializable
|
|
71
|
+
include Base::Content::Arccot
|
|
72
|
+
end
|
|
73
|
+
Configuration.register_model(Arccot, id: :arccot)
|
|
74
|
+
|
|
75
|
+
class Arccsc < Lutaml::Model::Serializable
|
|
76
|
+
include Base::Content::Arccsc
|
|
77
|
+
end
|
|
78
|
+
Configuration.register_model(Arccsc, id: :arccsc)
|
|
79
|
+
|
|
80
|
+
class Arcsec < Lutaml::Model::Serializable
|
|
81
|
+
include Base::Content::Arcsec
|
|
82
|
+
end
|
|
83
|
+
Configuration.register_model(Arcsec, id: :arcsec)
|
|
84
|
+
|
|
85
|
+
class Sinh < Lutaml::Model::Serializable
|
|
86
|
+
include Base::Content::Sinh
|
|
87
|
+
end
|
|
88
|
+
Configuration.register_model(Sinh, id: :sinh)
|
|
89
|
+
|
|
90
|
+
class Cosh < Lutaml::Model::Serializable
|
|
91
|
+
include Base::Content::Cosh
|
|
92
|
+
end
|
|
93
|
+
Configuration.register_model(Cosh, id: :cosh)
|
|
94
|
+
|
|
95
|
+
class Tanh < Lutaml::Model::Serializable
|
|
96
|
+
include Base::Content::Tanh
|
|
97
|
+
end
|
|
98
|
+
Configuration.register_model(Tanh, id: :tanh)
|
|
99
|
+
|
|
100
|
+
class Sech < Lutaml::Model::Serializable
|
|
101
|
+
include Base::Content::Sech
|
|
102
|
+
end
|
|
103
|
+
Configuration.register_model(Sech, id: :sech)
|
|
104
|
+
|
|
105
|
+
class Csch < Lutaml::Model::Serializable
|
|
106
|
+
include Base::Content::Csch
|
|
107
|
+
end
|
|
108
|
+
Configuration.register_model(Csch, id: :csch)
|
|
109
|
+
|
|
110
|
+
class Coth < Lutaml::Model::Serializable
|
|
111
|
+
include Base::Content::Coth
|
|
112
|
+
end
|
|
113
|
+
Configuration.register_model(Coth, id: :coth)
|
|
114
|
+
|
|
115
|
+
class Arcsinh < Lutaml::Model::Serializable
|
|
116
|
+
include Base::Content::Arcsinh
|
|
117
|
+
end
|
|
118
|
+
Configuration.register_model(Arcsinh, id: :arcsinh)
|
|
119
|
+
|
|
120
|
+
class Arccosh < Lutaml::Model::Serializable
|
|
121
|
+
include Base::Content::Arccosh
|
|
122
|
+
end
|
|
123
|
+
Configuration.register_model(Arccosh, id: :arccosh)
|
|
124
|
+
|
|
125
|
+
class Arctanh < Lutaml::Model::Serializable
|
|
126
|
+
include Base::Content::Arctanh
|
|
127
|
+
end
|
|
128
|
+
Configuration.register_model(Arctanh, id: :arctanh)
|
|
129
|
+
|
|
130
|
+
class Arccoth < Lutaml::Model::Serializable
|
|
131
|
+
include Base::Content::Arccoth
|
|
132
|
+
end
|
|
133
|
+
Configuration.register_model(Arccoth, id: :arccoth)
|
|
134
|
+
|
|
135
|
+
class Arccsch < Lutaml::Model::Serializable
|
|
136
|
+
include Base::Content::Arccsch
|
|
137
|
+
end
|
|
138
|
+
Configuration.register_model(Arccsch, id: :arccsch)
|
|
139
|
+
|
|
140
|
+
class Arcsech < Lutaml::Model::Serializable
|
|
141
|
+
include Base::Content::Arcsech
|
|
142
|
+
end
|
|
143
|
+
Configuration.register_model(Arcsech, id: :arcsech)
|
|
144
|
+
end
|
|
145
|
+
end
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Mml
|
|
4
|
+
module V3
|
|
5
|
+
class Compose < Lutaml::Model::Serializable
|
|
6
|
+
include Base::Content::Compose
|
|
7
|
+
end
|
|
8
|
+
Configuration.register_model(Compose, id: :compose)
|
|
9
|
+
|
|
10
|
+
class Domain < Lutaml::Model::Serializable
|
|
11
|
+
include Base::Content::Domain
|
|
12
|
+
end
|
|
13
|
+
Configuration.register_model(Domain, id: :domain)
|
|
14
|
+
|
|
15
|
+
class Codomain < Lutaml::Model::Serializable
|
|
16
|
+
include Base::Content::Codomain
|
|
17
|
+
end
|
|
18
|
+
Configuration.register_model(Codomain, id: :codomain)
|
|
19
|
+
|
|
20
|
+
class Image < Lutaml::Model::Serializable
|
|
21
|
+
include Base::Content::Image
|
|
22
|
+
end
|
|
23
|
+
Configuration.register_model(Image, id: :image)
|
|
24
|
+
|
|
25
|
+
class Ident < Lutaml::Model::Serializable
|
|
26
|
+
include Base::Content::Ident
|
|
27
|
+
end
|
|
28
|
+
Configuration.register_model(Ident, id: :ident)
|
|
29
|
+
|
|
30
|
+
class Domainofapplication < CommonElements
|
|
31
|
+
include Base::Content::Domainofapplication
|
|
32
|
+
end
|
|
33
|
+
Configuration.register_model(Domainofapplication, id: :domainofapplication)
|
|
34
|
+
end
|
|
35
|
+
end
|