NAME
v.net.alloc - Allocate subnets for nearest centres (direction from centre).
Centre node must be opened (costs >= 0). Costs of centre node are used in calculation
KEYWORDS
vector, networking
SYNOPSIS
v.net.alloc
v.net.alloc help
v.net.alloc [-g] input=name output=name [type=string[,string,...]] [alayer=integer] [nlayer=integer] [afcolumn=string] [abcolumn=string] [ncolumn=string] ccats=range [--overwrite] [--verbose] [--quiet]
Flags:
- -g
- Use geodesic calculation for longitude-latitude locations
- --overwrite
- Allow output files to overwrite existing files
- --verbose
- Verbose module output
- --quiet
- Quiet module output
Parameters:
- input=name
- Name of input vector map
- output=name
- Name for output vector map
- type=string[,string,...]
- Arc type
- Options: line,boundary
- Default: line,boundary
- alayer=integer
- Layer number
- Arc layer
- Default: 1
- nlayer=integer
- Layer number
- Node layer
- Default: 2
- afcolumn=string
- Arc forward/both direction(s) cost column (number)
- abcolumn=string
- Arc backward direction cost column (number)
- ncolumn=string
- Node cost column (number)
- ccats=range
- Category values
- Categories of centres (points on nodes) to which net will be allocated, layer for this categories is given by nlayer option
DESCRIPTION
v.net.alloc allocates subnets for nearest centres (direction from
centre). Centre node must be opened (costs >= 0). Costs of centre node are
used in calculation. Supported are cost assignments for both arcs and nodes,
and also different in both directions of a vector line. For areas cost will
be calculated along boundary lines.
NOTES
Center nodes have to be assigned to vector nodes using v.digit
or added from other map(s). Nodes and arcs can be closed using cost = -1.
EXAMPLES
Example 1: Calculating subnets for 3 centre nodes using distances
#Spearfish
# centre nodes:
echo "591235.5|4926306.62|1
596591.8|4917042.5|2
602722.9|4923544.2|3" | v.in.ascii out=centrenodes
g.copy vect=roads,myroads
#connect points to network
v.net myroads points=centrenodes out=myroads_net op=connect thresh=200
# view map
g.region vect=myroads_net
d.mon x0
d.vect myroads_net
d.vect myroads_net col=red icon=basic/triangle fcol=green size=12 layer=2
# allocate, specifying range of center cats (easier to catch all):
v.net.alloc myroads_net out=myroads_net_alloc ccats=1-100000 nlayer=2
# report categories
v.category myroads_net_alloc option=report
# the result has to be selected by category number of the relevant node:
d.vect myroads_net_alloc cat=1 col=red
d.vect myroads_net_alloc cat=2 col=green
d.vect myroads_net_alloc cat=3 col=yellow
d.vect myroads_net col=red icon=basic/triangle fcol=green size=12 layer=2
Example 2: Calculating subnets for 7 centre nodes using cost assigned to vector length
v.net.alloc in=vectmap out=vectmap.alloc ccats=1-7
Example 3: Calculating subnets for 7 centre nodes using cost assignments in both
directions
v.net.alloc in=vectmap afcol=INDEX abcol=INDEXBACK out=vectmap.alloc ccats=1-7
SEE ALSO
d.path,
v.net,
v.net.iso,
v.net.path,
v.net.steiner,
v.net.salesman
AUTHOR
Radim Blazek, ITC-Irst, Trento, Italy
Last changed: $Date: 2009-03-04 15:00:42 -0800 (Wed, 04 Mar 2009) $
Main index - vector index - Full index
© 2003-2010 GRASS Development Team