Jim's
Tutorials

Spring 2019
course
site

Jack - Feb 19

Good news: My independent (physics exams) is 1/3 done! Bad news: it took me the from Friday to 3:30am Monday to complete it. I didn't anticipate it taking so long or exhausting me so thoroughly afterwards, so I don't have nearly as much done for the tutorial as I'd like.

I started trying to plan my code for the simple Brownian motion simulation we talked about. It is fairly obvious that I need a particle class with properties mass, velocity, position, and some sort of dimension (I'm thinking radius would work well). When thinking through the physics of how the collisions would work I was surprised that I got stumped. I know for elastic collisions both momentum and kinetic energy are conserved, but I couldn't quite figure out how I would calculate the result of a collision. I tried looking for simulations of ideal gas, and even just simple collisions (the latter proved more useful), but I realized my problem was with the physics, not the programming so I turned to my physics books.

I reread the section on elastic collisions in my classical mechanics book and it was not much help. I found a chapter on collision theory (which was not covered in class) in my book, which appears to be almost exactly what I need. I'm worried about determining the scattering parameter with multiple particles moving in different directions, but I haven't finished reading the chapter, so it may not be much of a problem.

I also did some more reading of the paper to understand the analysis better, but I don't really have much. I know that the point of the auto-correlation and power spectrum functions are to determine these quantities Alpha Beta and Gamma, with Gamma being the most important number. Gamma is the decay rate, I don't really know what the other numbers are/ And from that we can determine diameter of the spheres (diameter was one of the constants in distribution). I still don't really grasp the details of all this yet.

Jim says

Since the Brownian motion collision thing is going to be a "visualization" thing without the real physics in it, don't try to be too realistic about the collision. Since these are atoms, it should be pretty elastic I would think. So the simplest thing would be to just reverse the velocity, with the tiny particle going from (+m v) to (-m v) and transferring moment (2 m v) to the big one.

I have no idea what Alpha Beta Gamma.

I mentioned "numpy" - numerical python library - and showed a simple example of doing array math with it. You also may want to google things like "numpy collision" to see how others have used numpy to speed up code for collision detection.

https://cs.marlboro.college /cours /spring2019 /jims_tutorials /jtuttle /feb19
last modified Fri May 3 2024 4:10 pm