Skip to content

Commit 5d2b421

Browse files
committed
Clean up code formatting
1 parent 7fd7a6e commit 5d2b421

File tree

6 files changed

+16
-17
lines changed

6 files changed

+16
-17
lines changed

dist/feascript.cjs.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/feascript.esm.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/feascript.umd.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
"finite element",
3030
"simulation",
3131
"javascript",
32-
"web",
3332
"FEA",
3433
"FEM",
3534
"finite element analysis",

src/models/flowBoundaryConditions.js

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ export class FlowBoundaryConditions {
3333
elementOrder,
3434
totalNodesVelocity,
3535
totalNodesPressure,
36-
q2ToPressureMap
36+
q2ToPressureMap,
3737
) {
3838
this.boundaryConditions = boundaryConditions;
3939
this.boundaryElements = boundaryElements;
@@ -58,11 +58,11 @@ export class FlowBoundaryConditions {
5858
* classic stiffness/conductivity matrix and `residualVector`
5959
* corresponds to the traditional load (RHS) vector.
6060
*
61-
* Supported boundary condition types:
62-
* - "constantVelocity": Set velocity components at boundary nodes
63-
* Format: ["constantVelocity", uValue, vValue]
64-
* - "stressFree": Natural boundary condition (zero traction), no assembly needed
65-
* Format: ["stressFree"]
61+
* Supported boundary condition types:
62+
* - "constantVelocity": Set velocity components at boundary nodes
63+
* Format: ["constantVelocity", uValue, vValue]
64+
* - "stressFree": Natural boundary condition (zero traction), no assembly needed
65+
* Format: ["stressFree"]
6666
*/
6767
imposeDirichletBoundaryConditions(residualVector, jacobianMatrix) {
6868
const totalDOFs = residualVector.length;
@@ -80,7 +80,7 @@ export class FlowBoundaryConditions {
8080
const uValue = this.boundaryConditions[boundaryKey][1];
8181
const vValue = this.boundaryConditions[boundaryKey][2];
8282
debugLog(
83-
`Boundary ${boundaryKey}: Applying constant velocity condition (u=${uValue}, v=${vValue})`
83+
`Boundary ${boundaryKey}: Applying constant velocity condition (u=${uValue}, v=${vValue})`,
8484
);
8585
this.boundaryElements[boundaryKey].forEach(([elementIndex, side]) => {
8686
if (this.elementOrder === "quadratic") {
@@ -97,7 +97,7 @@ export class FlowBoundaryConditions {
9797
debugLog(
9898
` - Applied velocity Dirichlet to node ${globalNodeIndex + 1} (element ${
9999
elementIndex + 1
100-
}, local node ${nodeIndex + 1})`
100+
}, local node ${nodeIndex + 1})`,
101101
);
102102
// Apply u-velocity Dirichlet boundary condition
103103
residualVector[uDOF] = uValue;
@@ -127,7 +127,7 @@ export class FlowBoundaryConditions {
127127
debugLog(
128128
` - Applied velocity Dirichlet to node ${globalNodeIndex + 1} (element ${
129129
elementIndex + 1
130-
}, local node ${nodeIndex + 1})`
130+
}, local node ${nodeIndex + 1})`,
131131
);
132132
// Apply u-velocity Dirichlet boundary condition
133133
residualVector[uDOF] = uValue;

src/models/stokesScript.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ export function assembleStokesMatrix(meshData, boundaryConditions) {
9696
const totalDOFs = 2 * totalNodesVelocity + totalNodesPressure;
9797

9898
debugLog(
99-
`Stokes DOFs: ${totalNodesVelocity} velocity nodes (Q2), ${totalNodesPressure} pressure nodes (Q1), ${totalDOFs} total DOFs`
99+
`Stokes DOFs: ${totalNodesVelocity} velocity nodes (Q2), ${totalNodesPressure} pressure nodes (Q1), ${totalDOFs} total DOFs`,
100100
);
101101

102102
// Initialize Jacobian matrix and residual vector
@@ -154,13 +154,13 @@ export function assembleStokesMatrix(meshData, boundaryConditions) {
154154
// Get velocity (Q2) basis functions for the current Gauss point
155155
const velocityBasisFunctionsAndDerivatives = velocityBasisFunctions.getBasisFunctions(
156156
gaussPoints[gaussPointIndex1],
157-
gaussPoints[gaussPointIndex2]
157+
gaussPoints[gaussPointIndex2],
158158
);
159159

160160
// Get pressure (Q1) basis functions for the current Gauss point
161161
const pressureBasisFunctionsAndDerivatives = pressureBasisFunctions.getBasisFunctions(
162162
gaussPoints[gaussPointIndex1],
163-
gaussPoints[gaussPointIndex2]
163+
gaussPoints[gaussPointIndex2],
164164
);
165165

166166
// Perform isoparametric mapping using Q2 velocity basis functions
@@ -241,7 +241,7 @@ export function assembleStokesMatrix(meshData, boundaryConditions) {
241241
elementOrder,
242242
totalNodesVelocity,
243243
totalNodesPressure,
244-
q2ToPressureMap
244+
q2ToPressureMap,
245245
);
246246

247247
flowBoundaryConditions.imposeDirichletBoundaryConditions(residualVector, jacobianMatrix);

0 commit comments

Comments
 (0)