Git Product home page Git Product logo

scikit-fem's Introduction

scikit-fem

PyPI version Build Status Documentation Join the chat at https://gitter.im/scikit-fem/Lobby DOI

Easy to use finite element assemblers and the related tools.

Features

This library fills an important gap in the spectrum of finite element codes. The library is lightweight meaning that it has minimal dependencies. It contains no compiled code meaning that it's easy to install and use on all platforms that support NumPy. Despite being fully interpreted, the code has a reasonably good performance.

Examples

In the following snippet, we create a tetrahedral mesh with over 1 million elements and assemble a discrete Laplace operator, all in just a few seconds.

from skfem import *
import numpy as np

mesh = MeshTet.init_tensor(*((np.linspace(0, 1, 60),) * 3))
basis = InteriorBasis(mesh, ElementTetP1())

@bilinear_form
def laplace(u, du, v, dv, w):
    return sum(du * dv)

A = asm(laplace, basis)

More examples can be found in the documentation.

Installation

The most recent release can be installed simply by pip install scikit-fem.

For more cutting edge features, you can clone this repository.

Getting started

If you installed a (recent) release using pip, you can find the accompanying documentation under Releases

The latest user documentation corresponding to the master branch can be found online.

Acknowledgements

This project was started while working under a grant from the Finnish Cultural Foundation. The approach used in the finite element assembly has been inspired by the work of A. Hannukainen and M. Juntunen.

In literature

The library has been used in the preparation of the following scientific works:

  • Gustafsson, T., Stenberg, R., & Videman, J. (2019). On Nitsche's method for elastic contact problems. arXiv preprint arXiv:1902.09312.
  • Gustafsson, T., Stenberg, R., & Videman, J. (2019). Error analysis of Nitsche's mortar method. Numerische Mathematik. Open access.
  • Gustafsson, T., Stenberg, R., & Videman, J. (2018). Nitsche's method for unilateral contact problems. arXiv preprint arXiv:1805.04283.
  • Gustafsson, T., Stenberg, R. & Videman, J. (2018). A posteriori estimates for conforming Kirchhoff plate elements. SIAM Journal on Scientific Computing, 40.3, A1386-A1407. arXiv preprint arXiv:1707.08396.
  • Gustafsson, T., Rajagopal, K. R., Stenberg, R., & Videman, J. (2018). An adaptive finite element method for the inequality-constrained Reynolds equation. Computer Methods in Applied Mechanics and Engineering, 336, 156-170. arXiv preprint arXiv:1711.04274.
  • Gustafsson, T., Stenberg, R., & Videman, J. (2018). A stabilised finite element method for the plate obstacle problem. BIT Numerical Mathematics, 1-28. arXiv preprint arXiv:1711.04166.
  • Gustafsson, T., Stenberg, R., & Videman, J. (2017). Nitsche’s Method for the Obstacle Problem of Clamped Kirchhoff Plates. In European Conference on Numerical Mathematics and Advanced Applications (pp. 407-415). Springer.
  • Gustafsson, T., Stenberg, R., & Videman, J. (2017). A posteriori analysis of classical plate elements. Rakenteiden Mekaniikka, 50(3), 141-145. Open access.

In case you want to cite the library, you can use the DOI provided by Zenodo.

Contributors

By contributing code to scikit-fem, you are agreeing to release it under BSD-3-Clause, see LICENSE.md.

scikit-fem's People

Contributors

kinnala avatar gdmcbain avatar gitter-badger 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.