private void MakePreconditioner(int simulation) { int matrixNo = matrixOrder[simulation + blockSize / 2]; string name = String.IsNullOrWhiteSpace(stiffnessMatrixPath) ? "K" : stiffnessMatrixPath; string path = Path.GetDirectoryName(name); string nameOnly = Path.GetFileNameWithoutExtension(name); string ext = Path.GetExtension(name); foreach (var sub in subdomains) { var m = new SkylineMatrix2D <double>(new int[0]); m.ReadFromFile(String.Format("{0}\\{1}Sub{3}Sim{4}{2}", path, nameOnly, ext, sub.Key, matrixNo)); m.Factorize(1e-8, new List <Vector <double> >(), new List <int>()); if (factorizedMatrices.ContainsKey(sub.Key)) { factorizedMatrices[sub.Key] = m; } else { factorizedMatrices.Add(sub.Key, m); } } }