cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Inverting a matrix does not invert the order of magnitude

reignofratch
6-Contributor

Inverting a matrix does not invert the order of magnitude

Hello, I am trying to invert a matrix to solve F=K*U in an FEA problem where F and K are known.

On paper this is solved by K^-1*F=U

 

All the units in K keep their same order of magnitude, which I believe is incorrect.

Multiple online calculators for inversing matrices give several very different answers so I no longer know what to believe.

 

My final answer for U is around 10^20 orders of magnitude higher that the expected value as shown below.

U values should be a 10^-3*m and 10^-1*rad or less.

 

I have attached the files as both pdf and mathcad prime express 4.0.

 

Please let me know what I am doing wrong.

1.PNG

 

11 REPLIES 11
LucMeekes
23-Emerald III
(To:reignofratch)

Please attach your worksheet.

{You have to ZIP it first, there's a bug on this forum that often causes a failure to attach a worksheet.

To zip, in Windows explorer select the worksheet file, then with the right-mous button select 'Send to'=> 'compressed (zipped) folder' the resulting .zip file can be attached.}

 

Luc

Thanks for the info, I have attached the zippped file.

Working in Prime 3.0:

minv.PNG

Could you explain what is different in your solution?

It seems like you used the same function on slightly rounded numbers and got a different  very answer.

Is my issue perhaps intrisic to 4.0?

LucMeekes
23-Emerald III
(To:reignofratch)

Your Kb matrix has zero values in the top-right and bottom-left corners. Fred's matrix has all non-zero values.

If I change the 1,5 and 5.1 elements in your K-matrix (the source) from 0 to 0.01 then all elements in the Kb matrix become non-zero and the results kb-1*Fb get into the range of 10^6 instead of 10^17...

I guess it's your data...

 

Success!

Luc

If the value is supposed to be 0 because those nodes share no interactions, should I just enter an extremely small number to just force the matrix inversion to work?

 

If so, is there any rule of thumb to choose an order of magnitude to enter?

LucMeekes
23-Emerald III
(To:reignofratch)

I did not say the matrix inversion doesn't work.

So far my conclusion is that your data results in high values.

 

Luc

 

LucMeekes
23-Emerald III
(To:reignofratch)

Your K matrix is extremely symmetric (w.r.t. the main diagonal).

I entered it in mathcad 11 and found that the inverse of (submatrix) Kb cannot be computed because it  (the matrix Kb) is singular. Its determinant is 0 exactly (so speaks the symbolic processor).

LM_20171207_MatrixInverse.png

Due to the numers you've entered, Prime does not see that the determinant of the matrix is 0 (there is a numerical inaccuracy always !), so it calculates an inverse anyway. And what you get is numbers due to that numerical inaccuracy. Generally the numerical accuracy lies in the order of 10^-17 (says: the numerical accuracy of Mathcad, and Prime alike, is about 17 digits). The reciprocal of course is 10^17, which is why you get numbers in that range, I guess.

 

Luc


@LucMeekes wrote:

Your Kb matrix has zero values in the top-right and bottom-left corners. Fred's matrix has all non-zero values.

zro.PNG

Zero with units is non-zero?  Please explain.


 

LucMeekes
23-Emerald III
(To:Fred_Kohlhepp)

Sorry Fred. I did not watch carefully enough. Mistook the inverse matrix for the upright matrix.
I guess it comes down to the fact that your matrix is not singular. That is to be checked though!
I'm on a smartphone now...

Luc
LucMeekes
23-Emerald III
(To:Fred_Kohlhepp)

Fred, I checked it. Your Matrix isn't singular, unlike the matrix of the OP.

LM_20171208_MatrixInverse.png

Zero's in the lower-left and upper-right corners doesn't necessarily make a matrix singular.

A careful arrangement of values can, however, as shown my other post above.

 

Luc

Top Tags