计算机科学 > 数据结构与算法
[提交于 2010年11月30日]
标题:Testing of sequences by simulation
查看原文 PDF 中文 PDF (下批处理) EasyResearch 阅读摘要:Let $\xi$ be a random integer vector, having uniform distribution \[\mathbf{P} \{\xi = (i_1,i_2,...,i_n) = 1/n^n \} \ \hbox{for} \ 1 \leq i_1,i_2,...,i_n\leq n.\] A realization $(i_1,i_2,...,i_n)$ of $\xi$ is called \textit{good}, if its elements are different. We present algorithms \textsc{Linear}, \textsc{Backward}, \textsc{Forward}, \textsc{Tree}, \textsc{Garbage}, \textsc{Bucket} which decide whether a given realization is good. We analyse the number of comparisons and running time of these algorithms using simulation gathering data on all possible inputs for small values of $n$ and generating random inputs for large values of $n$.
提交历史
来自:Zoltán Kása[v1] 2010年11月30日 星期二 21:41:24 UTC