4
votes
1answer
57 views

How to make a hbox several lines under the specified place?

Recently I asked How to colourfuly highlight some lines of an algorithm using algorithm2e? I wanted to acheive this effect using the algorithm2e package: Thanks to JLDiaz's answer I know how to do ...
4
votes
1answer
862 views

Questions about algpseudocode

I'm using the following packages: \usepackage{algpseudocode} \usepackage{algorithm} but I don't understand what package is algpseudocode, since I can't find the documentation. I have followed this ...
7
votes
2answers
3k views

Commands argmin and argmax in algorithm

I am trying to use the argmin and the argmax commands that I defined in an algorithm but I keep getting the argument not in the middle but on the right. Does anyone have an idea how to put the ...
6
votes
2answers
524 views

How do I create an algorithmic Tikz code to obtain a list of numbers which is conditionaly defined by a recurence relation?

Suppose, our initials are $a_{1,0}=0$, $a_{1,1}=1$ and $a_{1,j}=0$ for $j<0$. For given an integer $n$, define $$a_{i,j}=\begin{cases} a_{i-1,\frac{j}{2}} & \text{ if $j$ is even},\\ ...
4
votes
1answer
2k views

LaTeX algorithmic package: Undefined Control Sequence in for-Loop

I'm trying to specify an algorithm in pseudocode in a LaTeX document, but I'm having trouble with the for-Loop. My statement: \for{$bin=0 to binCount$} \item blablabla \endfor keeps on generating ...
7
votes
1answer
2k views

How do I define a new command in algorithmicx

The algorithmicx package defines two commands \Require and \Ensure for providing initial conditions. However, I'd like some custom commands such as \Assume, \Define, \Input, etc. At present, I merely ...
3
votes
2answers
352 views

Is \algorithmicand a standard command in the algorithmic package?

I have a tex file created by someone else which redefines commands of the algorithmic package to translate them to the Portuguese language. For example: ...