Meshing with OpenFOAM

Before running any CFD simulations we need to generate a mesh around our geometry to perform calculations on. This page is meant to document the standard process we use to generate this mesh for ARIS rockets. Inputs: Geometry exported from some CAD software in named STL format. The sample OpenFOAM case folder (ofcase_heidi_fullbody_meshing) Outputs: 3D

Automatic plotting with Python

Below is a sample Pyhton script to automatically plot a generic data file using matplotlib. It will automatically read an arbitrary number of datasets from a file and plot each as a separate line in a matplotlib plot. Usage python3 plot.py input_data_filename output_filename [plot_title [y_axis_label]] The first argument is the name of the file containing

Producer-consumer scheme with MPI

Below is a simple implementation of the producer-consumer parallel strategy with MPI. It’s just a dummy example, and could probably be improved greatly, but it is a nice illustration of the producer-consumer model, as well as uses for MPI_ANY_SOURCE, MPI_ANY_TAG, and MPI_Status. #include <stdio.h> #include <mpi.h> #include <time.h> #include <stdlib.h> #include <math.h> // Producer-consumer scheme

CUDA: efficient parallel reduction

CUDA is a very powerful API which allows us to run highly parallel software on Nvidia GPUs. It is typically used to accelerate specific operations, called kernels, such as matrix multiplication, matrix decomposition, training neural networks et cetera. One such common operation is a reduction: adding up a long array of numbers. One simple implementation

FLIP fluids simulation

In autumn 2018, I teamed up with classmates Silvia Nauer and Mikael Stellio for a project in the ETHZ course Physically-Based Simulation for Computer Graphics. The objective of our project was to create a video of a meteorite crashing into the sea, by implementing our own FLIP fluids solver and rendering the video with Blender.

IACV lecture 1: light, lenses and cameras

This is a summary of the introductory lecture to the coure Image Analysis and Computer Vision which I took at ETH in the autumn semester 2018. Interaction of light and matter Interactions of light and matter be divided into three main types (plus diffraction). Phenomenon Example Absorption Blue water Scattering Blue sky, red sunset Reflection