I want to solve the following problem using Matlab:(adsbygoogle = window.adsbygoogle || []).push({});

Here's the question regarding an object thrown in the air:

http://img197.imageshack.us/img197/7797/97452743.gif [Broken]

My code:

It doesn't produce a proper plot, all I can see is a dot. What is the problem with my code?Code (Text):theta=pi/4; v=10; g=9.81; a=0.1;

nfinal=50000;

for t=1:nfinal

x=((1-exp(-a*t))/a)*v*cos(theta);

y=((1-exp(-a*t))/a)*((g/a)+v*sin(theta))-((g*t)/a);

end

plot(t,y,'+')

**Physics Forums | Science Articles, Homework Help, Discussion**

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Help with Matlab

**Physics Forums | Science Articles, Homework Help, Discussion**