Poll

Is RCI working?

No, it needs major work.
10 (43.5%)
No, it needs some work.
7 (30.4%)
Mostly, just a little adjustment.
5 (21.7%)
Yes. It's fine.
1 (4.3%)

Total Members Voted: 0

Author Topic: Resdesigning RCI  (Read 11649 times)

Offline ptarth

  • Arcen Volunteer
  • Hero Member Mark III
  • *****
  • Posts: 1,166
  • I'm probably joking.
Re: Resdesigning RCI
« Reply #45 on: June 20, 2014, 11:15:38 pm »
  • I don't know Javascript. (tragic I know)
  • I spent some time trying to parse it but I don't think you have it programmed quite right.
  • Trying to change any of the numbers results in odd output behaviors.
  • The base population is different for both models.

    Try this: http://www.r-fiddle.org/#/fiddle?id=NrT0CG5a&version=2
    It's glitchy. I had to send each line to the console (copy & paste).
    When you get to functions or other complete constructs, you'll need to copy & paste everything between the matching braces {}.
    « Last Edit: June 21, 2014, 12:45:44 am by ptarth »
    Note: This post contains content that is meant to be whimsical. Any belittlement or trivialization of complex issues is only intended to lighten the mood and does not reflect upon the merit of those positions.

    Offline NichG

    • Full Member
    • ***
    • Posts: 125
    Re: Resdesigning RCI
    « Reply #46 on: June 21, 2014, 02:11:43 am »
    Yeah, we need to find some common ground between R and Javascript. Matlab/Octave maybe? C? Python?

    Anyhow, the starting population is definitely the same in both graphs - all the curves have at least some time evolution going on. The various curves are 10 years, 20 years, 40 years, and 80 years, and 160 years.

    Offline ptarth

    • Arcen Volunteer
    • Hero Member Mark III
    • *****
    • Posts: 1,166
    • I'm probably joking.
    Re: Resdesigning RCI
    « Reply #47 on: June 21, 2014, 04:49:24 am »
    Okay. That makes more sense. Why are you plotting population by deathrate for a set of years?
    Doesn't Population by year for a set of deathrates make more sense?

    Also, your changed your log.growth formula from:
    growthRate * P - deathRate * P * P (in your post)
    to
    rowthRate * P - deathRate * P * P / landAvail (in your code).
    I'm guessing landAvil == cap/2

    Lastly, I believe I now see what you are trying to say. You want a population to survive no matter what the deathrate is? If so, I'm at a loss to why you'd want this as a feature. All functions have a decelerating deathrates, but the log and lognormal models cause the populations to stabilize at above 0 people in the majority of cases. As long as we take care to reasonably limit the deathrate, I don't see a problem. More to the point, the deathrates you chose, are all within a reasonable frame.

    4 images
    lineardeath.png - Population Growth for a linear model with deathrates that vary from .1 to 1 versus growth rate of 1
    logdeath.png - Population Growth for a log model with deathrates that vary from .1 to 1 versus growth rate of 1.
    birth1.png - Population Growth for log, linear, and hybrid models for 10% growth versus 5% death.
    birth2.png - Population Growth for log, linear, and hybrid models for 10% growth versus 8% death.
    Note: This post contains content that is meant to be whimsical. Any belittlement or trivialization of complex issues is only intended to lighten the mood and does not reflect upon the merit of those positions.

    Offline ptarth

    • Arcen Volunteer
    • Hero Member Mark III
    • *****
    • Posts: 1,166
    • I'm probably joking.
    Re: Resdesigning RCI
    « Reply #48 on: June 21, 2014, 04:51:44 am »
    birth3.png - Population Growth for log, linear, and hybrid models for 10% growth versus 8% death with the following effects.
    #Let's say that our race catches the Arcen Megaflu for 25 years starting at year 50
    #and Mathematic Modelling Fever from years 80 to 100, it drops growthrates by 100%

    birth4.png - Population Growth for log, linear, and hybrid models for 10% growth versus 8% death with the following effects.
    #Let's give them something bad early on
    #Peltian Measles increases deathrate by 400% for years 5to50
    Note: This post contains content that is meant to be whimsical. Any belittlement or trivialization of complex issues is only intended to lighten the mood and does not reflect upon the merit of those positions.

    Offline NichG

    • Full Member
    • ***
    • Posts: 125
    Re: Resdesigning RCI
    « Reply #49 on: June 21, 2014, 07:05:34 am »
    Okay. That makes more sense. Why are you plotting population by deathrate for a set of years?
    Doesn't Population by year for a set of deathrates make more sense?

    Because what I'm trying to point out is the response of the simulation to changing death rates, rather than the population vs time curve (which looks familiar, but isn't very meaningful gameplay-wise). Essentially I'm interested in the long-term consequences more than the shape of the transient (which has very little gameplay consequence compared to the long-term behavior).

    Quote
    Also, your changed your log.growth formula from:
    growthRate * P - deathRate * P * P (in your post)
    to
    rowthRate * P - deathRate * P * P / landAvail (in your code).
    I'm guessing landAvil == cap/2

    Yes, this is the population normalization factor I talked about. Its because 'P' has units, so a coefficient of a linear term has different units than a coefficient of a quadratic term. If we want to compare growth and death rates, we need to normalize the quadratic term by something with units of population.

    So thats what landAvail is doing.

    Quote
    Lastly, I believe I now see what you are trying to say. You want a population to survive no matter what the deathrate is? If so, I'm at a loss to why you'd want this as a feature. All functions have a decelerating deathrates, but the log and lognormal models cause the populations to stabilize at above 0 people in the majority of cases. As long as we take care to reasonably limit the deathrate, I don't see a problem. More to the point, the deathrates you chose, are all within a reasonable frame.

    The nice thing about the hybrid (death<growth) and logistical models is that the equilibrium population is a continuous function of death rate. That is to say, if I increase the death rate, then the carrying capacity of that planet will change even if it doesn't cause extinction.

    For the linear model, your only choices at long times are extinction or a fixed population cap, which is uninteresting. It means that the growth and death rates become purely a matter of 'how long until you get there' rather than 'where do you end up?', which means that there are lots of gameplay cases where they just won't matter all that much.

    Offline ptarth

    • Arcen Volunteer
    • Hero Member Mark III
    • *****
    • Posts: 1,166
    • I'm probably joking.
    Re: Resdesigning RCI
    « Reply #50 on: June 21, 2014, 10:46:29 am »
    I completely disagree? The transition of deathrate & birthrate to some function that effectively moderates the population capacity of the planet is completely unintuitive. To produce an example hilarious scenario:
    Computer: Dear Player, the growth rate of the Skylaxian in 10%, the deathrate after you gave them chocolate is now 100%.
    Player: Oh no, I've wiped them out. Curse my meddling!
    Computer: Relax. The planetary capacity is 10 billion, so this situation will simply mean that they will stabilize at 2 billion population.
    Player: Er, wait, they will survive? Enough though 100% of them die per month? Okay, fine.
    Computer: Dear Player, the Skylaxian Chocolate trade has skyrocketed. Their deathrate is now 200%.
    Player: It did? Grea... Er, Oh no, I've wiped them out. Curse my medding!
    Computer: Relax. The planetary capacity is still 10 billion and their growth rate is 10%. This situation will stabalize at 1 billion population.
    Player: Eh? So 200% of them die in a month, but 1 billion of them survive... This game is buggy.

    I would say that, if you want to change the population equilibrium, then adjust the population capacity (and minimum) of the planet. Don't make birthrates and deathrates have some artificial meaning.
    Note: This post contains content that is meant to be whimsical. Any belittlement or trivialization of complex issues is only intended to lighten the mood and does not reflect upon the merit of those positions.

    Offline NichG

    • Full Member
    • ***
    • Posts: 125
    Re: Resdesigning RCI
    « Reply #51 on: June 21, 2014, 04:52:57 pm »
    I completely disagree? The transition of deathrate & birthrate to some function that effectively moderates the population capacity of the planet is completely unintuitive. To produce an example hilarious scenario:
    Computer: Dear Player, the growth rate of the Skylaxian in 10%, the deathrate after you gave them chocolate is now 100%.
    Player: Oh no, I've wiped them out. Curse my meddling!
    Computer: Relax. The planetary capacity is 10 billion, so this situation will simply mean that they will stabilize at 2 billion population.
    Player: Er, wait, they will survive? Enough though 100% of them die per month? Okay, fine.
    Computer: Dear Player, the Skylaxian Chocolate trade has skyrocketed. Their deathrate is now 200%.
    Player: It did? Grea... Er, Oh no, I've wiped them out. Curse my medding!
    Computer: Relax. The planetary capacity is still 10 billion and their growth rate is 10%. This situation will stabalize at 1 billion population.
    Player: Eh? So 200% of them die in a month, but 1 billion of them survive... This game is buggy.

    I would say that, if you want to change the population equilibrium, then adjust the population capacity (and minimum) of the planet. Don't make birthrates and deathrates have some artificial meaning.

    Instead what I would say is that you should report the instantaneous growth and death rates to the player, or alternately report the growth rate and the effective carrying capacity. The problem here is the choice the model should be expressed as a growth and death rate, when those concepts are not as meaningful in the logistic model as they are in the linear model.

    So for the hybrid model for example, you could report:

    Reported growth rate = inherentGrowthRate * ( 1 - P/capacity )
    Reported death rate = inherentDeathRate

    Now, instead of saying 'the growth rate is 100% but the population isn't growing' you're telling the player 'the growth rate decreases when you approach the planetary capacity'. All of the reasoning they could apply instantaneously with those numbers would still be true (doubling growth rate, doubling death rate, etc) - but as the situation changes (e.g. the population drops lower or increases higher) then the growth rate also changes.

    Alternately, if you wanted to report population capacity and timescale as the salient points, its much easier. I'll use the logistic model here because the math for it is trivial, but you could do it with hybrid as well.

    dP/dt = g*P - d* P*P/land

    Lets rewrite this:

    dP/dt = g*(P - (d/(g*land)) * P * P)

    So this equation has an intrinsic timescale which is 1/g - this is the 'doubling time' in the linear regime, but more generally this is roughly how long it takes to progress 30% towards the population cap (either up or down) from the current population.

    So report a population timescale = 1/g

    Next, you have the planet's carrying capacity, which is P=g*land/d. This is the (nonzero) value for P where dP/dt = 0

    So report 'the planet's maximum sustainable population' which is g*land/d

    Then you can have a tooltip explaining things like doubling the growth rate doubles the carrying capacity, or doubling the death rate halves the carrying capacity. Or you just never refer to 'growth rate' and 'death rate' in the game at all and express everything as carrying capacity.

    Offline Teal_Blue

    • Hero Member Mark II
    • *****
    • Posts: 935
    Re: Resdesigning RCI
    « Reply #52 on: June 22, 2014, 06:57:51 pm »
    Not that your discussion isn't interesting, though it is over my head, the thought I keep having is what 4x game out there gives the player the depth of realism and factors in so very many possibilities as you are talking about?


    Offline GC13

    • Full Member Mark III
    • ***
    • Posts: 204
    Re: Resdesigning RCI
    « Reply #53 on: June 22, 2014, 10:47:06 pm »
    I would consider Victoria 2 to be an aspiration target: every population group (that is to say, every group of people of the same job class, ethnicity, and religion inhabiting the same province) has its income (and therefore ability to afford to buy goods from the local and world markets), employment level, literacy level, political leanings, militancy, and social consciousness tracked. The lack of work can lead to them moving to other provinces where job prospects are better, and various factors can influence their moving between job classes.

    This way, when a rebellion happens and a population group takes up arms to join it, you know that it happened for a specific reason, not because the revolt risk was 10%.
    Furthermore, it is my opinion that Hari must be destroyed.

    Offline NichG

    • Full Member
    • ***
    • Posts: 125
    Re: Resdesigning RCI
    « Reply #54 on: June 23, 2014, 12:32:26 am »
    Not that your discussion isn't interesting, though it is over my head, the thought I keep having is what 4x game out there gives the player the depth of realism and factors in so very many possibilities as you are talking about?

    Well, off the top of my head both Civilization and Warlock effectively use the logistic growth model because the amount of food production needed to support the population grows as the city grows, and eventually the city cannot produce enough food to sustain its growth (e.g. the growth rate falls as the population increases, until it hits zero at a certain equilibrium population).

    Sim City and its descendants are the original inspiration for 'RCI' as I understand it, so that may also be a good place to look for examples.

    Things like Europa Universalis tend to be a lot more complex under the hood than I think we would necessarily want TLF to be. There's a good reason that they simplified things in going from EUIII to EUIV. I'm not sure about Victoria in particular.

    Offline GC13

    • Full Member Mark III
    • ***
    • Posts: 204
    Re: Resdesigning RCI
    « Reply #55 on: June 23, 2014, 01:15:37 am »
    Things like Europa Universalis tend to be a lot more complex under the hood than I think we would necessarily want TLF to be. There's a good reason that they simplified things in going from EUIII to EUIV. I'm not sure about Victoria in particular.
    EU versus Victoria? Let me put it this way: I laughed when you called Europa Universalis "complicated".
    Furthermore, it is my opinion that Hari must be destroyed.

    Offline Teal_Blue

    • Hero Member Mark II
    • *****
    • Posts: 935
    Re: Resdesigning RCI
    « Reply #56 on: June 23, 2014, 02:15:28 am »
    @nichg and @gc13,
                                   thank you for the interesting examples. if you are correct, then perhaps even part way toward that level of complexity would make for much more varied game, yes?
    And perhaps more satisfying for more players if there are more ways to win the game?


    Offline ptarth

    • Arcen Volunteer
    • Hero Member Mark III
    • *****
    • Posts: 1,166
    • I'm probably joking.
    Re: Resdesigning RCI
    « Reply #57 on: June 23, 2014, 02:54:21 am »
    • The level of abstraction and the ability to interact with the underlying components differs greatly between tLF and the previously mentioned games.  Using analogies to bridge them should be done carefully.
    • I don't think a logistic system of population growth is justified. For a simple system of food-based growth it works. However, that's not how tLF is handling it.  Population Capacity is how food production is handled. Population growth is purely a function of lots of alien sex and then aliens being killed by various causes. Neither needs to be logistic, I've previously provided figures to demonstrate that.
    • However, rather than argue about it, I was going to focus my efforts at producing a system that has the components that I've previously discussed, and then provide simulation data demonstrating its characteristics. That seems to be more productive than arguing about things without context.
    • Are you sure that RCI comes from SimCity, or is that a recurring forum rumor? I really don't see much of a connection there, to any of the SimCity games.
    • The level of abstraction in Victoria and EU isn't suitable for tLF because of the scale. In Victoria there are... hundreds if not thousands of pops, in EU hundreds if not thousands of countries (not to mention provinces). In tLF we have just a handful of races.  We also don't have access to manipulate many of the components that would provide those interactions. I believe the most promising area for complexity will be Racial Governments and Federation Governments.

    Interesting RCI questions:
    • how high should each of the Races RCI get in a normal game?
    • What happens if we boost a races technology?
    • How large of an impact to events make?
    • How do you recover after a negative event?
    • After a positive event, is there a decay?

    I've been considering something along the lines of: Technologically progressive races should obtain a RCI of 75% of maximum RCI at the 75th percentile of game duration. Races need to have the option to sacrifice RCI for gains in other regions. Trade should boost RCI. War should hinder RCI. The player should be able to influence RCI in both positive and negative ways. Events should be distributed thus that the majority of events impact RCI ~ 10% of RCI Range. Very rare major events can skew them all the way down (or up). RCI should impact racial budgeting and policy decisions.

    While note related to RCI or population, I think interest could be created with a story-event system as incorporated in King of Dragon Pass.
    Example:
    • Event 1: A Skylaxian sends you a note saying that he wants to help you form a Federation, but he needs some credits. You get to choose give him the money or not.
    • Event 2: After giving him the credits, he runs off to "work" with the Burlusts. He gets involved in a duel to the death, and asks you be his champion. You can decline or not. You can betray him. You can kill everyone involved or just the duelest.
    • Event 3: Skylaxian reports he has developed a virus that can calm the Burlusts down. Do you use it, save it, kill him and pick again, turn him into the Burlusts, spray the Burlusts with the virus.
    • Event 4a: Assuming you choose to spray the Burlusts, the virus may: work - reducing the wars they get into, do nothing, or have the opposite effect - send the Burlusts into a permanent state of frenzy.
    Obviously, there would be many possible outcomes to each of these steps, each feeding into another event. There would also need to be hundreds of these event chains.
    « Last Edit: June 23, 2014, 03:02:30 am by ptarth »
    Note: This post contains content that is meant to be whimsical. Any belittlement or trivialization of complex issues is only intended to lighten the mood and does not reflect upon the merit of those positions.

    Offline Teal_Blue

    • Hero Member Mark II
    • *****
    • Posts: 935
    Re: Resdesigning RCI
    « Reply #58 on: June 23, 2014, 03:26:25 am »
    Based on where Tlf is right now, what are the chances that the changes, additions, elaborations and relevant complexity will be added?

    realistically?



    Offline NichG

    • Full Member
    • ***
    • Posts: 125
    Re: Resdesigning RCI
    « Reply #59 on: June 23, 2014, 04:46:39 am »
    • The level of abstraction and the ability to interact with the underlying components differs greatly between tLF and the previously mentioned games.  Using analogies to bridge them should be done carefully.
    • I don't think a logistic system of population growth is justified. For a simple system of food-based growth it works. However, that's not how tLF is handling it.  Population Capacity is how food production is handled. Population growth is purely a function of lots of alien sex and then aliens being killed by various causes. Neither needs to be logistic, I've previously provided figures to demonstrate that.
    • However, rather than argue about it, I was going to focus my efforts at producing a system that has the components that I've previously discussed, and then provide simulation data demonstrating its characteristics. That seems to be more productive than arguing about things without context.

    I'll wait till you present this model before I comment in detail then. Is this something you think you can make interactive, so we can actually get an idea of how it feels when you play it? 

    Quote
    • Are you sure that RCI comes from SimCity, or is that a recurring forum rumor? I really don't see much of a connection there, to any of the SimCity games.

    In SimCity, RCI = Residential, Commercial, Industrial. Its a three-component quick summary of the status of a city and its focus. The term 'RCI' is very awkward as its used in TLF, which suggests that its an homage to SimCity.

    Quote
    • The level of abstraction in Victoria and EU isn't suitable for tLF because of the scale. In Victoria there are... hundreds if not thousands of pops, in EU hundreds if not thousands of countries (not to mention provinces). In tLF we have just a handful of races.  We also don't have access to manipulate many of the components that would provide those interactions. I believe the most promising area for complexity will be Racial Governments and Federation Governments.

    This is, for me at least, an argument that the individual elements of TLF have room to be more complex than the individual elements of EU or Victoria without making the gameplay too opaque, because there are fewer of those elements for the player to keep track of to still have an overall accurate picture of the state of the game. Whether it should be more complex depends on what you can do with that complexity, and is a separate question.

    Quote
    Interesting RCI questions:
    • how high should each of the Races RCI get in a normal game?
    • What happens if we boost a races technology?
    • How large of an impact to events make?
    • How do you recover after a negative event?
    • After a positive event, is there a decay?

    I've been considering something along the lines of: Technologically progressive races should obtain a RCI of 75% of maximum RCI at the 75th percentile of game duration. Races need to have the option to sacrifice RCI for gains in other regions. Trade should boost RCI. War should hinder RCI. The player should be able to influence RCI in both positive and negative ways. Events should be distributed thus that the majority of events impact RCI ~ 10% of RCI Range.

    ...

    RCI should impact racial budgeting and policy decisions.

    I have no problem with any of this. I'd say the 'sacrifice RCI for gains elsewhere' is a pretty interesting suggestion because it leads to a lot of gameplay possibilities in terms of manipulating that tradeoff action. Also, RCI impacting decision-making is huge and really essential to make RCI a core part of the player's strategy in a meaningful way.

    Quote
    Very rare major events can skew them all the way down (or up).

    I'd reserve the 'complete skew' major events to things that have concrete triggers that can be planned around, rather than RNG-generated happenstance. I like the idea for example that every race has some sort of last ditch attempt when they're about to be taken out, which could be a super-buff for themselves or a super-debuff for another race (similar to the Evuck self-destruction event). That means that working around those events can be part of the player's conscious strategy - triggering them intentionally, having someone else deal the finishing blow, taking out a race quickly enough they can't use their trick, etc.

    Quote
    While note related to RCI or population, I think interest could be created with a story-event system as incorporated in King of Dragon Pass.
    Example:
    • Event 1: A Skylaxian sends you a note saying that he wants to help you form a Federation, but he needs some credits. You get to choose give him the money or not.
    • Event 2: After giving him the credits, he runs off to "work" with the Burlusts. He gets involved in a duel to the death, and asks you be his champion. You can decline or not. You can betray him. You can kill everyone involved or just the duelest.
    • Event 3: Skylaxian reports he has developed a virus that can calm the Burlusts down. Do you use it, save it, kill him and pick again, turn him into the Burlusts, spray the Burlusts with the virus.
    • Event 4a: Assuming you choose to spray the Burlusts, the virus may: work - reducing the wars they get into, do nothing, or have the opposite effect - send the Burlusts into a permanent state of frenzy.
    Obviously, there would be many possible outcomes to each of these steps, each feeding into another event. There would also need to be hundreds of these event chains.

    Yes, this kind of thing is great. Full agreement.