Skip to main content

Laplace-Dirichlet Rule-based algorithm for assigning myocardial fiber orientations.

Project description

InstallConda CircleCI Documentation Status Platform

Laplace-Dirichlet Rule-Based (LDRB) algorithm for assigning myocardial fiber orientations

A software for assigning myocardial fiber orientations based on the Laplace Dirichlet Ruled-Based algorithm.

Bayer, J.D., Blake, R.C., Plank, G. and Trayanova, N.A., 2012. A novel rule-based algorithm for assigning myocardial fiber orientation to computational heart models. Annals of biomedical engineering, 40(10), pp.2243-2254.(https://www.ncbi.nlm.nih.gov/pmc/articles/PMC3518842/)

# Decide on the angles you want to use
angles = dict(alpha_endo_lv=30,    # Fiber angle on the LV endocardium
              alpha_epi_lv=-30,    # Fiber angle on the LV epicardium
              beta_endo_lv=0,      # Sheet angle on the LV endocardium
              beta_epi_lv=0,       # Sheet angle on the LV epicardium
              alpha_endo_sept=60,  # Fiber angle on the Septum endocardium
              alpha_epi_sept=-60,  # Fiber angle on the Septum epicardium
              beta_endo_sept=0,   # Sheet angle on the Septum endocardium
              beta_epi_sept=0,   # Sheet angle on the Septum epicardium
              alpha_endo_rv=80,    # Fiber angle on the RV endocardium
              alpha_epi_rv=-80,    # Fiber angle on the RV epicardium
              beta_endo_rv=0,      # Sheet angle on the RV endocardium
              beta_epi_rv=0)        # Sheet angle on the RV epicardium

# Choose space for the fiber fields
# This is a string on the form {family}_{degree}
fiber_space = 'Quadrature_2'

# Compute the microstructure
fiber, sheet, sheet_normal = ldrb.dolfin_ldrb(mesh=mesh,
                                              fiber_space=fiber_space,
                                              ffun=ffun,
                                              markers=markers,
                                              **angles)
# Store files using a built in xdmf viewer that also works for functions
# defined in quadrature spaces
ldrb.fiber_to_xdmf(fiber, 'fiber')
# And visualize it in Paraview

Installation

Install with pip

In order to install the software you need to have installedFEniCS (versions older than 2016 are not supprted)

The package can be installed with pip.

pip install ldrb

or if you need the most recent version you can install the source

pip install git+https://github.com/finsberg/ldrb.git

Install with conda

Alternatively you can install with conda

conda install -c finsberg ldrb

Documetation

Documentation is hosted at https://ldrb.readthedocs.io.

Getting started

Check out the demos and the documentation

License

ldrb is licensed under the GNU LGPL, version 3 or (at your option) any later version. ldrb is Copyright (2011-2019) by the authors and Simula Research Laboratory.

Contributors

Henrik Finsberg (henriknf@simula.no)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ldrb-2019.1.tar.gz (17.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ldrb-2019.1-py3-none-any.whl (18.1 kB view details)

Uploaded Python 3

File details

Details for the file ldrb-2019.1.tar.gz.

File metadata

  • Download URL: ldrb-2019.1.tar.gz
  • Upload date:
  • Size: 17.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.2

File hashes

Hashes for ldrb-2019.1.tar.gz
Algorithm Hash digest
SHA256 738b6583432a484ca6f3aa047ad26861d3530aa55b0d7812357acce6973ded93
MD5 0bd597a8f7c3870655e7514189928933
BLAKE2b-256 1bdec9f9248dddc771f01df760fa196608c40af9111e91ec2d8f0eb25644e6c6

See more details on using hashes here.

File details

Details for the file ldrb-2019.1-py3-none-any.whl.

File metadata

  • Download URL: ldrb-2019.1-py3-none-any.whl
  • Upload date:
  • Size: 18.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.2

File hashes

Hashes for ldrb-2019.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0a24f5373fdc6dd278eb5d1c0e1160579fbaf66323818e90d54c92bb80989092
MD5 5dc58133013b5f551e2994b75dfb9a0c
BLAKE2b-256 00257da10d873ae46e2586b30e49120d187886bd755e2ade6e7fe62980263ba7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page