Many physical processes can be simulated using computers. In fact, physics simulations are widely used in a variety of industries: computer games, education, scientific research, engineering and many more. Even the flow of water can look very realistic on a computer screen. And considering the growing popularity of mobile devices today, it’s not surprising that we see increasing demand for hydrodynamics simulations on mobile devices. Here, I will discuss imitation of paint dispersed on the surface of water – on an iPad.
To make such app look realistic, it is crucial to imitate real physics and what actually happens to the paint as it touches water. In order to do this, we decided to explore some basic hydrodynamics and then simulate them on an iPad. We are going to use real world formulas that describe water behavior. This process requires large volumes of calculations to be done very quickly. Initially, we tried these calculations on a CPU, but could only produce 5 to 7 frames per second. As we know, in order for eyes to see continuous movement, we need at least 24 frames per second. Clearly, we needed a way to process the data faster. That’s how we decided to utilize a GPU in order to try and generate more images per second.

.jpg)
