Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
CUDALink >

CUDAFold


gives the last element of CUDAFoldList.
  • The CUDALink application must be loaded using Needs.
  • works only on vectors.
  • does not work on fixed vector structure types like , , ....
  • does not work on symbolic input.
  • is equivalent to Fold.
First, load the CUDALink application:
This folds an input list with the Plus operator and initial value 0:
The above is equivalent to Fold:
operates on input CUDAMemory:
This folds the CUDAMemory as before:
Note that the output type is the same as the input—that is, if the input is a Real valued list, then the output is a real number.
Compared to Fold, only a few operations are supported by :
First, load the CUDALink application:
In[1]:=
Click for copyable input
This folds an input list with the Plus operator and initial value 0:
In[2]:=
Click for copyable input
Out[2]=
The above is equivalent to Fold:
In[3]:=
Click for copyable input
Out[3]=
 
operates on input CUDAMemory:
In[1]:=
Click for copyable input
Out[1]=
This folds the CUDAMemory as before:
In[2]:=
Click for copyable input
Out[2]=
Note that the output type is the same as the input—that is, if the input is a Real valued list, then the output is a real number.
 
Compared to Fold, only a few operations are supported by :
In[1]:=
Click for copyable input
Out[1]=
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team
Format:   HTML  |  CDF