Changeset 513

Show
Ignore:
Timestamp:
11/11/09 16:23:17 (14 years ago)
Author:
trnewman
Message:

Increased PU detection threshold for utility punishment

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • vtcross/trunk/src/cognitive_engines/DSA_CE/DSA_CognitiveEngine.cpp

    r512 r513  
    183183    int reward = 20; 
    184184    int punishment = -100; 
    185  
    186     if((observables[COMMUNICATION_TIME].value != 0) || (observables[ENERGY].value > 1000)) {  
    187         printf("Cognitive Engine:: Primary User caused channel change - Decrementing Utility. %f %f",observables[COMMUNICATION_TIME].value,observables[ENERGY].value); 
     185    int Detection_Threshold = 10000000; 
     186 
     187    if((observables[COMMUNICATION_TIME].value != 0) || (observables[ENERGY].value > Detection_Threshold)) {  
     188        printf("Cognitive Engine:: Possible PU Detection - Decrementing Utility. %f %f",observables[COMMUNICATION_TIME].value,observables[ENERGY].value); 
    188189        newUtilityValue = newUtilityValue + punishment; 
    189190    } else {