Hello all, madlysavage here and I (obviously) need help. I'm working on a making a video game(yes at 14), and i need to have two things spread out in 2 opposite parabolas on the x and z axis. the problem is i have a start point and an end point, both parabolas need to intersect where they hit (its an ion cannon ) and at the cannon itself, and my problem is, i need to figure out how to control the intersection points of two parabolas
I need to be able to set the intersections of two parabolas to two separate locations, lets say on a grid, i need the intersections to be at (19,5) and (10, 24)... its as simple as that, sorry about any confusion, im trying to explain it the to the fullest of my capabilities, im terrible with words hahaha
Also, you were talking about x- and z-axes. Does it mean you also have a y-axis and therefore a three-dimensional space?
yes it is three dimensional, but i can figure out how to turn it on its side, so just ignore that and say its on the x and y axis. and yes, i know that there are many parabolas that go through that space. ok i will try to explain the best i can. lets say i need two parabolas that pass through lets say (0, 10) and (0,-10). i need the parabolas to both be the same shape, but on is upside down(negative) but it has to be in the "eye" shape (yes i will explain that too). so i would use the two parabolas y=.025x^2-2.5 and -.025x^2+2.5 (i got this by trial and error).the space between the two parabolas forms a kind of pointy oval(eye shape), go to this site and type in those two equations for a visual.
And what if the two points have different y-coordinates? For example, consider (-1, 0) and (2, 3). All parabolas passing through them have equations y(x) = ax² + (1 - a)x + (1 -2a) for different a. But they don't really give the "eye shape" (e.g., try a = 1 and a = -1).
I think you are saying that you have and for some numbers a and b (y= 0). They will intersect when . Obviously z= 0 satisfies that but is not the point we want. If z is not 0, we can divide both sides by to get and then . We can do essentially the same thing, focusing on x rather than z, to get . Set those equal to the x and z coordinates of the point you want as intersection and you have two equations to solve for a and b.