Interface CoresAlgo.Result<V,E>

Type Parameters:
V - the vertices type
E - the edges type
All Known Subinterfaces:
CoresAlgo.IResult
Enclosing interface:
CoresAlgo

public static interface CoresAlgo.Result<V,E>
The result of the cores computation.
Author:
Barak Ugav
  • Method Summary

    Modifier and Type
    Method
    Description
    coreCrust(int core)
    The vertices in the crust of the given core.
    coreShell(int core)
    The vertices in the shell of the given core.
    coreVertices(int k)
    The vertices of the given core.
    int
    The maximum core number of the graph.
    int
    The core number of the given vertex.
  • Method Details

    • vertexCoreNum

      int vertexCoreNum(V v)
      The core number of the given vertex.

      The core number of a vertex is the highest order of a core that contains this vertex.

      Parameters:
      v - a vertex in the graph
      Returns:
      the core number of the vertex
      Throws:
      NoSuchVertexException - if v is not a valid vertex identifier in the graph
    • maxCore

      int maxCore()
      The maximum core number of the graph.
      Returns:
      the maximum core number of the graph
    • coreVertices

      Set<V> coreVertices(int k)
      The vertices of the given core.

      A vertex is in the core if its core number is at least the given core number.

      Parameters:
      k - the core number (order)
      Returns:
      the vertices of the core
      Throws:
      IndexOutOfBoundsException - if k is not in range [0, maxCore()]
    • coreShell

      Set<V> coreShell(int core)
      The vertices in the shell of the given core.

      A vertex is in the shell of the core if its core number is exactly the given core number. Namely it is in the k core but not in the (k+1) core.

      Parameters:
      core - the core number (order)
      Returns:
      the vertices in the shell of the core
      Throws:
      IndexOutOfBoundsException - if k is not in range [0, maxCore()]
    • coreCrust

      Set<V> coreCrust(int core)
      The vertices in the crust of the given core.

      A vertex is in the crust of the core if its core number is less than the given core. The crust is the complement of the core vertices set.

      Parameters:
      core - the core number (order)
      Returns:
      the vertices in the crust of the core
      Throws:
      IndexOutOfBoundsException - if k is not in range [0, maxCore()]