Open
Description
I have a problem with displaying LaTeX fonts in HTML files generated by MATLAB. I used the code from this link to create a simple plot with LaTeX annotations. The plot looks fine in MATLAB, but when I open the HTML file in Edge, the Latex fonts are not rendered correctly. How can I fix this issue?
The code
fib = zeros(1, 12);
for i = 1:12
fib(i) = (((1+sqrt(5))/2)^i - ((1-sqrt(5))/2)^i)/sqrt(5);
end
figure
plot(1:12, fib, 'k^-')
title('Fibonacci Numbers from 1-12')
xlabel('n')
ylabel('F_n')
eqtext = '$$F_n={1 \over \sqrt{5}}';
eqtext = [eqtext '\left[\left({1+\sqrt{5}\over 2}\right)^n -'];
eqtext = [eqtext '\left({1-\sqrt{5}\over 2}\right)^n\right]$$'];
text(0.5, 125, eqtext, 'Interpreter', 'Latex', 'FontSize', 12, 'Color', 'k')
fig2plotly(gcf);
MATLAB Figure
Figure opened in Edge
Metadata
Metadata
Assignees
Labels
No labels