From: <and...@us...> - 2008-07-23 02:30:15
|
Revision: 8560 http://plplot.svn.sourceforge.net/plplot/?rev=8560&view=rev Author: andrewross Date: 2008-07-23 02:30:24 +0000 (Wed, 23 Jul 2008) Log Message: ----------- Fix f77 example 21 so it produces identical results to C version. Enable example 21 for f77 tests using ctest. Modified Paths: -------------- trunk/examples/f77/x21f.fm4 trunk/plplot_test/test_f77.sh.in Modified: trunk/examples/f77/x21f.fm4 =================================================================== --- trunk/examples/f77/x21f.fm4 2008-07-23 02:28:54 UTC (rev 8559) +++ trunk/examples/f77/x21f.fm4 2008-07-23 02:30:24 UTC (rev 8560) @@ -84,6 +84,8 @@ integer ii, jj real*8 dist, d + character*1 defined + xmin = -0.2 ymin = -0.2 xmax = 0.6 @@ -147,7 +149,7 @@ do alg=1,6 call plgriddata(x, y, z, pts, xg, xp, yg, yp, zg, alg, - & opt(alg)) + & opt(alg),xp) c - CSA can generate NaNs (only interpolates? !). c - DTLI and NNI can generate NaNs for points outside the convex hull @@ -179,7 +181,7 @@ if (abs(ii-i) + abs(jj-j) .eq. 1) then d = 1.d0 else - d = 1.4142 + d = 1.4142d0 endif zg(i,j) = zg(i,j) + zg(ii,jj)/(d*d) dist = dist + d @@ -198,12 +200,12 @@ enddo endif - call a2mnmx(zg, xp, yp, lzmax, lzmin, xp); + call a2mnmx(zg, xp, yp, lzmin, lzmax, xp); call plcol0(1) call pladv(alg) - if (k.eq.0) then + if (k.eq.1) then lzmin = min(lzmin, zmin) lzmax = max(lzmax, zmax) @@ -213,8 +215,8 @@ call plenv0(xmin, xmax, ymin, ymax, 2, 0) call plcol0(15) call pllab("X", "Y", title(alg)) - call plshades(zg, xp, yp, xmin, xmax, ymin, ymax, - & clev, nl, 1, 0, 1, 1) + call plshades0(zg, xp, yp, defined, xmin, xmax, ymin, + & ymax, clev, nl, 1, 0, 1, xp) call plcol0(2) else @@ -222,8 +224,8 @@ clev(i) = lzmin + (lzmax-lzmin)/(nl-1.d0)*(i-1.d0); enddo call cmap1_init() - call plvpor(0.0, 1.0, 0.0, 0.9) - call plwind(-1.1, 0.75, -0.65, 1.20) + call plvpor(0.d0, 1.d0, 0.d0, 0.9d0) + call plwind(-1.1d0, 0.75d0, -0.65d0, 1.20d0) c c For the comparison to be fair, all plots should have the c same z values, but to get the max/min of the data generated @@ -232,11 +234,11 @@ c plw3d(1., 1., 1., xmin, xmax, ymin, ymax, zmin, zmax, 30, -60); c - call plw3d(1., 1., 1., xmin, xmax, ymin, ymax, lzmin, - & lzmax, 30, -40) - call plbox3("bntu", "X", 0., 0, - & "bntu", "Y", 0., 0, - & "bcdfntu", "Z", 0.5, 0) + call plw3d(1.d0, 1.d0, 1.d0, xmin, xmax, ymin, ymax, + & lzmin, lzmax, 30.d0, -40.d0) + call plbox3("bntu", "X", 0.d0, 0, + & "bntu", "Y", 0.d0, 0, + & "bcdfntu", "Z", 0.5d0, 0) call plcol0(15) call pllab("", "", title(alg)) call plot3dc(xg, yg, zg, xp, yp, ior(ior(DRAW_LINEXY, @@ -244,6 +246,8 @@ endif enddo enddo + + call plend end Modified: trunk/plplot_test/test_f77.sh.in =================================================================== --- trunk/plplot_test/test_f77.sh.in 2008-07-23 02:28:54 UTC (rev 8559) +++ trunk/plplot_test/test_f77.sh.in 2008-07-23 02:30:24 UTC (rev 8560) @@ -49,9 +49,7 @@ # Do the standard non-interactive examples. # skip 14, 17, and 20 because they are interactive, and 20 not implemented. -# skip 21 because it delivers variable results depending on computer timing -# and load (and not implemented yet). - for index in 01 02 03 04 05 06 07 08 09 10 11 12 13 15 16 18 19 22 23 28 29 30 ; do + for index in 01 02 03 04 05 06 07 08 09 10 11 12 13 15 16 18 19 21 22 23 28 29 30 ; do $f77dir/x${index}f -dev $device -o ${OUTPUT_DIR}/x${index}f.$dsuffix $options 2> test.error status_code=$? cat test.error @@ -90,9 +88,7 @@ # Do the standard non-interactive examples. # skip 14, 17, and 20 because they are interactive, and 20 not implemented. -# skip 21 because it delivers variable results depending on computer timing -# and load (and not implemented yet). - for index in 01 02 03 04 05 06 07 08 09 10 11 12 13 15 16 18 19 22 23 28 29 30 ; do + for index in 01 02 03 04 05 06 07 08 09 10 11 12 13 15 16 18 19 21 22 23 28 29 30 ; do $f77dir/x${index}f <<EOF 2> test.error $device ${OUTPUT_DIR}/x${index}f.$dsuffix This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |