|
From: | Kai Torben Ohlhus |
Subject: | Re: ITSOL interface |
Date: | Thu, 11 Jul 2013 16:54:49 +0200 |
Hi Kai,
Actually I think it is a good idea to not wait until the very end of the project to start looking at the test cases.
Which makes me think that I had promised you to provide a simple way to generate automatically matrices for testing your preconditioners,
so here is a quick example:
-------------------------------------
pkg load bim
n = 50;
%% set beta = 0 for SPD matrix
beta = 1e4;
msh = msh3m_structured_mesh (n, n, n, 1, 1:6);
inodes = setdiff (1:columns (msh.p), bim3c_unknowns_on_faces (msh, 1:6));
x = msh.p(1,:) .';
A = bim3a_advection_diffusion (msh, 1, 1, 1, beta*x);
b = bim3a_rhs (msh, 1, 1);
%% the matrix to factorize is the one below
A = A(inodes, inodes);
%% solve the system by GE forcomparison
%% n = 80 is already to large to do this on my system;
b = b(inodes);
u = 0*x;
u(inodes) = A \ b;
-------------------------------------
for beta = 0 the matrix will be SPD and its condition number should scale as n^2
otherwise it will be unsymmetric.
n = 80 is already too large to handle via mldivide on my system it'd be very
interesting in to know the maximum size of system you can deal with by ilu+pcg
or ilu+gmres.
Also, what's your plan about ichol?
c.
[Prev in Thread] | Current Thread | [Next in Thread] |