Problem with Matrix Algebra

Problem with Matrix Algebra - Messages

#1 Posted: 4/15/2012 3:00:40 PM
Martin Kraska

Martin Kraska

1222 likes in 2150 posts.

Group: Moderator

Hello,

I am using Smath for teaching Finite Element Analysis. The following file is an example for how to set up and solve an arbitrary plane (2D) truss structure in smath, including display of the deformed structure. However, there are some problems.

https://smath.com/wiki/GetFile.aspx?File=forum_attach%5cmkraska%5cFachwerk%20UE2.rar

Problem #1: The global system stiffness matrix KS is singular. However, Smath 0.93 and previous versions failed to compute the determinant directly with the error message "result is above max. allowed positive number". Of course, this can refer only to some intermediate result in the internal algorithm for computing the determinant.

This fails with the mentioned error message:
[MATH lang=eng]det(KS)=#@#[/MAT]

Scaling works:
[MATH lang=eng]det(KS/{1000*'kN/'cm})=0@#[/MAT]

Thus I propose to revise the determinant computing algorithm and replace it by some more robust one. Linpack/blas should do the job. I used these libraries when dealing with FEA fortran programming.

Problem #2: Starting with version 0.92 Smath fails to compute the solution, which involves the inversion of the reduced stiffness matrix K.r. Smath in version 0.92 and 0.93 complains about K.r being singular, whereas 0.91 does not.

In case these problems can be solved, I would be happy to translate the example to english or russian and contribute it to the examples section in the forum.

Best regards, Martin Kraska



Martin Kraska Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
#2 Posted: 4/15/2012 4:14:58 PM
Radovan Omorjan

Radovan Omorjan

325 likes in 2052 posts.

Group: Moderator

Hello Martin,

I do not know if this is something you could use but using Symboloc optimization you can have
[MATH=eng]det(KS)=0[/MATH]
The next matrix has the range less than the matrix dimension K.r(9x9) - Symbolic optimization again
[MATH=eng]rank(K.r)=6[/MATH]
Therefore there is no inverse matrix.

I hope this is of some help to you.

On the other hand, I agree and mentioned few times that SMath should have some numerical libraries incorporated. I really do not know what are the chances of this to be realized.

Regards,
Radovan
When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
#3 Posted: 4/15/2012 5:06:01 PM
Martin Kraska

Martin Kraska

1222 likes in 2150 posts.

Group: Moderator

Hello Radovan,

thank you for trying the example. I get the same result as you with symbolic optimization. BTW, I also get rank(KS)=8, which is as wrong (should be 9) as rank(K.r)=6. Otherwise version 0.91 would not be able to find a solution (which matches the ANSYS result and thus can be relied on).

The rank deficiency of the global stiffness is due to possible rigid body motions as KS represents the unconstrained system. System reduction due to dof constraints makes the displacement solution well defined and thus K.r is regular.

I consider the Smath 0.92 and 0.93 results being buggy.

btw: Any idea what went wrong with my initial post? I expected the expressions to be nicely formatted just like in your post. I obviously failed to follow the instructions in the wiki :-(

Best regards, Martin Kraska

Martin Kraska Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
#4 Posted: 4/16/2012 2:38:25 AM
kmihaylovich

kmihaylovich

8 likes in 131 posts.

Group: User

Wrote

btw: Any idea what went wrong with my initial post? I expected the expressions to be nicely formatted just like in your post. I obviously failed to follow the instructions in the wiki :-(


End tag should be [/MATH] instead of [/MAT]
#5 Posted: 5/20/2012 5:16:13 PM
Martin Kraska

Martin Kraska

1222 likes in 2150 posts.

Group: Moderator

Just tested with 0.94.xxxx, unfortunately linear algebra problem persists...
Determinant of KS can now be computed with scaling divisor of 10..100000

[MATH]det(KS/{100000*'kN/'cm})=0@#[/MATH]

Sorry for not being able to post the math expression correctly (used the bbcode tags from the editor menu and pasted from Smath via clipboard). I guess that this is my fault.


Wrote

Hello,

I am using Smath for teaching Finite Element Analysis. The following file is an example for how to set up and solve an arbitrary plane (2D) truss structure in smath, including display of the deformed structure. However, there are some problems.

https://smath.com/wiki/GetFile.aspx?File=forum_attach%5cmkraska%5cFachwerk%20UE2.rar

Problem #1: The global system stiffness matrix KS is singular. However, Smath 0.93 and previous versions failed to compute the determinant directly with the error message "result is above max. allowed positive number". Of course, this can refer only to some intermediate result in the internal algorithm for computing the determinant.

This fails with the mentioned error message:
[MATH lang=eng]det(KS)=#@#[/MATH]

Scaling works:
[MATH]det(KS/{1000*'kN/'cm})=0@#[/MATH]

Thus I propose to revise the determinant computing algorithm and replace it by some more robust one. Linpack/blas should do the job. I used these libraries when dealing with FEA fortran programming.

Problem #2: Starting with version 0.92 Smath fails to compute the solution, which involves the inversion of the reduced stiffness matrix K.r. Smath in version 0.92 and 0.93 complains about K.r being singular, whereas 0.91 does not.

In case these problems can be solved, I would be happy to translate the example to english or russian and contribute it to the examples section in the forum.

Best regards, Martin Kraska





Martin Kraska Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
  • New Posts New Posts
  • No New Posts No New Posts