[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [igraph] max min degree of a graph
From: |
Pagliari, Roberto |
Subject: |
Re: [igraph] max min degree of a graph |
Date: |
Tue, 29 Jul 2014 19:30:28 +0000 |
Hi Tamas,
how should I change the lines below for an undirected graph with weights (so
that max min \sum weight should be optimized)?
Thank you,
-----Original Message-----
From: Tamás Nepusz [mailto:address@hidden
Sent: Tuesday, July 29, 2014 3:27 PM
To: Help for igraph users; Pagliari, Roberto
Subject: Re: [igraph] max min degree of a graph
I'm pretty sure that this will do the trick:
coreness_scores = graph.coreness()
max_coreness = max(coreness_scores)
subgraph = graph.induced_subgraph([v for v, score in enumerate(coreness_scores)
if score == max_coreness])
(Assuming that you meant that the degrees of the vertices in the subgraph are
to be calculated on the subgraph only, otherwise the whole task would be pretty
trivial).
--
T.
-----Original Message-----
From: Pagliari, Roberto <address@hidden>
Reply: Help for igraph users <address@hidden>>
Date: 29 July 2014 at 16:43:31
To:address@hidden <address@hidden>>
Subject: [igraph] max min degree of a graph
> Is there a built in function (possibly in Python) to find the subgraph
> of a graph G that maximizes the min degree?
> _______________________________________________
> igraph-help mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/igraph-help
>