How can I get mathematical expression output on Matlab app designer in pretty format
8 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
brolaja
am 14 Mär. 2020
Kommentiert: brolaja
am 20 Mär. 2020
How can I get mathematical expression output on Matlab app designer in pretty format. I want d text field to display calculation results as x²instead of x^2
0 Kommentare
Akzeptierte Antwort
Walter Roberson
am 14 Mär. 2020
Bearbeitet: Walter Roberson
am 14 Mär. 2020
You might need to do text analysis and substitution, such as
regexprep(S, {'\^2', '\^3'}, {char(178), char(179)})
In particular, uitextarea() does not support any Interpreter property at this time.
I am seeing contradictory material on whether text() supports interpreter latex in AppDesigner. The material that says it does work is newer than the material that says it does not work, so it might be the case that it was added in a more recent release.
If you are doing a symbolic calculation, you could experiment with latex() of the symbolic expression, and text() that into place on a graph (not a text area)
5 Kommentare
Walter Roberson
am 19 Mär. 2020
L = latex(YourSymbolicExpression) ;
text(x, y, ['$' L '$'], 'interpreter', 'latex')
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Annotations finden Sie in Help Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!