예제 #1
0
 @Override
 public void auctionResult(Task previous, int winner, Long[] bids) {
   super.auctionResult(previous, winner, bids);
   for (long b : bids) {
     if (b != bid) {
       learn(previous, b);
     }
   }
   round += 1;
 }
예제 #2
0
  @Override
  public Long askPrice(Task task) {
    super.askPrice(task);

    double estimation = estimate(task);

    // The tax
    bid = Math.round(estimation) + 1;
    return bid;
  }
예제 #3
0
  @Override
  public void setup(Topology t, TaskDistribution td, Agent a) {
    super.setup(t, td, a);

    init();
  }