In combinatorics, it is the problem of selecting a minimum number of sets so that these sets combined contain all the elements found in some reference set.
Questions tagged [set-cover]
44 questions
0
votes
0 answers
Set cover problem with unknown elements inside of subset
The problem is:
Tommy has a square house with size N divided into cell and he want to place sensor detection devices around the house for security. Each sensor can detect up to K step count from the position it is placed. There are M positions…

Nguyễn Việt Anh
- 47
- 3
0
votes
1 answer
An example of an input to the set cover problem which does not provide a 2-approximation
I need some help with the following question:
Show an example of an input to the set cover problem for which the greedy algorithm shown in class does not provide a 2-approximation.
The greedy algorithm:
X - a finite set
F - family of subsets of X…

Eliad
- 39
- 7
0
votes
1 answer
optimal algorithm to solve CLSP(Capacitated Lot Sizing) with the transportation constraints and storage levels
A bank has an ATM machine. For a particular week, the usage of cash in millions as below.
5- Monday
4- Tuesday
1- Wednesday
15- Thursday
6- Friday
2- Saturday
4- Sunday
The bank hires a depositing company to deposit money in 5, 3, or 1 rounds per…

HMD
- 9
- 6
0
votes
1 answer
Optimizing Itertools Results in Python
I am calling itertools in python (see below). In this code, snp_dic is a dictionary with integer keys and sets as values. The goal here is to find the minimum list of keys whose union of values is a combination of unions of sets that is equivalent…

jaykk128
- 43
- 6
0
votes
2 answers
Optimum way to find fewest nodes with most points in Javascript
I have a set of nodes that each contain 0 or more points. There are duplicate points between nodes, but each node may contain points that are unique to that node.
For example:
Node A
Point 1
Point 2
Point 3
Node B
Node C
Point 1
Point 4
Node…

Tim AtLee
- 917
- 1
- 10
- 17
0
votes
1 answer
How to get ALL minimal set covers?
Set cover algorithms tend to provide just one solution for finding a minimum number of sets to cover. How to go about finding all such solutions?

Harold
- 11
- 2
0
votes
0 answers
Whether this is a set cover
Assume that the universe is U, and the subfamily is S={s11,s12,...s1a,s21,...,s2b,...,sn1,...snz}, each element is the subset of U. Now I want choose the minimal number of elements in S to cover the universe, but NOTE that if s11 is selected,…

Talia Hu
- 31
- 4
0
votes
4 answers
Logic to find minimum number of strings for complete coverage of characters
I have set of strings
[abcd,
efgh,
abefg]
How to find the minimum number of strings that covers all the characters (abcdefgh)
Answer would be abcd and efgh. But what would be the algorithm to find this answer?

Yuvaraj
- 23
- 9
0
votes
1 answer
What is the fastest way to do greedy set cover with Pandas?
This question is not completely the same as the greedy set cover problem, but they share the same idea.
Given a Pandas dataframe df1 with one column df['s'] composed of a set of keys of df2:
import numpy as np
import pandas as pd
>>> df =…

Rex
- 2,097
- 5
- 16
- 18
0
votes
1 answer
Minimum Set Cover Algorithm: Finding Size of Optimal Cover
The Set-Cover Problem consists of the following:
Given:
A set of Items U.
A set of Sets S each of which contain items from U.
Find the set of sets C such that:
C is a subset of S.
The sets in C contains all items in U. (at least…

JD009
- 49
- 7
0
votes
0 answers
Maximum set cover of graph
I have a universal set and number of sets S. i need to find maximum number of sets from S such that there is no common element between any choosen two sets.
My Approch--- I have consider each sets in S as a node and if there is any common element…
0
votes
1 answer
How would I sort through lists of frequently used words to find efficient combinations using the most unique words as possible?
I have lists of the most frequently used words, derived from Google's publicly available ngram data.
I have:
6800 frequent 2grams
4800 frequent 3grams
2500 frequent 4grams
1100 frequent 5grams
an example 2 ngram would be something like:
"the dog"…

Jeremy
- 925
- 2
- 11
- 22
-2
votes
1 answer
Greedy algorithm set cover
In the below instance of set cover. How many sets the greedy algorithm will pick?. All sets have cost 1.
Can anyone explain me. What is the solution for this question.
So how will be greedy algorithm works for the 2nd instance.
how many sets it…

Praveenkumar Beedanal
- 774
- 11
- 20
-2
votes
1 answer
Fastest Algorithm for Finding a Minimum Set Cover
What is the most time-efficient and correct algorithm that finds the minimum set cover?
I don't need the code itself. I would like an explanation or pseudo code on how it works.
For an example, we have
Set S = {1,2,3,..,12}
Subsets S1 =…