LaTeX Algorithm environment

I been having trouble fine-tuning the algorithm environment in \LaTeX. For instance, I could not insert it into a figure. As I wanted to adjust the width, I tried a minipage. This works, but not to my satisfaction. For instance the vertical placement in a blob of text is a hassle, it really doesn’t want to comply. Consequently, I had to write my own. Here it is, in the essence of readable forms:


\textbf{Algorithm \arabic{alg_count}}\label{#2} {{#1}}
\textbf{Input}: #3

then it is called

		\item {Go to step 1.}
Then a reference is done by […] using the bad-ass Algorithm \ref{alg:fs-alg}

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s