How best to handle ratios in a model?

This forum contains all archives from the SD Mailing list (go to http://www.systemdynamics.org/forum/ for more information). This is here as a read-only resource, please post any SD related questions to the SD Discussion forum.
Locked
rgd6 cornell.edu
Junior Member
Posts: 4
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by rgd6 cornell.edu »

Posted by <rgd6@cornell.edu>
This should be a simple question:

I regularly use ratios in models, especially where an influencing model
component is ""normalized"". If these ratios are far from zero, then things
work fine, but if numerator and denominator both approach zero (with
variations in both) things can get messy and unpredictable. The specific
instance I am thinking of is if both are approaching zero then where we
might expect a ratio of 1/1 we can easily get some very different outcomes.
Some modification of the ratio is called for....

are there any standard or ""best practice"" techniques for dealing with these
situations?


Richard
Posted by <rgd6@cornell.edu>
posting date Wed, 6 Apr 2005 15:54:34 +0700
John Sterman jsterman MIT.EDU
Junior Member
Posts: 6
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by John Sterman jsterman MIT.EDU »

Posted by John Sterman <jsterman@MIT.EDU>
Excellent question. This issue should be understood not as a problem
of mathematics but from a behavioral perspective. If two quantities
are both very small (and where noise or other variability is large
relative to the mean values) then the ratio of the two is highly
variable and it is highly unlikely to be used as the input to
decision making. The question is not: 'how can I find a mathematical
workaround for this problem' but 'what metric and comparison are the
actual decision makers using?' Field study or other empirical
insight into how real people make decisions using the cues is needed.

John Sterman
Posted by John Sterman <jsterman@MIT.EDU>
posting date Wed, 6 Apr 2005 10:10:09 -0400
Joel Rahn jrahn sympatico.ca
Newbie
Posts: 1
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by Joel Rahn jrahn sympatico.ca »

Posted by Joel Rahn <jrahn@sympatico.ca>
Vensim has a function Zero If Dividing by Zero, ZIDZ(A,B),
that gives A/B if B is not 0 and gives 0 if B=0.

Joel Rahn
Posted by Joel Rahn <jrahn@sympatico.ca>
posting date Wed, 06 Apr 2005 07:34:35 -0400
Bill Harris bill_harris facilita
Junior Member
Posts: 19
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by Bill Harris bill_harris facilita »

Posted by Bill Harris <bill_harris@facilitatedsystems.com>
>> ... The specific
>> instance I am thinking of is if both are approaching zero then where we
>> might expect a ratio of 1/1 we can easily get some very different outcomes.
>> Some modification of the ratio is called for....


How would the people / policies respond IRL in those cases?

Bill
- --
Bill Harris http://facilitatedsystems.com/weblog/
Facilitated Systems Everett, WA 98208 USA
http://facilitatedsystems.com/ phone: +1 425 337-5541
Posted by Bill Harris <bill_harris@facilitatedsystems.com>
posting date Wed, 06 Apr 2005 07:13:45 -0700
Wei Xie wei.xie delsys.ca
Newbie
Posts: 1
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by Wei Xie wei.xie delsys.ca »

Posted by Wei Xie <wei.xie@delsys.ca>


>> Vensim has a function Zero If Dividing by Zero, ZIDZ(A,B),
>> that gives A/B if B is not 0 and gives 0 if B=0.


ZIDZ(A,B) only solves the problem in a mathematical/technical sense.
Plus, ZIDZ(0.01, 0.00001)=1000, which may not be the ratio that
decision makers use in the practice.
Sterman's point is that decision makers still make decisions (not
based on the ZIDZ result, but on something else) when the ratio is
something like 0.01/0.00001. SD practitioners have to figure out what
is the ""something else"" and how they influence the decision.

Wei Xie
Posted by Wei Xie <wei.xie@delsys.ca>
posting date Thu, 7 Apr 2005 10:44:16 -0400
rgd6 cornell.edu
Junior Member
Posts: 4
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by rgd6 cornell.edu »

Posted by <rgd6@cornell.edu>
These are good points ... That I need to look at the specific case - what do
I expect to happen in the real world - of course.

In this particular case, I was expecting that the value should approach 1:1
which in the sense I have modeled it means it has no effect.

However, looking at it again (this is a ratio of payment to expected
payment) I think that as both payments and expected payments drop
substantially the whole issue (of relative size of payments) would
""evaporate"" - i.e. is no longer important.

A value of 1 satisfies this, but maybe something other than a simple ratio
is more appropriate. (Perhaps any deviation from 1 should be reduced by an
additional factor as expected payment gets low?)

In this case expected payment is, in part, determined by a smooth of
previous payments. If other effects are minimized, which could happen, then
I have x over a smooth of x which for given smooth times will be a constant
as x declines. This does not approach 1.

BTW Normally this doesn't happen... Just in looking at (sort of) extreme
conditions. But nevertheless I need to rethink this formulation.


-- Richard
Posted by <rgd6@cornell.edu>
posting date Fri, 8 Apr 2005 09:23:28 +0700
Jean-Jacques Laublé jean-jacques
Senior Member
Posts: 68
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by Jean-Jacques Laublé jean-jacques »

Posted by =?iso-8859-1?Q?Jean-Jacques_Laubl=E9?= <jean-jacques.lauble@wanadoo.fr>
Hi Richard.



Is the ratio used elsewhere in the model?

If not, the solution is to formulate this like:

ratio = it then else (ratio numerator < numerator limit :and: ratio
denominator < denominator limit, value indicating that the ratio is no more
important, xidz(ratio numerator, ratio denominator, value indicating that
the ratio is no more important) )

If the value of the ratio = the value indicating that the ratio is no more
important, then you know that the ratio is not important.

If the ratio is used elsewhere in the model, you have to decide what to do
with the values using the ratio if the ratio has no more importance, using
another in then else function like:

Value influenced by the ratio = If then else (ratio = value indicating that
the ratio is no more important, special treatment of the value, current
treatment of the value)

Regards.

J.J. Laublé, Allocar Strasbourg, France.

Posted by =?iso-8859-1?Q?Jean-Jacques_Laubl=E9?= <jean-jacques.lauble@wanadoo.fr>
posting date Fri, 8 Apr 2005 15:34:32 +0200
Magdy Helal mhelal mail.ucf.edu
Newbie
Posts: 1
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by Magdy Helal mhelal mail.ucf.edu »

Posted by ""Magdy Helal"" <mhelal@mail.ucf.edu>
When ratios like that happen in the model then it is because of the
way the mathematical formulation is made. They are just the values
resulting from the calculations. Then the considerations should be
reviewing the mathematical formulation so that such values do not
happen. Or review the structure of the system and the policies to
see if this what leads to these ratios.

We are not supposed to bypass a problem but we want to expose them
so they can be eliminated. If there is this ""something else"" to make
the decision and no way that we can avoid the ratios by mathematics
or system structure then this is the real life where humans are needed.
The use of lookup tables would be useful in that. By tables you force
the system towards certain values based on the conditions you see related.

My point is we do not need ways to bypass problems but we need to expose them.

Regards

Magdy Helal
Industrial Engi & Management Systems Dept
University of Central Florida
4000 Central Florida Blvd
Orlando, Florida 32816
Posted by ""Magdy Helal"" <mhelal@mail.ucf.edu>
posting date Fri, 08 Apr 2005 15:00:00 -0400
Louis Macovsky dynbiosys verizon
Junior Member
Posts: 4
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by Louis Macovsky dynbiosys verizon »

Posted by ""Louis Macovsky"" <dynbiosys@verizon.net>
Greetings,

1. It seems to me that the role of ratios in the structure of a model is
one of ""normalization"" of one or two variables. And THEN is used for
decision making based on the result. Am I correct?

2. IMHO: The use of IF Then statements suggested by Jean-Jacques seems more
of a tool of convenience for the elimination of the ratio when it can longer
be explained. If I interpreted Sterman correctly, in his book, the IF Then
statement should be avoided as in this case because it causes an abrupt
change in the behavior of the system. Comments?

Louis

Louis Macovsky, DVM, MS
Dynamic BioSystems, LLC
28695 SW Sandalwood Dr.
Wilsonville, OR, USA 97070
Posted by ""Louis Macovsky"" <dynbiosys@verizon.net>
posting date Sat, 09 Apr 2005 10:22:26 -0700
John Gunkler jgunkler sprintmail
Member
Posts: 30
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by John Gunkler jgunkler sprintmail »

Posted by ""John Gunkler"" <jgunkler@sprintmail.com>
As Magdy Helal wrote, I'd be quite tempting to use the ""ratio"" separately as
numerator and denominator. I would use the denominator as input to a table
function, which became quite non-linear as it approached zero. I might then
also use the numerator as an input to another table function, behaving quite
similarly. Then I might formulate a ratio of the two outputs of the two
table functions -- AND THEN see if that kind of thinking was what was
actually going on. I would anticipate some need for fiddling with the two
table functions, and I'd be a little surprised if the table functions
weren't identical, but you never know until you try it out with the policy
makers.

Good luck.
Posted by ""John Gunkler"" <jgunkler@sprintmail.com>
posting date Sat, 9 Apr 2005 08:53:10 -0500
Jean-Jacques Laublé jean-jacques
Senior Member
Posts: 68
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by Jean-Jacques Laublé jean-jacques »

Posted by =?iso-8859-1?Q?Jean-Jacques_Laubl=E9?= <jean-jacques.lauble@wanadoo.fr>
Hi Louis and everybody



<The use of IF Then statements suggested by Jean-Jacques seems more
<of a tool of convenience for the elimination of the ratio when it can
longer
<be explained. If I interpreted Sterman correctly, in his book, the IF Then
<statement should be avoided as in this case because it causes an abrupt
<change in the behavior of the system. Comments?





A general comment about ratios.

I use a lot of ratios in my business because they are convenient.

But there is a flaw in ratios: they transform two values in one value.

There is a loss of information.

Once normalized the ratio is representing the ratio of one value by another

always the same. So normalization is just making the denominator the unit of
measure or the value of reference. Ratios are then more valuable.

I use ratio but I have always to interpret them. They are often significant
in current situations but can express false indications if the denominator
or the numerator have special values.

One can see in this situation the fact that reality (specially social
reality) is not always possible to represent by equations or numbers. One
has then to do something about that.

Reality being not always continuous it is sometimes necessary to use If then
else functions.

Imagine that in you model there is the possibility that your main competitor
buys your second main competitor. You will have to build in you model a
sharp discontinuity with an if then else or build two different models
because there is no half buying it is yes or no.

I try to avoid if then else (Business dynamics John Sterman page 547) but it
is not always possible or it can distort reality.



There is in the molecules version 1.4 a soft if then else (Richardson),
built on a ratio and table functions.

But it has two drawbacks: It does not work with special values of one of the
value to be compared with the other (when Y = 0) and it transforms a
discontinuous process into a continuous one. It is okay if it does not
change reality too much, but in some cases it is impossible, as in the
buying or not buying of your main competitor. Just a remark for Jim Hines,
the soft if then else is no more in the Version 2 of the molecules!



Then in my last day remark, I was not discarding a particular case, but
considering that it could need a special treatment impossible to incorporate
into the main continuous one.

To see if it is really the case, one should study the particular case of
Richard to see if the problem can or cannot be represented in one continuous
model.

In my formulation, one can replace the :AND: by an :OR: depending on the
case.



Regards.

J.J. Laublé. Allocar.

Strasbourg. France
Posted by =?iso-8859-1?Q?Jean-Jacques_Laubl=E9?= <jean-jacques.lauble@wanadoo.fr>
posting date Sun, 10 Apr 2005 17:49:59 +0200
geoff coyle geoff.coyle btintern
Member
Posts: 21
Joined: Fri Mar 29, 2002 3:39 am

How best to handle ratios in a model?

Post by geoff coyle geoff.coyle btintern »

Posted by ""geoff coyle"" <geoff.coyle@btinternet.com>
Dear All,

One easy way to do this is to write X=A/(B+EPS) where EPS is a very small
number - 0.001 or less and has the same dimensions as B. There are more
sophisticated possibilities but this quick and dirty method has always
worked for me.

Regards,

Geoff

Visiting Professor of Strategic Analysis,
University of Bath
Posted by ""geoff coyle"" <geoff.coyle@btinternet.com>
posting date Tue, 12 Apr 2005 15:01:54 +0100
Locked