Author Topic: Rewriting formula's  (Read 2494 times)

0 Members and 1 Guest are viewing this topic.

Offline sjasogun1

  • LV3 Member (Next: 100)
  • ***
  • Posts: 88
  • Rating: +8/-1
    • View Profile
Rewriting formula's
« on: December 20, 2011, 07:27:41 am »
I’m trying to create a program that is able to solve certain physics problems (right now they’re all related to circular motion) for school. The problem is that the program doesn’t cover everything. I have rewritten all of the formula’s by hand and put them in the program’s code to let it process the data.

My problem is that it is unable to combine two formula’s in a way some variables get cancelled out.

For example, take a rollercoaster in a theme park. The track of the rollercoaster contains a looping with a radius of 2,0 metres (r=2,0). We assume that the gravitational accelleration is 9,81 m/s^2. How fast does it have to go at the top of the looping to prevent the carts from falling out? (we ignore the weight-shift of the cart train as it moves a along the track, as well as the friction)

We can solve this by equaling two formula’s: the one for the centrifugal force and the one for the gravitational force. F(centrifugal)=F(gravitational) Because the centrifugal force points directly from the center of the circle to the cart which is straight up when it is at the top, the opposite of the gravitational force’s direction.

We get (m*v^2)/r = m*g
Multiply with r
m*v^2 = m*g*r
divide by m
v^2 = g*r
v = sqrt(g*r)
filling that in gives
v = sqrt(9,81*2,0) = 4,3 m/s

This equation crosses the m out of the equation, something my program isn’t able to do. I can’t figure out how to make it do that. Does anybody know an algorithm for crossing out variables like this?
Veni, vidi, cecidi
(I came, I saw, I fell down dead)
MSPAFORUMS: http://www.mspaforums.com/
HOMESTUCK: http://www.mspaintadventures.com/?s=6&p=001901

Offline aeTIos

  • Nonbinary computing specialist
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3915
  • Rating: +184/-32
    • View Profile
    • wank.party
Re: Rewriting formula's
« Reply #1 on: December 20, 2011, 09:59:33 am »
Maybe ask this in the math section.
I'm not a nerd but I pretend: