Holy city location [[(10 + CityPopulation + SorenRandNum(1,10)) / (ReligionCount + 1)] / (IsthatCapital?: 8 : 1)] Legends:  means round down (or truncate) the value of the expression between such brackets. SorenRandNum(1,10) is simply the famous RNG with a tag name. It gives 1 to 10 of a value. ReligionCount + 1 : How many religions inside the city and +1 for avoiding the terrible "divide by zero black hole or BSOD". (IsthatCapital? 8 : 1 ==> Ask the question yourself. If the city is a capital, return the value 8. Otherwise, for all other cities, it is 1, which means no real division. City population certainly helps to favor some city you want to be the cradle of a religion, but what is the strongest parameter is indeed the religion count. And bigger the religion count, less imposing is the effect indeed. If we want to study the subject on deterministic grounds, we cut the RNG part and see religion count is the strongest factor to direct a religion fouding. Another pop in a city, small effect (also caused by the constant 10). Another religion added or simply the presence of a single religion, big effect. If population was a pure multiplier, then it would have a big effect... That works the same way as an inverse function. Spoiler : New cities are more favored because of the lack of a religion, then goes for highly populated cities, then loser capital takes it. Fast fall for the very few values and slow down as numbers (religion count) go up. Thread killed.