|
[Sponsors] |
October 21, 2006, 02:34 |
Where are the matricies stored
|
#1 |
Guest
Posts: n/a
|
Where are the matricies stored?
fvVectorMatrix UEqn ( fvm::ddt(rho, U) + fvm::div(phi, U) - fvm::laplacian(mu, U) ); solve(UEqn == -fvc::grad(p)); Is fvVectorMatrix a a template of fvMatrix class? Is solve() a member function of fvMatrix? Regards, Shuo |
|
October 21, 2006, 04:25 |
fvVectorMatrix is a typedef fo
|
#2 |
Senior Member
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33 |
fvVectorMatrix is a typedef for fvMatrix<vector>:
/home/hjasak/OpenFOAM/OpenFOAM-1.3/src/finiteVolume/fvMatrices/fvMatrix This lot is derived from lduMatrix in the foundation library. Beware, there is a template specialisation for fvScalarMatrix. Hrv
__________________
Hrvoje Jasak Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk |
|
October 23, 2006, 03:47 |
Hi Hrv,
Since this topic fi
|
#3 |
Senior Member
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,715
Rep Power: 40 |
Hi Hrv,
Since this topic finally came up, I was wishing to know how the initial residuals of a fvVectorMatrix should be tracked. As far as I can see, since lduMatrix::solverPerformanance is non-templated, only the last residuals can be obtained - regardless of the matrix type. Eg, the 'initialResidual' from the UEqn degenerates to that of the W-component and provides no access to the U/V information. Is the correct workaround to calculate all of the initial residuals prior to the UEqn.solve() step, or to unwrap the fvVectorMatrix and issue the calls for the scalar components ourselves? Thanks, /mark |
|
October 23, 2006, 04:01 |
Hello Mark,
'initialResidua
|
#4 | |
Senior Member
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33 |
Hello Mark,
Quote:
As for the issue of providing a scalar residual for a vector equation, here you are right: the underlying matrix machinery is scalar and it did not get the solverPerformance class as the appropriate type (mainly because it breaks some templating). This will be done properly (along with a suite of new solution techniques and my new super-fast solvers) in the rewrite of lduMatrix functionality. You can, of course, simply evaluate the residual yourself before calling the solve, which will of course give you all the functionality you need. An example is clearly laid out in the existing fvMatrix classes. Enjoy, Hrv
__________________
Hrvoje Jasak Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk |
||
October 23, 2006, 04:09 |
Hi Hrv,
Of course, the repo
|
#5 | |
Senior Member
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,715
Rep Power: 40 |
Hi Hrv,
Quote:
/mark |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Addressing matrix element and reuse of system matrix | marziolettich | OpenFOAM Running, Solving & CFD | 2 | February 19, 2008 06:04 |
Roe matrix | srinath | Main CFD Forum | 2 | March 26, 2003 11:39 |
about Roe matrix ! | Root Willow | Main CFD Forum | 2 | October 15, 2002 05:26 |
Elemtary matrix to CSR global matrix | xueying | Main CFD Forum | 2 | September 24, 2002 10:44 |
Gradient Matrix in FEM | Astrid Barros | Main CFD Forum | 3 | November 30, 1998 21:09 |