FlexPDE Matrix Output Log Out | Topics | Search
Moderators | Register | Edit Profile

FlexPDE User's Forum » User Postings » FlexPDE Matrix Output « Previous Next »

Author Message
Top of pagePrevious messageNext messageBottom of page Link to this message

Jaspreet (ftjin)
Member
Username: ftjin

Post Number: 8
Registered: 02-2006
Posted on Thursday, March 16, 2006 - 06:06 pm:   

Hello:
Can anybody tell me if there is a way one can output the global/elemental matrices FlexPDE produces?
Top of pagePrevious messageNext messageBottom of page Link to this message

Robert G. Nelson (rgnelson)
Moderator
Username: rgnelson

Post Number: 570
Registered: 06-2003
Posted on Thursday, March 30, 2006 - 04:20 pm:   

SELECT PRINT(MATRIX)
this will cause the constructed global matrix to be printed to the <filename>.dbg file in the folder with the script. This matrix is not really formatted for import to any external application, but the numbers are there.

SELECT PRINT(GRID)
this will cause the mesh structure to be printed to the <filename>.dbg file. This information is necessary to interpret the matrix data, since the matrix is listed in terms of mesh node numbers.

SELECT REORDER=OFF
This is necessary, because the printed matrix is reordered to move the nonzero entries nearer the diagonal, and the reorder map is not currently printed to the output.
Top of pagePrevious messageNext messageBottom of page Link to this message

christophe reiss (creiss)
New member
Username: creiss

Post Number: 1
Registered: 04-2006
Posted on Friday, April 07, 2006 - 12:52 pm:   

Hi all,
I found nowhere in documentation the SELECT parameters you mentioned here (MATRIX,GRID). Does this mean that, for example, if I specify linear heat PDE div(lambda*grad(T))+Q = 0, SELECT PRINT(MATRIX) will write the stiffness matrix K of the problem (K*T=F), assembled on the mesh structure returned by SELECT PRINT(GRID) ?
Top of pagePrevious messageNext messageBottom of page Link to this message

Robert G. Nelson (rgnelson)
Moderator
Username: rgnelson

Post Number: 579
Registered: 06-2003
Posted on Friday, April 07, 2006 - 07:42 pm:   

SELECT is a major section of the script, it is not a modifier to an equation. See documentation.

PRINT(MATRIX) and PRINT(GRID) are undocumented debugging functions provided primarily for our use in development. They happen to print the matrix and mesh data to the .DBG file, which is what the original posting requested.

The matrix printed to the .DBG file is the finite element coupling matrix (derivatives of the nodal Galerkin integrals wrt the nodal variable values). The values may be scaled, and the nodes reordered.

If the selectors mentioned above are set:
SELECT PRINT(MATRIX) PRINT(GRID) REORDER=OFF
then the matrix will be printed to the .DBG file every time it is constructed.
Top of pagePrevious messageNext messageBottom of page Link to this message

christophe reiss (creiss)
New member
Username: creiss

Post Number: 2
Registered: 04-2006
Posted on Thursday, June 22, 2006 - 08:15 am:   

Hi,
I come back to you with a question : when I define a PDE problem (for example heat diffusion problem) on a simple square (or cube), without specifying any boundary condition, I would expect that the generated matrix (obtained without reordering) would be square. It seems that this is not always the case (for example, 6521 rows for 6540 cols, with 6540 nodes). Do I miss something ?
Top of pagePrevious messageNext messageBottom of page Link to this message

christophe reiss (creiss)
Junior Member
Username: creiss

Post Number: 3
Registered: 04-2006
Posted on Thursday, June 22, 2006 - 12:53 pm:   

Hi,
my fault ! It works (I use latest linux version) but only when using the command line. The GUI seems to loose the latest piece of dbg file.
Top of pagePrevious messageNext messageBottom of page Link to this message

Jared Barber (jared_barber)
Member
Username: jared_barber

Post Number: 34
Registered: 01-2007
Posted on Tuesday, June 03, 2008 - 12:01 pm:   

Hey,

Just thought I'd add...I've experienced "disappearing lines" from exporting stuff in FlexPDE. What I found out (from a previous post) is that you have to close FlexPDE (GUI version) before FlexPDE fully writes the file. This may be what's happening for you (maybe not though, I'm not sure). I'm surprised no one has fixed this yet as, in C, all it takes is adding an "fflush" command (one line of code). It doesn't seem like it should be much work to fix it (regardless the language being used here).
Top of pagePrevious messageNext messageBottom of page Link to this message

Robert G. Nelson (rgnelson)
Moderator
Username: rgnelson

Post Number: 1126
Registered: 06-2003
Posted on Tuesday, June 03, 2008 - 01:59 pm:   

The .dbg file was not flushed on problem completion. We also neglected to fix the TRACE output flush when it was reported a few months ago. We have fixed both of these in version 5.0.23 (not yet released).

Looking at the code, it appears that all export forms (EXPORT, PRINT, TABLE, TECPLOT, VTK, TRANSFER, CDF) close the file at the end of the export, and this has been true at least since 5.0.0.


Top of pagePrevious messageNext messageBottom of page Link to this message

Jared Barber (jared_barber)
Member
Username: jared_barber

Post Number: 35
Registered: 01-2007
Posted on Wednesday, June 04, 2008 - 07:17 pm:   

Thanks. I shouldn't have used the term "exporting stuff" as in this context people would think it actually refers to the "EXPORT" command. It rather refers to what you mentioned.

Add Your Message Here
Post:
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Password:
Options: Enable HTML code in message
Automatically activate URLs in message
Action:

Topics | Last Day | Last Week | Tree View | Search | Help/Instructions | Program Credits Administration