# Problems with PaStiX solver and shell elements

**URL:** <https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169>\
**Category:** Uncategorized\
**Created:** [July 20, 2022, 3:40pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169 "2022-07-20T15:40:22Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![Matej](https://avatars.discourse-cdn.com/v4/letter/m/a698b9/32.png) [@Matej](https://calculix.discourse.group/u/Matej)\
**Post date:** [July 20, 2022, 3:40pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/1 "2022-07-20T15:40:22Z")

</div>

I prepared a simple model to demonstrate the wrong results when using the PaStiX solver from the official CalculiX version 2.19 for Windows: file ccx\_static.exe (the same also goes for version 2.18).

The model is a simple I-profile meshed using parabolic triangular shell elements. It is fixed on all edges on the left side and loaded with a distributed force - pressure as shown in the image.

 ![image](https://global.discourse-cdn.com/free1/uploads/calculix/original/1X/15ef8b764b1dbbf4388d3ac8bd01d2a1e9858709.jpeg)

When using the Spooles solver with the keyword: \*Static, Solver=Spooles the results are as expected and are shown in the following image:

 ![image](https://global.discourse-cdn.com/free1/uploads/calculix/original/1X/b128079b9cfdfd785a37f0e3bf927e99a6faeaab.png)

But if the solver is switched for PaStiX with the keyword: \*Static, Solver=PaStiX, the results are completely wrong and are shown in the following image:

 ![image](https://global.discourse-cdn.com/free1/uploads/calculix/original/1X/f8c89626c1afd1d9a4a874a633599661c7b1b634.jpeg)

The model with the Spooles solver can be downloaded from: [Profile.inp](https://univerzamb-my.sharepoint.com/:u:/g/personal/matej_borovinsek_um_si/EWBjxH12vWxDjtQ24O19IGYB197OKMVEAAlnsoSrLhQeJg?e=VmB0oh)

When using linear triangular shell elements, both solvers produce the same results. When using different mesh densities, the results are sometimes the same but sometimes they are different as in the shown example.

Can someone confirm this behaviour on Windows and on Linux.

---

<div class="post-metadata">

**Author:** ![Calc\_em](https://avatars.discourse-cdn.com/v4/letter/c/43a26b/32.png) [@Calc\_em](https://calculix.discourse.group/u/Calc_em)\
**Post date:** [July 20, 2022, 5:29pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/2 "2022-07-20T17:29:25Z")

</div>

Strange, I can’t confirm this. I downloaded your input file and submitted it without changes using 2.19 on Windows. Then I just changed \*Static, solver=Spooles to \*Static, solver=PaStiX. The results were pretty much the same (with insignificant differences in the second decimal place). No such distortions like in your third picture. Pardiso also provided correct results. Maybe it’s a bug that occurs occasionally.

---

<div class="post-metadata">

**Author:** ![xyont](https://yyz2.discourse-cdn.com/free1/user_avatar/calculix.discourse.group/xyont/32/3553_2.png) [@xyont](https://calculix.discourse.group/u/xyont)\
**Post date:** [July 20, 2022, 7:01pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/3 "2022-07-20T19:01:08Z")

</div>

> [@Matej](#):
>
> Can someone confirm this behaviour on Windows and on Linux.

i can confirm, it has produced different results for PaStiX solver. try modified the element with composite (2 layers), still yield the unexpected results.

 ![2022-07-21 01_50_03-CalculiX GraphiX](https://global.discourse-cdn.com/free1/uploads/calculix/original/1X/d70c045b5e1684ef3a8b34a865ba2d8d464623fb.png)

i only guess this problem occurs due to coarseness of the mesh. only one element match the knot positions. but, did not know why Spooles solver gave better results.

---

<div class="post-metadata">

**Author:** ![JWilliams](https://avatars.discourse-cdn.com/v4/letter/j/c2a13f/32.png) [@JWilliams](https://calculix.discourse.group/u/JWilliams)\
**Post date:** [July 20, 2022, 7:46pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/4 "2022-07-20T19:46:21Z")

</div>

Hello @Matej,

Just for the fun of it, I had a go using CalculiX on my Mac with Intel Pardiso. Please see the screenshot below. I have not had much luck with PaStiX and default to the Intel Pardiso solver 😅. Has anyone thought about using MUMPS ([http://mumps.enseeiht.fr](http://mumps.enseeiht.fr))?

 ![Screenshot 2022-07-20 at 3.34.56 PM](https://global.discourse-cdn.com/free1/uploads/calculix/original/1X/a2be74f3bd7e099fa64deb93a3e3091cba707307.jpeg)

Best wishes,  
JW

---

<div class="post-metadata">

**Author:** ![rafal.brzegowy](https://avatars.discourse-cdn.com/v4/letter/r/a9adbd/32.png) [@rafal.brzegowy](https://calculix.discourse.group/u/rafal.brzegowy)\
**Post date:** [July 21, 2022, 7:10am UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/5 "2022-07-21T07:10:06Z")

</div>

Try with this:  
\*Static, Solver=PaStiX  
1.,1.  
\*\*

---

<div class="post-metadata">

**Author:** ![Matej](https://avatars.discourse-cdn.com/v4/letter/m/a698b9/32.png) [@Matej](https://calculix.discourse.group/u/Matej)\
**Post date:** [July 21, 2022, 10:31am UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/6 "2022-07-21T10:31:16Z")

</div>

> [@rafal.brzegowy](#):
>
> Try with this:  
> \*Static, Solver=PaStiX  
> 1.,1.

I have tried using the proposed method, but it has no effect. Now I tried running the .inp file from the command line and got different results than previously when the analysis was started from PrePoMax. Strange. But both cases with and without the added line (1.,1.) give the same results as shown in the image.

 ![image](https://global.discourse-cdn.com/free1/uploads/calculix/original/1X/74f89481c557071d8b29f1e40d8d21d7bb028b57.png)

By the way, I am using AMD Ryzen 5 5600X 6-Core CPU. I have some other computers with different CPUs that I will try and post the results.

---

<div class="post-metadata">

**Author:** ![rafal.brzegowy](https://avatars.discourse-cdn.com/v4/letter/r/a9adbd/32.png) [@rafal.brzegowy](https://calculix.discourse.group/u/rafal.brzegowy)\
**Post date:** [July 21, 2022, 1:43pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/7 "2022-07-21T13:43:22Z")

</div>

I think that’s it:

set PASTIX\_MIXED\_PRECISION=0

---

<div class="post-metadata">

**Author:** ![xyont](https://yyz2.discourse-cdn.com/free1/user_avatar/calculix.discourse.group/xyont/32/3553_2.png) [@xyont](https://calculix.discourse.group/u/xyont)\
**Post date:** [July 21, 2022, 2:55pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/8 "2022-07-21T14:55:33Z")

</div>

> [@rafal.brzegowy](#):
>
> set PASTIX\_MIXED\_PRECISION=0

modified these setting for bConverged distribution at:  
C:\Program Files (x86)\bConverged\common\site\cmdStartup.bat

solved the problems here on Intel processor type.

 ![2022-07-21 21_50_41-CalculiX GraphiX](https://global.discourse-cdn.com/free1/uploads/calculix/original/1X/8855fa3a4c54da79b8a5ff7ec6be39091d6d124e.png)

---

<div class="post-metadata">

**Author:** ![Disla](https://yyz2.discourse-cdn.com/free1/user_avatar/calculix.discourse.group/disla/32/3548_2.png) [@Disla](https://calculix.discourse.group/u/Disla)\
**Post date:** [July 21, 2022, 4:31pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/9 "2022-07-21T16:31:22Z")

</div>

In my computer results are correct.  
AMD Ryzen 9 5900HX + Pastix Static & Dynamic with or without mixed precision doesn’t change the result.

 ![screenshot.1](https://global.discourse-cdn.com/free1/uploads/calculix/original/1X/03713662d2a1838383ab8b6a13ac3f5696239461.png)

Not reusing csc.  
±------------------------------------------------+

- 

```
PaStiX : Parallel Sparse matriX package +

```

±------------------------------------------------+  
Version: 6.0.1  
Schedulers:  
sequential: Enabled  
thread static: Started  
thread dynamic: Disabled  
PaRSEC: Disabled  
StarPU: Disabled  
Number of MPI processes: 1  
Number of threads per process: 12  
Number of GPUs: 0  
MPI communication support: Disabled  
Distribution level: 2D( 256)  
Blocking size (min/max): 1024 / 2048

Matrix type: General  
Arithmetic: Double  
Format: CSC  
N: 2231  
nnz: 166589

±------------------------------------------------+  
Ordering step :  
Ordering method is: Scotch  
Time to compute ordering: 0.0014

---

<div class="post-metadata">

**Author:** ![lucas\_bueno](https://yyz2.discourse-cdn.com/free1/user_avatar/calculix.discourse.group/lucas_bueno/32/1595_2.png) [@lucas\_bueno](https://calculix.discourse.group/u/lucas_bueno)\
**Post date:** [July 21, 2022, 5:46pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/10 "2022-07-21T17:46:30Z")

</div>

No problems here as well. I’m using Windows 10 with Intel i7-8750H as the processor.

 ![image](https://global.discourse-cdn.com/free1/uploads/calculix/original/1X/0c89e3f4998c9d5e2b5eaa7b7ad72198e00ba0fa.png)

---

<div class="post-metadata">

**Author:** ![Matej](https://avatars.discourse-cdn.com/v4/letter/m/a698b9/32.png) [@Matej](https://calculix.discourse.group/u/Matej)\
**Post date:** [July 21, 2022, 7:52pm UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/11 "2022-07-21T19:52:53Z")

</div>

> [@rafal.brzegowy](#):
>
> set PASTIX\_MIXED\_PRECISION=0

That setting solved the problem. Thank you! That is really helpful. If I understand correctly, this setting does not interfere with other solvers, so I could enable it every time the PaStiX solver is used?

Is it faster when the mixed\_precision=1?

---

<div class="post-metadata">

**Author:** ![prop\_design](https://yyz2.discourse-cdn.com/free1/user_avatar/calculix.discourse.group/prop_design/32/197_2.png) [@prop\_design](https://calculix.discourse.group/u/prop_design)\
**Post date:** [July 22, 2022, 12:08am UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/12 "2022-07-22T00:08:25Z")

</div>

I was previously told to use PASTIX\_MIXED\_PRECISION=1. Does anyone know the difference between setting that from 1 to 0. Which is best to use?

---

<div class="post-metadata">

**Author:** ![xyont](https://yyz2.discourse-cdn.com/free1/user_avatar/calculix.discourse.group/xyont/32/3553_2.png) [@xyont](https://calculix.discourse.group/u/xyont)\
**Post date:** [July 22, 2022, 12:26am UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/13 "2022-07-22T00:26:11Z")

</div>

> [@prop\_design](#):
>
> Which is best to use?

looking the [table](https://calculix.discourse.group/t/calculix-and-pastix-solver-windows-version/130/16) comparison from @rafal.brzegowy setiing to ‘1’ is better in computational times.

---

<div class="post-metadata">

**Author:** ![Disla](https://yyz2.discourse-cdn.com/free1/user_avatar/calculix.discourse.group/disla/32/3548_2.png) [@Disla](https://calculix.discourse.group/u/Disla)\
**Post date:** [July 22, 2022, 7:03am UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/14 "2022-07-22T07:03:36Z")

</div>

@prop_design

Novel approach to exploit mixed precision arithmetic . The approach is based on the observation that singular vectors associated with small singular values can be stored in lower precisions while preserving high accuracy overall.

[https://hal.archives-ouvertes.fr/hal-03251738v1/document](https://hal.archives-ouvertes.fr/hal-03251738v1/document)

---

<div class="post-metadata">

**Author:** ![Matej](https://avatars.discourse-cdn.com/v4/letter/m/a698b9/32.png) [@Matej](https://calculix.discourse.group/u/Matej)\
**Post date:** [July 22, 2022, 9:25am UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/15 "2022-07-22T09:25:08Z")

</div>

> [@Disla](#):
>
> [https://hal.archives-ouvertes.fr/hal-03251738v1/document](https://hal.archives-ouvertes.fr/hal-03251738v1/document)

Wow, that is science 🙂

---

<div class="post-metadata">

**Author:** ![JuanP74](https://avatars.discourse-cdn.com/v4/letter/j/b5a626/32.png) [@JuanP74](https://calculix.discourse.group/u/JuanP74)\
**Post date:** [July 23, 2022, 8:17am UTC](https://calculix.discourse.group/t/problems-with-pastix-solver-and-shell-elements/1169/16 "2022-07-23T08:17:37Z")

</div>

I got similar results. cpu AMD A9-9420 RADEON R5, and with `set PASTIX_MIXED_PRECISION=0` issue is fixed.
