Obtain formula text in explicit multiplication format?

Rulatir shared this question 11 months ago
Answered

In current GeoGebra 5 (and no, I won't be using 6, I find the UI unwieldy to the point of unusability), when I open properties of a formula, the formula is stored in a format that uses implied multiplication. This is incompatible with many CAS tools like (wx)Maxima, which require the use of explicit multiplication operator. This complicates copying formulas from GeoGebra to wxMaxima, which is sometimes needed when GeoGebra's CAS isn't powerful enough.


Is there a way to obtain a formula text in explicit multiplication format? If not, please consider it a feature request.


Note that this problem cannot be generally solved by an external converter, because formulas with implied multiplication are ambiguous. If types of objects represented by identifiers are not known, it is impossible to tell e.g. whether m(a+b) means "multiply m by the sum of a and b" or "call function m, passing the sum of a and b as argument".

Comments (5)

photo
1

Possible partial workaround (pending research):


CopyFreeObject(FormulaText(something))

Then copy the text from properties. It's LaTeX, and it seemingly uses `\;` as multiplication operator (or should I say "factor separator"), so it just might be unambiguously parseable.

photo
1

Try right-click -> copy here:


https://www.geogebra.org/cl...


gives

(x * sin(1 / x))

photo
1

The "Copy" context menu item is not present in GeoGebra 5. I do not use GeoGebra 6 because, as I've mentioned, I find its UI so clunky as to be unusable.


Please consider this a feature request to backport this functionality to GeoGebra 5.

photo
1

Sorry, we won't be adding that

photo
1

Gosh, what did I expect?

How about fixing GG6 then? Off the top of my head:

  • everything is Way Too Big resulting in 20% of the time being spent scrolling the object list in the algebra view
  • on-screen keyboard keeps getting in the way and occluding the very formula I'm typing; can't dismiss it without committing unfinished formula
  • exponents and subscripts are "sticky" and must be explicitly terminated by pressing right-arrow key when entering a formula
  • undebounced preview - this one is not specific to GG6, but combines with GG6 clunkiness in extra creative ways, and I would expect a bug this severe not to remain unfixed for so many years and at least two major releases
  • no autosave or crash recovery, the /tmp trick no longer works (undo buffer is not dumped to files)

photo
© 2021 International GeoGebra Institute