HTML code used with Matlab

I recently discovered that Matlab can use LaTeX character sequences. However, they can only be used with the text, title, xlabel, shortcut, and zlabel functions. I developed a GUI that has a user-friendly interface. Its title is a string that uses HTML code and looks like this:

headers = {'<html><center>Component X<br />(km/s^2)</center></html>', ...
           '<html><center>Component Y<br />(km/s^2)</center></html>', ...
           '<html><center>Component Z<br />(km/s^2)</center></html>'};

My intention is replacing s ^ 2 with a square. Due to the fact that I cannot use LaTeX characters inside the header line (at least I tried and did not work), I would like to know how I can do this if I use HTML code that I don’t I know.

+5
source share
2

HTML <sup>...</sup>:

headers = {'<html><center>Component X<br />(km/s<sup>2</sup>)</center></html>', ...
           '<html><center>Component Y<br />(km/s<sup>2</sup>)</center></html>', ...
           '<html><center>Component Z<br />(km/s<sup>2</sup>)</center></html>'};
+2

, , , km/s² kg/m³.

: ⁿⁱ⁰²³⁴⁵⁶⁷⁸⁹
, LaTeX ( Unicode). .

+2

All Articles