Complete.Org: Mailing Lists: Archives: freeciv-ai: April 2002:
[freeciv-ai] Re: Approximate win_chance
Home

[freeciv-ai] Re: Approximate win_chance

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Gregory Berkolaiko <Gregory.Berkolaiko@xxxxxxxxxxxx>, freeciv-ai@xxxxxxxxxxx
Subject: [freeciv-ai] Re: Approximate win_chance
From: Raahul Kumar <raahul_da_man@xxxxxxxxx>
Date: Thu, 18 Apr 2002 05:23:46 -0700 (PDT)

--- Gregory Berkolaiko <Gregory.Berkolaiko@xxxxxxxxxxxx> wrote:
> I ran some simulations with my approximate win_chance formula.
> 
> It doesn't perform as well as I initially thought, but it's definitely 
> better than the current system we have in most AI routines.
> Current system:
> 
> A_rating = A_strength * A_HP * A_FP;
> D_rating = D_strength * D_HP * D_FP;
> 
> chance = A_rating^2 / ( A_rating^2 + D_rating^2 )
> 
> My formula:
> 
> chance = A_rating^5 / ( A_rating^5 + D_rating^5 )

I believe diminishing returns kick in sharply. Would using the formula 

chance = A_rating^6 / ( A_rating^6 + D_rating^6 )

fix the problem of absolute error sometimes being 15%. You should have
mentioned how often those values crop up. 

> This performs way better but for some weird cases it still gives an 
> absolute error of about 15%.
> 

Is there any way we can avoid calling approx win_chance when that happens?

Aloha,
RK.

After all, what is your hosts' purpose in having a party?  Surely not
for you to enjoy yourself; if that were their sole purpose, they'd have
simply sent champagne and women over to your place by taxi.
-- P. J. O'Rourke

__________________________________________________
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/


[Prev in Thread] Current Thread [Next in Thread]