4
$\begingroup$

I am trying to put labels that look like the following,

enter image description here

enter image description here

I use

Graphics[{Text[
   Style[ToExpression["a+\\bm{v}_i", TeXForm, HoldForm], 
    FontSize -> 14, FontFamily -> "Times New Roman"], {0, 0}], 
  Text[Style[ToExpression["b+\\cal{L}(\\bm{v}_i)", TeXForm, HoldForm],
     FontSize -> 14, FontFamily -> "Times New Roman"], {0, .2}]}]

enter image description here

enter image description here

but do not get result as expected. Is there any way to solve this? Thank you!

$\endgroup$
  • $\begingroup$ Mathematica is not good at importing TeX, so instead of importing TeX, you could use boxes: e.g. Text["a+\!\(\[ScriptV]\_i\)"] and Text["b+\[ScriptCapitalL](\!\(\[ScriptV]\_i\))"] $\endgroup$ – JungHwan Min Aug 7 '16 at 22:18
  • 3
    $\begingroup$ Take a look at MaTeX, a package for $\LaTeX$ typesetting in Mathematica. $\endgroup$ – C. E. Aug 7 '16 at 23:23
  • $\begingroup$ Possible duplicate:(736) (specifically this answer). Related: (15884). $\endgroup$ – Michael E2 Aug 8 '16 at 0:35
3
$\begingroup$

Perhaps this will work for you.

Graphics[
  {Text[
     Style[
       a + Subscript[Style[v, Bold, SingleLetterItalics -> False], i], 
       "TR", 14], 
     {0, 0}, {-1, 0}], 
   Text[
     Style[
        b + \[ScriptCapitalL][Subscript[Style[v, Bold, SingleLetterItalics -> False], i]], 
        "TR", 14], 
     {0, -.1}, {-1, 0}]}]

result

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.