elastic collisions sierpinski carpet anakaren santana
DESCRIPTION
Method 1.Set up initial conditions (make sure both masses will actually collide). 2.For loop changes positions of the masses according to their respective velocities. 3.An if statement checks if the masses collide. When they collide the new velocities are calculated and initial positions reset. 4.A second for loop changes the positions of the masses according to these new velocities and initial coordinates.TRANSCRIPT
![Page 1: Elastic Collisions Sierpinski Carpet Anakaren Santana](https://reader038.vdocuments.us/reader038/viewer/2022100505/5a4d1b717f8b9ab0599b53fa/html5/thumbnails/1.jpg)
Elastic Collisions &Sierpinski Carpet
Anakaren Santana
![Page 2: Elastic Collisions Sierpinski Carpet Anakaren Santana](https://reader038.vdocuments.us/reader038/viewer/2022100505/5a4d1b717f8b9ab0599b53fa/html5/thumbnails/2.jpg)
Elastic Collisions
• Momentum is Conserved:–
• Kinetic Energy is Conserved:–
• Where U’s are velocities before the collision and V’s are velocities after the collision.
• Using these equations you can solve for and calculate the position of each mass at a given time ( x = V*t)
![Page 3: Elastic Collisions Sierpinski Carpet Anakaren Santana](https://reader038.vdocuments.us/reader038/viewer/2022100505/5a4d1b717f8b9ab0599b53fa/html5/thumbnails/3.jpg)
Method
1. Set up initial conditions (make sure both masses will actually collide).
2. For loop changes positions of the masses according to their respective velocities.
3. An if statement checks if the masses collide. When they collide the new velocities are calculated and initial positions reset.
4. A second for loop changes the positions of the masses according to these new velocities and initial coordinates.
![Page 4: Elastic Collisions Sierpinski Carpet Anakaren Santana](https://reader038.vdocuments.us/reader038/viewer/2022100505/5a4d1b717f8b9ab0599b53fa/html5/thumbnails/4.jpg)
1D: m1=2 m2=2, U1=2 U2=0, x01=0 x02=20Run Code With: elasticCollision.m
![Page 5: Elastic Collisions Sierpinski Carpet Anakaren Santana](https://reader038.vdocuments.us/reader038/viewer/2022100505/5a4d1b717f8b9ab0599b53fa/html5/thumbnails/5.jpg)
2D: m1=2 m2=4, Ux1=4 Uy2=4, Ux2=-1 Uy2=-1, x01=-90 y01=-90, x02=90 y02=90
Run Code With: elasticCollision2D.m
![Page 6: Elastic Collisions Sierpinski Carpet Anakaren Santana](https://reader038.vdocuments.us/reader038/viewer/2022100505/5a4d1b717f8b9ab0599b53fa/html5/thumbnails/6.jpg)
• The Sierpinski Carpet is a fractal of fractal dimension 1.8929.
• It begins with a square that you divide into 9 sub-squares and remove the center square. Repeat the process with each subsquare.
• Method:– Nested for loops within a while loop.– The while loop ensures that we can keep dividing
by 3.– The nested for loops “remove” the appropriate
squares in each iteration.
![Page 7: Elastic Collisions Sierpinski Carpet Anakaren Santana](https://reader038.vdocuments.us/reader038/viewer/2022100505/5a4d1b717f8b9ab0599b53fa/html5/thumbnails/7.jpg)