You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: 35_Plugins/50_Usual_plugins/80_MultiThreading.md
-102Lines changed: 0 additions & 102 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,108 +14,6 @@ This pipeline requires two components for the [broad phase](../../../components/
14
14
A usual choice is [BruteForceBroadPhase](../../../components/collision/detection/algorithm/bruteforcebroadphase/) for the broad phase, and [BVHNarrowPhase](../../../components/collision/detection/algorithm/bvhnarrowphase/) for the narrow phase.
15
15
Both of these components can be replaced with a parallel version from the MultiThreading plugin.
16
16
17
-
### ParallelBruteForceBroadPhase
18
-
19
-
This component is a parallel implementation of [BruteForceBroadPhase](../../../components/collision/detection/algorithm/bruteforcebroadphase/) using a global thread pool.
20
-
It means the result of a simulation with [BruteForceBroadPhase](../../../components/collision/detection/algorithm/bruteforcebroadphase/) or with ParallelBruteForceBroadPhase is expected to be equal.
21
-
ParallelBruteForceBroadPhase is the most efficient compared to [BruteForceBroadPhase](../../../components/collision/detection/algorithm/bruteforcebroadphase/) when there is a lot of objects in the scene.
22
-
23
-
#### Examples
24
-
25
-
Examples of ParallelBruteForceBroadPhase can be found in:
This component is a parallel implementation of [BVHNarrowPhase](../../../components/collision/detection/algorithm/bvhnarrowphase/) using a global thread pool.
34
-
It means the result of a simulation with [BVHNarrowPhase](../../../components/collision/detection/algorithm/bvhnarrowphase/) or with ParallelBVHNarrowPhase is expected to be equal.
35
-
36
-
#### Examples
37
-
38
-
Examples of ParallelBruteForceBroadPhase can be found in:
ParallelTetrahedronFEMForceField is the multi-threaded equivalent of [TetrahedronFEMForceField](../../../components/solidmechanics/fem/elastic/tetrahedronfemforcefield).
51
-
52
-
This implementation is the most efficient when the number of tetrahedron is large (> 1000).
53
-
54
-
The following methods are executed in parallel:
55
-
-`addDForce`
56
-
-`addKToMatrix`
57
-
58
-
#### Examples
59
-
60
-
Examples of ParallelTetrahedronFEMForceField can be found in:
ParallelHexahedronFEMForceField is the multi-threaded equivalent of [HexahedronFEMForceField](../../../components/solidmechanics/fem/elastic/hexahedronfemforcefield).
67
-
68
-
This implementation is the most efficient when:
69
-
70
-
1) the number of hexahedron is large (> 1000)
71
-
2) the global system matrix is not assembled. It is usually the case with a [CGLinearSolver](../../../components/linearsolver/iterative/cglinearsolver/) templated with GraphScattered types.
72
-
3) the method is 'large'. If the method is 'polar' or 'small', `addForce` is executed sequentially, but `addDForce` in parallel.
73
-
74
-
The following methods are executed in parallel:
75
-
76
-
-`addForce` for method 'large'.
77
-
-`addDForce`
78
-
79
-
The method `addKToMatrix` is not executed in parallel.
80
-
This method is called with an assembled system, usually with a direct solver or a [CGLinearSolver](../../../components/linearsolver/iterative/cglinearsolver/) templated with types different from GraphScattered.
81
-
In this case, the most time-consuming step is to invert the matrix. This is where efforts should be put to accelerate the simulation.
82
-
83
-
#### Examples
84
-
85
-
Examples of ParallelHexahedronFEMForceField can be found in:
This component inherits all the functionality from the BeamLinearMapping component and overrides three virtual functions that contain a `for` loop: `apply()`, `applyJ()` and `applyJT()`.
92
-
It adds only one data attribute, the granularity. This attribute sets the number of iterations of the `for` loop, corresponding to the number of points along the beam elements that must be assigned and executed for each task.
93
-
If this number is lower than the number of iterations the loop won't be parallelized, and the corresponding BeamLinearMapping function is called.
94
-
If this number is greater than the number of iterations of the loop the tasks are created, and each task executes the granularity value of iterations of the loop.
This component inherits all the functionality from the BeamLinearMapping component and overrides three virtual functions that contain a `for` loop: `apply()`, `applyJ()` and `applyJT()`.
4
+
It adds only one data attribute, the granularity. This attribute sets the number of iterations of the `for` loop, corresponding to the number of points along the beam elements that must be assigned and executed for each task.
5
+
If this number is lower than the number of iterations the loop won't be parallelized, and the corresponding BeamLinearMapping function is called.
6
+
If this number is greater than the number of iterations of the loop the tasks are created, and each task executes the granularity value of iterations of the loop.
This component is a parallel implementation of [BVHNarrowPhase](../../../../components/collision/detection/algorithm/bvhnarrowphase/) using a global thread pool.
4
+
It means the result of a simulation with [BVHNarrowPhase](../../../../components/collision/detection/algorithm/bvhnarrowphase/) or with ParallelBVHNarrowPhase is expected to be equal.
This component is a parallel implementation of [BruteForceBroadPhase](../../../../components/collision/detection/algorithm/bruteforcebroadphase/) using a global thread pool.
4
+
It means the result of a simulation with [BruteForceBroadPhase](../../../../components/collision/detection/algorithm/bruteforcebroadphase/) or with ParallelBruteForceBroadPhase is expected to be equal.
5
+
ParallelBruteForceBroadPhase is the most efficient compared to [BruteForceBroadPhase](../../../../components/collision/detection/algorithm/bruteforcebroadphase/) when there is a lot of objects in the scene.
ParallelHexahedronFEMForceField is the multi-threaded equivalent of [HexahedronFEMForceField](../../../../components/solidmechanics/fem/elastic/hexahedronfemforcefield).
4
+
5
+
This implementation is the most efficient when:
6
+
7
+
1) the number of hexahedron is large (> 1000)
8
+
2) the global system matrix is not assembled. It is usually the case with a [CGLinearSolver](../../../../components/linearsolver/iterative/cglinearsolver/) templated with GraphScattered types.
9
+
3) the method is 'large'. If the method is 'polar' or 'small', `addForce` is executed sequentially, but `addDForce` in parallel.
10
+
11
+
The following methods are executed in parallel:
12
+
13
+
-`addForce` for method 'large'.
14
+
-`addDForce`
15
+
16
+
The method `addKToMatrix` is not executed in parallel.
17
+
This method is called with an assembled system, usually with a direct solver or a [CGLinearSolver](../../../../components/linearsolver/iterative/cglinearsolver/) templated with types different from GraphScattered.
18
+
In this case, the most time-consuming step is to invert the matrix. This is where efforts should be put to accelerate the simulation.
ParallelTetrahedronFEMForceField is the multi-threaded equivalent of [TetrahedronFEMForceField](../../../../components/solidmechanics/fem/elastic/tetrahedronfemforcefield).
4
+
5
+
This implementation is the most efficient when the number of tetrahedron is large (> 1000).
0 commit comments