[Freeciv-Dev] Re: City sort algorithm
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Wed, 13 Oct 1999, Peter Schaefer wrote:
>Jarda Benkovsky wrote:
>>
>> Mika Korhonen wrote:
>> > The simple Freeciv Real City Rate R that implements the specification is
>> > obtained by the following formulation
>> >
>> > R = log P + log (A/1000)
>> >
>> > or R = log P + log A - log 1000
>> >
>> > where P is the current population and A the age in year 2000 (when Freeciv
>> > usually ends, right). And that's how I ordered the cities :-) Hence, a city
>> > founded in 1999 and 1000 people gets zero rate.
>>
>
>Ehm - this is equivalent to
>
> r = pow(R) = P*A/1000
>
>and sorting by r = P*A/1000.
>
>And what is the specification again :-)
For sorting purposes even P*A is, obviously, sufficient which on the other
hand cannot be reduced any further... -- the logarithm thing is just to get
nice looking numbers. (-:
Mika
_______________________________________________________________________________
Patience is a minor form of despair, disguised as virtue.
-- Ambrose Bierce, on qualifiers
|
|