Skip to content

Commit b088074

Browse files
authored
Merge pull request #2180 from nids2001/module-documentation
Move module documentation from old wiki
2 parents c5d2fc5 + e3715ab commit b088074

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+709
-19
lines changed
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
---
2+
title: ApplyFEMCurrentSource
3+
category: moduledocs
4+
module:
5+
category: FiniteElements
6+
package: SCIRun
7+
tags: module
8+
layout: null
9+
---
10+
11+
# {{ page.title }}
12+
13+
## Category
14+
15+
**{{ page.module.category }}**
16+
17+
## Description
18+
19+
### Summary
20+
21+
The ApplyFEMCurrentSource module builds the right-hand side (ColumnMatrix) to reflect monopolar and dipolar current sources for finite-element based bioelectric field problems.
22+
23+
####Inputs:
24+
25+
####Outputs:
26+
27+
The first output, RHS, is the right-hand-side vector to be used with the stiffness matrix. The size of the vector is the number of nodes of the input mesh.
28+
29+
The second output, Weights, is a vector giving the weight of each component of the current source. When dipole sources are used, Weights contains the x/y/z-component of each dipole moments.
30+
31+
**Detailed Description**
32+
33+
If an input RHS ColumnMatrix is present, this module adds the contributions for the current sources into that matrix (i.e. multiple ApplyFEMCurrentSource modules can be cascaded together). If no RHS is present, this module will generate one. The RHS ColumnMatrix will be of length n, where n is the number of nodes in the finite element mesh.
34+
35+
We assume the mesh will be stored in a TetVolMesh, a HexVolMesh, or a TriSurfMesh.
36+
37+
There are two types of current sources supported by this module: dipoles, and sources-and-sinks.
38+
39+
With dipoles, the user must pass in a PointCloudField<Vector> into the Sources input port. The position of each PointCloud node corresponds to the location of the dipole, and the corresponding Vector corresponds to the moment of the dipole. If the user wishes to use dipolar sources, they must pass in a PointCloudField<Vector> AND they must select "dipole" for the Source Model on the UI window.
40+
41+
In contrast to the dipole model, the sources-and-sinks option has several sub-models. To activate any of these, the user must select the "sources and sinks" option from the UI. The values that are used for sources-and-sinks are a combination of: the source and sink indices entered in the UI; a PointCloudField<double> passed into the Source port; and a MappingMatrix. Here is the logic for how those values are used:
42+
1. if we don't have a Mapping matrix, we use the source/sink indices from the UI as node indices from the volume mesh between which one unit of current is passed;
43+
2. if we have a Mapping matrix, but we don't have a Source field, then the source/sink indices refer to the PointCloud and we use the Mapping matrix to get their corresponding volume node indices, and we then pass one unit of current between them;
44+
3. if we have a Mapping matrix AND a Source field, then ignore the source/sink indices from the UI, and assume that the Mapping matrix maps the PointCloud nodes to Volume mesh nodes and that the data values (doubles) from the PointCloud indicate the strength (current density) for each point source.
45+
46+
{% capture url %}{% include url.md %}{% endcapture %}
47+
{{ url }}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
---
2+
title: ApplyFEMVoltageSource
3+
category: moduledocs
4+
module:
5+
category: FiniteElements
6+
package: SCIRun
7+
tags: module
8+
layout: null
9+
---
10+
11+
# {{ page.title }}
12+
13+
## Category
14+
15+
**{{ page.module.category }}**
16+
17+
## Description
18+
19+
### Summary
20+
21+
The module changes/creates the right-hand side (RHS) and forward matrices for voltage (Dirichlet) boundary conditions.
22+
23+
**Detailed Description**
24+
25+
The ApplyFEMVoltageSource module creates and fills a new ColumnMatrix, according to mesh and dipole parameters in situations where it does not locate a ColumnMatrix on its input that contains an RHS to modify, or when the module finds a ColumnMatrix of a different size than the number of nodes in the mesh.
26+
27+
<!-- TODO: Information out-of-date -->
28+
<!-- We assume the mesh to be a TetVolField(int) type, containing indices to the conductivity tensor lookup table.
29+
The documentation for the MODULE REFERENCE module provides further information about this mesh. -->
30+
31+
{% capture url %}{% include url.md %}{% endcapture %}
32+
{{ url }}
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
---
2+
title: BuildBEMatrix
3+
category: moduledocs
4+
module:
5+
category: Forward
6+
package: SCIRun
7+
tags: module
8+
layout: null
9+
---
10+
11+
# {{ page.title }}
12+
13+
## Category
14+
15+
**{{ page.module.category }}**
16+
17+
## Description
18+
19+
### Summary
20+
21+
The module solves a discretized model of Laplace's equation in a 3D volume conductor model using "surface method", given a particular type of boundary condition.
22+
23+
**Detailed Description**
24+
25+
The specific problem the authors had in mind was the forward problem of electrocardiography which consists of calculating, for a given time instant, the potential distribution generated at the surface of a specified volume conductor due the presence of the selected equivalent sources on a surface inside the conductor (The module should work for other problems which fit the same physical description, but has only been tested for forward electrocardiography.) In surface methods, the different volume conductor regions are assumed to have a constant and isotropic conductivity, and only the interfaces between the different regions are triangulated and represented in the numerical model. This module uses the "Transfer-Coefficient Approach" or "solid-angle method" developed by Barr et al. [i], as extended to include torso inhomogeneities in [ii] and with an improved algorithm for computing the solid angles [iii].
26+
27+
[i] R.C. Barr, M. Ramsey, and M.S. Spach, "Relating epicardial to body surface potential distribution by means of transfer coefficients based on geometry measurement," IEEE Trans. Biomed. Eng., vol. BME-24, pp. 1-11, 1977.
28+
29+
[ii] P.C. Stanley, T.C. Pilkington, and M.N. Morrow., "The effects of thoracic inhomogeneities on the relationship between epicardial and torso potentials," IEEE Transactions on Biomedical Engineering, BME-33, pp.273-284, 1986.
30+
31+
[iii] J.A. De Munck, "Linear discretization of the volume conductor boundary integral equation using analytically integrated elements," IEEE Trans. Biomed. Eng., vol. 39, no. 9, 1992.
32+
33+
This module requires the triangulated surfaces of all the objects as inputs and creates the forward solution matrix as output. The geometric relationships of the surfaces are defined as described below, as are the boundary conditions to apply.
34+
35+
The number of input fields is two or greater and can be unlimited but one of them must be defined as the "source surface" where the Dirichlet boundary condition is given and another one defined as the "measurement surface" where the quantity of interest is to be calculated. To do this we use a "SetProperty" module for each of these two designated surfaces with `Property` = `in/out` and `Value` = `in` for the "source surface" and `Value` = `out` for the "measurement surface". Insulating boundary conditions (Neumann boundary conditions) are assumed on the outermost surface.
36+
37+
To define the geometric relationships of the various fields, for each of the input fields use a "SetProperty" module with `Property` = `Inside Conductivity` and `Value` = the numerical value of the internal conductivity of the corresponding homogeneous region.
38+
39+
The output is the forward solution matrix. This matrix can be multiplied to a Dirichlet boundary condition on the "source surface" to result in the boundary values on the "measurement surface". This matrix is needed as an input for the modules "TikhonovSVD", "Tikhonov" and "TSVD".
40+
41+
{% capture url %}{% include url.md %}{% endcapture %}
42+
{{ url }}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
---
2+
title: BuildFESurfRHS
3+
category: moduledocs
4+
module:
5+
category: BIOPSE
6+
package: SCIRun
7+
tags: module
8+
layout: null
9+
---
10+
11+
# {{ page.title }}
12+
13+
## Category
14+
15+
**{{ page.module.category }}**
16+
17+
## Description
18+
19+
### Summary
20+
21+
Calculates the divergence of a vector field over a surface. It is designed to calculate the surface integral of the vector field (gradient of the potential in electrical simulations).
22+
23+
Builds the surface portion of the RHS of FE calculations where the RHS of the function is GRAD dot F.
24+
25+
**Detailed Description**
26+
27+
*Input*
28+
- A FE mesh with field vectors distributed on the elements (constant basis).
29+
30+
*Output*
31+
- The Grad dot F
32+
33+
{% capture url %}{% include url.md %}{% endcapture %}
34+
{{ url }}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
---
2+
title: BuildSurfaceLaplacianMatrix
3+
category: moduledocs
4+
module:
5+
category: Inverse
6+
package: SCIRun
7+
tags: module
8+
layout: null
9+
---
10+
11+
# {{ page.title }}
12+
13+
## Category
14+
15+
**{{ page.module.category }}**
16+
17+
## Description
18+
19+
### Summary
20+
21+
Transform attributes
22+
23+
**Detailed Description**
24+
25+
Transform attributes
26+
27+
{% capture url %}{% include url.md %}{% endcapture %}
28+
{{ url }}

docs/_includes/modules/CalcTMP.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
title: CalcTMP
3+
category: moduledocs
4+
module:
5+
category: Forward
6+
package: SCIRun
7+
tags: module
8+
layout: null
9+
---
10+
11+
# {{ page.title }}
12+
13+
## Category
14+
15+
**{{ page.module.category }}**
16+
17+
## Description
18+
19+
### Summary
20+
21+
Calculates the transmembrane action potentials given the input parameters generated from ECGSim
22+
23+
**Detailed Description**
24+
25+
###Inputs as matrices - These can be generated by ECGSim
26+
27+
- Amplitude
28+
- Depolarization Times
29+
- Depolarization Slope
30+
- Plateau Slope
31+
- Repolarization Slope
32+
- Resting Potential
33+
34+
###Output
35+
36+
- Transmembrane potentials for one cardiac cycle.
37+
38+
{% capture url %}{% include url.md %}{% endcapture %}
39+
{{ url }}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
---
2+
title: CalculateCurrentDensity
3+
category: moduledocs
4+
module:
5+
category: Forward
6+
package: SCIRun
7+
tags: module
8+
layout: null
9+
---
10+
11+
# {{ page.title }}
12+
13+
## Category
14+
15+
**{{ page.module.category }}**
16+
17+
## Description
18+
19+
### Summary
20+
21+
Compute the current density vector field
22+
23+
**Detailed Description**
24+
25+
CalculateCurrentDensity calculates the current density vector field.
26+
27+
Required inputs are the electric field and mesh with conductivities.
28+
29+
Technical note: The current density vector field J is the product of sigma and -del V. The minus sign is added in CalculateCurrentDensity, so the electric field input should be positive (which is the unmodified output of the {% include moduleLink.md moduleName='ChangeFieldData' %}::{% include moduleLink.md moduleName='CalculateGradients' %} module).
30+
31+
{% capture url %}{% include url.md %}{% endcapture %}
32+
{{ url }}
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
---
2+
title: CalculateMeshNodes
3+
category: moduledocs
4+
module:
5+
category: ChangeMesh
6+
package: SCIRun
7+
tags: module
8+
layout: null
9+
---
10+
11+
# {{ page.title }}
12+
13+
## Category
14+
15+
**{{ page.module.category }}**
16+
17+
## Description
18+
19+
### Summary
20+
21+
This module allows the computation of a new position for each node in the input field. The user defined function can depend on a number of variables
22+
23+
**Detailed Description**
24+
25+
**Overview**
26+
27+
#### Input Variables
28+
29+
1. ```DATA```: This is the current value stored in the field (either on the element or the node location). The value is only available if the data is located on the nodes.
30+
31+
2. ```X,Y,Z```: Cartesian coordinates of the node or element (center of the element)
32+
33+
3. ```POS```: Vector with Cartesian coordinates of the node or element
34+
35+
4. ```A,B,C,...```: Input from additional matrix ports. The input matrix can have either 1 row or the same number of rows as there are values in the field. In case the matrix has one value this value is the same for each data location, in case it has multiple values the module iterates of the values in the same way it iterates over the data values of the field. The matrix input can have either 1 column, 3 columns, 6 or 9 columns. In case the matrix has 1 column values are assumed to be scalar values, in case the matrix has 3 columns it is assumed to contain vector values and in case it has either 6 or 9 columns it is assumed to be a tensor value (A 6 valued tensor is defined as xx, xy, xz, yy, yz, and zz).
36+
37+
5. ```INDEX```: The index number of the element or node.
38+
39+
6. ```SIZE```: The number of elements or nodes in the Field (depends on the input Field mesh type).
40+
41+
#### Output Variable
42+
43+
1. ```NEWPOS```: The output needs to be stored in the variable NEWPOS.
44+
45+
#### Available Functions
46+
47+
A list of available functions is available in the GUI of the module. The ***Parser Help*** button brings up a list of available functions to do scalar/vector/tensor algebra.
48+
49+
#### Input Ports
50+
51+
The first input is the Field whose node positions need to be recalculated using a function. The second port is an optional port that allows the user to script the module with a user defined input function. This function will override the function given in the GUI of the module. The third and next ports are used to import a matrix. The first port corresponds to matrix A, the next to matrix B and so on. These ports can be used to do algebra with values stored as a matrix or can be used to enter scriptable scalar/vector/tensor values that can be defined elsewhere.
52+
53+
#### Output Port
54+
55+
The module has one output port that has the newly defined values.
56+
57+
#### Output Data Type
58+
59+
As the function is parsed using the compiler, the output type cannot be guessed by the module, hence it needs to be set by the user to the correct data type.
60+
61+
62+
{% capture url %}{% include url.md %}{% endcapture %}
63+
{{ url }}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
---
2+
title: GetFieldNodes
3+
category: moduledocs
4+
module:
5+
category: ChangeMesh
6+
package: SCIRun
7+
tags: module
8+
layout: null
9+
---
10+
11+
# {{ page.title }}
12+
13+
## Category
14+
15+
**{{ page.module.category }}**
16+
17+
## Description
18+
19+
### Summary
20+
21+
This module loads in a field and returns its nodes in the form of a matrix.
22+
23+
**Detailed Description**
24+
25+
Input: a SCIRun field. Output: All the nodes of the input field, represented by an N*3 matrix. Each row gives the x-y-z coordinates of one node.
26+
27+
{% capture url %}{% include url.md %}{% endcapture %}
28+
{{ url }}

docs/_includes/modules/GetNetworkFilename.md renamed to docs/_includes/modules/GetNetworkFileName.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title: GetNetworkFilename
2+
title: GetNetworkFileName
33
category: moduledocs
44
module:
55
category: String

0 commit comments

Comments
 (0)