Giter Club home page Giter Club logo

csbq's Introduction

Convergent slender-body quadrature (CSBQ)

Principal author Dhairya Malhotra, with additional code by Alex Barnett. This work was done at the Center for Computational Mathematics at the Flatiron Institute, NY, NY.

This is a high-performance parallel C++ implementation of a high-order adaptive Nyström quadrature for the boundary integral equations arising in 3D Laplace and Stokes Dirichlet and rigid mobility boundary-value problems for closed loop filaments of arbitrarily small circular cross-section. Its quadrature setup cost is independent of the slenderness parameter, being around 20000 unknowns/sec per core, at 6-digit accuracy, away from close-to-touching regions. Close-to-touching geometries may be handled to close to machine accuracy using adaptivity. Open-ended fibers with rounded ends are possible and will be added soon.

This repository also contains MATLAB codes implementing the classical slender-body theory asymptotic approximation, and solving its linear inverse problem as needed for a mobility solve.

It is research software; use at your own risk. The following figures show some of the capabilities of the code (see the preprint below for details).

Stokes flow solution around rigid slender fiber with aspect ratio $10^3$, max error $10^{-10}$:

Stokes flow solution near close-to-touching rings, max error $10^{-11}$:

Sedimentation of 512 rings each of aspect ratio 20, timestepped to 7-digit accuracy on 160 cores:

Minimum requirements to compile:

C++ compiler that supports C++11 standard

Optional libraries for better performance:

BLAS, LAPACK, FFTW, MPI (distributed memory parallelism), PVFMM

Instructions:

git clone https://github.com/dmalhotra/CSBQ.git
cd CSBQ
git submodule init
git submodule update
# update Makefile as necessary
make
./bin/demo1-geometry

For visualization do (after installing PARAVIEW):

make && ./bin/demo1-geometry && paraview vis/ring.pvtu

Overview:

This is a header-only C++ library: you only need to #include <csbq.hpp> in your code. It relies on the SCTL library (included as a submodule) and the path to sctl.hpp must be provided to the C++ compiler. The included Makefile may be used as a template for new projects. Everything is contained within sctl:: namespace. Demo codes for learning to use the library are provided in tutorial/. Precomputed quadrature tables for Laplace and Stokes kernels and some geometry files are provided in data/. Test codes used to generate the results in the paper are provided in test/, along with SLURM scripts in scripts/.

For slender-body numerical implementations in MATLAB, see SBT/ directory.

Citing this work

If you find this code useful in your research, please cite our preprint, "Efficient Convergent Boundary Integral Methods for Slender Bodies," Dhairya Malhotra and Alex Barnett, arXiv:2310.00889, submitted, J. Comput. Phys. (2023).

csbq's People

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.