Complete.Org: Mailing Lists: Archives: freeciv-dev: February 2005:
[Freeciv-Dev] Re: (PR#12313) Battle computation questionable
Home

[Freeciv-Dev] Re: (PR#12313) Battle computation questionable

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: chrisk@xxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#12313) Battle computation questionable
From: "Marko Lindqvist" <marko.lindqvist@xxxxxxxxxxx>
Date: Mon, 21 Feb 2005 12:28:23 -0800
Reply-to: bugs@xxxxxxxxxxx

<URL: http://bugs.freeciv.org/Ticket/Display.html?id=12313 >

Jason Short wrote:
> <URL: http://bugs.freeciv.org/Ticket/Display.html?id=12313 >
> 
> Christian Knoke wrote:
> 
>><URL: http://bugs.freeciv.org/Ticket/Display.html?id=12313 >
>>
>>
>>CVS 21 FEB 2005 GTK2 S2_0
>>
>>Maybe this is a case where the fight computation is wrong - please check.
>>
>>Battle:   Tank attacks stack of 20 howitzers
>>Ruleset:  default
>>Options:  mostly default (irrelevant AFAICS)
>>
>>Details:    Tank     Any of 20 howitzers (identical)
>>----------------------------------------------------
>>Attack:     10       12
>>Defense:     5        2
>>Firepower:   1        2
>>Hitpoints:  30       30
>>HP (act.):  30       30
>>Movepoints:  3        2
>>MP (act.):   2       (unknown)
>>Veteran:     1.75     1.50
>>
>>  Boni:
>>fortified:  no       no (F, not X)
>>Hills:      --        1.5
>>River:      --        1.5
>>
>>Attack value (Tank):        10 * 1 * 1.75 = 17.5
>>Defense value (Howitzer):   2 * 2 * 1.5 * 1.5 * 1.5 = 13.5
>>
>>Winning chance displayed in popup: 45% (!)
>>
> 
> Hills are x2, not x1.5.  (This comes from the defense_value of 20 in the 
> ruleset.  I guess this is not a per-cent but is a per-deca or something.)
> 
> So it is instead (with the "internal" factor of 10 added on):
> 
> Attack: 10 * 1 * 1.75 = 175
> Defense: 2 * 2 * 2 * 1.5 * 1.5 = 180.

  You are multiplying by firepower?

  Tank needs to win 30 / 1 = 30 rounds before Howitzer wins 30 / 2 = 15 
rounds. Tank needs to win at least 30 / 44 = 68.2% rounds in order to 
win battle.

  For single round
  Attack: 10 * 1.75 = 175
  Defense: 2 * 2 * 1.5 * 1.5 = 90

  Win chance for tank is 175 / 265 = 66.0% for each round.

  Probability that Tank wins 30 rounds and Howizer only x (x < 15):
  0: 0.660^30                             =
  1: 0.660^30 * 0.34 * 30                 =
  2: 0.660^30 * 0.34^2 * 31! / 29! / 2    = 0.000
  3: 0.660^30 * 0.34^3 * 32! / 29! / 3!   = 0.001
  4: 0.660^30 * 0.34^4 * 33! / 29! / 4!   = 0.002
  5: 0.660^30 * 0.34^5 * 34! / 29! / 5!   = 0.005
  6: 0.660^30 * 0.34^6 * 35! / 29! / 6!   = 0.010
  7: 0.660^30 * 0.34^7 * 36! / 29! / 7!   = 0.017
  8: 0.660^30 * 0.34^8 * 37! / 29! / 8!   = 0.027
  9: 0.660^30 * 0.34^9 * 38! / 29! / 9!   = 0.040
10: 0.660^30 * 0.34^10 * 39! / 29! / 10! = 0.053
11: 0.660^30 * 0.34^11 * 40! / 29! / 11! = 0.063
12: 0.660^30 * 0.34^12 * 41! / 29! / 12! = 0.073
13: 0.660^30 * 0.34^13 * 42! / 29! / 13! = 0.080
14: 0.660^30 * 0.34^14 * 43! / 29! / 14! = 0.083
                                            =====
                                            0.454


  Seems correct to me.


  - ML





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