This post is about my recent work. A swelling process simulator (german: Quellprozess) with glass fibers. The project is running at the IKGB Department of the University of Freiberg (East Germany).
I have been working mostly on my own, doing this besides of my master study for one year and it makes a lot of fun. The simulator is open source, licensed under GPL v3, so you can grab the source from git (qptool).
At the moment third party libraries are not provided, but they can be obtained from the web.
I will post a running application here, when v1.0.0 is released.
The swelling process is driven by 'expanding' hydrogen gas bubbles within the fluid concrete. It is a part of the production process of the AAC, a really versatile, lightweight, cheap precast building material.
That hydrogen gas is triggered by a really small amount of aluminium powder in the raw mix.
The gas can escape later and in the end the pores contains just air.
To improve the properties of the AAC, (alkali-resistant) glass fibers will be added to the raw mix.
The swelling process will distribute the fibers.
The simulation helps to understand the movements and directions of the fibers from beginning to the end of the whole swelling process.
QPTool is written in C++, Qt 4.7.4, CUDA 5.0, OpenGL 3. The simulation and visualization is completely done on the (Nvidia) GPU. This gives a good framerate even for medium sized simulations (131k Spheres, 8k Fibers at ~16 FPS). The pores are just expanding spheres, following the Cherrypit Model. The fibers are just lines in the simulation colliding only with spheres (no fiber-fiber interaction), since the glass fibers are very thin.
QPTool is written in C++, Qt 4.7.4, CUDA 5.0, OpenGL 3. The simulation and visualization is completely done on the (Nvidia) GPU. This gives a good framerate even for medium sized simulations (131k Spheres, 8k Fibers at ~16 FPS). The pores are just expanding spheres, following the Cherrypit Model. The fibers are just lines in the simulation colliding only with spheres (no fiber-fiber interaction), since the glass fibers are very thin.
Renderer:
- Simple Raycast-Shader (e.g. Spheres are computed in Shader)
- Multipass Raycast-Shader with Shadows and Edge Filter
- Geometry Renderer (using instancing technique, but it is slower and uglier than simple raycast-shader)
- CUDA driven physics engine
- Using uniform space subdivision (based on SDK example 'particles' from Nvidia)
- Slice-cutting computation (simulates cutting of the concrete block)
- User can create fiber clusters with preferred directions
- Real-data based and generic distribution of end radii of pores
- Distribution of pores and fibers
- Radii of pores
- Fiber directions (phi/theta diagram)
- ...
- Recording long-term simulations into video alongside with statistics
- Benchmark tool to compare algorithms
- Export simulation data to csv for further processing
- Import simulation data
- Session and simulation setting management
- ...
Just some pictures:
Credits:
- S. Matthes: My boss :) He does the higher mathematics and experimental investigations for this simulation. Thanks for all the great discussions and for giving me this opportunity.
- Prof. B. Steinbach, allowing me to use an office room for free (including Desktop PC with Nvidia GPU of course :) )
- Nvidia, CUDA, Simon Green, SDK Demo 'particles'.
- Qt (used Qt 4.7.4), Qwt, Qxt / libqxt
- CAviFile Class, Xvid Encoder used for recording tool (video rendering)
- ...
Further sources which I used or adapted or helped me to understand the things better
- FastDelegate
- PixelBufferObjects Class
- Camera Control Class
- several tutorials over the web about OpenGL buffer objects, renderbuffer, framebuffer, shader instancing, shadows shader, ... (take the appropriate buzzword and google it)
- Christian Sigg (GPU-Based Ray-Casting of Quadratic Surfaces)
- Article on Molecules: Enhancing Molecules using OpenGL ES 2.0
- ... and many more ... :)
v0.9.7 still has some bugs and cylinder impostor shader is not finished yet.