Skip to main content
2 of 2
Address updated question
Carl Woll
  • 131.7k
  • 6
  • 246
  • 359

Don't use ToString (and especially, don't use a single argument ToString). Instead, just use expressions instead of strings:

Subscript[θ,n]==π/2

enter image description here

Addendum to address updated question

Again, don't use ToString. Here is how I would create your legend:

θ = Pi/2;
Style[HoldForm[θ] == θ, 20]

enter image description here

(Note that legends in plots are by default displayed in TraditionalForm, so that the double equal symbol gets rendered as a (long) single equal.)

Carl Woll
  • 131.7k
  • 6
  • 246
  • 359