vCoverHypergraph         package:hypergraph         R Documentation

_A_p_p_r_o_x_i_m_a_t_e _m_i_n_i_m_u_m _w_e_i_g_h_t _v_e_r_t_e_x _c_o_v_e_r _i_n _a _h_y_p_e_r_g_r_a_p_h

_D_e_s_c_r_i_p_t_i_o_n:

     Approximate minimum weight vertex cover in a hypergraph

_U_s_a_g_e:

     vCoverHypergraph(hg, vW=rep(1, numNodes(hg)))

_A_r_g_u_m_e_n_t_s:

      hg: an instance of the 'Hypergraph' class 

      vW: vertex weights

_D_e_t_a_i_l_s:

     Hypergraph 'g' has non-negative weights on its vertices. The
     minimum weight vertex cover problem is to find a subset of
     vertices C  such that C includes at least one vertex from each
     hyperedge and the sum of  the weights of the vertices in C is
     minimum.  This problem is NP-hard.

     We implement the greedy algorithm to approximate near-optimal
     solution,  proposed by E. Ramadan, A. Tarafdar, A. Pothen, 2004.

_V_a_l_u_e:

     A list of vertices from hypergraph 'g'.

_A_u_t_h_o_r(_s):

     Li Long <li.long@isb-sib.ch>

_R_e_f_e_r_e_n_c_e_s:

     A hypergraph model for the yeast protein complex network, 
     Ramadan, E.   Tarafdar, A.   Pothen, A., Parallel and Distributed
     Processing Symposium, 2004. Proceedings. 18th International.

_S_e_e _A_l_s_o:

_E_x_a_m_p_l_e_s:

     # to turn the snacoreex.gxl graph (from RBGL package) to a hypergraph
     # this is a rough example 
     kc_hg_n <- c("A", "C", "B", "E", "F", "D", "G", "H", "J", "K", "I", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U")
     kc_hg_e <- list(c("A", "C"), c("B", "C"), c("C", "E"), c("C", "F"), c("E", "D"), c("E", "F"), c("D", "G"), c("D", "H"), c("D", "J"), c("H", "G"), c("H", "J"), c("G", "J"), c("J", "M"), c("J", "K"), c("M", "K"), c("M", "O"), c("M", "N"), c("K", "N"), c("K", "F"), c("K", "I"), c("K", "L"), c("F", "I"), c("I", "L"), c("F", "L"), c("P", "Q"), c("Q", "R"), c("Q", "S"), c("R", "T"), c("S", "T"))
     kc_hg_he <- lapply(kc_hg_e, "Hyperedge")
     kc_hg <- new("Hypergraph", nodes=kc_hg_n, hyperedges=kc_hg_he)

     vCoverHypergraph(kc_hg)

