fredreload Posted September 5, 2016 Posted September 5, 2016 (edited) So I got this name from Wikipedia. Basically I got a few linear equations of n equations n unknowns so that it is always solvable. For example. val=[3,1,2,3,4,5,3,1,8,7,9,5,0,2,5,3] I got by splitting in half x=[3,1,2,4,6,5,3,1], y=[8,7,9,5,0,2,5,3],z=[?,?,?,?,?,?,?,?],w[?,?,?,?,?,?,?,?] So for each x and y value I plug it into the equation to get z and w 2x+y=14 2x-y=-2 x=3, y=8 z=14,w=-2 Now if I put this in Matrix form it would be |2 1|14| |2 -1|-2| Which I can reduce this matrix with the row reduction formula to solve for x and y using z=14 and w=-2 with the constants |1 0|3| |0 1|8| My point is you can control the constants however you see fit, meaning you can change the equation to 3x+y=17 3x-y=1 You would still get x=3 and y=8 except now z=17 and w=1 so the matrix become. |3 1|17| |3 -1| 1| The equation can also be in polynomials, derivatives, anti-derivatives, as long as I can back solve x and y from w and z. And linear equation is the easiest solvable one. ---------------------------------------------------------------------------------------- But let me show you a mistake I made when I tried to reduce the formula. For instance, I set x-y=-5 y-x=5 These two equations looks opposite of each other, and by doing this I've successfully reduced the output z and w where they are just the opposite of each other z=-w, but this equation doesn't work because they are actually the same equation, so it's 1 equation 2 unknowns and you cannot solve for x and y with this x-y=5 y-x=5, (-1)(x-y)=5, x-y=-5 ---------------------------------------------------------------------------------------- So I want a way to reduce the z and w outputs maybe so that they can reference to each other, but still able to solve for x and y. I can also split val into 3 parts or 4 parts and introduce another variable into the equation for instance val=[3,1,2,3,4,5,3,1,8,7,9,5,0,2,5,3] v=[3,1,2,3],w=[4,5,3,1],x=[8,7,9,5],y=[0,2,5,3] and 4 results [?,?,?,?],[?,?,?,?],[?,?,?,?],[?,?,?,?] So now you have 4 equations 4 unknowns v+w+x+y=15 v+w+x-y=15 v+w-x+y=-1 v-w+x+y=7 | 1 1 1 1|15| | 1 1 1 -1|15| | 1 1 -1 1|-1| | 1 -1 1 1| 7| And at this point if you still knows what I'm talking about, tell me how to set up the equations constants, so I can reduce the results = = Edited September 5, 2016 by fredreload
fredreload Posted September 5, 2016 Author Posted September 5, 2016 (edited) This one is attributed to League of Legends, Google, and Shokugeki no Soma and free for use Edited September 5, 2016 by fredreload
Country Boy Posted September 6, 2016 Posted September 6, 2016 I am simply not clear what you are doing! The system of equation [math]a_{n1}x_1+ a_{n2}x_2+ \cdot\cdot\cdot+ a_{nn}x_n= z_n[/math] has a unique solution as long as the determinant of coefficients is non-zero, irrespective of what numbers you have on the right side. In your first example, that determinant is [math]\left|\begin{array}{cc}2 & 1 \\ 2 & -1\end{array}\right|= 2(-1)- 1(2)= -4[/math], which is non-zero. In the second, it is [math]\left|\begin{array}{cc} 3 & 1 \\ 3 & -1\end{array}\right|= 3(-1)- 1(3)= -6[/math], non-zero. For the third example, x- y= 5 and y- x= -5, which is the same as 1(x)- 1(y)= 5, -1(x)+ 1(y)= -5, the determinant is [math]\left|\begin{array}{cc} 1 & -1 \\ -1 & 1\end{array}\right|= 1(-1)- (-1)(1)= 0[/math] so there is no unique solution. But it is easy to see that if you multiply both sides of x- y= 5 by -1 you get -x+ y= y- x= -5. That is you really have only one equation. There are an infinite number of solutions- pick any number you like for x and take y to be x- 5. You can, by taking w to be -z, get an infinite number of solutions but if [math]w\ne -z[/math], there is no solution.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now