pimath 0.0.125 → 0.0.127
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.
- package/.idea/inspectionProfiles/Project_Default.xml +5 -5
- package/.idea/shelf/Uncommitted_changes_before_Checkout_at_07_11_2023_08_30_[Default_Changelist]/shelved.patch +192 -192
- package/.idea/shelf/Uncommitted_changes_before_Checkout_at_09_11_2023_10_43_[Default_Changelist]/shelved.patch +2404 -2404
- package/.idea/shelf/Uncommitted_changes_before_Checkout_at_09_11_2023_11_01_[Default_Changelist]/shelved.patch +1362 -1362
- package/dev/pimath.js +7945 -0
- package/dev/pimath.js.map +1 -0
- package/dist/pimath.js +192 -221
- package/dist/pimath.js.map +1 -1
- package/dist/pimath.min.js +1 -1
- package/dist/pimath.min.js.map +1 -1
- package/docs/.nojekyll +1 -0
- package/docs/assets/highlight.css +78 -0
- package/docs/assets/main.js +59 -0
- package/docs/assets/navigation.js +1 -0
- package/docs/assets/search.js +1 -0
- package/docs/assets/style.css +1383 -0
- package/docs/classes/Logicalset.Logicalset.html +217 -0
- package/docs/classes/Polynom.Rational.html +397 -0
- package/docs/classes/Vector-1.Vector.html +490 -0
- package/docs/classes/Vector.Point.html +337 -0
- package/docs/classes/algebra_equation.Equation.html +790 -0
- package/docs/classes/algebra_linearSystem.LinearSystem.html +404 -0
- package/docs/classes/algebra_monom.Monom.html +962 -0
- package/docs/classes/algebra_polynom.Polynom.html +1275 -0
- package/docs/classes/coefficients_fraction.Fraction.html +934 -0
- package/docs/classes/geometry_circle.Circle.html +472 -0
- package/docs/classes/geometry_line.Line.html +774 -0
- package/docs/classes/geometry_triangle.Triangle.html +429 -0
- package/docs/classes/numeric.Numeric.html +265 -0
- package/docs/classes/shutingyard.Shutingyard.html +250 -0
- package/docs/enums/algebra_equation.PARTICULAR_SOLUTION.html +83 -0
- package/docs/enums/geometry_line.LinePropriety.html +97 -0
- package/docs/enums/shutingyard.ShutingyardMode.html +97 -0
- package/docs/enums/shutingyard.ShutingyardType.html +111 -0
- package/docs/index.html +63 -0
- package/docs/interfaces/algebra_equation.ISolution.html +105 -0
- package/docs/interfaces/algebra_polynom.IEuclidian.html +87 -0
- package/docs/interfaces/geometry_triangle.remarquableLines.html +163 -0
- package/docs/modules/Logicalset.html +65 -0
- package/docs/modules/Polynom.html +65 -0
- package/docs/modules/Vector-1.html +65 -0
- package/docs/modules/Vector.html +65 -0
- package/docs/modules/algebra_equation.html +69 -0
- package/docs/modules/algebra_linearSystem.html +61 -0
- package/docs/modules/algebra_monom.html +65 -0
- package/docs/modules/algebra_polynom.html +69 -0
- package/docs/modules/coefficients_fraction.html +65 -0
- package/docs/modules/geometry_circle.html +61 -0
- package/docs/modules/geometry_line.html +65 -0
- package/docs/modules/geometry_triangle.html +65 -0
- package/docs/modules/numeric.html +61 -0
- package/docs/modules/shutingyard.html +75 -0
- package/docs/types/algebra_monom.literalType.html +61 -0
- package/docs/types/algebra_polynom.PolynomParsingType.html +56 -0
- package/docs/types/coefficients_fraction.FractionParsingType.html +56 -0
- package/docs/types/shutingyard.Token.html +63 -0
- package/docs/types/shutingyard.tokenType.html +68 -0
- package/docs/variables/shutingyard.tokenConstant.html +61 -0
- package/esm/index.js +1 -1
- package/esm/index.js.map +1 -1
- package/esm/maths/algebra/monom.d.ts +19 -19
- package/esm/maths/algebra/monom.js +66 -66
- package/esm/maths/algebra/monom.js.map +1 -1
- package/esm/maths/algebra/polynom.d.ts +14 -14
- package/esm/maths/algebra/polynom.js +72 -50
- package/esm/maths/algebra/polynom.js.map +1 -1
- package/esm/maths/numeric.js +3 -48
- package/esm/maths/numeric.js.map +1 -1
- package/package.json +1 -1
- package/src/index.ts +1 -1
- package/src/maths/algebra/monom.ts +138 -130
- package/src/maths/algebra/polynom.ts +97 -82
- package/src/maths/geometry/line.ts +22 -25
- package/src/maths/geometry/point.ts +43 -29
- package/src/maths/numeric.ts +61 -90
- package/src/maths/randomization/random.ts +7 -0
- package/src/maths/randomization/rndGeometryCircle.ts +50 -0
- package/src/maths/randomization/rndTypes.ts +10 -4
- package/tests/algebra/linear.test.ts +1 -1
- package/tests/algebra/polynom.test.ts +162 -1
- package/tests/algebra/study.test.ts +1 -0
- package/tests/geometry/circle.test.ts +320 -115
- package/tests/geometry/line.test.ts +8 -17
- package/tests/numeric.test.ts +19 -3
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>tokenType | pimath</title><meta name="description" content="Documentation for pimath"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.15.1/dist/katex.min.css" integrity="sha384-R4558gYOUz8mP9YWpZJjofhk+zx0AS11p36HnD2ZKj/6JR5z27gSSULCNHIRReVs" crossorigin="anonymous"><script defer src="https://cdn.jsdelivr.net/npm/katex@0.15.1/dist/katex.min.js" integrity="sha384-z1fJDqw8ZApjGO3/unPWUPsIymfsJmyrDVWC8Tv/a1HeOtGmkwNd/7xUS0Xcnvsx" crossorigin="anonymous"></script><script defer src="https://cdn.jsdelivr.net/npm/katex@0.15.1/dist/contrib/auto-render.min.js" integrity="sha384-+XBljXPPiv+OzfbB3cVmLHf4hdUFHlWNZN5spNQ7rmHTXpd7WvJum6fIACpNNfIR" crossorigin="anonymous" onload="renderMathInElement(document.body);"></script></link>}); }</head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os"</script><header class="tsd-page-toolbar">
|
|
2
|
+
<div class="tsd-toolbar-contents container">
|
|
3
|
+
<div class="table-cell" id="tsd-search" data-base="..">
|
|
4
|
+
<div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div>
|
|
5
|
+
<div class="field">
|
|
6
|
+
<div id="tsd-toolbar-links"></div></div>
|
|
7
|
+
<ul class="results">
|
|
8
|
+
<li class="state loading">Preparing search index...</li>
|
|
9
|
+
<li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">pimath</a></div>
|
|
10
|
+
<div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="#icon-menu"></use></svg></a></div></div></header>
|
|
11
|
+
<div class="container container-main">
|
|
12
|
+
<div class="col-content">
|
|
13
|
+
<div class="tsd-page-title">
|
|
14
|
+
<ul class="tsd-breadcrumb">
|
|
15
|
+
<li><a href="../index.html">pimath</a></li>
|
|
16
|
+
<li><a href="../modules/shutingyard.html">shutingyard</a></li>
|
|
17
|
+
<li><a href="shutingyard.tokenType.html">tokenType</a></li></ul>
|
|
18
|
+
<h1>Type alias tokenType</h1></div>
|
|
19
|
+
<div class="tsd-signature"><span class="tsd-kind-type-alias">token<wbr/>Type</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{ </span><br/><span> </span>[<span class="tsd-kind-index-signature">key</span>: <span class="tsd-signature-type">string</span>]<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{ </span><br/><span> </span><span class="tsd-kind-property">associative</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">; </span><br/><span> </span><span class="tsd-kind-property">precedence</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">; </span><br/><span> </span><span class="tsd-kind-property">type</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">; </span><br/><span> </span><span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">; </span><br/><span class="tsd-signature-symbol">}</span></div>
|
|
20
|
+
<div class="tsd-type-declaration">
|
|
21
|
+
<h4>Type declaration</h4>
|
|
22
|
+
<ul class="tsd-parameters">
|
|
23
|
+
<li class="tsd-parameter-index-signature">
|
|
24
|
+
<h5><span class="tsd-signature-symbol">[</span><span class="tsd-kind-parameter">key</span>: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">]: </span><span class="tsd-signature-symbol">{ </span><br/><span> </span><span class="tsd-kind-property">associative</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">; </span><br/><span> </span><span class="tsd-kind-property">precedence</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">; </span><br/><span> </span><span class="tsd-kind-property">type</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">; </span><br/><span class="tsd-signature-symbol">}</span></h5>
|
|
25
|
+
<ul class="tsd-parameters">
|
|
26
|
+
<li class="tsd-parameter">
|
|
27
|
+
<h5><span class="tsd-kind-property">associative</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span></h5></li>
|
|
28
|
+
<li class="tsd-parameter">
|
|
29
|
+
<h5><span class="tsd-kind-property">precedence</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span></h5></li>
|
|
30
|
+
<li class="tsd-parameter">
|
|
31
|
+
<h5><span class="tsd-kind-property">type</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span></h5></li></ul></li></ul></div><aside class="tsd-sources">
|
|
32
|
+
<ul>
|
|
33
|
+
<li>Defined in <a href="https://github.com/basilgass/PI/blob/6e984d0/src/maths/shutingyard.ts#L1">shutingyard.ts:1</a></li></ul></aside></div>
|
|
34
|
+
<div class="col-sidebar">
|
|
35
|
+
<div class="page-menu">
|
|
36
|
+
<div class="tsd-navigation settings">
|
|
37
|
+
<details class="tsd-index-accordion"><summary class="tsd-accordion-summary">
|
|
38
|
+
<h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="#icon-chevronDown"></use></svg>Settings</h3></summary>
|
|
39
|
+
<div class="tsd-accordion-details">
|
|
40
|
+
<div class="tsd-filter-visibility">
|
|
41
|
+
<h4 class="uppercase">Member Visibility</h4><form>
|
|
42
|
+
<ul id="tsd-filter-options">
|
|
43
|
+
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><use href="#icon-checkbox"></use></svg><span>Protected</span></label></li>
|
|
44
|
+
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-private" name="private"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><use href="#icon-checkbox"></use></svg><span>Private</span></label></li>
|
|
45
|
+
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><use href="#icon-checkbox"></use></svg><span>Inherited</span></label></li>
|
|
46
|
+
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><use href="#icon-checkbox"></use></svg><span>External</span></label></li></ul></form></div>
|
|
47
|
+
<div class="tsd-theme-toggle">
|
|
48
|
+
<h4 class="uppercase">Theme</h4><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div></div>
|
|
49
|
+
<div class="site-menu">
|
|
50
|
+
<nav class="tsd-navigation"><a href="../index.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-1"></use></svg><span>pimath</span></a>
|
|
51
|
+
<ul class="tsd-small-nested-navigation" id="tsd-nav-container" data-base="..">
|
|
52
|
+
<li><a href="../modules/Logicalset.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>Logicalset</a></li>
|
|
53
|
+
<li><a href="../modules/Polynom.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>Polynom</a></li>
|
|
54
|
+
<li><a href="../modules/Vector.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>Vector</a></li>
|
|
55
|
+
<li><a href="../modules/Vector-1.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>Vector</a></li>
|
|
56
|
+
<li><a href="../modules/algebra_equation.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>algebra/equation</a></li>
|
|
57
|
+
<li><a href="../modules/algebra_linearSystem.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>algebra/linearSystem</a></li>
|
|
58
|
+
<li><a href="../modules/algebra_monom.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>algebra/monom</a></li>
|
|
59
|
+
<li><a href="../modules/algebra_polynom.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>algebra/polynom</a></li>
|
|
60
|
+
<li><a href="../modules/coefficients_fraction.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>coefficients/fraction</a></li>
|
|
61
|
+
<li><a href="../modules/geometry_circle.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>geometry/circle</a></li>
|
|
62
|
+
<li><a href="../modules/geometry_line.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>geometry/line</a></li>
|
|
63
|
+
<li><a href="../modules/geometry_triangle.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>geometry/triangle</a></li>
|
|
64
|
+
<li><a href="../modules/numeric.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>numeric</a></li>
|
|
65
|
+
<li><a href="../modules/shutingyard.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>shutingyard</a></li></ul></nav></div></div></div>
|
|
66
|
+
<div class="tsd-generator">
|
|
67
|
+
<p>Generated using <a href="https://typedoc.org/" rel="noopener" target="_blank">TypeDoc</a></p></div>
|
|
68
|
+
<div class="overlay"></div><svg style="display: none"><g id="icon-1"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-namespace)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.33 16V7.24H10.77L13.446 14.74C13.43 14.54 13.41 14.296 13.386 14.008C13.37 13.712 13.354 13.404 13.338 13.084C13.33 12.756 13.326 12.448 13.326 12.16V7.24H14.37V16H12.93L10.266 8.5C10.282 8.692 10.298 8.936 10.314 9.232C10.33 9.52 10.342 9.828 10.35 10.156C10.366 10.476 10.374 10.784 10.374 11.08V16H9.33Z" fill="var(--color-text)"></path></g><g id="icon-2"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-namespace)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.33 16V7.24H10.77L13.446 14.74C13.43 14.54 13.41 14.296 13.386 14.008C13.37 13.712 13.354 13.404 13.338 13.084C13.33 12.756 13.326 12.448 13.326 12.16V7.24H14.37V16H12.93L10.266 8.5C10.282 8.692 10.298 8.936 10.314 9.232C10.33 9.52 10.342 9.828 10.35 10.156C10.366 10.476 10.374 10.784 10.374 11.08V16H9.33Z" fill="var(--color-text)"></path></g><g id="icon-4"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-namespace)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.33 16V7.24H10.77L13.446 14.74C13.43 14.54 13.41 14.296 13.386 14.008C13.37 13.712 13.354 13.404 13.338 13.084C13.33 12.756 13.326 12.448 13.326 12.16V7.24H14.37V16H12.93L10.266 8.5C10.282 8.692 10.298 8.936 10.314 9.232C10.33 9.52 10.342 9.828 10.35 10.156C10.366 10.476 10.374 10.784 10.374 11.08V16H9.33Z" fill="var(--color-text)"></path></g><g id="icon-8"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-enum)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.45 16V7.24H14.49V8.224H10.518V10.936H14.07V11.908H10.518V15.016H14.49V16H9.45Z" fill="var(--color-text)"></path></g><g id="icon-16"><rect fill="var(--color-icon-background)" stroke="#FF984D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.354 16V7.24H12.174C12.99 7.24 13.638 7.476 14.118 7.948C14.606 8.412 14.85 9.036 14.85 9.82C14.85 10.604 14.606 11.232 14.118 11.704C13.638 12.168 12.99 12.4 12.174 12.4H10.434V16H9.354ZM10.434 11.428H12.174C12.646 11.428 13.022 11.284 13.302 10.996C13.59 10.7 13.734 10.308 13.734 9.82C13.734 9.324 13.59 8.932 13.302 8.644C13.022 8.356 12.646 8.212 12.174 8.212H10.434V11.428Z" fill="var(--color-text)"></path></g><g id="icon-32"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-variable)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.106 16L8.85 7.24H9.966L11.454 13.192C11.558 13.608 11.646 13.996 11.718 14.356C11.79 14.708 11.842 14.976 11.874 15.16C11.906 14.976 11.954 14.708 12.018 14.356C12.09 13.996 12.178 13.608 12.282 13.192L13.758 7.24H14.85L12.582 16H11.106Z" fill="var(--color-text)"></path></g><g id="icon-64"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-function)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.39 16V7.24H14.55V8.224H10.446V11.128H14.238V12.112H10.47V16H9.39Z" fill="var(--color-text)"></path></g><g id="icon-128"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-class)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)"></path></g><g id="icon-256"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-interface)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.51 16V15.016H11.298V8.224H9.51V7.24H14.19V8.224H12.402V15.016H14.19V16H9.51Z" fill="var(--color-text)"></path></g><g id="icon-512"><rect fill="var(--color-icon-background)" stroke="#4D7FFF" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)"></path></g><g id="icon-1024"><rect fill="var(--color-icon-background)" stroke="#FF984D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.354 16V7.24H12.174C12.99 7.24 13.638 7.476 14.118 7.948C14.606 8.412 14.85 9.036 14.85 9.82C14.85 10.604 14.606 11.232 14.118 11.704C13.638 12.168 12.99 12.4 12.174 12.4H10.434V16H9.354ZM10.434 11.428H12.174C12.646 11.428 13.022 11.284 13.302 10.996C13.59 10.7 13.734 10.308 13.734 9.82C13.734 9.324 13.59 8.932 13.302 8.644C13.022 8.356 12.646 8.212 12.174 8.212H10.434V11.428Z" fill="var(--color-text)"></path></g><g id="icon-2048"><rect fill="var(--color-icon-background)" stroke="#FF4DB8" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.162 16V7.24H10.578L11.514 10.072C11.602 10.328 11.674 10.584 11.73 10.84C11.794 11.088 11.842 11.28 11.874 11.416C11.906 11.28 11.954 11.088 12.018 10.84C12.082 10.584 12.154 10.324 12.234 10.06L13.122 7.24H14.538V16H13.482V12.82C13.482 12.468 13.49 12.068 13.506 11.62C13.53 11.172 13.558 10.716 13.59 10.252C13.622 9.78 13.654 9.332 13.686 8.908C13.726 8.476 13.762 8.1 13.794 7.78L12.366 12.16H11.334L9.894 7.78C9.934 8.092 9.97 8.456 10.002 8.872C10.042 9.28 10.078 9.716 10.11 10.18C10.142 10.636 10.166 11.092 10.182 11.548C10.206 12.004 10.218 12.428 10.218 12.82V16H9.162Z" fill="var(--color-text)"></path></g><g id="icon-4096"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-function)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.39 16V7.24H14.55V8.224H10.446V11.128H14.238V12.112H10.47V16H9.39Z" fill="var(--color-text)"></path></g><g id="icon-8192"><rect fill="var(--color-icon-background)" stroke="#FF984D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.354 16V7.24H12.174C12.99 7.24 13.638 7.476 14.118 7.948C14.606 8.412 14.85 9.036 14.85 9.82C14.85 10.604 14.606 11.232 14.118 11.704C13.638 12.168 12.99 12.4 12.174 12.4H10.434V16H9.354ZM10.434 11.428H12.174C12.646 11.428 13.022 11.284 13.302 10.996C13.59 10.7 13.734 10.308 13.734 9.82C13.734 9.324 13.59 8.932 13.302 8.644C13.022 8.356 12.646 8.212 12.174 8.212H10.434V11.428Z" fill="var(--color-text)"></path></g><g id="icon-16384"><rect fill="var(--color-icon-background)" stroke="#4D7FFF" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)"></path></g><g id="icon-32768"><rect fill="var(--color-icon-background)" stroke="#FF984D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.354 16V7.24H12.174C12.99 7.24 13.638 7.476 14.118 7.948C14.606 8.412 14.85 9.036 14.85 9.82C14.85 10.604 14.606 11.232 14.118 11.704C13.638 12.168 12.99 12.4 12.174 12.4H10.434V16H9.354ZM10.434 11.428H12.174C12.646 11.428 13.022 11.284 13.302 10.996C13.59 10.7 13.734 10.308 13.734 9.82C13.734 9.324 13.59 8.932 13.302 8.644C13.022 8.356 12.646 8.212 12.174 8.212H10.434V11.428Z" fill="var(--color-text)"></path></g><g id="icon-65536"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-type-alias)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.31 16V8.224H8.91V7.24H14.79V8.224H12.39V16H11.31Z" fill="var(--color-text)"></path></g><g id="icon-131072"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-type-alias)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.31 16V8.224H8.91V7.24H14.79V8.224H12.39V16H11.31Z" fill="var(--color-text)"></path></g><g id="icon-262144"><rect fill="var(--color-icon-background)" stroke="#FF4D4D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M8.85 16L11.13 7.24H12.582L14.85 16H13.758L13.182 13.672H10.53L9.954 16H8.85ZM10.746 12.76H12.954L12.282 10.06C12.154 9.548 12.054 9.12 11.982 8.776C11.91 8.432 11.866 8.208 11.85 8.104C11.834 8.208 11.79 8.432 11.718 8.776C11.646 9.12 11.546 9.544 11.418 10.048L10.746 12.76Z" fill="var(--color-text)"></path></g><g id="icon-524288"><rect fill="var(--color-icon-background)" stroke="#FF4D4D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M8.85 16L11.13 7.24H12.582L14.85 16H13.758L13.182 13.672H10.53L9.954 16H8.85ZM10.746 12.76H12.954L12.282 10.06C12.154 9.548 12.054 9.12 11.982 8.776C11.91 8.432 11.866 8.208 11.85 8.104C11.834 8.208 11.79 8.432 11.718 8.776C11.646 9.12 11.546 9.544 11.418 10.048L10.746 12.76Z" fill="var(--color-text)"></path></g><g id="icon-1048576"><rect fill="var(--color-icon-background)" stroke="#FF4D4D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M8.85 16L11.13 7.24H12.582L14.85 16H13.758L13.182 13.672H10.53L9.954 16H8.85ZM10.746 12.76H12.954L12.282 10.06C12.154 9.548 12.054 9.12 11.982 8.776C11.91 8.432 11.866 8.208 11.85 8.104C11.834 8.208 11.79 8.432 11.718 8.776C11.646 9.12 11.546 9.544 11.418 10.048L10.746 12.76Z" fill="var(--color-text)"></path></g><g id="icon-2097152"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-type-alias)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.31 16V8.224H8.91V7.24H14.79V8.224H12.39V16H11.31Z" fill="var(--color-text)"></path></g><g id="icon-4194304"><rect fill="var(--color-icon-background)" stroke="#FF4D82" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M10.354 17V8.24H13.066C13.586 8.24 14.042 8.348 14.434 8.564C14.826 8.772 15.13 9.064 15.346 9.44C15.562 9.816 15.67 10.256 15.67 10.76C15.67 11.352 15.514 11.86 15.202 12.284C14.898 12.708 14.482 13 13.954 13.16L15.79 17H14.518L12.838 13.28H11.434V17H10.354ZM11.434 12.308H13.066C13.514 12.308 13.874 12.168 14.146 11.888C14.418 11.6 14.554 11.224 14.554 10.76C14.554 10.288 14.418 9.912 14.146 9.632C13.874 9.352 13.514 9.212 13.066 9.212H11.434V12.308Z" fill="var(--color-text)"></path></g><g id="icon-chevronDown"><path d="M4.93896 8.531L12 15.591L19.061 8.531L16.939 6.409L12 11.349L7.06098 6.409L4.93896 8.531Z" fill="var(--color-text)"></path></g><g id="icon-chevronSmall"><path d="M1.5 5.50969L8 11.6609L14.5 5.50969L12.5466 3.66086L8 7.96494L3.45341 3.66086L1.5 5.50969Z" fill="var(--color-text)"></path></g><g id="icon-checkbox"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></g><g id="icon-menu"><rect x="1" y="3" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="7" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="11" width="14" height="2" fill="var(--color-text)"></rect></g><g id="icon-search"><path d="M15.7824 13.833L12.6666 10.7177C12.5259 10.5771 12.3353 10.499 12.1353 10.499H11.6259C12.4884 9.39596 13.001 8.00859 13.001 6.49937C13.001 2.90909 10.0914 0 6.50048 0C2.90959 0 0 2.90909 0 6.49937C0 10.0896 2.90959 12.9987 6.50048 12.9987C8.00996 12.9987 9.39756 12.4863 10.5008 11.6239V12.1332C10.5008 12.3332 10.5789 12.5238 10.7195 12.6644L13.8354 15.7797C14.1292 16.0734 14.6042 16.0734 14.8948 15.7797L15.7793 14.8954C16.0731 14.6017 16.0731 14.1267 15.7824 13.833ZM6.50048 10.499C4.29094 10.499 2.50018 8.71165 2.50018 6.49937C2.50018 4.29021 4.28781 2.49976 6.50048 2.49976C8.71001 2.49976 10.5008 4.28708 10.5008 6.49937C10.5008 8.70852 8.71314 10.499 6.50048 10.499Z" fill="var(--color-text)"></path></g><g id="icon-anchor"><g stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5"></path><path d="M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5"></path></g></g></svg></body></html>
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>tokenConstant | pimath</title><meta name="description" content="Documentation for pimath"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.15.1/dist/katex.min.css" integrity="sha384-R4558gYOUz8mP9YWpZJjofhk+zx0AS11p36HnD2ZKj/6JR5z27gSSULCNHIRReVs" crossorigin="anonymous"><script defer src="https://cdn.jsdelivr.net/npm/katex@0.15.1/dist/katex.min.js" integrity="sha384-z1fJDqw8ZApjGO3/unPWUPsIymfsJmyrDVWC8Tv/a1HeOtGmkwNd/7xUS0Xcnvsx" crossorigin="anonymous"></script><script defer src="https://cdn.jsdelivr.net/npm/katex@0.15.1/dist/contrib/auto-render.min.js" integrity="sha384-+XBljXPPiv+OzfbB3cVmLHf4hdUFHlWNZN5spNQ7rmHTXpd7WvJum6fIACpNNfIR" crossorigin="anonymous" onload="renderMathInElement(document.body);"></script></link>}); }</head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os"</script><header class="tsd-page-toolbar">
|
|
2
|
+
<div class="tsd-toolbar-contents container">
|
|
3
|
+
<div class="table-cell" id="tsd-search" data-base="..">
|
|
4
|
+
<div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div>
|
|
5
|
+
<div class="field">
|
|
6
|
+
<div id="tsd-toolbar-links"></div></div>
|
|
7
|
+
<ul class="results">
|
|
8
|
+
<li class="state loading">Preparing search index...</li>
|
|
9
|
+
<li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">pimath</a></div>
|
|
10
|
+
<div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="#icon-menu"></use></svg></a></div></div></header>
|
|
11
|
+
<div class="container container-main">
|
|
12
|
+
<div class="col-content">
|
|
13
|
+
<div class="tsd-page-title">
|
|
14
|
+
<ul class="tsd-breadcrumb">
|
|
15
|
+
<li><a href="../index.html">pimath</a></li>
|
|
16
|
+
<li><a href="../modules/shutingyard.html">shutingyard</a></li>
|
|
17
|
+
<li><a href="shutingyard.tokenConstant.html">tokenConstant</a></li></ul>
|
|
18
|
+
<h1>Variable tokenConstant<code class="tsd-tag ts-flagConst">Const</code> </h1></div>
|
|
19
|
+
<div class="tsd-signature"><span class="tsd-kind-variable">token<wbr/>Constant</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{ </span><br/><span> </span>[<span class="tsd-kind-index-signature">Key</span>: <span class="tsd-signature-type">string</span>]<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">; </span><br/><span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol"> = ...</span></div>
|
|
20
|
+
<div class="tsd-type-declaration">
|
|
21
|
+
<h4>Type declaration</h4>
|
|
22
|
+
<ul class="tsd-parameters">
|
|
23
|
+
<li class="tsd-parameter-index-signature">
|
|
24
|
+
<h5><span class="tsd-signature-symbol">[</span><span class="tsd-kind-parameter">Key</span>: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">]: </span><span class="tsd-signature-type">number</span></h5></li></ul></div><aside class="tsd-sources">
|
|
25
|
+
<ul>
|
|
26
|
+
<li>Defined in <a href="https://github.com/basilgass/PI/blob/6e984d0/src/maths/shutingyard.ts#L9">shutingyard.ts:9</a></li></ul></aside></div>
|
|
27
|
+
<div class="col-sidebar">
|
|
28
|
+
<div class="page-menu">
|
|
29
|
+
<div class="tsd-navigation settings">
|
|
30
|
+
<details class="tsd-index-accordion"><summary class="tsd-accordion-summary">
|
|
31
|
+
<h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="#icon-chevronDown"></use></svg>Settings</h3></summary>
|
|
32
|
+
<div class="tsd-accordion-details">
|
|
33
|
+
<div class="tsd-filter-visibility">
|
|
34
|
+
<h4 class="uppercase">Member Visibility</h4><form>
|
|
35
|
+
<ul id="tsd-filter-options">
|
|
36
|
+
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><use href="#icon-checkbox"></use></svg><span>Protected</span></label></li>
|
|
37
|
+
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-private" name="private"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><use href="#icon-checkbox"></use></svg><span>Private</span></label></li>
|
|
38
|
+
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><use href="#icon-checkbox"></use></svg><span>Inherited</span></label></li>
|
|
39
|
+
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><use href="#icon-checkbox"></use></svg><span>External</span></label></li></ul></form></div>
|
|
40
|
+
<div class="tsd-theme-toggle">
|
|
41
|
+
<h4 class="uppercase">Theme</h4><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div></div>
|
|
42
|
+
<div class="site-menu">
|
|
43
|
+
<nav class="tsd-navigation"><a href="../index.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-1"></use></svg><span>pimath</span></a>
|
|
44
|
+
<ul class="tsd-small-nested-navigation" id="tsd-nav-container" data-base="..">
|
|
45
|
+
<li><a href="../modules/Logicalset.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>Logicalset</a></li>
|
|
46
|
+
<li><a href="../modules/Polynom.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>Polynom</a></li>
|
|
47
|
+
<li><a href="../modules/Vector.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>Vector</a></li>
|
|
48
|
+
<li><a href="../modules/Vector-1.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>Vector</a></li>
|
|
49
|
+
<li><a href="../modules/algebra_equation.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>algebra/equation</a></li>
|
|
50
|
+
<li><a href="../modules/algebra_linearSystem.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>algebra/linearSystem</a></li>
|
|
51
|
+
<li><a href="../modules/algebra_monom.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>algebra/monom</a></li>
|
|
52
|
+
<li><a href="../modules/algebra_polynom.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>algebra/polynom</a></li>
|
|
53
|
+
<li><a href="../modules/coefficients_fraction.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>coefficients/fraction</a></li>
|
|
54
|
+
<li><a href="../modules/geometry_circle.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>geometry/circle</a></li>
|
|
55
|
+
<li><a href="../modules/geometry_line.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>geometry/line</a></li>
|
|
56
|
+
<li><a href="../modules/geometry_triangle.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>geometry/triangle</a></li>
|
|
57
|
+
<li><a href="../modules/numeric.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>numeric</a></li>
|
|
58
|
+
<li><a href="../modules/shutingyard.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2"></use></svg>shutingyard</a></li></ul></nav></div></div></div>
|
|
59
|
+
<div class="tsd-generator">
|
|
60
|
+
<p>Generated using <a href="https://typedoc.org/" rel="noopener" target="_blank">TypeDoc</a></p></div>
|
|
61
|
+
<div class="overlay"></div><svg style="display: none"><g id="icon-1"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-namespace)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.33 16V7.24H10.77L13.446 14.74C13.43 14.54 13.41 14.296 13.386 14.008C13.37 13.712 13.354 13.404 13.338 13.084C13.33 12.756 13.326 12.448 13.326 12.16V7.24H14.37V16H12.93L10.266 8.5C10.282 8.692 10.298 8.936 10.314 9.232C10.33 9.52 10.342 9.828 10.35 10.156C10.366 10.476 10.374 10.784 10.374 11.08V16H9.33Z" fill="var(--color-text)"></path></g><g id="icon-2"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-namespace)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.33 16V7.24H10.77L13.446 14.74C13.43 14.54 13.41 14.296 13.386 14.008C13.37 13.712 13.354 13.404 13.338 13.084C13.33 12.756 13.326 12.448 13.326 12.16V7.24H14.37V16H12.93L10.266 8.5C10.282 8.692 10.298 8.936 10.314 9.232C10.33 9.52 10.342 9.828 10.35 10.156C10.366 10.476 10.374 10.784 10.374 11.08V16H9.33Z" fill="var(--color-text)"></path></g><g id="icon-4"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-namespace)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.33 16V7.24H10.77L13.446 14.74C13.43 14.54 13.41 14.296 13.386 14.008C13.37 13.712 13.354 13.404 13.338 13.084C13.33 12.756 13.326 12.448 13.326 12.16V7.24H14.37V16H12.93L10.266 8.5C10.282 8.692 10.298 8.936 10.314 9.232C10.33 9.52 10.342 9.828 10.35 10.156C10.366 10.476 10.374 10.784 10.374 11.08V16H9.33Z" fill="var(--color-text)"></path></g><g id="icon-8"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-enum)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.45 16V7.24H14.49V8.224H10.518V10.936H14.07V11.908H10.518V15.016H14.49V16H9.45Z" fill="var(--color-text)"></path></g><g id="icon-16"><rect fill="var(--color-icon-background)" stroke="#FF984D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.354 16V7.24H12.174C12.99 7.24 13.638 7.476 14.118 7.948C14.606 8.412 14.85 9.036 14.85 9.82C14.85 10.604 14.606 11.232 14.118 11.704C13.638 12.168 12.99 12.4 12.174 12.4H10.434V16H9.354ZM10.434 11.428H12.174C12.646 11.428 13.022 11.284 13.302 10.996C13.59 10.7 13.734 10.308 13.734 9.82C13.734 9.324 13.59 8.932 13.302 8.644C13.022 8.356 12.646 8.212 12.174 8.212H10.434V11.428Z" fill="var(--color-text)"></path></g><g id="icon-32"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-variable)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.106 16L8.85 7.24H9.966L11.454 13.192C11.558 13.608 11.646 13.996 11.718 14.356C11.79 14.708 11.842 14.976 11.874 15.16C11.906 14.976 11.954 14.708 12.018 14.356C12.09 13.996 12.178 13.608 12.282 13.192L13.758 7.24H14.85L12.582 16H11.106Z" fill="var(--color-text)"></path></g><g id="icon-64"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-function)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.39 16V7.24H14.55V8.224H10.446V11.128H14.238V12.112H10.47V16H9.39Z" fill="var(--color-text)"></path></g><g id="icon-128"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-class)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)"></path></g><g id="icon-256"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-interface)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.51 16V15.016H11.298V8.224H9.51V7.24H14.19V8.224H12.402V15.016H14.19V16H9.51Z" fill="var(--color-text)"></path></g><g id="icon-512"><rect fill="var(--color-icon-background)" stroke="#4D7FFF" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)"></path></g><g id="icon-1024"><rect fill="var(--color-icon-background)" stroke="#FF984D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.354 16V7.24H12.174C12.99 7.24 13.638 7.476 14.118 7.948C14.606 8.412 14.85 9.036 14.85 9.82C14.85 10.604 14.606 11.232 14.118 11.704C13.638 12.168 12.99 12.4 12.174 12.4H10.434V16H9.354ZM10.434 11.428H12.174C12.646 11.428 13.022 11.284 13.302 10.996C13.59 10.7 13.734 10.308 13.734 9.82C13.734 9.324 13.59 8.932 13.302 8.644C13.022 8.356 12.646 8.212 12.174 8.212H10.434V11.428Z" fill="var(--color-text)"></path></g><g id="icon-2048"><rect fill="var(--color-icon-background)" stroke="#FF4DB8" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.162 16V7.24H10.578L11.514 10.072C11.602 10.328 11.674 10.584 11.73 10.84C11.794 11.088 11.842 11.28 11.874 11.416C11.906 11.28 11.954 11.088 12.018 10.84C12.082 10.584 12.154 10.324 12.234 10.06L13.122 7.24H14.538V16H13.482V12.82C13.482 12.468 13.49 12.068 13.506 11.62C13.53 11.172 13.558 10.716 13.59 10.252C13.622 9.78 13.654 9.332 13.686 8.908C13.726 8.476 13.762 8.1 13.794 7.78L12.366 12.16H11.334L9.894 7.78C9.934 8.092 9.97 8.456 10.002 8.872C10.042 9.28 10.078 9.716 10.11 10.18C10.142 10.636 10.166 11.092 10.182 11.548C10.206 12.004 10.218 12.428 10.218 12.82V16H9.162Z" fill="var(--color-text)"></path></g><g id="icon-4096"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-function)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.39 16V7.24H14.55V8.224H10.446V11.128H14.238V12.112H10.47V16H9.39Z" fill="var(--color-text)"></path></g><g id="icon-8192"><rect fill="var(--color-icon-background)" stroke="#FF984D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.354 16V7.24H12.174C12.99 7.24 13.638 7.476 14.118 7.948C14.606 8.412 14.85 9.036 14.85 9.82C14.85 10.604 14.606 11.232 14.118 11.704C13.638 12.168 12.99 12.4 12.174 12.4H10.434V16H9.354ZM10.434 11.428H12.174C12.646 11.428 13.022 11.284 13.302 10.996C13.59 10.7 13.734 10.308 13.734 9.82C13.734 9.324 13.59 8.932 13.302 8.644C13.022 8.356 12.646 8.212 12.174 8.212H10.434V11.428Z" fill="var(--color-text)"></path></g><g id="icon-16384"><rect fill="var(--color-icon-background)" stroke="#4D7FFF" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)"></path></g><g id="icon-32768"><rect fill="var(--color-icon-background)" stroke="#FF984D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M9.354 16V7.24H12.174C12.99 7.24 13.638 7.476 14.118 7.948C14.606 8.412 14.85 9.036 14.85 9.82C14.85 10.604 14.606 11.232 14.118 11.704C13.638 12.168 12.99 12.4 12.174 12.4H10.434V16H9.354ZM10.434 11.428H12.174C12.646 11.428 13.022 11.284 13.302 10.996C13.59 10.7 13.734 10.308 13.734 9.82C13.734 9.324 13.59 8.932 13.302 8.644C13.022 8.356 12.646 8.212 12.174 8.212H10.434V11.428Z" fill="var(--color-text)"></path></g><g id="icon-65536"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-type-alias)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.31 16V8.224H8.91V7.24H14.79V8.224H12.39V16H11.31Z" fill="var(--color-text)"></path></g><g id="icon-131072"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-type-alias)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.31 16V8.224H8.91V7.24H14.79V8.224H12.39V16H11.31Z" fill="var(--color-text)"></path></g><g id="icon-262144"><rect fill="var(--color-icon-background)" stroke="#FF4D4D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M8.85 16L11.13 7.24H12.582L14.85 16H13.758L13.182 13.672H10.53L9.954 16H8.85ZM10.746 12.76H12.954L12.282 10.06C12.154 9.548 12.054 9.12 11.982 8.776C11.91 8.432 11.866 8.208 11.85 8.104C11.834 8.208 11.79 8.432 11.718 8.776C11.646 9.12 11.546 9.544 11.418 10.048L10.746 12.76Z" fill="var(--color-text)"></path></g><g id="icon-524288"><rect fill="var(--color-icon-background)" stroke="#FF4D4D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M8.85 16L11.13 7.24H12.582L14.85 16H13.758L13.182 13.672H10.53L9.954 16H8.85ZM10.746 12.76H12.954L12.282 10.06C12.154 9.548 12.054 9.12 11.982 8.776C11.91 8.432 11.866 8.208 11.85 8.104C11.834 8.208 11.79 8.432 11.718 8.776C11.646 9.12 11.546 9.544 11.418 10.048L10.746 12.76Z" fill="var(--color-text)"></path></g><g id="icon-1048576"><rect fill="var(--color-icon-background)" stroke="#FF4D4D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M8.85 16L11.13 7.24H12.582L14.85 16H13.758L13.182 13.672H10.53L9.954 16H8.85ZM10.746 12.76H12.954L12.282 10.06C12.154 9.548 12.054 9.12 11.982 8.776C11.91 8.432 11.866 8.208 11.85 8.104C11.834 8.208 11.79 8.432 11.718 8.776C11.646 9.12 11.546 9.544 11.418 10.048L10.746 12.76Z" fill="var(--color-text)"></path></g><g id="icon-2097152"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-type-alias)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.31 16V8.224H8.91V7.24H14.79V8.224H12.39V16H11.31Z" fill="var(--color-text)"></path></g><g id="icon-4194304"><rect fill="var(--color-icon-background)" stroke="#FF4D82" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M10.354 17V8.24H13.066C13.586 8.24 14.042 8.348 14.434 8.564C14.826 8.772 15.13 9.064 15.346 9.44C15.562 9.816 15.67 10.256 15.67 10.76C15.67 11.352 15.514 11.86 15.202 12.284C14.898 12.708 14.482 13 13.954 13.16L15.79 17H14.518L12.838 13.28H11.434V17H10.354ZM11.434 12.308H13.066C13.514 12.308 13.874 12.168 14.146 11.888C14.418 11.6 14.554 11.224 14.554 10.76C14.554 10.288 14.418 9.912 14.146 9.632C13.874 9.352 13.514 9.212 13.066 9.212H11.434V12.308Z" fill="var(--color-text)"></path></g><g id="icon-chevronDown"><path d="M4.93896 8.531L12 15.591L19.061 8.531L16.939 6.409L12 11.349L7.06098 6.409L4.93896 8.531Z" fill="var(--color-text)"></path></g><g id="icon-chevronSmall"><path d="M1.5 5.50969L8 11.6609L14.5 5.50969L12.5466 3.66086L8 7.96494L3.45341 3.66086L1.5 5.50969Z" fill="var(--color-text)"></path></g><g id="icon-checkbox"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></g><g id="icon-menu"><rect x="1" y="3" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="7" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="11" width="14" height="2" fill="var(--color-text)"></rect></g><g id="icon-search"><path d="M15.7824 13.833L12.6666 10.7177C12.5259 10.5771 12.3353 10.499 12.1353 10.499H11.6259C12.4884 9.39596 13.001 8.00859 13.001 6.49937C13.001 2.90909 10.0914 0 6.50048 0C2.90959 0 0 2.90909 0 6.49937C0 10.0896 2.90959 12.9987 6.50048 12.9987C8.00996 12.9987 9.39756 12.4863 10.5008 11.6239V12.1332C10.5008 12.3332 10.5789 12.5238 10.7195 12.6644L13.8354 15.7797C14.1292 16.0734 14.6042 16.0734 14.8948 15.7797L15.7793 14.8954C16.0731 14.6017 16.0731 14.1267 15.7824 13.833ZM6.50048 10.499C4.29094 10.499 2.50018 8.71165 2.50018 6.49937C2.50018 4.29021 4.28781 2.49976 6.50048 2.49976C8.71001 2.49976 10.5008 4.28708 10.5008 6.49937C10.5008 8.70852 8.71314 10.499 6.50048 10.499Z" fill="var(--color-text)"></path></g><g id="icon-anchor"><g stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5"></path><path d="M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5"></path></g></g></svg></body></html>
|
package/esm/index.js
CHANGED
package/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,6CAAwC;AACxC,2CAAsC;AACtC,qDAAgD;AAChD,yDAAoD;AACpD,4DAAuD;AACvD,0DAAqD;AACrD,iDAA4C;AAC5C,qDAAgD;AAChD,uDAAkD;AAClD,+DAA0D;AAC1D,uDAAkD;AAClD,2DAAsD;AACtD,oDAA+C;AAC/C,gDAA2C;AAC3C,wDAAmD;AACnD,oDAA+C;AAC/C,kDAA6C;AAE7C,mBAAmB;AACN,QAAA,MAAM,GAAG;IAClB,WAAW,EAAE,yBAAW;IACxB,OAAO,EAAE,iBAAO;IAChB,MAAM,EAAE,eAAM;IACd,QAAQ,EAAE,mBAAQ;IAClB,IAAI,EAAE,iBAAO;IACb,KAAK,EAAE,aAAK;IACZ,OAAO,EAAE,iBAAO;IAChB,QAAQ,EAAE,mBAAQ;IAClB,YAAY,EAAE,2BAAY;IAC1B,QAAQ,EAAE,mBAAQ;IAClB,UAAU,EAAE,uBAAU;IACtB,MAAM,EAAE,eAAM;IACd,QAAQ,EAAE;QACN,MAAM,EAAE,eAAM;QACd,KAAK,EAAE,aAAK;QACZ,IAAI,EAAE,WAAI;QACV,QAAQ,EAAE,mBAAQ;QAClB,MAAM,EAAE,eAAM;KACjB;CACJ,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,6CAAwC;AACxC,2CAAsC;AACtC,qDAAgD;AAChD,yDAAoD;AACpD,4DAAuD;AACvD,0DAAqD;AACrD,iDAA4C;AAC5C,qDAAgD;AAChD,uDAAkD;AAClD,+DAA0D;AAC1D,uDAAkD;AAClD,2DAAsD;AACtD,oDAA+C;AAC/C,gDAA2C;AAC3C,wDAAmD;AACnD,oDAA+C;AAC/C,kDAA6C;AAE7C,mBAAmB;AACN,QAAA,MAAM,GAAG;IAClB,WAAW,EAAE,yBAAW;IACxB,OAAO,EAAE,iBAAO;IAChB,MAAM,EAAE,eAAM;IACd,QAAQ,EAAE,mBAAQ;IAClB,IAAI,EAAE,iBAAO;IACb,KAAK,EAAE,aAAK;IACZ,OAAO,EAAE,iBAAO;IAChB,QAAQ,EAAE,mBAAQ;IAClB,YAAY,EAAE,2BAAY;IAC1B,QAAQ,EAAE,mBAAQ;IAClB,UAAU,EAAE,uBAAU;IACtB,MAAM,EAAE,eAAM;IACd,QAAQ,EAAE;QACN,MAAM,EAAE,eAAM;QACd,KAAK,EAAE,aAAK;QACZ,IAAI,EAAE,WAAI;QACV,QAAQ,EAAE,mBAAQ;QAClB,MAAM,EAAE,eAAM;KACjB;CACJ,CAAC;AAEF,4BAA4B"}
|
|
@@ -4,8 +4,6 @@ export type literalType = {
|
|
|
4
4
|
[Key: string]: Fraction;
|
|
5
5
|
};
|
|
6
6
|
export declare class Monom {
|
|
7
|
-
private _coefficient;
|
|
8
|
-
private _literal;
|
|
9
7
|
/**
|
|
10
8
|
* Create a Monom
|
|
11
9
|
* Defined as \\(k \\cdot x^{n}\\), where \\( k,n \in \\mathbb{Q}\\).
|
|
@@ -13,6 +11,7 @@ export declare class Monom {
|
|
|
13
11
|
* @param value (optional) string The value that should be parse. Can be a Monom, a Fraction, a string or a number. If nothing is provided, it will return the trivial monom (0).
|
|
14
12
|
*/
|
|
15
13
|
constructor(value?: unknown);
|
|
14
|
+
private _coefficient;
|
|
16
15
|
/**
|
|
17
16
|
* Get the coefficient \\(k\\) of the Monom \\(k\\cdot x^{n}\\)
|
|
18
17
|
* @returns {Fraction}
|
|
@@ -23,22 +22,23 @@ export declare class Monom {
|
|
|
23
22
|
* @param {Fraction | number | string} F
|
|
24
23
|
*/
|
|
25
24
|
set coefficient(F: Fraction | number | string);
|
|
25
|
+
private _literal;
|
|
26
26
|
/**
|
|
27
27
|
* Get the literal part of \\(x^{n_1}y^{n_2}\\) as dictionary \\[\\begin{array}{ll}x&=n_1\\\\y&=n_2\\end{array}\\]
|
|
28
28
|
* @returns {literalType}
|
|
29
29
|
*/
|
|
30
30
|
get literal(): literalType;
|
|
31
|
+
/**
|
|
32
|
+
* Set the literal part of the monom. Must be a dictionary {x: Fraction, y: Fraction, ...}
|
|
33
|
+
* @param {literalType} L
|
|
34
|
+
*/
|
|
35
|
+
set literal(L: literalType);
|
|
31
36
|
/**
|
|
32
37
|
* Get the literal square roots of the Monom.
|
|
33
38
|
* TODO: remove this getter ? Is it used and is it correct ?
|
|
34
39
|
* @returns {literalType}
|
|
35
40
|
*/
|
|
36
41
|
get literalSqrt(): literalType;
|
|
37
|
-
/**
|
|
38
|
-
* Set the literal part of the monom. Must be a dictionary {x: Fraction, y: Fraction, ...}
|
|
39
|
-
* @param {literalType} L
|
|
40
|
-
*/
|
|
41
|
-
set literal(L: literalType);
|
|
42
42
|
/**
|
|
43
43
|
* Set the literal part of the monom from a string
|
|
44
44
|
* @param inputStr String like x^2y^3
|
|
@@ -53,7 +53,6 @@ export declare class Monom {
|
|
|
53
53
|
*/
|
|
54
54
|
get display(): string;
|
|
55
55
|
get dividers(): Monom[];
|
|
56
|
-
private _getLiteralDividers;
|
|
57
56
|
/**
|
|
58
57
|
* Display the monom, forcing the '+' sign to appear
|
|
59
58
|
*/
|
|
@@ -64,13 +63,22 @@ export declare class Monom {
|
|
|
64
63
|
* Get the tex output of the monom
|
|
65
64
|
*/
|
|
66
65
|
get tex(): string;
|
|
66
|
+
/**
|
|
67
|
+
* Get the least common multiple of monoms
|
|
68
|
+
* @param monoms Array of monoms
|
|
69
|
+
*/
|
|
70
|
+
static lcm: (...monoms: Monom[]) => Monom;
|
|
71
|
+
/**
|
|
72
|
+
* Multiply two monoms and return a NEW monom.
|
|
73
|
+
* @param monoms
|
|
74
|
+
*/
|
|
75
|
+
static xmultiply: (...monoms: Monom[]) => Monom;
|
|
67
76
|
/**
|
|
68
77
|
* Parse a string to a monom. The string may include fraction.
|
|
69
78
|
* @param inputStr
|
|
70
79
|
*/
|
|
71
80
|
parse: (inputStr: unknown) => Monom;
|
|
72
81
|
addToken: (stack: Monom[], element: Token) => void;
|
|
73
|
-
private _shutingYardToReducedMonom;
|
|
74
82
|
/**
|
|
75
83
|
* Clone the current Monom.
|
|
76
84
|
*/
|
|
@@ -182,16 +190,6 @@ export declare class Monom {
|
|
|
182
190
|
*/
|
|
183
191
|
derivative: (letter?: string) => Monom;
|
|
184
192
|
primitive: (letter?: string) => Monom;
|
|
185
|
-
/**
|
|
186
|
-
* Get the least common multiple of monoms
|
|
187
|
-
* @param monoms Array of monoms
|
|
188
|
-
*/
|
|
189
|
-
static lcm: (...monoms: Monom[]) => Monom;
|
|
190
|
-
/**
|
|
191
|
-
* Multiply two monoms and return a NEW monom.
|
|
192
|
-
* @param monoms
|
|
193
|
-
*/
|
|
194
|
-
static xmultiply: (...monoms: Monom[]) => Monom;
|
|
195
193
|
/**
|
|
196
194
|
* Determine if multiple monoms are similar
|
|
197
195
|
* @param M
|
|
@@ -203,4 +201,6 @@ export declare class Monom {
|
|
|
203
201
|
*/
|
|
204
202
|
areEquals: (...M: Monom[]) => boolean;
|
|
205
203
|
isDivisible: (div: Monom) => boolean;
|
|
204
|
+
private _getLiteralDividers;
|
|
205
|
+
private _shutingYardToReducedMonom;
|
|
206
206
|
}
|
|
@@ -15,8 +15,6 @@ class Monom {
|
|
|
15
15
|
* @param value (optional) string The value that should be parse. Can be a Monom, a Fraction, a string or a number. If nothing is provided, it will return the trivial monom (0).
|
|
16
16
|
*/
|
|
17
17
|
constructor(value) {
|
|
18
|
-
// ------------------------------------------
|
|
19
|
-
// Creation / parsing functions
|
|
20
18
|
// -----------------------------------------
|
|
21
19
|
/**
|
|
22
20
|
* Parse a string to a monom. The string may include fraction.
|
|
@@ -84,36 +82,6 @@ class Monom {
|
|
|
84
82
|
}
|
|
85
83
|
}
|
|
86
84
|
};
|
|
87
|
-
this._shutingYardToReducedMonom = (inputStr) => {
|
|
88
|
-
// Get the RPN array of the current expression
|
|
89
|
-
const SY = new shutingyard_1.Shutingyard().parse(inputStr);
|
|
90
|
-
const rpn = SY.rpn;
|
|
91
|
-
let stack = [], m, pow, letter, q1, q2;
|
|
92
|
-
if (rpn.length === 0) {
|
|
93
|
-
this.zero();
|
|
94
|
-
return this;
|
|
95
|
-
}
|
|
96
|
-
else if (rpn.length === 1) {
|
|
97
|
-
const element = rpn[0];
|
|
98
|
-
this.one();
|
|
99
|
-
if (element.tokenType === 'coefficient') {
|
|
100
|
-
this.coefficient = new fraction_1.Fraction(element.token);
|
|
101
|
-
}
|
|
102
|
-
else if (element.tokenType === 'variable') {
|
|
103
|
-
this.setLetter(element.token, 1);
|
|
104
|
-
}
|
|
105
|
-
return this;
|
|
106
|
-
}
|
|
107
|
-
else {
|
|
108
|
-
// Reset the monom
|
|
109
|
-
for (const element of rpn) {
|
|
110
|
-
this.addToken(stack, element);
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
this.one();
|
|
114
|
-
this.multiply(stack[0]);
|
|
115
|
-
return this;
|
|
116
|
-
};
|
|
117
85
|
/**
|
|
118
86
|
* Clone the current Monom.
|
|
119
87
|
*/
|
|
@@ -513,6 +481,9 @@ class Monom {
|
|
|
513
481
|
}
|
|
514
482
|
return M;
|
|
515
483
|
};
|
|
484
|
+
// ----------------------------------------
|
|
485
|
+
// Static functions
|
|
486
|
+
// ----------------------------------------
|
|
516
487
|
// TODO: The rest of the functions are not used or unnecessary ?
|
|
517
488
|
/**
|
|
518
489
|
* Determine if multiple monoms are similar
|
|
@@ -562,6 +533,36 @@ class Monom {
|
|
|
562
533
|
}
|
|
563
534
|
return this.coefficient.clone().divide(div.coefficient).isRelative();
|
|
564
535
|
};
|
|
536
|
+
this._shutingYardToReducedMonom = (inputStr) => {
|
|
537
|
+
// Get the RPN array of the current expression
|
|
538
|
+
const SY = new shutingyard_1.Shutingyard().parse(inputStr);
|
|
539
|
+
const rpn = SY.rpn;
|
|
540
|
+
let stack = [], m, pow, letter, q1, q2;
|
|
541
|
+
if (rpn.length === 0) {
|
|
542
|
+
this.zero();
|
|
543
|
+
return this;
|
|
544
|
+
}
|
|
545
|
+
else if (rpn.length === 1) {
|
|
546
|
+
const element = rpn[0];
|
|
547
|
+
this.one();
|
|
548
|
+
if (element.tokenType === 'coefficient') {
|
|
549
|
+
this.coefficient = new fraction_1.Fraction(element.token);
|
|
550
|
+
}
|
|
551
|
+
else if (element.tokenType === 'variable') {
|
|
552
|
+
this.setLetter(element.token, 1);
|
|
553
|
+
}
|
|
554
|
+
return this;
|
|
555
|
+
}
|
|
556
|
+
else {
|
|
557
|
+
// Reset the monom
|
|
558
|
+
for (const element of rpn) {
|
|
559
|
+
this.addToken(stack, element);
|
|
560
|
+
}
|
|
561
|
+
}
|
|
562
|
+
this.one();
|
|
563
|
+
this.multiply(stack[0]);
|
|
564
|
+
return this;
|
|
565
|
+
};
|
|
565
566
|
this.zero();
|
|
566
567
|
if (value !== undefined) {
|
|
567
568
|
// A string is given - try to parse the value.
|
|
@@ -570,8 +571,6 @@ class Monom {
|
|
|
570
571
|
return this;
|
|
571
572
|
}
|
|
572
573
|
// ------------------------------------------
|
|
573
|
-
// Getter and setter
|
|
574
|
-
// ------------------------------------------
|
|
575
574
|
/**
|
|
576
575
|
* Get the coefficient \\(k\\) of the Monom \\(k\\cdot x^{n}\\)
|
|
577
576
|
* @returns {Fraction}
|
|
@@ -579,6 +578,8 @@ class Monom {
|
|
|
579
578
|
get coefficient() {
|
|
580
579
|
return this._coefficient;
|
|
581
580
|
}
|
|
581
|
+
// ------------------------------------------
|
|
582
|
+
// Getter and setter
|
|
582
583
|
/**
|
|
583
584
|
* Set the coefficient \\(k\\) value of the monom
|
|
584
585
|
* @param {Fraction | number | string} F
|
|
@@ -593,6 +594,13 @@ class Monom {
|
|
|
593
594
|
get literal() {
|
|
594
595
|
return this._literal;
|
|
595
596
|
}
|
|
597
|
+
/**
|
|
598
|
+
* Set the literal part of the monom. Must be a dictionary {x: Fraction, y: Fraction, ...}
|
|
599
|
+
* @param {literalType} L
|
|
600
|
+
*/
|
|
601
|
+
set literal(L) {
|
|
602
|
+
this._literal = L;
|
|
603
|
+
}
|
|
596
604
|
/**
|
|
597
605
|
* Get the literal square roots of the Monom.
|
|
598
606
|
* TODO: remove this getter ? Is it used and is it correct ?
|
|
@@ -610,13 +618,6 @@ class Monom {
|
|
|
610
618
|
return this._literal;
|
|
611
619
|
}
|
|
612
620
|
}
|
|
613
|
-
/**
|
|
614
|
-
* Set the literal part of the monom. Must be a dictionary {x: Fraction, y: Fraction, ...}
|
|
615
|
-
* @param {literalType} L
|
|
616
|
-
*/
|
|
617
|
-
set literal(L) {
|
|
618
|
-
this._literal = L;
|
|
619
|
-
}
|
|
620
621
|
/**
|
|
621
622
|
* Set the literal part of the monom from a string
|
|
622
623
|
* @param inputStr String like x^2y^3
|
|
@@ -737,28 +738,6 @@ class Monom {
|
|
|
737
738
|
}
|
|
738
739
|
return monomDividers.length === 0 ? [new Monom().one()] : monomDividers;
|
|
739
740
|
}
|
|
740
|
-
_getLiteralDividers(arr, letter) {
|
|
741
|
-
let tmpList = [];
|
|
742
|
-
// Be default, this.literal[letter] should be a rational number.
|
|
743
|
-
for (let d = 0; d <= this.literal[letter].value; d++) {
|
|
744
|
-
if (arr.length === 0) {
|
|
745
|
-
let litt = {};
|
|
746
|
-
litt[letter] = new fraction_1.Fraction(d);
|
|
747
|
-
tmpList.push(litt);
|
|
748
|
-
}
|
|
749
|
-
else {
|
|
750
|
-
for (let item of arr) {
|
|
751
|
-
let litt = {};
|
|
752
|
-
for (let currentLetter in item) {
|
|
753
|
-
litt[currentLetter] = item[currentLetter];
|
|
754
|
-
}
|
|
755
|
-
litt[letter] = new fraction_1.Fraction(d);
|
|
756
|
-
tmpList.push(litt);
|
|
757
|
-
}
|
|
758
|
-
}
|
|
759
|
-
}
|
|
760
|
-
return tmpList;
|
|
761
|
-
}
|
|
762
741
|
/**
|
|
763
742
|
* Display the monom, forcing the '+' sign to appear
|
|
764
743
|
*/
|
|
@@ -857,11 +836,30 @@ class Monom {
|
|
|
857
836
|
isOne() {
|
|
858
837
|
return this._coefficient.value === 1 && this.variables.length === 0;
|
|
859
838
|
}
|
|
839
|
+
_getLiteralDividers(arr, letter) {
|
|
840
|
+
let tmpList = [];
|
|
841
|
+
// Be default, this.literal[letter] should be a rational number.
|
|
842
|
+
for (let d = 0; d <= this.literal[letter].value; d++) {
|
|
843
|
+
if (arr.length === 0) {
|
|
844
|
+
let litt = {};
|
|
845
|
+
litt[letter] = new fraction_1.Fraction(d);
|
|
846
|
+
tmpList.push(litt);
|
|
847
|
+
}
|
|
848
|
+
else {
|
|
849
|
+
for (let item of arr) {
|
|
850
|
+
let litt = {};
|
|
851
|
+
for (let currentLetter in item) {
|
|
852
|
+
litt[currentLetter] = item[currentLetter];
|
|
853
|
+
}
|
|
854
|
+
litt[letter] = new fraction_1.Fraction(d);
|
|
855
|
+
tmpList.push(litt);
|
|
856
|
+
}
|
|
857
|
+
}
|
|
858
|
+
}
|
|
859
|
+
return tmpList;
|
|
860
|
+
}
|
|
860
861
|
}
|
|
861
862
|
exports.Monom = Monom;
|
|
862
|
-
// ----------------------------------------
|
|
863
|
-
// Static functions
|
|
864
|
-
// ----------------------------------------
|
|
865
863
|
/**
|
|
866
864
|
* Get the least common multiple of monoms
|
|
867
865
|
* @param monoms Array of monoms
|
|
@@ -895,6 +893,8 @@ Monom.lcm = (...monoms) => {
|
|
|
895
893
|
}
|
|
896
894
|
return M;
|
|
897
895
|
};
|
|
896
|
+
// ------------------------------------------
|
|
897
|
+
// Creation / parsing functions
|
|
898
898
|
/**
|
|
899
899
|
* Multiply two monoms and return a NEW monom.
|
|
900
900
|
* @param monoms
|