Reducing Subset-Sum to Scheduling with start time.

2.7k Views Asked by At

Given a set of $n$ jobs with processing time $t_i$, release time $r_i$, and deadline $d_i$, can we schedule all $K$ number of jobs ($0 \le K$)on a single machine. Reduce SubsetSum to Schedule. The solution goes as Given an instance of SUBSET-SUM $\{a_1,..,a_n\}$ and $T$. Design $r_i = 0$, $d_i = 1+\sum_i a_i$ , $p_i = a_i$ where $p_i$ is process time for $n$ jobs and create another job with release time $T$,process time 1, and deadline $T+1$ (so create $n+1$ jobs). We show that an instance can be accepted by Subset sum iff our designed $n+1$ jobs all can be accepted by schedule.

However, I'm confused here, because if a SubsetSum takes an array [1,1,2] and the target = 6. Then, SubsetSum would return False; but this instance according to transformation would give a set of job (0,1,5), (0,1,5), (0,2,5), (6,1,7). The first element is release time, second is process time, third is deadline. Schedule Problem can schedule all of these jobs without overlap or miss deadline. So SubsetSum() return False but Schedule return True