Added import of z0 for transmission line.

这个提交包含在:
Craig Warren
2016-01-25 16:23:49 +00:00
父节点 eb49400f7d
当前提交 32b8d51a13

查看文件

@@ -16,6 +16,7 @@
# You should have received a copy of the GNU General Public License
# along with gprMax. If not, see <http://www.gnu.org/licenses/>.
from gprMax.constants import z0
from gprMax.exceptions import CmdInputError
from gprMax.geometry_views import GeometryView
from gprMax.materials import Material, PeplinskiSoil
@@ -265,7 +266,7 @@ def process_multicmds(multicmds, G):
raise CmdInputError("'" + cmdname + ': ' + ' '.join(tmp) + "'" + ' z-coordinate is not within the model domain')
if positionx < G.pmlthickness[0] or positionx > G.nx - G.pmlthickness[3] or positiony < G.pmlthickness[1] or positiony > G.ny - G.pmlthickness[4] or positionz < G.pmlthickness[2] or positionz > G.nz - G.pmlthickness[5]:
print("WARNING: '" + cmdname + ': ' + ' '.join(tmp) + "'" + ' sources and receivers should not normally be positioned within the PML.')
if resistance <= 0 or resistance > 376.7:
if resistance <= 0 or resistance > z0:
raise CmdInputError("'" + cmdname + ': ' + ' '.join(tmp) + "'" + ' requires a resistance greater than zero and less than the impedance of free space, i.e. 376.73 Ohms')
# Check if there is a waveformID in the waveforms list