RANDOM_WALK_2D_AVOID_TASKS
Task Computation of Multiple Self Avoiding Walks


RANDOM_WALK_2D_AVOID_TASKS is a MATLAB program which sets up a job as a collection of tasks. Each task is required to initialize the random number generator, and then attempt to construct a self-avoiding walk in 2D, returning the number of steps it was able to take, and its final distance from the origin.

The task computing feature of MATLAB's Parallel Computing Toolbox is used to manage the creation, execution, and analysis of the multiple tasks.

Licensing:

The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.

Languages:

RANDOM_WALK_2D_AVOID_TASKS is available in a MATLAB version.

Related Data and Programs:

BIRTHDAY_REMOTE, a program which runs a Monte Carlo simulation of the birthday paradox, and includes instructions on how to run the job, via MATLAB's BATCH facility, on a remote system such as Virginia Tech's ITHACA cluster.

CELL_DETECTION_TASKS, a program which creates modified versions of a sequence of gray-scale TIF files containing images of cells; the process of each file is carried out independently, using the "task" feature of MATLAB's parallel computing toolbox.

CG_DISTRIBUTED, a program which implements a version of the NAS CG conjugate gradient benchmark, using distributed memory.

COLLATZ_PARFOR, a program which seeks the maximum Collatz sequence between 1 and N, running in parallel using MATLAB's "PARFOR" feature.

CONTRAST_SPMD, a program which demonstrates the SPMD parallel programming feature for image operations; the client reads an image, the workers increase contrast over separate portions, and the client assembles and displays the results.

CONTRAST2_SPMD, a program which demonstrates the SPMD parallel programming feature for image operations; this improves the contrast_spmd program by allowing the workers to share some data; this makes it possible to eliminate artificial "seams" in the processed image.

FD2D_HEAT_EXPLICIT_SPMD, a program which uses the finite difference method and explicit time stepping to solve the time dependent heat equation in 2D. A black and white image is used as the "initial condition". MATLAB's SPMD facility is used to carry out the computation in parallel.

FMINCON_PARALLEL, a program which demonstrates the use of MATLAB's FMINCON constrained minimization function, taking advantage of MATLAB's Parallel Computing Toolbox for faster execution.

IMAGE_DENOISE_SPMD, a program which demonstrates the SPMD parallel programming feature for image operations; the client reads an image, the workers process portions of it, and the client assembles and displays the results.

LINEAR_SOLVE_DISTRIBUTED, a program which solves a linear system A*x=b using MATLAB's spmd facility, so that the matrix A is "distributed" across multiple MATLAB workers.

MATLAB_PARALLEL, programs which illustrate "local" parallel programming on a single computer with MATLAB's Parallel Computing Toolbox.

MD_PARFOR, a program which carries out a molecular dynamics simulation, running in parallel using MATLAB's "PARFOR" feature.

ODE_SWEEP_PARFOR, a program which demonstrates how the PARFOR command can be used to parallelize the computation of a grid of solutions to a parameterized system of ODE's.

PLOT_SPMD, a library which demonstrates the SPMD parallel programming feature, by having a number of labs compute parts of a sine plot, which is then displayed by the client process.

PRIME_PARFOR, a MATLAB program which counts the number of primes between 1 and N; running in parallel using MATLAB's "PARFOR" feature.

PRIME_SPMD, a program which counts the number of primes between 1 and N; running in parallel using MATLAB's "SPMD" feature.

QUAD_PARFOR, a program which estimates an integral using quadrature; running in parallel using MATLAB's "PARFOR" feature.

QUAD_SPMD, a program which estimates an integral using quadrature; running in parallel using MATLAB's "SPMD" feature.

QUAD_TASKS, a program which estimates an integral using quadrature; running in parallel using MATLAB's "TASK" feature.

RANDOM_WALK_1D_SIMULATION, a program which simulates a random walk in a 1-dimensional region.

RANDOM_WALK_2D_AVOID_SIMULATION, a program which simulates a self-avoiding random walk in a 2-dimensional region.

RANDOM_WALK_2D_SIMULATION, a program which simulates a random walk in a 2-dimensional region.

RANDOM_WALK_3D_SIMULATION, a program which simulates a random walk in a 3-dimensional region.

SATISFY_PARFOR, a program which demonstrates, for a particular circuit, an exhaustive search for solutions of the circuit satisfiability problem, running in parallel using MATLAB's "PARFOR" feature.

SUBSET_SUM_TASKS, a program which solves a subset sum problem by exhaustive search, subdividing the search range among separate tasks.

Reference:

The User's Guide for the Parallel Computing Toolbox is available at http://www.mathworks.com/access/helpdesk/help/pdf_doc/distcomp/distcomp.pdf

  1. Brian Hayes,
    How To Avoid Yourself,
    American Scientist,
    Volume 86, Number 4, July-August 1998, pages 314-319.
  2. Gaurav Sharma, Jos Martin,
    MATLAB: A Language for Parallel Computing,
    International Journal of Parallel Programming,
    Volume 37, Number 1, pages 3-36, February 2009.

Source Code:

You can go up one level to the MATLAB source codes.


Last revised on 02 April 2011.