Date: Thursday February 22, 2001 @ 20:34 Author: ahn Update of /home/netrek/cvsroot/Vanilla/robots In directory swashbuckler.fortress.real-time.com:/var/tmp/cvs-serv22838/robots Modified Files: inl.c Log Message: Changes to continuous scoring formula. **************************************** Index: Vanilla/robots/inl.c diff -u Vanilla/robots/inl.c:1.36 Vanilla/robots/inl.c:1.37 --- Vanilla/robots/inl.c:1.36 Fri Jan 26 17:58:01 2001 +++ Vanilla/robots/inl.c Thu Feb 22 20:34:09 2001 @@ -1,7 +1,7 @@ -/* $Id: inl.c,v 1.36 2001/01/26 23:58:01 ahn Exp $ */ +/* $Id: inl.c,v 1.37 2001/02/23 02:34:09 ahn Exp $ */ #ifndef lint -static char vcid[] = "$Id: inl.c,v 1.36 2001/01/26 23:58:01 ahn Exp $"; +static char vcid[] = "$Id: inl.c,v 1.37 2001/02/23 02:34:09 ahn Exp $"; #endif /* lint */ /* @@ -601,7 +601,7 @@ int p, t; double weight = (double) inl_stat.game_ticks / (double) inl_stat.time; - static const double weight_max = 2.7408445; /* 0.5 + 0.5 * exp(1.5); */ + static const double weight_max = 2.0; /* exp(1.0) - 0.71828183 */ /* sanity check! */ if (weight < 0.0) @@ -611,11 +611,11 @@ /* weight = linear range between 0.0 and 1.0 during regulation. * map this to exponential curve using formula: - * weight = 0.5 + 0.5 * exp(1.5 * time) - * weight range is 1.0 to 2.7408445 + * weight = exp(time) - (0.71828183 * time) + * weight range is 1.0 to 2.0 * -da */ - weight = 0.5 + 0.5 * exp(1.5 * weight); + weight = exp(weight) - (0.71828183 * weight); /* sanity check */ if (weight < 1.0)