private static ISection1D <Layer1D> CreateSection1D() { IEnumerable <ResistivityLayer1D> layers = new ResistivityLayer1D[] { new ResistivityLayer1D(0, float.PositiveInfinity), new ResistivityLayer1D(1000m, 1000), new ResistivityLayer1D(6500m, 10000), new ResistivityLayer1D(0, 10), }; var section1D = new Section1D <ResistivityLayer1D>(layers.ToArray()); return(section1D); }
private ISection1D <Sigma1DLayer> CreateSection1D(Section1D <Sigma1DLayer> section1D) { var layers = new List <Sigma1DLayer>(); layers.Add(section1D[0]); var newZeroLevel = section1D.ZeroAirLevelAlongZ; if (_settings.AnomalyStartDepth < section1D.ZeroAirLevelAlongZ) { newZeroLevel = _settings.AnomalyStartDepth; layers.Add(new Sigma1DLayer(section1D.ZeroAirLevelAlongZ - _settings.AnomalyStartDepth, section1D[0].Sigma)); } for (int i = 1; i < section1D.NumberOfLayers - 1; i++) { layers.Add(section1D[i]); } var summ = section1D.ZeroAirLevelAlongZ; for (int i = 0; i < section1D.NumberOfLayers; i++) { summ += section1D[i].Thickness; } var anomEnd = _settings.AnomalyStartDepth + _settings.AnomalySizeZ; if (anomEnd > summ) { layers.Add(new Sigma1DLayer(anomEnd - summ, section1D[section1D.NumberOfLayers - 1].Sigma)); } layers.Add(section1D[section1D.NumberOfLayers - 1]); return(new Section1D <Sigma1DLayer>(newZeroLevel, layers.ToArray())); }