0

I am working on an application based on PyQt5 and I want to display a LaTeX Equation in my PyQt5 application with proper formatting

To better explain it taking an example: Jupyter renders the expression with proper formatting and I desire to display this in my PyQt5 application

for example how can I display this expression : 2/3 + (-1/2 - sqrt(3)I/2)(79/54 + sqrt(921)/18)(1/3) - 8/(9*(-1/2 - sqrt(3)I/2)(79/54 + sqrt(921)/18)(1/3))

as a properly formatted Expression in this form : want to display the above expression as such in my PyQt5 window

I couldn't find a lot of articles on this topic, So any help would be very helpful. Thanks.

1 Answers1

0

You can always display it from Html. If you don't know how to display the Latex mathematical expression in html see this link.

Using this source code, you can simply add your own Html with your Latex expressions.

Using the above code and using the Html from the second answer in the first link you can simply get what you want. You just have to change that Html and adapt it to your mathematical expression:

enter image description here

WhoKnowsMe
  • 498
  • 2
  • 13