Recent content by TaurusI76

  1. TaurusI76

    Accelerating car catches up with another (accelerating) car

    I have a follow up question to the above formulas: The formula does not work if both accelerations ##a_x## and ##a_1## are 0 (Scenario: car 1 is already at its max speed, and so is car 2. But due to a higher max speed car 2 will eventually catch up and will have to slow down). In this case...
  2. TaurusI76

    Accelerating car catches up with another (accelerating) car

    So, just to complete this: I've got ##g+h(t_1+t_2)+\frac{1}{2}it_1^2+\frac{1}{2}jt_2^2-a_1t_1t_2 = 0## where ##e=\frac{a_2-a_x}{a_x-a_1}## ##f=\frac{v_y-v_x}{a_x-a_1}## ##g=p_x-p_y-d## ##h=v_x-v_y## ##i=a_x-a_1## ##j=a_x-a_2## Given that ##t_1=e*t_2+f## by substituting this in the top...
  3. TaurusI76

    Accelerating car catches up with another (accelerating) car

    OK, so I've got ##t_1=et_2+f## and ##e=\frac{a_2-a_x}{a_x-a_1}## and ##f=\frac{v_y-v_x}{a_x-a_1}## Then, I've got ##P_x = P_y + d## which means that ##p_x + v_x (t_1+t_2) + \frac{1}{2} a_x (t_1+t_2)^2 = p_y + v_y (t_1+t_2) + \frac{1}{2} a_1 t_1^2 + a_1 t_1 t_2 + \frac{1}{2} a_2 t_2^2 + d## and...
  4. TaurusI76

    Accelerating car catches up with another (accelerating) car

    How did you get to that? What are e and f made up of? When I solve for ##t_1## I end up with ##t_1## = (-##a_x## ##t_2## + ##a_2## ##t_2## - ##v_x## + ##v_y##) / (##a_x## - ##a_1##)
  5. TaurusI76

    Accelerating car catches up with another (accelerating) car

    That gives me one hell of a long formula! Is that supposed to be that long? (Because the equation for ##t_c## = (...) already is a long equation that I have to substitute in a number of places) Also, I struggle to find a quadratic formula in the form of ax2 + bx + c = 0. ##t_d## is all over the...
  6. TaurusI76

    Accelerating car catches up with another (accelerating) car

    @mfb: you are right, the accelerations are known. And BTW, I think my initial question was a bit unclear. I should have asked not only if there is a solution, but what that solution is (because that's what was unclear to me as well). But the max speed is ok, that's a variable I already have in...
  7. TaurusI76

    Accelerating car catches up with another (accelerating) car

    How does tc fit into the final speed of car 2 function? I think that's the only part I don't get about your procedure. I got: vf = v21 + a21 * ta + a22 * td ... so what do I do with tc here?
  8. TaurusI76

    Accelerating car catches up with another (accelerating) car

    Yes, I eventually want to cover that with different driver profiles (the whole thing will be used in a video game). But since the accelerations are always defined (default would be equal acceleration and deceleration, 'eco-friendly' driver would be determined by how big the deceleration from...
  9. TaurusI76

    Accelerating car catches up with another (accelerating) car

    Thanks Andrew for clearing that up. I was suspecting that I had too little known values to solve it. However, in the simulation that I use this, I define the acceleration and deceleration rates. The cars have a max acceleration and deceleration and they use 'default' acceleration/deceleration...
  10. TaurusI76

    Accelerating car catches up with another (accelerating) car

    I still don't get how I can get rid of some of the unknowns. I updated the graph a little (for my better understanding) What I managed to caluclate so far is the time/distance where the green line crosses the red line. But that is not of a lot of use to me, because the deceleration would...
  11. TaurusI76

    Accelerating car catches up with another (accelerating) car

    I'm not sure if I can follow your line of thought. What would t1 and t2 stand for then? I suppose t1 is the time that car 2 accelerates and t2 the time it decelerates - correct? So what equations would I use to calculate them? If I use the same formula base as above (v * t + 0.5 * a * t2), how...
  12. TaurusI76

    Accelerating car catches up with another (accelerating) car

    Homework Statement I have the following situation: car 1 is distance di ahead of car 2. Car 1 has either a constant speed v1 or accelerates with a1 (I eventually want to cover both cases). Car 2 accelerates faster than car 1. Car 2 is eventually going to catch up with car 1. I want to calculate...
  13. TaurusI76

    Struggling with Calculus in Game Development - Seeking Advice!

    I'm a software engineer/game developer and I'm currently developing a game that requires me to do some calculations that are based on physics. I guess I was ok at maths/physics up to the 'precalculus' level, but started to struggle at the calculus level. That's why I need some help on some...
Back
Top