# The eHash Main Page

(Difference between revisions)
 Revision as of 15:05, 11 October 2006 (view source)Nobbi (Talk | contribs) (→Some How Tos)← Older edit Revision as of 08:35, 12 October 2006 (view source)Nobbi (Talk | contribs) Newer edit → Line 11: Line 11: == Some How Tos == == Some How Tos == + === Working with maths and Tex === + + We can write "normal" latex equation by using the ''math'' class. For instance the following code + +

$[itex] {\textbf x}_{t} = {\textbf f}({x}_{t-1},{u}_{t-1},{p}_{t-1}) {\textbf x}_{t} = {\textbf f}({x}_{t-1},{u}_{t-1},{p}_{t-1})$                                                                                                                                                                                                                                                                                                                                                                                                                                                 [/itex]
+
+ + is displayed as + + $+ {\textbf x}_{t} = {\textbf f}({x}_{t-1},{u}_{t-1},{p}_{t-1}) +$ + + In order to use tex commands from the amsmath package we use the class ''amsmath''. + Automated numbering of equations works within a single ''amsmath'' environment. + The class amsmath uses the tex template defined in + /var/www/html/mediawiki/extensions/wikitex/wikitex.math.inc.tex + + I changed the template such that we can define global commands. The template looks like + +

+                                                                                         \documentclass[10pt]{article}
+                                                                                         \usepackage{amssymb,amsmath,amscd,concmath}
+                                                                                         % we can define whatever comments we would like to use for consistency.
+                                                                                         % of course we have to somewhere list this special commands (may be we can use
+                                                                                         % a pop up with editiing help or somkething similar
+                                                                                         % for instance:
+                                                                                         \newcommand{\rs}{\ensuremath{\gg}} %right shift >>
+                                                                                         \newcommand{\ls}{\ensuremath{\ll}} %left shift <<
+                                                                                         \newcommand{\rr}{\ensuremath{\ggg}}  %right rotate >>>
+                                                                                         \newcommand{\lr}{\ensuremath{\lll}}  %left rotate <<<
+                                                                                         \pagestyle{empty}
+                                                                                         \begin{document}
+                                                                                         %value%
+                                                                                         \end{document}
+
+ + For instance: + + {| align="center" border="1" cellpadding="10" cellspacing="0" + |- + !code fragment + !displayed equation + |- + | +

+
+
+                                                                                         a = \sum_{i=0}^{n}{2^i}
+
+
+
+ | + + + a = \sum_{i=0}^{n}{2^i} + + + |- + ! colspan="2" style="background:#ffdead;" | %value% in tex-template is  $$...$$ + |} - if we want to use the ''amsmath'' package we have to usse the class ''amsmath''. - Automated numbering of equations works within a single ''amsmath'' environment but only if we do some dirty hacking ... (click on one of the equations to see why). If we start a new ''amsmath'' environment then the equation numbering starts from counter=1 again. So in general, we should not expect that we can do whatever we want with ''amsmath''. - - \end{equation*} - - a = \sum_{i=0}^{n}{2^i} - - \begin{equation*} - - start a new ''amsmath'' environment: + If we start a new ''amsmath'' environment then the equation numbering starts from counter=1 again. Start a new ''amsmath'' environment: - \end{equation*} b = \sum_{i=0}^{n}{2^i} b = \sum_{i=0}^{n}{2^i} Line 36: Line 87: a = \sum_{i=0}^{n}{2^i} a = \sum_{i=0}^{n}{2^i} - \begin{equation*} + \begin{eqnarray} + a &\lr& b\\ + c &\rr& d\\ + e &\ls& f\\ + g &\rs& h + \end{eqnarray}

## 1 List of Hash Functions

On this page you can find a collection of existing hash functions.

## 4 Some How Tos

### 4.1 Working with maths and Tex

We can write "normal" latex equation by using the math class. For instance the following code

${\textbf x}_{t} = {\textbf f}({x}_{t-1},{u}_{t-1},{p}_{t-1})$


is displayed as

${\textbf x}_{t} = {\textbf f}({x}_{t-1},{u}_{t-1},{p}_{t-1})$

In order to use tex commands from the amsmath package we use the class amsmath. Automated numbering of equations works within a single amsmath environment. The class amsmath uses the tex template defined in /var/www/html/mediawiki/extensions/wikitex/wikitex.math.inc.tex

I changed the template such that we can define global commands. The template looks like

 \documentclass[10pt]{article}
\usepackage{amssymb,amsmath,amscd,concmath}
% we can define whatever comments we would like to use for consistency.
% of course we have to somewhere list this special commands (may be we can use
% a pop up with editiing help or somkething similar
% for instance:
\newcommand{\rs}{\ensuremath{\gg}} %right shift >>
\newcommand{\ls}{\ensuremath{\ll}} %left shift <<
\newcommand{\rr}{\ensuremath{\ggg}}  %right rotate >>>
\newcommand{\lr}{\ensuremath{\lll}}  %left rotate <<<
\pagestyle{empty}
\begin{document}
%value%
\end{document}


For instance:

code fragment displayed equation
 <amsmath>
$$a = \sum_{i=0}^{n}{2^i}$$
</amsmath>



%value% in tex-template is $$...$$

If we start a new amsmath environment then the equation numbering starts from counter=1 again. Start a new amsmath environment:

Note: so far I have no idea how to refer to an equation $\dots$

## 5 Getting started

ECRYPT is a Network of Excellence within the Information Societies Technology (IST) Programme of the European Commission. The information on this web site is provided as is, and no guarantee or warranty is given or implied that the information is fit for any particular purpose. The user thereof uses the information at his or her sole risk and liability.