Wed, Feb 5 2003
05:23:58
|
|
Request created by guest
|
|
Subject: r.profile: extraneous output
Platform: GNU/Linux/i386
grass obtained from: Mirror of Trento site
grass binary for platform: Compiled from Sources
GRASS Version: 5.0.0
r.profile keeps going for one record after it is done, creating extraneous output.
e.g. (using just fixed r.transect frontend for clarity)
[ line=easting, northing, azimuth, distance]
> r.transect map=idw_out3 line=2026061.733,5532326.336,116.0,40
Using Resolution 5.000000
Output Format:
[Along Track Dist.(m)] [Elevation]
Approx. transect length 40.000000 m.
0.000000 -319.511866
5.000000 -316.296928
10.000000 -314.788610
15.000000 -312.100558
20.000000 -312.100558
25.000000 -310.551977
30.000000 -308.326899
35.000000 -306.653716
40.000000 -304.539002
Approx. transect length 0.000000 m.
45.000000 -304.539002
So for some reason it runs the do_profile function again, when it should really
stop at dist=40.000. Maybe at line 238:
/* Ge last coord */
if (i == k-2)
do_profile(...
shouldn't be there?
If I ask for [0-10], resolution 3, it should return 0=, 3=, 6=, 9=; and not 12=.
thanks,
Hamish
|
|
Tue, Mar 11 2003
10:41:45
|
|
Mail sent by mneteler
|
|
Is this bug fixed? If yes, please close the report.
Thanks,
Markus |
|
Tue, Mar 11 2003
15:14:40
|
|
Mail sent by guest
|
|
No, it isn't fixed.
I wanted to have a proper look to make sure the fix did the correct thing for
all cases, but I haven't done that yet.
Hamish
|
|
Thu, Mar 13 2003
01:54:39
|
|
Status changed to resolved by hbowman
|
|
Thu, Mar 13 2003
01:54:39
|
|
Comments added by hbowman
|
|
Right, it's done now & the change is in CVS.
I think what the erroneous code was trying to do was output the value for the
end point, but it was actually outputing for a position off the end of the
profile which is the wrong thing to do - so now it's gone.
Hamish
|
|