|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.cpsolver.studentsct.heuristics.selection.PriorityConstructionSelection
public class PriorityConstructionSelection
This selection is very much like BranchBoundSelection
, but it works in cycles
(over all the students) assigning only the first N priority courses. It starts with
N = 1 and increases it by one after each cycle. The selection ends when no student can
get more requests assigned in a whole cycle. Run the selection only once (at the
beginning), the selection falls back to BranchBoundSelection
if there are already
some requests assigned at the time of initialization.
Nested Class Summary | |
---|---|
class |
PriorityConstructionSelection.ConstructionNeighbour
Takes BranchBoundSelection.BranchBoundNeighbour but only assign the given
number of assignments, corresponding to the number of cycles. |
Field Summary | |
---|---|
protected StudentOrder |
iOrder
|
protected List<Student> |
iStudents
|
protected Iterator<Student> |
iStudentsEnumeration
|
Constructor Summary | |
---|---|
PriorityConstructionSelection(DataProperties properties)
Constructor |
Method Summary | |
---|---|
Neighbour<Request,Enrollment> |
branchAndBound(Solution<Request,Enrollment> solution)
Find best solution for the next student using BranchBoundSelection . |
void |
init(Solver<Request,Enrollment> solver)
Initialize |
protected void |
nextCycle(Solution<Request,Enrollment> solution)
Increment cycle |
Neighbour<Request,Enrollment> |
selectNeighbour(Solution<Request,Enrollment> solution)
Select neighbor. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected Iterator<Student> iStudentsEnumeration
protected StudentOrder iOrder
protected List<Student> iStudents
Constructor Detail |
---|
public PriorityConstructionSelection(DataProperties properties)
properties
- configurationMethod Detail |
---|
public void init(Solver<Request,Enrollment> solver)
init
in interface NeighbourSelection<Request,Enrollment>
public Neighbour<Request,Enrollment> branchAndBound(Solution<Request,Enrollment> solution)
BranchBoundSelection
.
protected void nextCycle(Solution<Request,Enrollment> solution)
public Neighbour<Request,Enrollment> selectNeighbour(Solution<Request,Enrollment> solution)
selectNeighbour
in interface NeighbourSelection<Request,Enrollment>
solution
- given solution
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |