- #1
cathalcummins
- 46
- 0
Hi there,
I am working on a problem in Fluid dynamics. I've written a code in MATLAB which finds the shape of the free surface of the liquid based on Newton Relaxation. The code is fairly robust and produces good results which agree with current papers on the same problem.
Unfortunately, for some values of the parameters of the problem, the results are just plain wrong. It's not straightforward to identify a priori which values of the parameters will lead to the correct results and which will give spurious ones.
The method boils down to solving a matrix equation successively in a relaxation fashion. The number of iterates is generally quite modest ~30 and the matrix is usually about 600X600.
The quantity being calculated, the height of the free surface, is fairly smooth but displays some fine structure too.
The way I have the problem working now is to use MATLAB's rand function to generate random parameter values and then filter the results based on the condition numbers of the resulting system. This seems to get me a little further but I am unhappy with this approach.
I was thinking about rescaling the large matrix of coefficients and dumping them onto the right hand side of the matrix equation. Is this usually advantageous? Does anyone have similar experience with numerical error/scaling?
Thanks for reading
I am working on a problem in Fluid dynamics. I've written a code in MATLAB which finds the shape of the free surface of the liquid based on Newton Relaxation. The code is fairly robust and produces good results which agree with current papers on the same problem.
Unfortunately, for some values of the parameters of the problem, the results are just plain wrong. It's not straightforward to identify a priori which values of the parameters will lead to the correct results and which will give spurious ones.
The method boils down to solving a matrix equation successively in a relaxation fashion. The number of iterates is generally quite modest ~30 and the matrix is usually about 600X600.
The quantity being calculated, the height of the free surface, is fairly smooth but displays some fine structure too.
The way I have the problem working now is to use MATLAB's rand function to generate random parameter values and then filter the results based on the condition numbers of the resulting system. This seems to get me a little further but I am unhappy with this approach.
I was thinking about rescaling the large matrix of coefficients and dumping them onto the right hand side of the matrix equation. Is this usually advantageous? Does anyone have similar experience with numerical error/scaling?
Thanks for reading