Looking for a function that will split profits/loss equally between 2 business partners.
Posted
by
Hamish Grubijan
on Stack Overflow
See other posts from Stack Overflow
or by Hamish Grubijan
Published on 2011-01-02T05:22:10Z
Indexed on
2011/01/02
5:54 UTC
Read the original article
Hit count: 320
This is not homework, for I am not a student. This is for my general curiosity. I apologize if I am reinventing the wheel here.The function I seek can be defined as follows (language agnostic):
int getPercentageOfA(double moneyA, double workA, double moneyB, double workB)
{
// Perhaps you may assume that workA == 0
// Compute result
return result;
}
Suppose Alice and Bob want to do business together ... such as ... selling used books. Alice is only interested in investing money in it and nothing else. Bob might invest some money, but he might have no $ available to invest. He will, however, put in the effort in finding a seller, a buyer, and doing maintenance.
There are no tools, education, health insurance costs, or other expenses to consider. Both Alice and Bob wish to split the profits "equally" (A different weight like 40/60 for advanced users). Both are entrepreneurs, so they deal with low ROI/wage, and high income alike. There is no fixed wage, minimum wage, fixed ROI, or minimum ROI. They try to find the best deal possible, assume risks and go for it.
Now, let's stick with the 50/50 model. If Alice invests $100, Bob invests work, and they will end up with a profit (or loss) of $60, they will split it equally - either both get $30 for their efforts/investments, or Bob ends up owing $30 to Alice.
A second possibility: Both Alice and Bob invest 100, then Bob does all the work, and they end up splitting $60 profit. It looks like Alice should get only $15, because $30 of that profit came from Bob's investment and Bob's effort, so Alice shall have none of it, and the other $30 is to be split 50/50.
Both of the examples above are trivial even when A and B want to split it 35/65
or what have you. Now it gets more complicated: What if Alice invests $70, and Bob invests $30 + does all of the work. It appears simple: (70,30) = (30,30) + (40,0) ... but, if only we knew how to weigh the two parts relative to each other. Another complicated (I think) example: what if Alice and Bob invest $70 and $30 respectively, and also put in an equal amount of work?
I have a few data points:
- When A and B put in the same amount of work and the same $ - 50/50.
- When A puts in 100% of the money, and B does 100% of the work - 50/50.
- When A does all of the work and puts in all of the money - 100 for A / 0 for B (and vice-versa).
- When A puts in 50% of the money, and B puts in 50% of the money as well as does all of the work - 25 for A, and 75 for B (and vice-versa).
If I fix things such that always workA = 0%
, workB = 100%
of the total work, then getPercentageOfA
becomes a function: height z
given x
and y
. The question is - how do you extrapolate this function between these several points? What is this function?
If you can cover the cases when workA does not have to be 0%
of the total work, and when investment vs work is split as 85/15 or using some other model, then what would the new function be?
© Stack Overflow or respective owner