cpmech / russell

Rust Scientific Libary. ODE and DAE (Runge-Kutta) solvers. Special functions (Bessel, Elliptic, Beta, Gamma, Erf). Linear algebra. Sparse solvers (MUMPS, UMFPACK). Probability distributions. Tensor calculus.
MIT License
102 stars 8 forks source link

Examples of russell to solve 3D Poisson equations #107

Closed supernova4869 closed 4 months ago

supernova4869 commented 4 months ago

I want to solve the 3D Poisson-Boltzmann equation like $$\nabla^2 \phi - \kappa^2 \phi = 4 \pi \rho_f / \epsilon$$ with the boundary contitions $$\phi (\infty) = 0$$ could the russell handle this problem? I saw that the PDE example was for 2D Laplace equation.

cpmech commented 4 months ago

Hi, unfortunately, Russell doesn't have a solver for such a problem.

The goal for the 2D Laplace operator in the russell_ode crate is to test the ODE solvers only. It may be converted to a 3D solver based on Finite Differences, nonetheless.

Russell aims to provide the foundation tools for implementing PDE solvers, but not implement them (because there are many problem types and many solution methods!).

As another example, it is possible to use the foundation tools of the russell_lab crate (within the algo module) to develop Spectral Collocation methods for multidimensional PDEs. There is a 1D example here that may serve as a basis to implement a 3D solver.

supernova4869 commented 4 months ago

Thank you. I will try to develop it as an extend work.