Solving Initial Value Problems in polar coordinates

Hi there. So I'm trying to solve a differential equation, but I just don't know where to start. I have a problem where a block is connected to a spring, and that spring is a swinging pendulum (think a normal pendulum but instead of a string, a spring is used).
I have the following differential equations:
-in the r direction: d2rdt2 = -(k*r)/m + g*cos(theta)
-in the theta direction: d2thetadt2 = -g*sin(theta)
I want to use something along the lines of 'ode45' to solve these, I'm just not sure how to do this. Eventually, I want to get to the total displacement of the swinging/bouncing block over a set period of time.
If anybody could help in anyway, or just get me started in the right direction, that would be greatly appreciated!
Thank You, Brayden

댓글 수: 1

Mohammad Abouali
Mohammad Abouali 2014년 10월 16일
편집: Mohammad Abouali 2014년 10월 16일
My question is regarding your equations. How did you got these equations? Theta seems to be completely independent of r. So in a way you do not have a coupled equation.
If your equations are correct, you should be first solving Theta completely independently and then solve r by plugin in the value of Theta back into r equation.
However, I think something is missing in your equations. The period of movement is related to the length of the rope (or spring here). and that period is related to changes in time of theta. So, somehow I do think that the equation for theta should have some sort of r in it.

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

도움말 센터File Exchange에서 Programming에 대해 자세히 알아보기

질문:

2014년 10월 16일

편집:

2014년 10월 16일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by