Where are the matricies stored
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 |
fvVectorMatrix is a typedef fo
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 |
Hi Hrv,
Since this topic fi
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 |
Hello Mark,
'initialResidua
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 |
Hi Hrv,
Of course, the repo
Hi Hrv,
Quote:
/mark |
All times are GMT -4. The time now is 20:41. |