v.plant(1)		      Grass User's Manual		    v.plant(1)



NNAAMMEE
       vv..ppllaanntt	-  module to insert intermediate points on GRASS vector lines.
       _(_G_R_A_S_S _V_e_c_t_o_r _P_r_o_g_r_a_m_)

SSYYNNOOPPSSIISS
       vv..ppllaanntt
       vv..ppllaanntt hheellpp
       vv..ppllaanntt mmaapp==_n_a_m_e


       v.plant is an interactive program.



DDEESSCCRRIIPPTTIIOONN
       This report describes the use and operation  of	the  program  _v_._p_l_a_n_t,
       used  with  the GRASS GIS system.  The report contains (i) a discussion
       of the problem which motivated the development of the program,  (ii)  a
       description  of	the  method used, (iii) the manual page describing the
       usage of the program,  (iv) a listing of the source-code.

IInnttrroodduuccttiioonn
       _M_a_p _p_r_o_j_e_c_t_i_o_n_s

       Projections are representations of information defined on  curved  sur-
       faces  (usually	spheroids)  in two-dimensional space.  This allows the
       description of the location information in  cartesian  or  other  plane
       coordinate  systems.   Particular  projections  are  defined by precise
       mathematical relations, which allows conversion of  maps  from  between
       projections  to	be  achieved using straightforward mathematical opera-
       tions [1].

       _P_r_o_j_e_c_t_i_n_g _l_i_n_e _s_e_g_m_e_n_t_s

       When converted from  one  map  projection  to  another,	straight-lines
       become  curves.	 Thus,	a  line segment which can be described by four
       parameters only (eg the coordinates of the end points) in  one  projec-
       tion  becomes  an arc which needs more parameters in other projections.
       In GIS systems which describe arcs as a sequence of line segments, this
       means  that  intermediate  points  between  the ends of the segment are
       used.  The easiest method of projecting a line accurately is to include
       intermediate  points  in  the  description in the source projection, so
       that all these points are included in the target map.

       _C_o_n_t_e_x_t _w_i_t_h_i_n _t_h_e _G_R_A_S_S _G_I_S

       Vector maps (lines and arcs) in the GRASS GIS are represented by a rel-
       atively	straightforward format.  This is exemplified in the ascii ver-
       sion of vector files, as produced by _v_._o_u_t_._a_s_c_i_i [2] and  described  in
       the  programmer's manual [3].  Individual vector segments are described
       by a sequence of coordinate pairs, with the number of coordinated pairs
       for  the segment recorded in a brief header for each segment.  The pro-
       gram _v_._p_r_u_n_e [4] is provided to	remove	points	which  are  considered
       redundant  through  being too close together within a segment.  _v_._p_l_a_n_t
       has been designed as the complement of this, to insert extra points  at
       a specified spacing along straight-line segments.

	DDeessiiggnn ooff vv..ppllaanntt

       _v_._p_l_a_n_t	has been implemented as a Bourne shell script.	The basic pro-
       cedure is as follows:

       1.  Write out the existing map in the _d_i_g___a_s_c_i_i format;

       2.  Use an included _a_w_k script to process each vector segment in  turn,
       moving  from  point  to point along the segment.  If a span between two
       adjacent points is greater than the specified threshold (in map	units)
       extra points are inserted collinearly.

       3.   The modified _d_i_g___a_s_c_i_i file is re-imported, overwriting the origi-
       nal file.

       Because the original _d_i_g file is overwritten, all the support files are
       preserved.   Since the vector segments remain in the same sequence, and
       all the original points remain in the modified map, including the  end-
       points of each segment, all topology, attributes, etc are maintained.

       The  usage is exemplified in the attached manual page.  The source code
       is also attached, which may be examined for a detailed understanding of
       the method.

TTOODDOO
       A command-line version of _v_._p_l_a_n_t would be highly desirable.

SSEEEE AALLSSOO
       _v_._p_r_u_n_e _v_._s_u_p_p_o_r_t

RReeffeerreenncceess
       [1]  Evenden,  G.I.   (1990) Cartographic projection procedures for the
       UNIX environment - a user's manual.  USGS Open-File Report 90-284 (Also
       see  Interim Report and 2nd Interim Report on Release 4, Evenden 1994).

       [2]  Higgins, M. & Westervelt, J.   v.out.ascii	-  Converts  a	binary
       GRASS vector map layer into an ASCII GRASS vector map layer.  GRASS 4.1
       documentation (main section).

       [3]  Shapiro, M., Westervelt, J, Gerdes, D., Larson,  M.  &  Brownfeld,
       K.R.  (1993) GRASS 4.1 programmer's manual.  US Army Construction Engi-
       neering Research Laboratory.

       [4]  Gerdes D.,	v.prune - Prunes points from binary GRASS vector  data
       files.  GRASS 4.1 documentation (main section).


       Copyright (C)  1997 AGCRC & CSIRO

       CSIRO Exploration & Mining Report 239F, March 1996.

       S.J.D. Cox

       _A_G_C_R_C_, _C_S_I_R_O _E_x_p_l_o_r_a_t_i_o_n _& _M_i_n_i_n_g_, _N_e_d_l_a_n_d_s_, _W_A

       _L_a_s_t _c_h_a_n_g_e_d_: _$_D_a_t_e_: _2_0_0_2_/_0_1_/_2_5 _0_5_:_4_5_:_3_5 _$



GRASS 5.0							    v.plant(1)
