Skip to content

⛏️ FE code that discretizes a two-dimensional Poisson’s equation using B-Spline basis functions

Notifications You must be signed in to change notification settings

huaminghuangtw/B-Spline-FEM-Computation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

B-Spline-FEM-Computation

FE code that discretizes a two-dimensional Poisson’s equation using B-Spline basis functions.

Setup

  1. Recursively clone this project to your machine: git clone --recursive https://github.com/huaminghuangtw/B-Spline-FEM-Computation.git
  2. Use Cmake to build/generate project files corresponding to your preferred complier/IDE, e.g., Visual Studio 2019
    (Remember to tick the PYBIND11_INSTALL box, otherwise there will be ImportError: DLL not found message)

  3. Open project solution file (in this case splinecomputation.sln)
  4. Go to Solution Explorer > Right-click on INSTALL > Select build

  5. A new folder called install will be generated under your build folder
  6. After this step you can go to the install folder and run the splinekernel testrunner or any python scripts


How to use the code?

In the install folder, you could play around with:

  • splinekernel testrunner

    • CMD

    • Git Bash

    • Visual Studio
      • Go to Solution Explorer > Right-click on splinekernel_testrunner > Select Debug > Select Start New Instance
      • Go to Solution Explorer > Right-click on splinekernel_testrunner > Select Set as StartUp Project > Click F5
  • Python scripts

    python plotBSplineBasis.py


    python plotBSplineCurve.py


    python plotBSplineBasis2D.py


    python plotBSplineSurface.py


    python laplaceProblem.py



Contact

If you have any question or suggestion, feel free to contact me at huaming.huang.tw@gmail.com. Contributions are also welcomed. Please open a pull-request or an issue in this repository.