pimath 0.0.81 → 0.0.82

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/dist/pi.js CHANGED
@@ -3221,7 +3221,7 @@ class Polynom {
3221
3221
  display += `(${item.factor.display})${item.degree > 1 ? '^(' + item.degree + ')' : ''}`;
3222
3222
  }
3223
3223
  }
3224
- return display.replaceAll(' ', '');
3224
+ return display;
3225
3225
  }
3226
3226
  get length() {
3227
3227
  // TODO: Must reduce the monoms list to remove the zero coefficient.
@@ -3269,7 +3269,7 @@ class Polynom {
3269
3269
  _parseString(inputStr, ...values) {
3270
3270
  if (values === undefined || values.length === 0) {
3271
3271
  inputStr = '' + inputStr;
3272
- this._rawString = inputStr;
3272
+ this._rawString = inputStr.trim().replaceAll(' ', '');
3273
3273
  // Parse the polynom using the shutting yard algorithm
3274
3274
  if (inputStr !== '' && !isNaN(Number(inputStr))) {
3275
3275
  this.empty();