Skills:
Physically based modeling, Computer Graphics, User interface
Tools:
OpenGL, C++
What I learned:
∙ Programming Simulations
Physically based modeling, Computer Graphics, User interface
Tools:
OpenGL, C++
What I learned:
∙ Programming Simulations
Gained practical experience in using C++ to program and simulate physical systems.
∙ Numerical Integrators
Implemented four types of integrators and learned how different approaches affect the accuracy and stability of simulations.
∙ Physics Principles
Enhanced my understanding of ODEs, spring systems, and particle dynamics.
∙ Problem-Solving and Debugging
Overcame numerous debugging challenges, which improved my problem-solving skills and patience.
∙ Animation Simulation
Gained insight into creating animations based on physical laws, marking my first step into this domain.
Cloth Concept
Bend
Responsible for maintaining the overall shape and resisting bending.
Shear
Ensures diagonal connections for shear deformation control.
Stretch
Maintains distances between directly connected points to control stretching.
UI Control
Using IGMUI to set the parameters to control the integrator. Different integrator provide different integrate methods for simulation.
Additionally, it enables users to adjust the spring coefficient parameters and modify the speed of the balls.
A. Explicit Euler
Step 1 - Get the position, velocity and acceleration of the particles.
Step 2 - Follow the formula, Xn+1 = Xn + h * X’n ( h is delta time).
Step 3 - Update the position and velocity.
B. Implicit Euler
Step 1 - Get the position, velocity and acceleration of the particles after delta time by simulateOneStep function.
Step 2 - Follow the formula, Xn+1 = Xn + h * X’n+1 ( h is delta time).
Step 3 - Update the position and velocity.
C. Midpoint Euler
Step 1 - Calculate the initial position, velocity, and acceleration of the particles.
Step 2 - Use the initial values to calculate the midpoint velocity and acceleration
Step 3 - Compute the midpoint position using the midpoint velocity.
Step 4 - Update the particle's position and velocity using the midpoint position and velocity.
Step 5 - Update the system's particle data accordingly.
D. Rune Kutta Fourth
Step 1 - Compute the acceleration and velocity at the initial conditions, labeled as k1k_1k1.
Step 2 - Use k1k_1k1 to calculate the intermediate data at half the time step, h/2h/2h/2, labeled as k2k_2k2.
Step 3 - Use k2k_2k2 to compute another intermediate data point at h/2h/2h/2, labeled as k3k_3k3.
Step 4 - Use k3k_3k3 to calculate the data at the full time step, hhh, labeled as k4k_4k4.
Step 5 - Combine k1,k2,k3,k_1, k_2, k_3,k1,k2,k3, and k4k_4k4 using a weighted average to compute the final position and velocity.
Step 6 - Update the particle's position and velocity using the computed results.
Collision between cloth and spheres:
Step 1 - Get the position between two objects and the length of objects.
Step 2 - Detect whether the objects collide or not.
Step 3 - Calculate the normal vector of two objects through formula.
Step 4 - Use this collision formula to compute the acceleration.
Step 5 - Update the current acceleration and position.