#Simple physics task
249 messages · Page 1 of 1 (latest)
i got 22.5 degrees but its surely wrong since i didnt take into account the horizontal speed component and only used 2as = v^2-v_o^2 for horizontal
wait
ok
yes
now eq 1->>>>
- y = v sin α (T) - 1/2 g(T^2)
ok continue
and when the object will hit the target it will be Y m down in negative y axis
ya
u shuld get it ig
i tried solving the simultaneous equation but it has no solution in wolfram
yea
we were supposed to use python to solve this
fsolve or something, i tried by hand
but the equation is unsolvable
cos(x)5.3t-2.1 = 0 and -1/29.81t^2 + sin(x)5.3t+2.1 = 0
there is * lost in between the numbers
idk what can i do?
cos(x)*5.3*t-2.1 = 0 and -1/2*9.81*t^2 + sin(x)*5.3*t+2.1 = 0
i think im screwed
i could have sworn i have done so many of these and none of them were this difficult. isnt this a simple problem? can i even verify if 22.5 is correct? i tried putting that angle in and it seems to be wrong if my verification method is right
Let the initial height be h and the needed distance be l. Then the equations of motion are:
x(t) = v0 cos(α)t
y(t) = h + v0 sin(α)t - (1/2)gt^2
First, let's find the time of flight T.
We know that at the end x(T) = l. So:
x(T) = v0 cos(α)T = l
T = l/(v0 cos(α))
Now, let's substitute that into y(t).
y(T) = h + v0 sin(α)l/(v0 cos(α)) - (1/2)gl^2/(v0 cos(α))^2 = h + tan(α)l - (1/2)gl^2/(v0 cos(α))^2
As this is the landing point, we must have y(T) = 0. So:
h + tan(α)l - (1/2)gl^2/(v0 cos(α))^2 = 0
Let k = tan(α), then 1/cos(α)^2 = 1 + k^2. So:
h + lk - (1/2)(gl^2/v0^2)(1 + k^2) = 0
k^2 - 2(v0^2/(gl))k + 1 - 2hv0^2/(gl^2) = 0
Let's find the discriminant first.
D = 4v0^4/(gl)^2 - 4 + 8h^2v0^4/(gl^2)^2 = 4(v0^4/(gl)^2)(1 + 8h^2/l^2) - 4
So:
k = v0^2/(gl) ± √((v0^2/(gl))^2 (1 + 8(h/l)^2) - 1)
That is the tangent of the angle. So:
α = arctan(v0^2/(gl) ± √((v0^2/(gl))^2 (1 + 8(h/l)^2) - 1))
In our case we have v0 = 5.3 m/s, h = 0.21 m, l = 2.1 m. So, we get the values:
α = arctan(v0^2/(gl) + √((v0^4/(gl)^2)(1 + 8(h/l)^2) - 1)) = arctan((5.3 m/s)^2/(9.81 m/s^2*2.1 m) + √(((5.3 m/s)^2/(9.81 m/s^2*2.1 m))^2 (1 + 8(0.21 m/(2.1 m))^2) - 1)) ≈ 67.1°
α = arctan(v0^2/(gl) - √((v0^4/(gl)^2)(1 + 8(h/l)^2) - 1)) = arctan((5.3 m/s)^2/(9.81 m/s^2*2.1 m) - √(((5.3 m/s)^2/(9.81 m/s^2*2.1 m))^2 (1 + 8(0.21 m/(2.1 m))^2) - 1)) ≈ 19.8°
So, the available angles are 67.1° and 19.8°, if I didn't mess up.
im checking your steps rn
you did exactly what i did
but i got stuck here, since i couldnt simplify it further
Let k = tan(α), then 1/cos(α)^2 = 1 + k^2. So:
that is a hard substitution trick, well done
ill keep checking further
but it still seems impossible to find an answer
after we switch from tan to k this is what we get
-21.63k^2 + k*l + 2.1-21.63
which according to the discriminant would cause a negative under the square root
@glossy radish any thoughts?
Well, if you want to substitute the numbers at that point, then also substitute l.
i did
its impossible to solve it
l is also positive
Which form did you take to substitute into to get this?
I think you forgot to multiply something by 2.
See, that's why I don't like to substitute constants before the very end.
Well, I got a solution and checked it, seems to be fine. So, you are substituting something wrong.
hmmm
now that i think about it i dont think i should multiply by 2
Well, again, I'm not entirely sure what you're doing exactly.
h + tan(α)l - (1/2)gl^2/(v0 cos(α))^2 = 0
Yeah, that's good. That leads to h + lk - (1/2)(gl^2/v0^2)(1 + k^2) = 0, which then leads to:
k^2 - 2(v0^2/(gl))k + 1 - 2hv0^2/(gl^2) = 0
where can i see the solution on wolfram? to make sure there arent any hand written errors
i assume this is radians
Well, yeah.
Also, easier to solve it in terms of k, then just take the arctangent of it.
why isnt wolfram doing that and getting your answers?
It is, though.
Though, actually...
Let me check.
Oh, no, it does.
For n = 1.
The first value is πn - 5.10316, the second is πn - 5.99208. Both make sense in our problem for n = 2. So, we get the values:
α = 2π - 5.10316 = (2 - 5.10316/π)*180° ≈ 67.6°
α = 2π - 5.99208 = (2 - 5.99208/π)*180° ≈ 16.7°
There seems to be some discrepancy with my answers. Maybe due to error? Who knows. Maybe I just messed up a bit.
Because -π/2 < α < π/2.
No. The equation tan(x) = a has solutions x = arctan(a) + πn, because tan(x) is π-periodic.
i know that
i forgot this was the case
Ah, ok.
lets see if i can solve it using fsolve
fsolve? What is that?
method for solving math equations in python
ye i guess, just making sure wolfram is not misinterpreting my intentions which it has many times before
it almost always assumes something even though i type in something that makes little to no mathematical sense, and provides an answer
Projectile motion at its finest
Well, as I said, better to solve in variable form 😁
fsolve is not taking into account the trigonometric symmetry here
completely forgetting that there are two answers for each rotation
Well, to be fair, there are infinitely many solutions.
It just picked a point and found one closest to it.
in one rotation
Well, then you need another initial guess.
there are infinite solutions if you talk about multiple of the same rotations
oh
lemme try that
i dont even know why fsolve needs initial guess
Exactly for the reason that trigonometric equations usually have infinitely many solutions.
A computer can't list infinitely many items.
i tried having an initial guess of 16.7 so that the next solution is closer to it, but i get something much bigger
You need to guess in radians, not degrees.
oh yea
sorry for that
my bad
No problem! Take your time, I'm also interested if it will work.
Great!
its funny how it refused to work for 50 but worked for 60
Refused how?
its weird sometimes
here it wants to say 376
for 60 it wants to say 67.1
i dont see the pattern
Hm. Perhaps some numerical stuff going wrong? Or maybe the method that it uses is ill-posed for functions with a lot of discontinuities.
If it uses Newton's method, then don't look for a pattern. The dependence of the root you get on the initial condition is chaotic.
it might be newtons method, since we had it covered a year ago
So, the pattern exists, but it may be infinitely complex in some regions.
Look up Newton's basins for more info on that.
fascinating
I recommend 3Blue1Brown's video on it.
Who knew root-finding could be so complicated?
Next part: https://youtu.be/LqbZpur38nw
Special thanks to the following supporters: https://3b1b.co/lessons/newtons-fractal#thanks
An equally valuable form of support is to simply share the videos.
Interactive for this video:
https://www.3blue1brown.com/lessons/newtons-fractal
...
i think i have seen that at one point, time to watch it agian
i went on a spiritual journey with that video 😅, i remember a lot now
Cool!
this is the definition of unstable
earlier it said 67.1 for 60
now it says 955.63 for 60
Hm. I think it's better to switch from Newton-Rhaphson to somthing simpler, like dichotomy.
That shouldn't fail.
alright
And, as I said, it's probably better to solve the algebraic equation in k first.
Polynomial, even.
Polynomials don't have discontinuities.
Well, solve for k, then it's easy to solve tan(α) = k.
^^
If you're worried about the precision, find k to 5-6 decimal places.
That is way more than enough.
alright ill just switch to k
Oh, well, alright...
Then, maybe there's a way to constrict the region in which it looks for solutions?
ill try -90 to 90
Our region is (-π/2, π/2), so take the values to be, say, -π/2 + 0.0001 and π/2 - 0.0001.
i was just testing if it would spit random nonsense
Again, remember: you need radians.
yup 🙂
Don't take the exact angles. tan(x) is undefined, it will cause problems.
Again, try -1.57 and 1.57.
oh
smart
Let me try, too.
Oh, alright. That's good.
now if i restrict it from 60 to 89 degrees
Now, try 0.3 and 1.57.
i see you chose .3 because of 17 degrees
smart
and 1.57 so that its not exactly 90
so many small details to remember
its been a while since i studied trig
Yeah, I just converted the first angle to radians and rounded the first decimal up.
Actually, you know what?
I shouldn't be lazy.
Give me 10-15 minutes, I'll cook it up in Scilab.
At least so I don't get too rusty.
proud
must practice once in a while
are you a math major?
No, chemistry.
cool
First root:
b=1.57;
D=0.00001;
d=b-a;
while d > D do
c=(a+b)/2;
fa=0.21+tan(a)*2.1-(1/2)*9.81*2.1^2/(5.3*cos(a))^2;
fb=0.21+tan(b)*2.1-(1/2)*9.81*2.1^2/(5.3*cos(b))^2;
fc=0.21+tan(c)*2.1-(1/2)*9.81*2.1^2/(5.3*cos(c))^2;
if sign(fa*fc) < 0 then
b=c;
else a=c;
end;
d=b-a;
end;
c=c*180/%pi;
disp(c)
Second:
b=1.57;
D=0.00001;
d=b-a;
while d > D do
c=(a+b)/2;
fa=0.21+tan(a)*2.1-(1/2)*9.81*2.1^2/(5.3*cos(a))^2;
fb=0.21+tan(b)*2.1-(1/2)*9.81*2.1^2/(5.3*cos(b))^2;
fc=0.21+tan(c)*2.1-(1/2)*9.81*2.1^2/(5.3*cos(c))^2;
if sign(fa*fc) < 0 then
b=c;
else a=c;
end;
d=b-a;
end;
c=c*180/%pi;
disp(c)
Nice
its easy to forget unless you warm up once in a while
it feels like that when i comeback from a break each semester
but once you type the first few words onto your computer it then doesnt feel as heavy as it did a second ago
same thing with math problems tbh
Well, thankfully, I also used Scilab for my report for the student conference in May of 2022. And several times after that (including, I believe, a week ago).
Well, our IT lessons weren't very informative. Just for the sake of them being there, I guess.
We mostly just worked in Excel or Scilab, as well as some stuff in draw io (which, surprisingly, turned out to be useful to make some pictures for chemistry labs, for example), as well as some other graphic stuff which I can't care to remember.
What kinda saddened me is that the programs for some other students had labs on equation mode in MS Word, which I think would be 9000% more useful than most of the stuff we did.
But we didn't have it...
I mean, I don't need it, I can use it. But almost noone else can.
So, the only way they can nicely write formulas is by hand.
I mean, I don't expect LaTeX courses, but at least this would be good...
thats so sad, i write formulas the way i write them on discord haha
or i use latex if im in dire need to make it look good
I really recommend looking into MS Word's equation editor. Of course, that's no professional LaTeX editor, but still suitable for simple things.
I've made a ton of tables using that, as well as some homeworks.
I can show an example - a physical chemistry HW.
maybe its already provided with my education pack
would love that
I'll DM you.
thank you @glossy radish
@frosty nest has given 1 rep to @glossy radish
You're welcome!