# How to circle a letter

• Jan 9th 2009, 03:19 AM
darkmoon
How to circle a letter
I want to right circled letters.
Just like \fbox{} but with a circle. How can I do it?

Tia
• Jan 9th 2009, 04:08 AM
flyingsquirrel
Hi,
Quote:

Originally Posted by darkmoon
I want to right circled letters.
Just like \fbox{} but with a circle. How can I do it?

If you want to circle one letter at a time you can use \textcircled{} :
Code:

\textcircled{u}
$\textcircled{u}$
Code:

\text{d\textcircled{a}rkmoo\textcircled{n}}
$\text{d\textcircled{a}rkmoo\textcircled{n}}$
• Jan 9th 2009, 04:18 AM
darkmoon
Quote:

Originally Posted by flyingsquirrel
Hi,

If you want to circle one letter at a time you can use \textcircled{} :
Code:

\textcircled{u}
$\textcircled{u}$
Code:

\text{d\textcircled{a}rkmoo\textcircled{n}}
$\text{d\textcircled{a}rkmoo\textcircled{n}}$

Almost there...
I'm looking a way to draw graphs and I need a way to draw the nodes...

I did some diagrams like this

\begin{diagram}
\node{A} \arrow{e}\node{\textcircled{$b_1$}}\arrow{e} \node{C}\end{diagram}

so the \textcircled doesn't work very well.

Do you know other way to draw graphs?
• Jan 9th 2009, 05:52 AM
flyingsquirrel
Quote:

Originally Posted by darkmoon
Do you know other way to draw graphs?

We can use the package PStricks to draw graphs :
Code:

\documentclass[11pt,a4paper]{article}

\usepackage[utf8]{inputenc}
\usepackage{pstricks,pst-node,pst-tree}

\title{Diagrams}
\author{}
\date{}

\begin{document}
\maketitle

%%% using \pstree...
$\psset{arrows=->} \pstree[treemode=R,levelsep=5em]{\TR{A}}{ \pstree{ \Tcircle{b_1}}{ \TR{C} } }$

%%% ...or using \psmatrix :
$\psmatrix[colsep=5em,mnode=circle] A & b_1 & C \ncline{->}{1,1}{1,2} \ncline{->}{1,2}{1,3} \endpsmatrix$

\end{document}

The result of this code can be seen in the attached file.