Skip to content

Commit 4228762

Browse files
committed
Update README files for heat conduction examples to enhance clarity and structure
1 parent 618c572 commit 4228762

File tree

3 files changed

+51
-58
lines changed

3 files changed

+51
-58
lines changed
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
<img src="https://feascript.github.io/FEAScript-website/assets/FEAScriptHeatTransfer.png" width="80" alt="FEAScript Logo">
2+
3+
# Heat Conduction Examples
4+
5+
This directory contains Node.js examples demonstrating how to use the FEAScript library to solve steady-state heat conduction problems.
6+
7+
## Examples
8+
9+
#### 1. Heat Conduction Through a Wall
10+
11+
This example demonstrates a heat flow case through a building wall. For detailed information on the model setup refer to the corresponding [tutorial](https://feascript.com/tutorials/HeatConduction1DWall.html) in the FEAScript website.
12+
13+
#### 2. Heat Conduction in a 2D Fin
14+
15+
This example demonstrates a typical cooling fin scenario. There are two Node.js implementations:
16+
17+
#### i. Standard Version (`heatConduction2DFin.js`)
18+
19+
Basic implementation using the FEAScriptModel class
20+
21+
#### ii. Gmsh Version (`heatConduction2DFinGmsh.js`)
22+
23+
Implementation using an unstructured mesh generated by [Gmsh](https://gmsh.info/) (the mesh file, `rect_quad_unstruct.msh`, is also located in the current directory). For detailed information on the model setup refer to the corresponding [tutorial](https://feascript.com/tutorials/HeatConduction2DFin.html) in the FEAScript website.
24+
25+
## Running the Examples
26+
27+
#### 1. Create package.json with ES module support:
28+
29+
```bash
30+
echo '{"type":"module"}' > package.json
31+
```
32+
33+
#### 2. Install dependencies:
34+
35+
```bash
36+
npm install feascript mathjs
37+
```
38+
39+
#### 3. Run the example:
40+
41+
```bash
42+
node HeatConduction1DWall.js
43+
```
44+
45+
(for the "Heat Conduction Through a Wall" case)

examples/heatConductionScript/heatConduction1DWall/README.md

Lines changed: 1 addition & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -2,27 +2,4 @@
22

33
## Heat Conduction Through a Wall
44

5-
This example demonstrates solving a steady-state heat transfer problem in a 1D domain using the FEAScript library. The problem represents heat flow through a building wall, where heat conduction is modeled to determine temperature profiles under specific boundary conditions.
6-
7-
### Instructions
8-
9-
The example requires the `feascript` npm package and its peer dependencies (`mathjs`). It imports FEAScript directly from the npm package and runs the simulation in a Node.js environment, making it suitable for server-side applications or local development without a browser (no WEB APIs here). To run the example you should follow these instructions:
10-
11-
1. **Create package.json with ES module support:**
12-
13-
```bash
14-
echo '{"type":"module"}' > package.json
15-
```
16-
17-
2. **Install dependencies:**
18-
19-
```bash
20-
npm install feascript mathjs
21-
```
22-
23-
3. **Run the example:**
24-
```bash
25-
node HeatConduction1DWall.js
26-
```
27-
28-
**Note:** For detailed information on the model setup, boundary conditions, and simulation results, refer to the comments in the JavaScript files and the corresponding [tutorial](https://feascript.com/tutorials/HeatConduction1DWall.html).
5+
This example demonstrates a heat flow case through a building wall. For detailed information on the model setup refer to the corresponding [tutorial](https://feascript.com/tutorials/HeatConduction1DWall.html) in the FEAScript website.

examples/heatConductionScript/heatConduction2DFin/README.md

Lines changed: 5 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -2,41 +2,12 @@
22

33
## Heat Conduction in a 2D Fin
44

5-
This example demonstrates solving a steady-state heat transfer problem in a 2D rectangular domain using the FEAScript library. The problem represents a typical cooling fin scenario, where the objective is to model heat conduction and understand temperature distribution under specific boundary conditions.
5+
This example demonstrates a typical cooling fin scenario. There are two Node.js implementations:
66

7-
### Available Versions
7+
#### i. Standard Version (`heatConduction2DFin.js`)
88

9-
This example is available in two Node.js implementations:
9+
Basic implementation using the FEAScriptModel class
1010

11-
1. **Standard Version** (`heatConduction2DFin.js`) - Basic implementation using the FEAScriptModel class
12-
2. **Gmsh Version** (`heatConduction2DFinGmsh.js`) - Implementation using an unstructured mesh generated by [Gmsh](https://gmsh.info/) (the mesh file, `rect_quad_unstruct.msh`, is also located in the current directory)
11+
#### ii. Gmsh Version (`heatConduction2DFinGmsh.js`)
1312

14-
### Instructions
15-
16-
The examples require the `feascript` npm package and its peer dependencies (`mathjs`). They import FEAScript directly from the npm package and run the simulations in a Node.js environment, making them suitable for server-side applications or local development without a browser (no WEB APIs here). To run the examples, follow these instructions:
17-
18-
1. **Create package.json with ES module support:**
19-
20-
```bash
21-
echo '{"type":"module"}' > package.json
22-
```
23-
24-
2. **Install dependencies:**
25-
26-
```bash
27-
npm install feascript mathjs
28-
```
29-
30-
3. **Run the desired version:**
31-
32-
```bash
33-
node HeatConduction2DFin.js
34-
```
35-
36-
or
37-
38-
```bash
39-
node HeatConduction2DFinGmsh.js
40-
```
41-
42-
**Note:** For detailed information on the model setup, boundary conditions, and simulation results, refer to the comments in the JavaScript files and the corresponding standard [tutorial](https://feascript.com/tutorials/HeatConduction2DFin.html) as well as to the Gmsh mesh [tutorial](https://feascript.com/tutorials/HeatConduction2DFinGmsh.html).
13+
Implementation using an unstructured mesh generated by [Gmsh](https://gmsh.info/) (the mesh file, `rect_quad_unstruct.msh`, is also located in the current directory). For detailed information on the model setup refer to the corresponding [tutorial](https://feascript.com/tutorials/HeatConduction2DFin.html) in the FEAScript website.

0 commit comments

Comments
 (0)