2
$\begingroup$

I want to put the following two labels in my mathematica (3D) graphic:

In $\LaTeX$ it would be:

$D^2 \times \{ 1 \}$ and $\partial D^2 \times D^1$

For the first one the hard part for me was the curly brackets. I came up with something that works well enough but I think is not the right way:

Text[TraditionalForm[D^2 ] TraditionalForm[x] TraditionalForm[{1}], {0, 0, 1}]

But the second one currently has me stumped. I can write \[PartialD] in a notebook but don't see how to use this.

$\endgroup$
  • 4
    $\begingroup$ I would use MaTeX package by Szabolcs Horvát and not bother with traditional formatting and all that. $\endgroup$ – Nasser Jan 16 '17 at 23:33
1
$\begingroup$

You may type these directly as strings with the following key strokes (including " ).

"D Ctrl+6 2 Ctrl+Space \[Times] {1}"

"\[PartialD]D Ctrl+6 2 Ctrl+Space \[Times] D Ctrl+6 1 Ctrl+Space "

You may find the Mathematical Typesetting guide and (from the menu) the Palettes | Writing Assistant | Typesetting palette useful. The guide and the tooltips on the palettes give keyboard shortcuts to the typesetting structures.

Hope this helps.

$\endgroup$
0
$\begingroup$

For the first one I would use:

Cross[Superscript[D,2],{1}]//TraditionalForm

%//TeXForm

enter image description here

$D^2\times \{1\}$

Note I substituted the image for the TraditionalForm above. For the second one I would do:

pd /: MakeBoxes[pd[n_], TraditionalForm] := RowBox[{
    "\[PartialD]",
    SuperscriptBox["D", MakeBoxes[n, TraditionalForm]]
}]

Cross[pd2[2], Superscript[D, 1]] //TraditionalForm

% //TeXForm

enter image description here

$\partial D^2\times D^1$

$\endgroup$
0
$\begingroup$
Row[{D^2, "\[ThinSpace]\[Times]\[ThinSpace]", {1}}] // TraditionalForm
Row[{"\[PartialD]", D^2, "\[ThinSpace]\[Times]\[ThinSpace]", D^"1"}] // TraditionalForm

screenshot

$\endgroup$

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