From 343349c7493a4aa1fd5c3ff92d1fa8f60fac9ba1 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Tue, 9 Nov 2010 10:29:21 -0500 Subject: [PATCH] Update links to plot_image.py. --- assignments/archive/poisson/index.shtml.itex2MML | 2 +- content/2D_Domain_Decomposition/index.shtml.itex2MML | 12 ++++++------ content/game_of_life/index.shtml | 4 ++-- content/programming_strategies/index.shtml.itex2MML | 9 +++++---- src/poisson_2d/P_2d.c | 2 +- src/poisson_2d/poisson_2d.c | 2 +- 6 files changed, 16 insertions(+), 15 deletions(-) diff --git a/assignments/archive/poisson/index.shtml.itex2MML b/assignments/archive/poisson/index.shtml.itex2MML index 650b2b5..1997686 100644 --- a/assignments/archive/poisson/index.shtml.itex2MML +++ b/assignments/archive/poisson/index.shtml.itex2MML @@ -41,7 +41,7 @@ with specified boundary conditions and source term $S(x,y)$.

(poisson_1d.tar.gz) codes as guides.
  • Use MPE or a pipe in the Python graphic code - (plot_image.py) + (plot_image.py) to display the solution.
  • Compare your solution (map image of $u(x,y)$) to the serial code solution as a rough check of the code.
  • diff --git a/content/2D_Domain_Decomposition/index.shtml.itex2MML b/content/2D_Domain_Decomposition/index.shtml.itex2MML index 5bf3ddb..5094a33 100644 --- a/content/2D_Domain_Decomposition/index.shtml.itex2MML +++ b/content/2D_Domain_Decomposition/index.shtml.itex2MML @@ -94,16 +94,16 @@ implements the above scheme. The steps in the code are:

     gcc poisson_2d.c -lm -o poisson_2d
    -./poisson_2d N Nx Ny | ./plot_image.py -s Nx Ny -t "2d Poisson"
    +./poisson_2d N Nx Ny | ./plot_image.py -s Nx,Ny -t "2d Poisson"
     

    where N, Nx and Ny are the (arbitrary) maximum number of iterations and number of grid points (image size) respectively. Good numbers to use could be 10000, 300, -300. We -introduced plot_image.py -in Programming Strategies: -Color Images.

    +300. We introduced plot_image.py in Programming Strategies: Color +Images.

    The code stops once good convergence (parameter EPS) is obtained.

    @@ -115,7 +115,7 @@ is obtained.

    Numerical Receipes for an optimum choice).
  • The code is written in the simplest possible way.
  • The code outputs the field values to pipe - into plot_image.py + into plot_image.py for field display.
  • diff --git a/content/game_of_life/index.shtml b/content/game_of_life/index.shtml index 1f88f49..9158aad 100644 --- a/content/game_of_life/index.shtml +++ b/content/game_of_life/index.shtml @@ -77,10 +77,10 @@ universe. Each one of these generations defines an image, or a frame, from which we can generate a movie.

    The Python -program display_frames_GTK.py +program display_frames_GTK.py accepts the image content for each frame in the movie. It uses the same notation for each frame as that of the previously -used plot_image.py +used plot_image.py for single image. It loops over the frames until the end of stream, at which point it crashes. The syntax to display the Game of Life above is:

    diff --git a/content/programming_strategies/index.shtml.itex2MML b/content/programming_strategies/index.shtml.itex2MML index 3f7b4eb..622f099 100644 --- a/content/programming_strategies/index.shtml.itex2MML +++ b/content/programming_strategies/index.shtml.itex2MML @@ -193,10 +193,11 @@ must translate the function range to a color palette range. For our purpose, this tool must read in a 2-dimensional array containing the values of $f(x,y)$ on a 2-dimensional lattice and produce the color image. The Python script plot_image.py does precisely this. It is -based on matplotlib -(the tutorials, user's guide and examples found in the matplotlib site -are easier to read with some previous knowledge of plot_image.py does +precisely this. It is based on matplotlib (the +tutorials, user's guide and examples found in the matplotlib site are +easier to read with some previous knowledge of Python and Numerical Python).

    diff --git a/src/poisson_2d/P_2d.c b/src/poisson_2d/P_2d.c index d885818..e16928b 100644 --- a/src/poisson_2d/P_2d.c +++ b/src/poisson_2d/P_2d.c @@ -16,7 +16,7 @@ gcc poisson_2d.c -lm -o poisson_2d -./poisson_2d N N_x N_y | plot_image.py -s N_x N_y -t "2d Poisson" +./poisson_2d N N_x N_y | plot_image.py -s N_x,N_y -t "2d Poisson" */ diff --git a/src/poisson_2d/poisson_2d.c b/src/poisson_2d/poisson_2d.c index d885818..e16928b 100644 --- a/src/poisson_2d/poisson_2d.c +++ b/src/poisson_2d/poisson_2d.c @@ -16,7 +16,7 @@ gcc poisson_2d.c -lm -o poisson_2d -./poisson_2d N N_x N_y | plot_image.py -s N_x N_y -t "2d Poisson" +./poisson_2d N N_x N_y | plot_image.py -s N_x,N_y -t "2d Poisson" */ -- 2.26.2