>

Eric Turkheimer

@ent3c

Dumb (but real and research-related) question:

Y1 = aX^2 + bX + c

Y2 = dX^2 + eX + f

What is Y1 in terms of Y2?

r/t if you know a good high school math teacher >

>

Eric Turkheimer

@ent3c

Dumb (but real and research-related) question:

Y1 = aX^2 + bX + c

Y2 = dX^2 + eX + f

What is Y1 in terms of Y2?

r/t if you know a good high school math teacher >

This entry was posted in Uncategorized. Bookmark the permalink.

%d bloggers like this:

The quadratic equation is usually taught in the 7th grade, not high school. Algebra I

Seriously, how the f are ‘we’ losing with muppets like this on the other side. I genuinely don’t understand.

Because their message is attractive and without noticeable downside in a world that can comfortably ignore heredity.

Every mother can completely mold her child! Good social policy can fix every unfortunate person! We just have to put our minds and money to the effort!

I can remember working on them age 14 or 15 I think. However, I cannot say they changed my life for the better. A regret.

There is no general solution where y1 is a function of y2 or vice-versa.

Take a simple example :

y1=x^2 + x + 1

y2= -x^2 + 3x + 4

for x=1, y1=1+1+1=3, y2= -1+3+4=6

for x=2, y1=4+2+1=7, y2= -4+6+4=6

So for the same value of y2 you can have two different y1.

Now depending on your particular equations there might be a particular solution.

x= (-b (+/-) sqrt(b^2-4a(c-y1)))/2a, same with y2

If you can determine which way the (+/-) falls for both solutions, then you have it (a typical case is if x always want to be positive over the range of the model). Good luck.

The two parabolas are independent of one another. I don’t any way to express Y1 in terms of Y2.

I suppose you could say that:

Y1 = (a/d)

dX^2 + (b/e)eX + (c/f)*fbut I can’t see how that would be useful.

Do you mean how to express the roots of Y1 in terms of the roots of Y2?

You might get a connection if both the equations could be factored.

But I assume the question is asking in general, for any two quadratic equations. There is no way to do it.

I suppose you could say that

Y1 – Y2 = (a – d)X^2 + (b – e)X + c – f

so

Y1 = Y2 + (a – d)X^2 + (b – e)X + c – f

but that does not express Y1 in terms of Y2 alone.

Silly question.

Turkheimer clarifies:

“Clarifying: I want an expression for Y1 in terms of Y2 and (a,b,c,d,e,f). ”

So

Y1 = Y2 + (a – d)X^2 + (b – e)X + c – f

is no good. It has X’s in it.

Someone tweeted a solution for the roots (zeros) or Y1 in terms of a,b,c,d,e and f, but that is not what Turkheimer asked for.

You can’t do much with algebra alone.

You get some connection if both equations can be factored but you can’t assume that in general.

I never studied how to do it but there must computerized methods of getting an approximation of the roots.

But that’s not much use, it can’t be generalized.

I agree with you.

Frau why he hell are we both awake at 2:30 am? I’m going to bed.

Does “completing the square” ring a bell? Definitely for me but it’s very distant,

I could complete the square in my sleep. It is just deriving the quadratic formula for the roots of the function. But Turkheimer didn’t say anything about roots.

Don’t you just complete the square?

x = (-e +/- sqrt(e^2 – 4d(y_2 – f)))/2d

Then substitute in eq1.

What’s the catch?

Oops, typo inside the sqrt() there; should be -4d(f – y_2).

“Completing the square” does ring a bell now that you mention it. It’s been many decades since I heard it, in the early 1970s.

One thing I remember from physics was that unrelated polynomials like this was that you were at an algebraic dead end with them though. I have recollections of that happening.

Completing the square must the way a computerized calcution would work.

But that will only work when Y2 is equal to zero. It says nothing about that.

Nope, look closer.

So you have made an equation equal to zero by subtracting y2 from itself. Still, there will be either 0, 1, or 2 x values. If there are 2, which one are you going to substitute into Y1?

You seem to be rather dense, so I’ll break it down for you:

Write y_2 = dx^2 + ex + f

Complete the square so that y_2 = λ(x+θ)^2 + φ, where: λ=d, θ=e/2d, and φ=f-((e^2)/4d)

Rearrange so that x is the subject: x = -θ +/- sqrt((y_2 – φ)/λ)

Unpack the Greeks back to d, e, f

Substitute x into the y_1 equation.

There’s no assumption that y_2 = 0.

“There’s no assumption that y_2 = 0.”

I see that. Did you not read my response?

You are a very rude person. And you don’t read carefully either.

There’s a y_2 term inside the sqrt. It does reduce to the quadratic formula when y_2 = 0, but it’s still valid otherwise.

But you might get two x values. Which will you sub into Y1?

Both of them. It’s an inherently multi-valued problem.

Draw two parabolas A and B, and ask “when A(x)=10, what is the value of B?”

There may be zero, one, or two solutions. Nothing wrong with that.

A quadratic function is a FUNCTION. For every x in the domain there is exactly one y in the range. The domain of a quadratic function is all real numbers, so every real number x , including the x value that makes A(x) = 10, there must be exactly one B(x).

There is more than one x value that makes A(x) = 10.

Here’s a picture:

We’re asking: when the purple function takes on the blue value on the y-axis, what is the corresponding value of the orange function? We solve for the two x-values that satisfy that condition, then compute Orange(x), for both of them.

@Catte The parabolas don’t need to intersect each other at all.

All those parameters appearing as denominators will fail if the parameter = 0 (or any expression involving the parameters = 0).

Those must be cases of denominators being zero. Or another problem: anything for which you’re taking a square root cannot be negative.

I never said they had to intersect each other.

If there is a division by zero error (d=0) it means that y_2 is linear not quadratic, and the solution is trivial to find anyway.

If the square root is negative then it means you’re asking about a value of y_2 that isn’t part of that function’s range, so of course it will break.

You know, it seems as though there are quite a few people reading Westhunt who don’t have this extra sense, either.

If A(x,y) = y – x^2 and B(x,y) = y – 2 x^2 then on the parabola A(x,y) = 10 viz. y – x^2 -10 = 0 the function B(x,y) will of course assume an infinite number of values.

If the level set of a quadratic polynomial A(x,y) defines a parabola for say one value of k, A(x,y) = k, then all level curves will be a parabolas. (In the case of A defining say a hyperbola for some k (A(x,y) = k) it will in general define a hyperbola for other values but degenerate to two straight lines if k is the value of A at it’s center and also if A defines an ellipse for some value of k (A(x,y) = k) it defines an ellipse for other values of k or degenerates to a single point or empty locus. But such degeneration doesn’t happen for a quadratic defining a parabola for whatever the value of k it will be centerless and parabolas are the only centerless conics. All degenerate conics have centers.)

Two distinct parabolas like any two distinct non-degenerate conics may intersect in up to four points.

There’s no catch. Just that you can have 0, 1 or 2 Y2’s given a Y1. Very simple math, that’s the point.

Y2 is a single parabola. It is completely determined by it’s coefficients d, e, and f. There is exsctly 1 Y2.

Yes, but given a Y coordinate from the first parábola, you get back up to two x’s. Each of these x’s can yield two different values when plugged into the Y2’s equation.

True. So that suggests there is no way to make a single formula work.

(I switched Y1 and Y2: actually, he’s asking for a map from Y2 into Y1, if I understand it right)

May be I’m wrong, but this is how I see the problem: you have y2 = x^2 and, on the other hand, y1 = (x-1)^2. Those are two parallel parabolas. If you fix an horizontal ruler on y2 = 1, you will get two x’s: 1 and -1. Then, if you plug these values in y1, you get either 0 or 4.

Ok. But they have only a single y value at different places–their vertices.

Catte,

well I guess your solution will work as long as y2 is only allowed to take on values in the range of y2. But at the vertex of y2 you will just get a single x value. How will you be able to get 2 y1 values out of that?

Well in that case there’s only one solution.

But there should be two, unless they have the same vertex.

sighCatte what are you sighing about? I suppose you think I’m stupid for asking about the vertices. You assume your formula will map the vertex of y2 onto the vertex of y1.

If the square root in your formula is zero, then there is one x. x = -e/(2d), which is the x value where the vertex of y2 occurs. How is plugging -e/((2d) into y1 going to yield the vertex of y1? You should plug -b/(2a) into y1 to get the y coordinate of the vertex of y1.

There is not a functional relationship between y1 and y2. The pairs (y1,y2) constitute a relation but not a functional relation.

I assume nothing of the sort. It’s not supposed to map the vertex of y_2 onto the vertex of y_1. Why on Earth would it?

Oh goodness. Solve equation (2) for x and plug into equation (1). Of course, you will get two solutions in general.

Trivial if d=0. Even Eric should be able to work it out.

This is why I love twitter. People sometimes slip up and reveal useful information.

The equations are unrelated except for form, far more variables than equations , no solution

The coefficients a-f are given. So given y2, there are two equations in two unknowns (x,y1)

Off topic, but some might find this interesting. Non linear systems of equations cannot be solved with linear algebra, bur iterative solutions (Newton/Raphson, etc.) are often possible. Sometimes there are an infinite number of solutions to a set of equations, but most of the solutions are useless. An example of this occurs in electrical power systems work: Power flow between various sources and loads in a network is modeled using periodic functions, and the solutions are found using a computer to solve the non-linear system. All of this was fine when a few base load plants were feeding a somewhat known and predictable electrical grid, but it becomes a bit of a pain when various sources (I’m glaring at you wind guys) keep turning on and off, or varying their outputs.

Treat Y2 as a constant in equation 2 and solve for x using the standard formula for solving quadratic equations (which is derived by completing the square in any Algebra 1 class). Now substitute these values of x, which are expressed as a function of Y2, in equation 1 to express Y1 as a function of Y2.

If (f-y2)/d > (e/2d)^2: no solutions

If (f-y2)/d = (e/2d)^2:

y1 = ae^2/(4d^2) -be/2d + c

If (f-y2)/d < (e/2d)^2: two solutions

Solution 1:

r = (-e/2d) + sqrt ((e/2d)^2 – (f-y2)/d)

y1 = ar^2 + br + c

Solution 2:

s = (-e/2d) – sqrt ((e/2d)^2 – (f-y2)/d)

y1 = as^2 + bs + c

For full credit consider also the cases where d = 0 etc.

I wonder what the chances are that Turkheimer is for the first time cranking through Bayes’ rule in the case of two normal distributions (or a related computation), i.e. Pr[G] = N(mu_g, a), Pr[P|G] = N(G, b) => Pr[G|P] = N(mu, c), with c = a

b/(a + b) and mu = [b/(a + b)mu_g + a/(a + b)*P]. (There’s the heritability coefficient, a/(a+b).) Naively, one would indeed get this result by completing the square in equations like those above–but it’s not actually necessary, because one knows that the result is a normal distribution and therefore doesn’t have to keep track of the “constant” terms that are independent of G….Good thinking. I guess the most charitable explanation I can come up with is that he wants to do that on the blackboard tomorrow, in a lecture, and can’t remember how you derive it.

But still… there’s a reason you should be embarrassed to ask certain questions in public.

Especially when the tweet immediately below your school-boy algebra problem wants to tell people what to think about the reality of g…

That’s probably a little unfair to Turkheimer.

Ah, this makes me remember my misspent youth at the Mathematics Olympiad in the old country. Clearly, one can solve one equation for x, and then plug it into the other one. But this is messy algebra, apart form the fact that you get two solutions for x, so you have to check out both. There is a more elegant way to do things, see below. Pls do not get frightened by nested parentheses: I included them here: If there is demand, I can type it up in swp and post the pdf…

Moreover, greg – if the Y1,Y2 are noisy data and you want to test: I can give you a bit more help, but I do not want to publish it here (would be too informative of me..): just drop me a line…

If a or d is zero, then the problem is trivial: one Y is a linear function of x, so solve for x (unique solution) and plug it into the other one. If the corresponding coefficient to the linear term is zero too, then the corresponding Y is constant – and we cannot do anything. So let us assume that a, d are nonzero.

First of all define Z1=(Y1-c+(b^2)/(4a))/a and Z2=(Y2-f+(e^2)/(4d))/d . Z1, Z2 are linear transformations of Y1 and Y2 , not involving x. So if we find a relation between Z1 and Z2, we can simply plug in the definitions and get our result.

Now observe that Z1=(ax^2+bx+c-c+(b^2)/(4a))/a=a

(x^2+2(b/(2a))x+(b^2)/(4a^2))/a=(x+b/(2a))^2. Analogously (substituting d,e,f for a,b,c) we get Z2= (x+e/(2d))^2. Lets now define

M=((b/2a)+(e/2d))/2 and S=((b/2a)-(e/2d))/2. Then Z1=(x+M+S)^2=(X+M)^2+2(X+M)S+S^2 and

Z2=(x+M-S)^2=(x+M)^2-2(X+M)*S+S^2 .

Hence Z1-Z2=4(X+M)S. If S is not equal zero, Then we can divide by S, and we have

X+M=(Z1-Z2)/(4S), which we can now substitute in our expressions for Z1 and Z2, and get relations depending on Z1, Z2 alone. The most aesthetically pleasing one you get when you add up Z1 and Z2, because the linear terms cancel out: Z1+Z2=2(X+M)^2+2S^2 which is – expressed in Z1,Z2

Z1+Z2=(((Z1-Z2)^2)/(8S^2))+2S^2.

Remains the case S=0, which means b/a=e/d. Then we have Y1/a=x^2+(b/a)x+(c/a) and

Y2/d=x^2+(e/d)x+(f/d). Subtracting these two equations, we get (Y1/a-Y2/d)=(c/a)-(f/d), so we have covered this case, too.

I hope I did not make any typos. If anything is unclear, pls ask – I will try to explain: I enjoy thinking of the time when I was young!

Congrats. I was doing these for my baccalaureate 12 years ago and I have forgotten nearly everything. Where are you from?

Not related. Perhaps I am obtuse and over-literal, but I am not seeing the point.

isn’t… isn’t it just (y1-y2) = blah blah blah? and then y1 = blah blah blah + y2? Am I just retarded or is Turkheimer?

Since everyone else is agonizing over the math, I’ll point out that the title of this post comes from a Darwin quote: he felt that people who were good at math had an extra sense, which he envied.

The ability to quickly construct mathematical models of things has come in handy for me a lot. And it does seem to intimidate those who can’t, sometimes.

Wait…

Turkheimer writes:

“Clarifying: I want an expression for Y1 in terms of Y2 and (a,b,c,d,e,f). ”

How about Y1 = ax^2 + bx + c. Turkheimer says you can use a, b, and c.

Because you don’t know what x to use unless you solve for it from equation 2, from the given value of y_2.

It doesn’t matter what x’s you use. You can use any x’s you like.

For goodness sake, how are you not getting this? We are

givena value of y_2, so the x’s are constrained to be whatever is the pre-image of that value of y_2. We then plug those values into the equation for y_1.That’s what “y_1 in terms of y_2”

means.If I say

y1 = ax^2 + bx + c + 0*y2

Then y1 is expressed in terms of y2 and { a, b,c,d,e,f}

With your system you are given a y2 value, and you find the x value(s) associated with that y2 value, and plug them into y1. But Turkheimet didnt specify he wanted that. That is not what “y1 in terms of y2” means.

Yes, it is. It really, really is.

I’m not an idiot, as you seem to think. I know what “express y2 in terms of y1” means.

It is a pointless question, as I said from the start. Your formula uses a y2. You must have had an x in the first place in order to get that y2. So just plug the damned x into y1.

It would only matter what x you use if you were trying to find where the functions intersect.

If this is a physical system then maybe y2 is easier to measure directly than x. You’d have to ask Turkheimer what he needed it for. In any event it’s still a well-posed question, if unusual.

I am too lazy to solve it explicitly. The extra sense to solve it is as follow. No need for sqrt.

First get x^2 in term of y1,y2,a,b,c,d,e,f, i.e multiply eq1 with e and eq2 with b and subtract the

two to eliminate the x term, re-arrange to get eq for x^2

Similar get x in term of y1,y2,a,b,c,d,e,f, i.e. multiply eq1 with d and eq2 with a and subtract the two to eliminate the x^2 term, re-arrange to get eq for x

Next substitute the x^2 and x term into eqn1 or eqn2 and rearrange to get y1 explicity without the x^2 and x and in terms of y2,a,b,c,d,e,f only. QED.

” I want an expression for Y1 in terms of Y2 and (a,b,c,d,e,f)”. Fine. However, Turkheimer will – in general – get two values for each value of Y2, because a quadratic equation has two solutions: First observe that we can write the equation for Y2 as dx^2+ex+(f-Y2)=0 , so

x=(-e +/- sqrt(e^2-4e(f-Y2))/(2d) (+/- should mean + or -, remember two solutions…). We now could plug these solutions into the equation for Y1. But assuming both a and d to be nonzero (otherwise trivial) we have

Y1/a=x^2+(b/a)x+(c/a) and Y2/d=x^2+(e/d)x+(f/d). When we subtract these equations, the quadratic term cancels out and we get Y1/a-Y2/d=((b/a)-(e/d))x+(c/a)-(f/d). Now plugging in the solution for x is easy. Add Y2/d to both sides, and then multiply by a gives the final expression:

Y1=a(Y2/d+((b/a)-(e/d))(((-e +/- sqrt(e^2-4e(f-Y2)))/(2d))+((c/a)-(f/d))))

A bit ugly, and the parentheses are a mess (I hope I got them right, but nothing mysterious..

slightly off-topic comments (except for the last paragraph):

I am not good at all at understanding other people’s view of math problems, so I would not be a good high school math teacher.

Plus, every year when daylight savings time rolls around I have to think a little bit to understand the simple arithmetic involved. Also, I still harbor unfounded suspicions that

“long division” is somehow fundamentally flawed, even if it always “works” when done right.

I don’t have the “extra sense” Darwin wrote about, not even close.

On the other hand, a few years ago I almost understood how the oceanic lunar tides are generally figured out, but I suspect that my understanding was much less complete than I thought.

… to continue that line of thought:

as a counterexample where my understanding was complete: having played hundreds of rubbers of bridge in my youth, often very successfully, I can no longer sympathetically understand how the basic Monty Hall “problem” has ever been viewed by anyone as anything but trivial. Maybe in this extremely limited realm of the mathematical universe – a realm limited to some very simple math derived from bridge – I know what Darwin’s extra sense feels like, but to me it does not feel interesting or exciting (whereas winning at bridge was very rewarding).

A few years back, an ex-crytographer named Hugh Thurston, in a magazine for college math teachers (sponsored by the Mathematical Association of America) wrote an article which seemed to me to be persuasively explaining that the “usual treatment” of the ways of denoting derivatives, limits, and integrals in the teaching of elementary calculus (in the Leibniz notation) is illogical, because, inter alia, the student is likely to confound “x” qua variable with “x” qua number in the early expressions used for derivatives, and therefore the student is going to be much slower to notice that the usual notation “purports to define dy/dx without imposing enough conditions to ensure that dy/dx is uniquely determined by x and y.”

So, not that anyone asked, I am not going to join in the mockery, even if I get it, sort of (and yes I understand that “sort of getting it” means “not really getting it,” as Hegel pointed out in a different context in the first pages of his long book on the history of philosophy).

First a really simple problem:

T1 = a

T2 = b

Express T1 in terms of T2:

T1 = T2; when a = b

Over to:

Y1 = aX^2 + bX + c

Y2 = dX^2 + eX + f

That can be reformulated to:

Y1 = Parabola(a,b,c)

Y2 = Parabola(d,e,f)

A parabola is uniquely defined by its parameters.

Express Y1 in terms of Y2:

Y1 = Y2 = Parabola(d,e,f) where a=d,b=e,c=f.

Y1 and Y2 are the same parabola.

The square roots then? Two roots are given: r1 and r2.

X must be r1^2 on both sides, or r2^2 on both sides, otherwise we would have two different X values.

People just dont get it. The extra sense is that the question posed is fundamentally linear and the x^2 is the red herring thrown in to confuse as shown by the number of people talking about quadratic and parabola which will further complicate things with sqrt and y1*y2 terms unnecessary. Yesterday I just jump in intuitively without trying to sought the why and how for the rest of the day. This morning I woke up with the understanding of the why and how. I must have worked that out in my sleep 🙂

Counter intuitively it is easier to explain and to understand by kicking the problem up another extra dimension in terms of (y1,y2,w,x) instead of just (y1,y2,x), re-phrasing the problem stated as

y1=a

w + bx + c –(eqn1)y2=d

w + ex + f –(eqn2)w=x^2 –(eqn3)

It is bleeding obvious that eqns 1 and 2 are

strictly linear. People encountering thatwill notinvoking quadratic, parabola or sqrt. Period. And they will have no problem expressing y1 in terms of linear y2 term and other given constants a,b,c,d,e,f. They will realized that eqn3 is not needed at all for the question posed. The extra sense is to short cut all that. The similar approach is also applicable for three cubic equations and any similar higher order problems with the equivalent extra y’s equations.The system reformats the text.

y1=a

w + bx + cy2=d

w + ex + fw=x^2

The level set for a given value of y_1 will be a straight line in w-x space, and this will in general get mapped to the entire real line by the y_2 function. The fact that w=x^2 is an useful constraint, because it reduces an infinite set of solutions down to merely two.

Turkheimer has slipped. He thrown in x^2 to confuse but the use of (x,y1,y2) which does not stop me to imagine (x1,x2,y1,y2) higher dimensions. If he had use (x,y,z) in the first place that might have tricked and anchored me to strict 3 dimensional real space and miss the obvious. It is easier to accept (x1,x2,y1,y2) abstract mathematical space with algebraic manipulations but there will be a mental block to the “real” (w,x,y,z) 4 dimensional space using spatial perception. Those that have better spatial perception tended to use this faster and intuitive spatial perception rather than the mental manipulation of algebraic terms. I had switched to the algebraic mindset.

Just like in “Dune”, there is a space where noone dare to look. “””People find little difficulty facing that (3-D) place within themself, where the taking force dwells, but it’s almost impossible for them to see into the giving force (higher dimensions with embeding 3-Ds and space foldings like the Turkheimer space into 4-D space) without changing into something other than human. These things are so ancient within us that they are ground into each separate cell in our bodies, we are shaped by such force. You can say to yourself, yes I see how such a thing may be, but when you look inward, and confront the raw force of your life unshielded, you see your peril.””” Cantor looked into infinity and become crazy. Boltzmann looked into randomness and become equally mental.

1) Subtract Y2 from both sides of 2nd equation 2) Use quadratic formula to solve for X in terms of d, e, f and Y2.

3) Substitute the resulting expression for X into the 1st equation, and simplify.

You now have your answer: Y2 expressed in terms of only a, b, c, d, e, f, and Y2.

(Note that because the general quadratic formula yields 2 solutions for X in step 2), step 3) will yield 2 district expressions for Y1. In an application for which the 7 parameters a-f and Y2 have known numeric values, it is possible that the two expressions for Y2 will end up being numerically equal; but typically, and certainly as long as the problem is expressed algebraically, there will be 2 distinct solutions)

Correction: “

Y1expressed in terms of…”Watching high-IQ math whizzes do their thing https://youtu.be/-ruC5A9EzzE

Assume without loss of generality that Y2=x^2.

Then Y1=aY2 – b

sqrt(Y1) + c or Y2=aY1 + bsqrt(Y2) + c, depending on whether you’re left or right of the origin on the Y2 parabola.If the original Y2 parabola isn’t in the above simple form, transform the axes by shifting and stretching till it is. Do this transformation to both Y1 and Y2 equations, then solve as above.