I am looking for the way to write a algorithm as: (without numbering). Please help me to write it in latex. Thanks in advance
Algorithm:
Input: A, B,C.
Initialize \alpha, \beta,u
Employ the A
While |u^(k+1)-u^k |≥ \epsilon
Compute \alpha as \hat {\alpha} by Eq. \eqref{eq:1}.
Compute \beta as \hat {\beta} by Eq. \eqref{eq:2}.
Compute u as \hat u by Eq. \eqref{eq:3}.
End
Output: \alpha, \beta.
Best Answer
Here is a sample code for your algorithm using the package
algorithm2e
as suggested by your tags:And here is what the output looks like:
There are many different options within
algorithm2e
to configure the layout of the algorithm. You can for instance replace the optionplainruled
byplain
in order to remove the horizontal lines. More information is available in the package documentation here. See section 7.3.As for the numbering of the algorithm, if you completely remove the number, you will not be able to label it and reference it in the text. Have a look at section 9.2 and the command
\SetAlgoRefName
in order to customize the referencing.