v.net.connectivity(1grass)

✨ v.net.connectivity ✨

okay bestie, welcome to v.net.connectivity(1grass) πŸ’– this is the module that does vertex connectivity between two sets of nodes, and it is lowkey iconic. it lives in the vector, network, connectivity corner of GRASS and no cap, it's about to be your fave.

🌸 NAME 🌸

v.net.connectivity β€” computes vertex connectivity between two sets of nodes in the network. it's giving "how many little guys do i have to delete to break these two apart" energy πŸ¦‹

πŸŽ€ KEYWORDS πŸŽ€

  • vector
  • network
  • connectivity

⭐ SYNOPSIS ⭐

v.net.connectivity
v.net.connectivity --help
v.net.connectivity input=name  [arc_layer=string]   [node_layer=string]
[arc_column=name]   [arc_backward_column=name]  output=name
[node_column=name]   [set1_cats=range]   [set1_where=sql_query]
[set2_cats=range]   [set2_where=sql_query]   [--overwrite]  [--help]
[--verbose]  [--quiet]  [--ui]

🫢 Flags:

  • --overwrite β€” lets output files straight up overwrite files that already exist. be brave, bestie πŸ’…
  • --help β€” prints the usage summary, for when you're like "wait what"
  • --verbose β€” verbose module output, the module will NOT stop talking
  • --quiet β€” quiet module output, the module goes silent mode 🀫
  • --ui β€” forces launching the GUI dialog, for the visual girlies

🧚 Parameters:

  • input=name [required] β€” name of input vector map. can also be a data source for direct OGR access
  • arc_layer=string β€” arc layer. so here's the thing: vector features can have category values in different layers, and this number picks which layer to use. when you're using direct OGR access, this thing is the layer name instead. default: 1
  • node_layer=string β€” node layer. same deal as above: vector features can have category values in different layers, this number decides which layer, and with direct OGR access it's the layer name. default: 2
  • arc_column=name β€” arc forward/both direction(s) cost column (number)
  • arc_backward_column=name β€” arc backward direction cost column (number)
  • output=name [required] β€” name for output vector map
  • node_column=name β€” node cost column (number)
  • set1_cats=range β€” Set1 category values. example: 1,3,7-9,13
  • set1_where=sql_query β€” Set1 WHERE conditions of SQL statement without ’where’ keyword. example: income < 1000 and population >= 10000
  • set2_cats=range β€” Category values. Set2 category values πŸ“
  • set2_where=sql_query β€” Set2 WHERE conditions of SQL statement without ’where’ keyword. example: income < 1000 and population >= 10000

πŸ’œ DESCRIPTION πŸ’œ

so v.net.connectivity computes vertex connectivity between two sets β€” periodt. what that means is: it finds the minimum number of vertices whose removal would separate two given sets. literally the smallest sabotage squad that would cut set1 off from set2 πŸ˜­πŸ‘‘


🌈 NOTES 🌈

your two sets (set1 and set2) get specified through their own layer, where and cats parameters β€” mix and match however, bestie.

and just like the v.net.flow module, you can hand over capacities of nodes using the node_column option. obsessed.

what v.net.connectivity actually does: it finds the set of nodes with the minimum total capacitiy separating the two given sets, and then it outputs a map containing points on the positions of these nodes. slay.

the default capacity β€” the one it uses when you didn't specify any column β€” is 1. no notes, iconic.


πŸ”₯ EXAMPLE πŸ”₯

say you wanna find the minimum number of intersections separating roads on the left bank from roads on the right bank. bet:

v.net.connectivity input=roads output=roads_conn set1_where="bank=left" \
      set2_where="bank=right"

and here's the airtraffic one, cutting JFK off from Heathrow with capacity as the node column:

v.net.connectivity input=airtraffic output=connectivity \
      set1_where="name=JFK" set2_where="name=Heathrow" node_column=capacity

πŸ‘‘ SEE ALSO πŸ‘‘

  • v.net
  • v.net.flow
  • v.net.bridge

go read those too, bestie, it's a whole ecosystem 🫢


πŸ’– AUTHORS πŸ’–

  • Daniel Bundala, Google Summer of Code 2009, Student
  • Wolf Bergenheim, Mentor

πŸ¦‹ SOURCE CODE πŸ¦‹

Available at: v.net.connectivity source code (history)

Latest change: Friday Feb 07 19:16:09 2025 in commit: a82a39f673b97fafcfce1604dc3e6015cb96487a

Main index | Vector index | Topics index | Keywords index | Graphical index | Full index


okay that's the whole page πŸŽ€ and for the lil sign-off: this is GRASS 8.5.0, straight out of the GRASS 8.5.0 Reference Manual, Β© 2003-2026 GRASS Development Team πŸ’œ ty for coming to my ted talk, now go compute some connectivity, iykyk ✨

πŸ“¦ where this page comes from