Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
linear system
Posted Jan 15, 2010, 3:58 a.m. EST 9 Replies
Please login with a confirmed email address before reporting spam
I'd like to ask if is there a chance to get the resulting linear system after assembly (and perhaps preconditioning) out of the program to let it be solved on other machine with my own solver and then load the solution vector back to COMSOL for postprocessing.
Thnx,
Hans
Please login with a confirmed email address before reporting spam
If you have the matlab link andyou study from the doc the comsol "fem" structure you can do about everything, within the RAM limits of your PC
Do an indexed search on your doc files, you will find many references
Good luck
Ivar
Please login with a confirmed email address before reporting spam
Hi
If you have the matlab link andyou study from the doc the comsol "fem" structure you can do about everything, within the RAM limits of your PC
Do an indexed search on your doc files, you will find many references
Good luck
Ivar
Yes, the assemble command assembles the stiffness matrix, right-hand side, mass matrix, damping matrix, and constraints of a PDE problem using a finite element discretization. You can output all these matrices or one or more selected matrices. Read more in the COMSOL Multiphysics MATLAB Interface Guide.
Please login with a confirmed email address before reporting spam
Indeed this works very nicely for small and medium models. But for "true" engineering cases of some complexity the sizes of the matrices become too heavy to export and work with in Matlab.
There is a nice niche for COMSOL to explore the "superelement" and modal reduction approach. Something like what is implemented in "FEDEM" (from Trondheim www.fedem.no) for structural, or again differently in NASTRAN, but for COMSOL in a more generalised way.
Have a nice week-end
Ivar
Please login with a confirmed email address before reporting spam
yes there are, you have some similar discussions ongoing, see the eigenfrequency modal mass extraction of this months. Or just read through your doc on matlab exchange and "fem" structure.
It will take some time to get into the structure details, but afterwards you will have the knowledge to get to any variable. The main tricky thing is the indexing of elements and how to identify/reidentify, BC's and geoemtrical items.
Good luck
Ivar
Please login with a confirmed email address before reporting spam
Yes, the assemble command assembles the stiffness matrix, right-hand side, mass matrix, damping matrix, and constraints of a PDE problem using a finite element discretization. You can output all these matrices or one or more selected matrices. Read more in the COMSOL Multiphysics MATLAB Interface Guide.
Hi, I'd like to use stiffness matrix 'K' from assemble function and solve linear system of equations 'Kx=y', where I know 'y' vector. Which function should I use? I looked for femstatic function, but it only accepts fem structure.
thanks
peter
Please login with a confirmed email address before reporting spam
u = femlin('in',{'K' K 'L' L},'out','u') is equivalent to solving the linear system using u = K\L, with the important difference that you have access to all linear system solvers (except Geometric multigrid) using the Linsolver property.
Peter
Please login with a confirmed email address before reporting spam
You've mentioned "indexed search" on the doc files in several of your responses here. Could you remind us how to do that?
Thx.
Please login with a confirmed email address before reporting spam
But where to begin? I can download a trial version of Matlab from Mathworks. Which modules do I need? Matlab presumably. How about Simulink? Any others? I guess the latest version of Matlab works with COMSOL 4.0?
Thanks, John
p.s. Is anyone else on COMSOL 4.0 having trouble seeing the equations?? Yes, I've clicked on show equations, and I click on "Update Equation View". But the only things to ever show up are the constraints. Once, on a k-e, I got loads of equations to show up on a boundary condition, but this is a rare event.
Please login with a confirmed email address before reporting spam
for the indexing, I'm just directing Microsoft indexer onto the doc files and run a normal MS search, but I would love to have the Google indexer (not in our company policy) as I find it better, and it opens the pdf doc directly at the right page, while with the MS you must rerun a "find" within the pdf.
For matlab normally you need only a simple standard matlab, not even Simulinl if you do not intend to control a system via Matlab + Simulink <=> Comsol
for the equation, the "upper level" is not yet implemented, but the "lower level" is there see file
Have fun Comsoling
Ivar
Attachments:
Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.
Suggested Content
- FORUM fail to extract the system matrix
- BLOG Using the Algebraic Multigrid (AMG) Method for Large CFD Simulations
- BLOG Solving Linear Static Finite Element Models
- FORUM Issues when solving linear system in Frequency Domain study step when removing symmetry BCs
- KNOWLEDGE BASE Maximum number of linear iterations reached