Skip to content

Commit 4cd74bf

Browse files
updating triangle utility docs
1 parent 1048945 commit 4cd74bf

File tree

88 files changed

+2512
-689
lines changed

Some content is hidden

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

88 files changed

+2512
-689
lines changed

docs/about/easifemBase.md

+13-13
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,15 @@ title: easifemBase
33
sidebar_position: 5
44
---
55

6+
<!-- markdownlint-disable MD041 MD013 MD033 MD012 -->
7+
68
`easifemBase` (henceforth read as Base) library is the lowest (or, base) level component of EASIFEM. All other components are built upon `easifemBase`.
79

8-
It contains a lot of valuable routines and derived types.
10+
It contains a lot of valuable routines and derived types.
911

1012
## Programming paradigm
1113

12-
The programming paradigm of `easifemBase` is [Multiple dispatch approach](https://en.wikipedia.org/wiki/Multiple_dispatch) and Procedural programming.
14+
The programming paradigm of `easifemBase` is [Multiple dispatch approach](https://en.wikipedia.org/wiki/Multiple_dispatch) and Procedural programming.
1315

1416
:::note
1517
The base library do not use the object-oriented programming concepts. In the Base library `String_Class` is the only exception wherein Object-oriented paradigm has been used.
@@ -22,14 +24,14 @@ import TabItem from '@theme/TabItem';
2224

2325
## Key features
2426

25-
Currently, easifemBase has interface with
27+
Currently, easifemBase has interface with
2628

27-
- `BLAS95`
28-
- `Lapack95`
29-
- `Sparsekit`
30-
- `Metis`
31-
- `PlPlot`
32-
- `SuperLU`
29+
- `BLAS95`
30+
- `Lapack95`
31+
- `Sparsekit`
32+
- `Metis`
33+
- `PlPlot`
34+
- `SuperLU`
3335
- `ARPACK`
3436

3537
- [ ] TODO Add key features in `easifemBase.md`.
@@ -53,11 +55,11 @@ The `easifemBase` library exposes three main modules.
5355

5456
1. `BaseType`, which contains the user-defined data-type
5557
2. `BaseMethods`, contains the modules (each module defines the routines for data-types defined in `BaseType.F90`.)
56-
3. `easifemBase`
58+
3. `easifemBase`
5759

5860
The structure of source directory is shown in the following figure.
5961

60-
![](./figures/figure-2.svg)
62+
![easifem-base-design](/img/svg/easifem-base-design.svg)
6163

6264
The source directory has two directories
6365

@@ -244,5 +246,3 @@ import {basemethods_columns, basemethods_articles} from "./BaseMethods.table.js"
244246
columns={basemethods_columns}
245247
data={basemethods_articles}
246248
/>
247-
248-
###

docs/about/figures/figure-2.svg

-4
This file was deleted.

docs/about/index.md

+3-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
11
---
2-
id: "index"
3-
aliases:
4-
- "EASIFEM"
52
tags:
63
- "easifemBase"
74
- "easifemClasses"
@@ -10,6 +7,8 @@ sidebar_position: 1
107

118
# EASIFEM
129

10+
<!-- markdownlint-disable MD041 MD013 MD033 -->
11+
1312
Expandable And Scalable Infrastructure for Finite Element Methods, EASIFEM, is [Modern FORTRAN](https://fortran-lang.org) framework for solving partial differential equations (PDEs) using finite element methods. EASIFEM “eases” the efforts to develop scientific programs in FORTRAN. It is meant for researchers, scientists, and engineers using FORTRAN to implement numerical methods for solving the initial-boundary-value problems (IBVPs). EASIFEM is equipped with both low- and high-level datatype and classes for implementing finite element methods.
1413

1514
Following are some features which may interest you.
@@ -26,7 +25,7 @@ Currently, EASIFEM focuses on finite element methods. Eventually, the library wi
2625

2726
## Structure of EASIFEM
2827

29-
![](/img/what-is-easifem.svg)
28+
![easifem structure](/img/what-is-easifem.svg)
3029

3130
EASIFEM consists following three hierarchical components:
3231

@@ -77,7 +76,6 @@ Currently, `easifemBase` has interface with `HDF5`, `Gmsh`, `PlPlot`, `GTK4`, `P
7776
</div>
7877
</div>
7978

80-
8179
## Kernels
8280

8381
`easifemKernels` (henceforth, read as Kernels) contains physics simulators. For example, we have:
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,11 @@
11
# BarycentricVertexBasis
22

3+
<!-- markdownlint-disable MD041 MD013 MD033 MD012 -->
4+
35
Returns the vertex basis functions on reference Triangle.
46

57
## Interface
68

7-
import Tabs from '@theme/Tabs';
8-
import TabItem from '@theme/TabItem';
9-
10-
<Tabs>
11-
<TabItem value="interface" label="܀ Interface" default>
12-
139
```fortran
1410
INTERFACE
1511
MODULE PURE FUNCTION BarycentricVertexBasis_Triangle(lambda) &
@@ -22,17 +18,21 @@ INTERFACE
2218
END INTERFACE
2319
```
2420

25-
</TabItem>
21+
:::info `lambda`
22+
Barycentric coordinates. The vertex basis function will be evaluated here. The number of rows in lambda is 3 and the number of columns is the number of points. The three rows of lambda dentoe the $\lambda_{i=1,2,3}$.
23+
:::
2624

27-
<TabItem value="example" label="️܀ See example">
25+
:::info `ans`
26+
The number of rows in `ans` is equal to the number of points of evaluation. The number of columns is 3. The three columns of `ans` denote the basis functions of vertex $v=1,2,3$ at all points.
27+
:::
2828

29-
import EXAMPLE29 from "./_BarycentricVertexBasis_Triangle_test_1.md";
29+
<details>
30+
<summary>Example</summary>
31+
<div>
3032

31-
<EXAMPLE29 />
32-
33-
</TabItem>
33+
import EXAMPLE29 from "./examples/_BarycentricVertexBasis_Triangle_test_1.md";
3434

35-
<TabItem value="close" label="">
35+
<EXAMPLE29 />
3636

37-
</TabItem>
38-
</Tabs>
37+
</div>
38+
</details>

docs/docs-api/TriangleInterpolationUtility/Dubiner_Triangle.md

+31-21
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,40 @@
1-
# Dubiner
1+
# Dubiner_Triangle
22

3-
Forms Dubiner basis on reference triangle domain.
3+
<!-- markdownlint-disable MD041 MD013 MD033 MD012 -->
44

5-
Reference triangle can be "biunit" or "unit".
5+
Forms Dubiner basis on reference triangle domain. Reference triangle can be "biunit" or "unit".
66

7-
The shape of `ans` is (M,N), where M=SIZE(xij,2) (number of points) N = 0.5*(order+1)*(order+2).
7+
:::note It is alias to `OrothogonalBasis_Triangle` method.
8+
:::
9+
10+
The shape of `ans` is (M,N), where `M=SIZE(xij,2)` (number of points) `N = 0.5*(order+1)*(order+2)`.
11+
12+
- `M` number of points of evaluations.
13+
- `N` number of degrees of freedom for a given order of approximation.
814

915
In this way, `ans(j,:)` denotes the values of all polynomial at jth point.
1016

1117
Polynomials are returned in following way:
1218

1319
$$
14-
P_{0,0}, P_{0,1}, \cdots , P_{0,order} \\
15-
P_{1,0}, P_{1,1}, \cdots , P_{1,order-1} \\
16-
P_{2,0}, P_{2,1}, \cdots , P_{2,order-2} \\
17-
\cdots
18-
P_{order,0}
20+
P_{0,0}, P_{0,1}, \cdots , P_{0,order} \\
21+
P_{1,0}, P_{1,1}, \cdots , P_{1,order-1} \\
22+
P_{2,0}, P_{2,1}, \cdots , P_{2,order-2} \\
23+
\cdots
24+
P_{order,0}
1925
$$
2026

2127
For example for order=3, the polynomials are arranged as:
2228

2329
$$
24-
P_{0,0}, P_{0,1}, P_{0,2}, P_{0,3} \\
25-
P_{1,0}, P_{1,1}, P_{1,2} \\
26-
P_{2,0}, P_{2,1} \\
27-
P_{3,0}
30+
P_{0,0}, P_{0,1}, P_{0,2}, P_{0,3} \\
31+
P_{1,0}, P_{1,1}, P_{1,2} \\
32+
P_{2,0}, P_{2,1} \\
33+
P_{3,0}
2834
$$
2935

3036
## Interface 1
3137

32-
import Tabs from '@theme/Tabs';
33-
import TabItem from '@theme/TabItem';
34-
3538
<Tabs>
3639
<TabItem value="interface" label="܀ Interface" default>
3740

@@ -44,8 +47,8 @@ INTERFACE
4447
!! points in reference triangle, shape functions will be evaluated
4548
!! at these points. SIZE(xij,1) = 2, and SIZE(xij, 2) = number of points
4649
CHARACTER(*), INTENT(IN) :: refTriangle
47-
!! "unit"
48-
!! "biunit"
50+
!! "UNIT"
51+
!! "BIUNIT"
4952
REAL(DFP) :: ans(SIZE(xij, 2), (order + 1)* (order + 2) / 2)
5053
!! shape functions
5154
!! ans(:, j), jth shape functions at all points
@@ -54,19 +57,23 @@ INTERFACE
5457
END INTERFACE
5558
```
5659

60+
:::info `xij`
61+
Points in reference triangle, shape functions will be evaluated at these points. SIZE(xij,1) = 2, and SIZE(xij, 2) = number of points
62+
:::
63+
5764
</TabItem>
5865

5966
<TabItem value="example" label="️܀ order=1">
6067

61-
import EXAMPLE61 from "./_Dubiner_Triangle_test_1.md";
68+
import EXAMPLE61 from "./examples/_Dubiner_Triangle_test_1.md";
6269

6370
<EXAMPLE61 />
6471

6572
</TabItem>
6673

6774
<TabItem value="example2" label="️܀ order=2">
6875

69-
import EXAMPLE100 from "./_Dubiner_Triangle_test_2.md";
76+
import EXAMPLE100 from "./examples/_Dubiner_Triangle_test_2.md";
7077

7178
<EXAMPLE100 />
7279

@@ -100,7 +107,10 @@ INTERFACE
100107
END INTERFACE
101108
```
102109

103-
Forms Dubiner basis on reference triangle domain. Reference triangle can be biunit or unit. Here x and y are the coordinates on the line. xij is given by outerproduct of x and y.
110+
- Forms Dubiner basis on the reference triangle domain.
111+
- Reference triangle can be biunit or unit.
112+
- Here x and y are the coordinates on the line. `xij` is given by outer-product of `x` and `y`.
113+
104114
</TabItem>
105115

106116
<TabItem value="close" label="">

docs/docs-api/TriangleInterpolationUtility/EquidistanceInPoint_Triangle.md

+4-5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
# EquidistanceInPoint
1+
# EquidistanceInPoint_Triangle
2+
3+
<!-- markdownlint-disable MD041 MD013 MD033 MD012 -->
24

35
This function returns the equidistance points in triangle.
46

@@ -7,9 +9,6 @@ This function returns the equidistance points in triangle.
79

810
## Interface
911

10-
import Tabs from '@theme/Tabs';
11-
import TabItem from '@theme/TabItem';
12-
1312
<Tabs>
1413
<TabItem value="interface" label="܀ Interface" default>
1514

@@ -32,7 +31,7 @@ END INTERFACE
3231

3332
<TabItem value="example" label="️܀ See example">
3433

35-
import EXAMPLE35 from "./_EquidistancePoint_Triangle_test_1.md";
34+
import EXAMPLE35 from "./examples/_EquidistanceInPoint_Triangle_test_1.md";
3635

3736
<EXAMPLE35 />
3837

docs/docs-api/TriangleInterpolationUtility/EquidistancePoint_Triangle.md

+22-14
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,25 @@
1-
# EquidistancePoint
1+
# EquidistancePoint_Triangle
22

3-
This function returns the nodal coordinates of higher order triangle element
3+
<!-- markdownlint-disable MD041 MD013 MD033 MD012 -->
44

5-
- the layout is always "VEFC"
5+
This function returns the nodal coordinates of higher order triangle element.
6+
7+
- the layout is always "VEFC", that is, the node numbering is according to GMSH convention, VEFC.
68
- coordinates are distributed uniformly
7-
- these coordinates can be used to construct lagrange polynomials
9+
- these coordinates can be used to construct Lagrange polynomials
810
- the returned coordinates are in $x_{iJ}$ format.
9-
- the node numbering is according to Gmsh convention, VEFC.
1011

11-
## Interface
12+
:::info `VEFC` layout
13+
14+
`VEFC` layout is a way to store the nodal coordinates of a triangle element. The layout is as follows:
1215

13-
import Tabs from '@theme/Tabs';
14-
import TabItem from '@theme/TabItem';
16+
- First we store the coordinates of the vertices.
17+
- Then we store the coordinates of the edge midpoints.
18+
- Finally we store the coordinates of the face center.
19+
20+
:::
21+
22+
## Interface
1523

1624
<Tabs>
1725
<TabItem value="interface" label="܀ Interface" default>
@@ -20,13 +28,13 @@ import TabItem from '@theme/TabItem';
2028
INTERFACE
2129
MODULE RECURSIVE PURE FUNCTION EquidistancePoint_Triangle(order, xij) RESULT(ans)
2230
INTEGER(I4B), INTENT(IN) :: order
23-
!! order
31+
!! order
2432
REAL(DFP), OPTIONAL, INTENT(IN) :: xij(:, :)
25-
!! coordinates of point 1 and point 2 in $x_{iJ}$ format
26-
!! number of rows = nsd
27-
!! number of cols = 3
33+
!! coordinates of point 1 and point 2 in $x_{iJ}$ format
34+
!! number of rows = nsd
35+
!! number of cols = 3
2836
REAL(DFP), ALLOCATABLE :: ans(:, :)
29-
!! returned coordinates in $x_{iJ}$ format
37+
!! returned coordinates in $x_{iJ}$ format
3038
END FUNCTION EquidistancePoint_Triangle
3139
END INTERFACE
3240
```
@@ -35,7 +43,7 @@ END INTERFACE
3543

3644
<TabItem value="example" label="️܀ See example">
3745

38-
import EXAMPLE38 from "./_EquidistancePoint_Triangle_test_1.md";
46+
import EXAMPLE38 from "./examples/_EquidistancePoint_Triangle_test_1.md";
3947

4048
<EXAMPLE38 />
4149

docs/docs-api/TriangleInterpolationUtility/HeirarchicalBasis_Triangle.md

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
1-
# HeirarchicalBasis
1+
# HeirarchicalBasis_Triangle
2+
3+
<!-- markdownlint-disable MD041 MD013 MD033 MD012 -->
24

35
Evaluate all modal basis (heirarchical polynomial) on Triangle.
46

5-
# Interface
7+
## Interface
68

79
import Tabs from '@theme/Tabs';
810
import TabItem from '@theme/TabItem';

0 commit comments

Comments
 (0)