FreeCAD 1.1.1 + CfdOF in wsl + DesignSPH installation tutorial 2026

*00:00* - Introduction and overview of the setup *00:53* - Downloading and installing FreeCAD *01:29* - Installing the CfdOF addon in FreeCAD *02:36* - Downloading and installing ParaView *04:30* - Linking the ParaView executable to FreeCAD preferences *05:24* - Installing Windows Subsystem for Linux (WSL) via PowerShell *06:31* - Installing Ubuntu for WSL *07:29* - Configuring WSL RAM limits (`.wslconfig`) *08:31* - Installing OpenFOAM and dependencies in Ubuntu *09:30* - Locating the OpenFOAM installation path in Linux *09:56* - Linking the OpenFOAM directory to FreeCAD preferences *11:29* - Running the dependency checker to verify the CFDOF setup *12:38* - Creating a basic 3D model (cylinder) to test CFDOF *13:28* - Generating a mesh for the CFD simulation *14:29* - Setting up boundary conditions (inlet, outlet, wall) *15:08* - Running the OpenFOAM solver from FreeCAD *15:53* - Viewing the CFD simulation results in ParaView *16:23* - Starting the Smoothed Particle Hydrodynamics (SPH) setup *16:40* - Installing the DesignSPHysics addon in FreeCAD *17:11* - Adding the SPH macro to a custom FreeCAD toolbar *18:51* - Downloading and extracting DualSPHysics binaries from GitHub *21:13* - Creating a test case for SPH (dropping a box of water) *24:37* - Generating the SPH case and running it on the GPU *26:26* - Exporting SPH simulation data to VTK and visualizing it in ParaView Open *PowerShell as Administrator* for the following commands. ```bash 1. Install the WSL engine (no distribution yet) wsl --install --no-distribution -- RESTART YOUR COMPUTER NOW -- 2. Ensure WSL 2 is the default architecture wsl --set-default-version 2 3. Force an update to get the latest Microsoft Linux kernel wsl --update 4. Restart the WSL engine to apply updates wsl --shutdown 5. Install exactly the distribution you want wsl --install Ubuntu-24.04 6. Set your Linux username and password within the Ubuntu terminal ``` #### PART B: Configure WSL2 RAM (Recommended) Run in PowerShell: ```bash Add-Content -Path "$env:USERPROFILE\.wslconfig" -Value "[wsl2]`nmemory=16GB" ``` Alternatively, manually create/edit `C:\Users\#your_user#\.wslconfig` and add: ```text [wsl2] memory=16GB ``` #### PART C: Install OpenFOAM, cfMesh & Hisa (Inside Ubuntu) Once inside your Ubuntu terminal, copy and paste this entire block to run the automated setup script. sudo apt-get update && \ sudo apt-get upgrade -y && \ sudo apt-get install -y \ build-essential \ git \ wget \ curl \ unzip \ bison \ cmake \ flex \ zlib1g-dev \ libboost-system-dev \ libboost-thread-dev \ libgmp-dev \ libmpfr-dev \ libmpc-dev && \ curl -s https://dl.openfoam.com/add-debian-re... | sudo bash && \ sudo apt-get install -y openfoam2512-default && \ bash -c 'source /usr/lib/openfoam/openfoam2512/etc/bashrc && \ cd ~ && \ curl -L -o cfmesh-cfdof.zip https://sourceforge.net/projects/cfme... && \ unzip -o cfmesh-cfdof.zip && \ cd cfmesh-cfdof && \ export WM_NCOMPPROCS=$(nproc) && \ ./Allwmake && \ cd ~ && \ git clone https://gitlab.com/hisa/hisa.git && \ cd hisa && \ ./Allwmake' --- 📁 Important Paths & Notes *Your OpenFOAM Path for FreeCAD/CfdOF setup:* Copy this path into the CfdOF preferences inside FreeCAD to link to OpenFOAM: `\\wsl.localhost\Ubuntu-24.04\usr\lib\openfoam\openfoam2512` *Syntax Note:* Syntax has slightly changed in newer OpenFOAM versions. While we haven't encountered major issues yet, be aware that old tutorials might require slight adjustments to dictionary files. *Troubleshooting WSL Installation:* If you have problems with `wsl --install --no-distribution`, go to Windows Settings - System - Optional features - More windows features. Ensure these are ticked, then restart: Windows Subsystem for Linux Windows Hypervisor Platform Virtual Machine Platform --- 🔗 Useful Links *FreeCAD Official Website:* [https://www.freecad.org](https://www.freecad.org) *CfdOF Workbench (jaheyns):* [https://github.com/jaheyns/CfdOF](https://github.com/jaheyns/CfdOF) *DesignSPHysics Workbench:* [https://github.com/dualsphysics/desig...](https://github.com/dualsphysics/desig...) *ParaView (Post-processing):* [https://www.paraview.org/](https://www.paraview.org/) --- #FreeCAD #OpenFOAM #WSL2 #Ubuntu #CFD #Simulation #DesignSPHysics #Engineering #OpenSource #Tutorial ---