Combinatorica Package >

SetVertexWeights

SetVertexWeights[g]
assigns random real weights in the range [0,1] to vertices in g.
SetVertexWeights[g, w]
assigns the weights in the weight list w to the vertices of g.
SetVertexWeights[g, vs, w]
assigns the weights in the weight list w to the vertices in the vertex list vs.
  • WeightingFunction can take values Random, RandomInteger, or any pure function that takes two arguments, an integer as the first argument and a pair {number, number} as the second argument.
© 2008 Wolfram Research, Inc. japanese.gif
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team