Algodoo is too much real

Forums for educators and researchers to discuss educational aspects of Algodoo.

Algodoo is too much real

Postby korry » Sat Dec 26, 2009 12:49 pm

Hi,
I have created some simulations in Phun/Algodoo for my e-learning website, but I encountered some problems. Biggest problem is in differences between teaching physics and real world.
Now I have worked on simulations of mechanical energy and there is one of that difference.
There is 2 springs with same parameters, if they fire away two same boxes, its must stop in same distance. It works, but if I decrease mass of one of boxes by 2, it may ride 2 times long distance. Try it, it doesn´t works.
Or another exam - there is 2 springs with same parameters and fire out 2 boxes with different masses. If they hits to another box, both should move box by same distance. It doesn´t happened.
I think, that problem is in time, which spring forced on box - heavier box is pressed for longer time (or on longer distance so it means that work is bigger - W=F.s, F is same and s is bigger).
I solved it by decreasing mass of box which is hitted by lighter box - I have attached zipped phunlet.
This is biggest problem for me and maybe for otehr teachers, we describe idealistics word, although we know, that real world is more complicated.
Is there any possibility to "switch" phun to "didactic" mode, or have anybody some ideas how to repair my animations?
Thanks for reply.
Korry
Attachments
kineticka.zip
(12.23 KiB) Downloaded 405 times
korry
 
Posts: 21
Joined: Thu Nov 26, 2009 7:25 pm
Location: Czech republic

Re: Algodoo is too much real

Postby KarateBrot » Sat Dec 26, 2009 1:13 pm

Algodoo simulated it correct. Your scene includes friction. Did you take it into account while calculating?
Image
User avatar
KarateBrot
 
Posts: 825
Joined: Mon Aug 31, 2009 7:32 pm
Location: Germany

Re: Algodoo is too much real

Postby korry » Sat Dec 26, 2009 3:18 pm

But friction is same for both boxes, it isn´t the problem. Friction stops boxes, it is necessary in this scene.
korry
 
Posts: 21
Joined: Thu Nov 26, 2009 7:25 pm
Location: Czech republic

Re: Algodoo is too much real

Postby KarateBrot » Sat Dec 26, 2009 6:06 pm

I don't see any problem. If I understood everything for the second example it's no surprise that the two boxes which get hit don't move the same distance.

The two springs have got the same condotions and when they expand they push the two boxes m1 and m2 with the same force the same distance. So the kinetic energy the two boxes get is the same:

E1 = E2
1/2 * m1 * v1² = 1/2 * m2 * v2²

The second box m2 has got a mass of k*m1.

m2 = k*m1

1/2 * m1 * v1² = 1/2 * k * m1 * v2²
v1² = k * v2²
v1 = √k * v2

Now we calculate the impulse of the two boxes.

p1 = m1 * v1
p2 = m2 * v2

We know: m2 = k*m1 and v2 = v1/√k

p2 = k*m1 * v1/√k
p2 = √k * m1 * v1
- - - - - - - -
p2 = √k * p1
- - - - - - - -

The impulse of m2 is √k times bigger than the impulse of m1. So it's no surprise if they collide with a box with the same conditions, m2 carries over another impulse which results in a different distance (k=1 is excluded) the boxes are pushed to.

Edit:
Whoops, I didn't end the calculation.

Edit2:
Alright, another try:
I want to calculate the mass of the boxes you need so that they stop at the same distance after the collision. If they travel the same distance the two boxes with the same conditions must have the same velocities after the collision.

vBox1 = vBox2

vBox1 = 2 * m1 * v1 / (m1 + mBox)
vBox2 = 2 * m2 * v2 / (m2 + mBox)

2 * m1 * v1 / (m1 + mBox) = 2 * m2 * v2 / (m2 + mBox)
2 * m2 / k * √k * v2 / (m2 / k + mBox) = 2 * m2 * v2 / (m2 + mBox)
1 / (√k * (m2 / k + mBox)) = 1 / (m2 + mBox)
1 / (m2 / √k + √k * mBox) = 1 / (m2 + mBox)
m2 / √k + √k * mBox = m2 + mBox
m2 / √k - m2 = mBox - √k * mBox
m2 * (1 / √k - 1) = mBox(1 - √k)
m2 * (1 - √k) / √k = mBox(1 - √k)
m2 / √k = mBox


We know: k = m2 / m1

m2 / √(m2 / m1) = mBox
m2² / (m2 / m1) = mBox²
m2² * m1 / m2 = mBox²
m2 * m1 = mBox²
- - - - - - - - - - - -
mBox = √(m1 * m2)
- - - - - - - - - - - -


Now we know: The boxes must have a specific mass so that they stop at the same distance. Otherwise they travel a different distance. So only your assumption was wrong. Algodoo calculated it correct.
Try it with this mass. It works.
Image
User avatar
KarateBrot
 
Posts: 825
Joined: Mon Aug 31, 2009 7:32 pm
Location: Germany

Re: Algodoo is too much real

Postby korry » Sat Dec 26, 2009 7:54 pm

Thanks for your reply.
You looking to the problem from law of impulse conservation.
I want to show law of energy conservation.
Springs makes work W, this work is used to move small boxes.Theoretically: whole work W is used to kinetic energy Ek (1/2.m.v^2). So both boxes might have some Ek. Small boxes hits to big boxes and stops. All their energy might be used to work to move big boxes. They has same mass, so for move them is necasary same force. W=F.s - same W, same F, there might be same s, but isn´t.
It is easy thing to show, but as I wrote in idealistic world.
I must have a look to your equations, one of us isn´t right, conservation of impulse or energy must be true both. (I hope, that I´m right ;) )
Or may be some of my assumption isn´t right - eg. totally energy transport from small boxes to bigger ones.
korry
 
Posts: 21
Joined: Thu Nov 26, 2009 7:25 pm
Location: Czech republic

Re: Algodoo is too much real

Postby KarateBrot » Sat Dec 26, 2009 8:13 pm

Ok, I see... I think I didn't understand you first. Both of us are right but I didn't solve your problem. I made an assumption that s is the same for both but now I got it. THAT'S your problem.
Yeah that's a problem but maybe you can solve it if you make an obstacle for both "pushers" so that they only push the two boxes the same distance and then they get stopped by it. The two boxes can pass the obstacle if they have got another collision group. So select collision group A and B for the "pushers", only A for the two boxes and only B for the obstacles. Maybe it's better.

And my calculations are right but only if the boxes only collide ONCE but I think you wanted to know something different because if they collide as much as possible they also get pushed the same distance even if the mass is different from my equation. => Forget my calculations. They deal with something different.
Image
User avatar
KarateBrot
 
Posts: 825
Joined: Mon Aug 31, 2009 7:32 pm
Location: Germany

Re: Algodoo is too much real

Postby korry » Sat Dec 26, 2009 9:12 pm

I made this, but it is "swindle" - the bigger boxes hasn´t same mass. In theory it may works.
Your equations are right, but for "inflexible(?)" crash - after crash will be small and big box connected a will move together.
Thanks so much for your work.
Problem isn´t still solved - I will be happy if will be possible turn Algodoo/Phun to idealistic/real world.
I have another suggestions which is good for teachers, but not consistent with real world.
Like things with zero mass (eg. for levers or ropes)
korry
 
Posts: 21
Joined: Thu Nov 26, 2009 7:25 pm
Location: Czech republic

Re: Algodoo is too much real

Postby KarateBrot » Sat Dec 26, 2009 9:57 pm

My equation is for fully elastic collisions but it doesn't solve your problem, I know.
But when I tried to rebuild your problem they traveled nearly the same distance. There's a little difference but you can see that it should be the same distance. I know what you want to say in this topic. You can set everything so that it's nearly idealistic but not completely idealistic.

Btw. I made a setup that may be interesting for you because it deletes the springs after a specific distance so they really push the blocks only as far as you want. (along the way: it the example of my second equation but look at the springs. That's maybe the most idealistic one I could make)
Attachments
Spring Example.rar
(4.42 KiB) Downloaded 408 times
Image
User avatar
KarateBrot
 
Posts: 825
Joined: Mon Aug 31, 2009 7:32 pm
Location: Germany

Re: Algodoo is too much real

Postby korry » Sat Dec 26, 2009 11:43 pm

Your spring looks great, how can I do this? I like your meter too - I try made some similar, but it doesn´t looks like yours.
Thanks for your interest to my problem. Hi. Korry
korry
 
Posts: 21
Joined: Thu Nov 26, 2009 7:25 pm
Location: Czech republic

Re: Algodoo is too much real

Postby KarateBrot » Sun Dec 27, 2009 8:47 am

No problem.
First you should turn on "advanced mode" in the options to have full access to all settings.
I attached a little bar to the box and then I connected the springs to the bar. Somewhere in front of the bar I made a second bar and made it a "killer" in the material menu. now everything that collides with it will get deleted. In the collision menu I set the group to only B. the same needs to be set for the bar that's attached to the box. now only the two bars can collide and nothing else will be deleted. Then I extended the spings length.
That's it. now after your spring traveled all along the way to the killer bar, the bar that's attached to the box will get deleted and because the spring is attached to the bar it will get deleted, too.

And for the ruler: just make a box, in the collision menu uncheck all gropus so it's not colliding with anything. in the appearance menu select "ruler". now you could also move the ruler to the background in the "selection..." menu so it's not in front of the moving boxes. or just press SHIFT + mousewheel up
Image
User avatar
KarateBrot
 
Posts: 825
Joined: Mon Aug 31, 2009 7:32 pm
Location: Germany

Re: Algodoo is too much real

Postby korry » Sun Dec 27, 2009 8:51 pm

Thanks, it looks easy, I will try it.
korry
 
Posts: 21
Joined: Thu Nov 26, 2009 7:25 pm
Location: Czech republic

Re: Algodoo is too much real

Postby Frank » Wed Feb 03, 2010 10:34 pm

Part of it is the damping of your springs. The faster a spring is stretching, the stronger the damping forces.

Edit: Also, a bit of the work done by the springs stays in the little green blocks they're attached to.

Edit 2: If you set all the boxes to the same size and only change their density, that makes it a little more predictable.
And if you set the restitution on the boxes to 1, then the target boxes get moved about the same amount.
Made some cool stuff a long time ago
User avatar
Frank
[Best Tutorial Maker 2010]
 
Posts: 193
Joined: Mon Aug 31, 2009 6:37 pm
Location: the dark side of the moon


Return to Algodoo for educators

Who is online

Users browsing this forum: No registered users and 5 guests

cron