parallprefix.html

来自「数据结构词典(英文)」· HTML 代码 · 共 46 行

HTML
46
字号
<!DOCTYPE HTML PUBLIC "-//IETF//DTD W3 HTML 2.0//EN">
<HTML lang="en-US">
<HEAD>
<TITLE>parallel prefix computation</TITLE>
<META name="description"
  content="Definition of parallel prefix computation,
	possibly with links to more information and implementations.">
<META name="keywords" content="parallel prefix computation">
</HEAD>
<BODY BGCOLOR="#FFFFFF">

<H1>parallel prefix computation</H1>
<P>
(algorithm)

<P>
<strong>Definition:</strong>
Calculate a function, f, on all prefixes of an n-element array, that is, s[0], f(s[0], s[1]), f(s[0], f(s[1], s[2])),  ..., f(s[0],  ... f(s[n-2], s[n-1]) ...),  using <a href="theta.html" tppabs="http://hissa.nist.gov/dads/HTML/theta.html"><em> <img src="Theta-1.gif" tppabs="http://hissa.nist.gov/dads/HTML/Images/Theta.gif"  border=0 height=10 width=8  alt="Capital Theta">(n)</em></a> processors in  <img src="Theta-1.gif" tppabs="http://hissa.nist.gov/dads/HTML/Images/Theta.gif"  border=0 height=10 width=8  alt="Capital Theta">( log n) time. The algorithm is <br> for j := 0 to lg(n-1) do <br> &nbsp;&nbsp;&nbsp;&nbsp;for i := 2<sup>j</sup> to n-1 parallel-do<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; s[i] := f(s[i-2<sup>j</sup>], s[i]) <br> where lg is the logarithm base 2, and parallel-do does the innermost computations in parallel.  The function must be <a href="associative.html" tppabs="http://hissa.nist.gov/dads/HTML/associative.html"><em>associative</em></a>.
<P><em>Note:
In particular, this calculates any associative function, such as sum, maximum, or concatenate, over a list of values in <a href="logarithmic.html" tppabs="http://hissa.nist.gov/dads/HTML/logarithmic.html"><em>logarithmic</em></a> time.  Since this overwrites the initial values, the n processors can copy input values to a working array in parallel in one additional step.<br> From Yair Tuaff (r56409@email.sps.mot.com), 29 December 1999.</em>
<P>Author: <a href="terms.html#authorPEB" tppabs="http://hissa.nist.gov/dads/terms.html#authorPEB">PEB</a>

<hr>

Go to the
<A HREF="terms.html" tppabs="http://hissa.nist.gov/dads/terms.html">Algorithms, Data Structures, and Problems</A>
home page.

<hr>

If you have suggestions, corrections, or comments, please get in touch
with
<a href="javascript:if(confirm('http://hissa.nist.gov/~black/black.html  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://hissa.nist.gov/~black/black.html'" tppabs="http://hissa.nist.gov/~black/black.html">Paul E. Black</a>
&nbsp;(<a href="mailto:paul.black@nist.gov">paul.black@nist.gov</a>).

<p>
Entry modified Wed Dec 29 14:01:48 1999.<BR>
HTML page formatted Wed Dec 29 14:02:13 1999.

<P>
This page's URL is
<A href="parallprefix.html" tppabs="http://hissa.nist.gov/dads/HTML/parallprefix.html">http://hissa.nist.gov/dads/HTML/parallprefix.html</A>

</BODY>
</HTML>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?