Q:

Rotating a letter

I'd like to rotate a letter such as, say B, to show its reflection or inversion symmetry, or even at an arbitrary angle clockwise or counter-clockwise. Is this possible using commands without drawing a picture? Can I use \usepackage{rotating} out of a table? I used the code \begin{rotate}{180}B\end{rotate}. That puts B rotated as a subscript to the line. Any idea how to make it in-line aligned with other charcters?

A:

With the graphicx package, you can do it as follows: \rotatebox[origin=c]{180}{B}
This rotates around the center of the letter. You can also rotate around other points: \rotatebox[origin=tr]{180}{B} will rotate around the top right of the box. See page 8 of this document for all the relevant options.
Following from what egreg pointed out, you may need a \raisebox to have the resulting this sit on the baseline:
\documentclass{scrartcl}
\usepackage{graphicx}
\newcommand\testletter[1]{
  \begin{tabular}{rl}
    Rotate: & #1\rotatebox{180}{#1}\hspace{-1em}\rule{1em}{0.5pt}\\
    Rotate and raise: & #1\raisebox{\depth}{\rotatebox{180}{#1}}\hspace{-1em}\rule{1em}{0.5pt} \\
    Rotate around centre: & #1\rotatebox[origin=c]{180}{#1}\hspace{-1em}\rule{1em}{0.5pt} \\
    Rotate around centre and raise: & #1\raisebox{\depth}{\rotatebox[origin=c]{180}{#1}}\hspace{-1em}\rule{1em}{0.5pt} \\
    Rotate (120): & #1\rotatebox{120}{#1}\hspace{-1em}\rule{1em}{0.5pt} \\
    Rotate (120) around centre: & #1\rotatebox[origin=c]{120}{#1}\hspace{-1em}\rule{1em}{0.5pt} \\
    Rotate (120) and raise: & #1\raisebox{\depth}{\rotatebox{120}{#1}}\hspace{-1em}\rule{1em}{0.5pt} \\
    Rotate (120) around centre and raise: & #1\raisebox{\depth}{\rotatebox[origin=c]{120}{#1}}\hspace{-1em}\rule{1em}{0.5pt}
  \end{tabular}
}
\begin{document}
\testletter{B}

\testletter{g}

\testletter{f}
\end{document}

The rule is just to show where the baseline is.

As you can see, the raisebox only makes a difference for letters with descenders (g,y,j etc). And which one you prefer is a matter of taste. (Also, doing both rotate about centre and raise seems otiose. Doing one or the other suffices, depending on which result you want...

A:

If you need also a reflection, use \reflectbox{B}; you might need also \raisebox when rotating the letter with \rotatebox, for example
\raisebox{\depth}{\rotatebox[origin=c]{120}{B}}

will make the rotated "B" sit on the baseline. There are differences between the three calls
B\rotatebox{120}{B}B
B\rotatebox[origin=c]{120}{B}B
B\raisebox{\depth}{\rotatebox[origin=c]{120}{B}}B

Choose the one that suits you better. The \depth can be multiplied by a factor; you can use also \height and \totalheight as is customary for LaTeX boxes.

A:

with package rotating or graphicx
B\rotatebox[origin=c]{180}{B}

