Skip to content

Commit b010f79

Browse files
committed
adding fiber generation codes
1 parent 2f17399 commit b010f79

File tree

27 files changed

+2089
-0
lines changed

27 files changed

+2089
-0
lines changed
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# SV-fibergen
2+
Python + SVmultiphysics codes for fiber generation. Two methods are implemented:
3+
* Bayer et al. (2012). [link](https://doi.org/10.1007/s10439-012-0593-5)
4+
* Doste et al. (2018). [link](https://doi.org/10.1002/cnm.3185)
5+
6+
### Examples
7+
The `main_bayer.py` and `main_doste.py` are scripts to run both methods in the geometry described in the `example/truncated` and `example/ot` folders respectively.
8+
9+
<img src="example/truncated/bayer.png" alt="Results for truncated BiV (Bayer)" width="640" />
10+
<img src="example/ot/doste.png" alt="Results for BiV w/ outflow tracts (Doste)" width="640" />
11+
12+
Note that the Doste methods needs a geometry with outflow tracts to be run (each valve needs to be defined as a separated surface). Bayer can be run in any biventricular geometry.
13+
14+
15+
### Updates to the old code
16+
* All operations are vectorized now.
17+
* The SVmultiphysics solver now solves a Laplace equation.
18+
* In Bayer: For the bislerp interpolation, instead of using the correction described in Bayer et al. (that returns a discontinuity), the basis are flipped to maintain a coherent fiber direction (see function `generate_fibers_BiV_Bayer_cells` in `FibGen.py`).
19+
* In Bayer: The beta angles were not being included correctly. The second rotation was being applied respect the first vector (circumferential) when it should be respect to the second vector (longitudinal) (see function `generate_fibers_BiV_Bayer_cells` in `FibGen.py`).
20+
21+
### Notes on SVmultiphysics solver
22+
23+
To solve a Laplace equation directly from the transient HEAT solver in SVmultiphysics, in `<GeneralSimulationParameters>` we need to set,
24+
```
25+
<Number_of_time_steps> 1 </Number_of_time_steps>
26+
<Time_step_size> 1 </Time_step_size>
27+
<Spectral_radius_of_infinite_time_step> 0. </Spectral_radius_of_infinite_time_step>
28+
```
29+
and in `<Add_equation type="heatS" >`,
30+
```
31+
<Conductivity> 1.0 </Conductivity>
32+
<Source_term> 0.0 </Source_term>
33+
<Density> 0.0 </Density>
34+
```
35+
This will allow us to solve the Laplace equation directly in 1 timestep and 1 iteration.
Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:9347d6e7907816749cc16471130397f264c7721d029626fb1b9f7fdd6ac1e02c
3+
size 28209696
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:1431a90e42af727af648dacde59095e9c3fd8e37d4a7dfef3fef57b633eaf139
3+
size 2867
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:ee7d4d8eb31b2639f75599c188cb2af9fa4fcc466d27e34b65dc3ec4f4f3633b
3+
size 14489
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:fa09ea16a80da5813b133a22f42b94b7aae48cd414e9c8ce174d46a4d7eb3a19
3+
size 563261
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:b0c07b7ca1ad1b8c38d826d363f5572e1e6359595f5701a2b3f8f25606e30073
3+
size 734382
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:2168042f6f99283d747e5895df8bb30d443631b5be7e31b51c55e1a7be83fa29
3+
size 1293881
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:712904ededfdd630a736abfc213758155f8dd68a7f1512c2128c2b0305eeecb6
3+
size 90751
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:1b99698dc66260cd1c63d4612402f07e98b0a547549e42d896048bf7bdbe2afb
3+
size 12559

0 commit comments

Comments
 (0)