Getting stuck

slyerfox

New member
Joined
Jul 11, 2012
Messages
6
Hi, I don't know if I'm doing the right thing, but I think I've come to the conclusion that I have two equations which needs answering (at the same time).

1) ax = k + x + y

2) by = k + x + y

I'm trying to find a formula to optimize x and y given that a and b are variables and k is a constant.

So far I have:

1) ax - x = k + y

2) by -y = k + x

which isn't much.

Is this solvable at all? :shock:

/Cheers
 
Hi, and thanks for answering!

I'm not even sure I've got the equations correct... :(

None of the expressions can be negative, that's for sure. What it's all about is getting figures for x and y that is equal to the sum of the constant, x and y.

I tried to make it a bit fancy by adding a and b to the equations, but we could use hypothetical numbers just as well for the time being.

For example, if a = 1,5 b = 4,5 and k = 500

1) 1,5x = 500 + x + y
2) 4,5y = 500 + x + y

I remember there are instances where you set all on one side and zero on the other, but I can't recall if it's correct to do so and if it would help me in this case.

That would be:
1) 0,5x - y - 500 = 0
2) 3,5y - x - 500 = 0


Did that help at all?
 
I think you have described the problem a lot better than I could do and I will try to put your formulas into Excel and see if it works out.

I do assume that ab > (a + b) and it's a fair assumption that a is unequal to 1 as well.

Thank you very much! I'll do some lab testing with it.

Cheers!
/Slyerfox
 
An added problem to the problem

Hi all, the initial question regarded

1) ax = k + x + y

2) by = k + x + y

which has been solved by Jeff.

What happens if there's another equation added?

3) cz = k + x + y + z

changing the first two into

1) ax = k + x + y + z

2) by = k + x + y + z

????????? ;)
 
You're the man, Jeff!!

Matrices are MUCH more efficient for large systems, but, if the system is soluble at all, it can always be solved by the method of substitution.

System:

\(\displaystyle ax = k + x + y + z\)

\(\displaystyle by = k + x + y + z\)

\(\displaystyle cz = k + x + y + z\)

Solution (assuming all pronumerals are positive, a \(\displaystyle \ne \) 1, ab > a + b, and abc > ab + ac + bc)

\(\displaystyle ax = k + x + y + z \implies x(a - 1) = k + y + z \implies x = \dfrac{k + y + z}{a - 1}.\) Now substitute for x in the other two equations.

\(\displaystyle So\ by = k + x + y + z \implies by = k + \dfrac{k + y + z}{a - 1} + y + z \implies aby - by = ak - k + k + y + z + ay - y + az - z \implies y(ab - a - b) = a(k + z).\)

\(\displaystyle So\ cz = k + x + y + z \implies cz = k + \dfrac{k + y + z}{a - 1} + y + z \implies acz - cz = ak - k + k + y + z + ay - y + az - z \implies z(ac - a - c) = a(k + y).\)

Now we have two equations in two variables, y and z. So do it again.

\(\displaystyle y(ab - a - b) = a(k + z) \implies y = \dfrac{a(k + z)}{ab - a - b}.\) Now substitute for y in the other equation.

\(\displaystyle So\ z(ac - a - c) = a(k + y) \implies z(ac - a - c) = ak + a\left(\dfrac{a(k + z)}{ab - a - b}\right) \implies z(ab - a - b)(ac - a - c) = ak(ab - a - b) + a^2k + a^2z \implies\)

\(\displaystyle z(a^2bc - a^2b - abc - a^2c + a^2 + ac - abc + ab + bc) = a^2bk - a^2k - abk + a^2k + a^2z \implies\)

\(\displaystyle z[a^2(bc - b - c) - a(bc - b - c) - bc(a - 1)]= z[(a^2 - a)(bc - b - c) - bc(a - 1)] = (a - 1)z(abc - ab - ac - bc) = abk(a - 1) \implies\)

\(\displaystyle z = \dfrac{abk}{abc - ab - ac - bc} \implies\)

\(\displaystyle a(k + z) = \dfrac{ak(abc - ab - ac - bc) + a^2bk}{abc - ab - ac - bc} = \dfrac{ak(abc - ac - bc)}{abc - ab - ac - bc} = \dfrac{ack(ab - a - b)}{abc - ab - ac - bc} \implies\)

\(\displaystyle y = \dfrac{ack(ab - a - b)}{abc - ab - ac - bc} \div (ab - a - b) = \dfrac{ack}{abc - ab - ac - bc} \implies\)

\(\displaystyle k + y + z = k + \dfrac{abk + ack}{abc - ab - ac - bc} = \dfrac{abck - abk - ack - bck + abk + ack}{abc - ab - ac - bc} = \dfrac{bck(a - 1)}{abc - ab - ac - bc} \implies\)

\(\displaystyle x = \left(\dfrac{bck(a - 1)}{abc - ab -ac -bc}\right) \div (a - 1) = \dfrac{bck}{abc - ab - ac - bc}.\)

Now you should see the pattern if you decide to add more variables. I am not going to work this out for four variables, and I am certainly not going to prove the pattern for n variables. But you now have 2 ways to do this kind of problem, substitution and matrices, plus a pattern that makes intuitive sense. So good luck.



Double substitutions! I've never used those before. I guess my math class didn't get that far, but at the age of 48 I find math becoming really interesting again! :D

I'm with you until the part where it says z = abk/(abc-ab-ac-bc), and I think I understand the symmetry, but where does the next line come from?
 
Last edited by a moderator:
Top