0. edit claLength when you use it for Syngenta projects.

1. check each record is in order. -- take care when you use that -- when insert the theory - -you need to reverse the order of PosEI. 
You can check the inserted results first. 

2. How did u update the Description Length



??? only keep the non-zero branch: % it is unfair to remove one branch -- add one more branch -- then it has 


?? minus score-- so that it is sorted by descending order, rather than  when they have the same score
-- then you will start combining from the head of list. also you need another variable to 
-- the advantage of this, is when you have the same score, you will combine the one with higher coverage/lower DL. 


/* This version's competing: a *complete* search. Which one to include is a decision to be made by comparing their scores.  



Test example:
the whole module has lower score because of one bad branch -- if that bad one is replaced by sth better, then 

several single-clause candidate --- is the shortest 
-- make it quicker by grouping

Design one DAG, to have my redundancy assumption tested

*/


% how does pruning work? -- the competing of same example will be ignored; on the other hand, it consider more combination than pure covering. Because it doesn't simply choose one and continue, but scoring as a whole.  

/* what variables required? 

*** Final decision: 
for each returned candidate -- did u keep their score -- you don't need to re-score? -- no still need, because which branch did u choose really depends.
for combining and competing
??? How did u compute DL? -- it requires recalculation when u remove some bits.

Re-calculate every time. -- some bit is updated -- everything is recorded along the line (the cost is that you have to maintained the record)
There is no point to keep the score -- because the coverage will depends on the intersection. 
OK, now final decision, 


1. score related to each returned hypothesis -- it is contained in the variable of hypothesis: [ClaID-Length-EIList,] -- which Cla is specially for which example can be determined from this information.
The description length is a sum of each candidate
The potential example covered is the union of those appeared at the EI-List.
% to improve efficiency, you may want to have seperated variable, and only alter them each time (rather than compute from scratch).

2. To avoid recalculating the coverage and description length of each branch, please record them for each branch. 
3. endNode -- for the nodes ended with the same claID, they should be gathered, otherwise, they have to compete with each other at that point. 

*/
/* To be extended
 beam search -- consider those equal score

negative score, so that when same score, it will be 

also grouping the same coverage -- do this later -- since the expanding is only about
*/
