A modular GUI for streamlined CFD workflows across all OpenFOAM versions.
SplashFOAM is a modular GUI for the Computational Fluid Dynamics (CFD) code OpenFOAM. The main impetus behind building SplashFOAM has been to increase the efficiency of CFD production, remove unnecessary friction, and allow engineers to focus on the physics of the problem rather than coding syntax.
Unlike other tools, SplashFOAM is not confined to a specific OpenFOAM release. It handles all OpenFOAM versions, whether ESI or Foundation versions, making it both forward and backward-compatible. This flexibility ensures that users can switch between different OpenFOAM versions without any hassle, maintaining a streamlined workflow across different projects. SplashFOAM aims to be a dynamic, intuitive, and efficient pre-processor, streamlining the setup and execution of OpenFOAM simulations.
To get started with SplashFOAM, follow the steps below:
SplashFOAM includes a pre-installation script to ensure your system is ready:
- Automated Dependency Installation: The script checks for required packages and installs them if missing, including OpenFOAM, FreeCAD, Gmsh, and more.
- WSL Compatibility: Special considerations for users running SplashFOAM on Windows Subsystem for Linux (WSL), including setting up display configurations.
Whether you are running Ubuntu natively, through VirtualBox, or WSL, you must execute the Ubuntu_MEL.sh
script prior to launching SplashFOAM.
Currently, SplashFOAM is supported on Ubuntu (recommended to run on 22.04.5 LTS).
-
Step 1: Clone the Repository
Clone the SplashFOAM repository to your local machine by running:
git clone https://github.com/mohamedalysayed/Splash-OpenFOAM.git
-
Step 2: Switch to the Correct Branch
Ensure you are on the Standard-release branch to access the latest stable version:
cd SplashFOAM git checkout Standard-release
-
Step 3: Install Necessary Packages
Navigate to the SplashFOAM/Resources/Build_Splash/ directory and run the Ubuntu_MEL.sh script to install all the necessary dependencies:
cd SplashFOAM/Resources/Build_Splash/ chmod +x PreInstaller.sh ./PreInstaller.sh
This will ensure that all required packages are installed. The user can install other secondary packages from the suggested list if needed.
-
Step 4: Launch SplashFOAM
After installing the necessary packages, navigate to the Sources directory and launch SplashFOAM using Python 3:
cd ../../Sources/ python3 SplashFOAM.py
SplashFOAM allows users to import geometry files from various formats, including:
- STL (stereolithography)
- OBJ (Wavefront object)
- STEP (Standard for the exchange of product data - analytical format)
Import Geometry enables the user to view their CAD in one of five options:
- Splash Viewer: A local program built into SplashFOAM for quick and efficient CAD visualization.
- FreeCAD: Open your geometries directly in FreeCAD for further design modifications.
- Gmsh: Utilize Gmsh for meshing or geometry inspection.
- Blender: Seamlessly load your CAD files into Blender.
- ParaView: Use ParaView to visualize and inspect complex CAD models.
SplashFOAM offers a range of meshing capabilities:
Currently, SplashFOAM supports three types of meshes:
- Cartesian: Generate structured hex-dominant meshes.
- Polyhedral: Create meshes with polyhedral elements that benefit complex geometries.
- Tetrahedral: Flexible tetrahedral meshing for various applications.
When creating a mesh from scratch, these meshes are generated using cfMesh. Additionally, SplashFOAM handles cases with SnappyHexMesh scripts, making it versatile in handling different meshing setups.
Splash Mesher offers the option to add refinement objects to the domain. As shown below, by defining the type of refinement object and the number of objects you can add the corresponding block to the background meshing script then you’ll be asked to provide the relevant info for the chosen type. Once done and mesh is created, Splash will automatically remove the refinement object assignment to avoid accumulating unwanted blocks in the underlying meshDict (or any equivalent) script.
- Step 1: From Mesh Controls, click on Add Refinement Objects
- Step 2: Choose the refinement objects type and number of repetitions (if any)
- Step 3: Populate the parameters relevant to that object and click add
- Step 4: Create the mesh and review the changes in Paraview
SplashFOAM simplifies the setup of OpenFOAM cases by providing:
- Case Directory Management: Seamlessly load, configure and organize case directories.
- Simulation Configuration: Adjust boundary conditions, solvers, and other simulation parameters through a graphical interface.
- Initialization and Execution: Directly initialize and run simulations from within the SplashFOAM environment. These set the simulation to its initial state and set up the necessary parameters to launch the case. Note: SplashFOAM does not allow direct changes in boundary condition (BC) files. If BC changes are needed, users may set up the case manually and then load it in SplashFOAM for further processing.
Easily manage configuration files for different versions of OpenFOAM:
- Automatic Detection of Installed OpenFOAM Versions: SplashFOAM identifies available versions on your system and sets up the necessary environment variables.
- Alias Setup: Aliases for various OpenFOAM versions are added to .bashrc during installation, ensuring easy access to different versions.
SplashFOAM can launch a simulation locally or on a remote HPC cluster (Cloud HPC):
- Local Execution: Run your simulations directly on your local machine.
- Remote Execution: Configure SplashFOAM to submit jobs to a remote HPC environment for more computational power. More information on setting up remote HPC access can be found here.
SplashFOAM integrates with popular post-processing tools to streamline analysis:
-
ParaView: Currently, results can be analyzed using the visualization tool Paraview. Users can launch ParaView directly from the main SplashFOAM window to post-process simulation results.
-
Grace: Quick access to plot simulation results in 2D using Xmgrace.
Splash-Cloud is an innovative web-based application currently under development to bring CFD workflows to your browser. Designed to complement SplashFOAM, this tool enables users to interact with their geometries directly online, offering an intuitive way to inspect, modify, and prepare geometries for simulation and exports seamless OpenFOAM cases.
- Browser-Based Geometry Manipulation: Load, rotate, scale, and inspect geometries (STL, OBJ, STEP) right from your web browser.
- Advanced 3D Rendering: Experience glossy, interactive 3D rendering for geometries in formats like STL, OBJ, and STEP, with seamless camera control and enhanced lighting for precision inspections.
- Seamless Integration with SplashFOAM: Prepare OpenFOAM-ready cases effortlessly, as Splash-Cloud outputs configurations that are fully compatible with SplashFOAM.
- No Installation Required: Accessible on any device with an internet connection—eliminating setup hassle.
- Collaboration Made Easy: Share geometries and configurations in real time with teammates.
The manual is currently under development. In the meantime, please check the repository for updates or contact the CFD Dose community for help.
Feel free to contribute to SplashFOAM by submitting issues or feature suggestions. Your feedback is super valuable here ;)
[*Please refer to this GitHub repository when using any of the images below (proper referencing is required)]
- Motorbike OpenFOAM Case - Steady State
- Grid wall distance of a 90-degree-bend geometry
- Velocity distribution in a 90-degree-bend at Re=4080
- Instantaneous velocity and particle distribution at a cross-section of a rectangular channel at shear Re=150