你已经派生过 gprMax
镜像自地址
https://gitee.com/sunhf/gprMax.git
已同步 2025-08-07 23:14:03 +08:00
Updated dispersion warning to take account of when there are no sources in the model (not a very useful scenario....)
这个提交包含在:
@@ -100,11 +100,13 @@ def dispersion_check(waveforms, materials, dx, dy, dz):
|
||||
dx, dy, dz (float): Spatial discretisation of the model.
|
||||
|
||||
Returns:
|
||||
dispersionwarning (boolean): Potential numerical dispersion
|
||||
(boolean): Potential numerical dispersion
|
||||
"""
|
||||
|
||||
# Find maximum frequency
|
||||
freqs = [waveform.freq for waveform in waveforms]
|
||||
if not freqs:
|
||||
return False
|
||||
maxfreq = max(freqs)
|
||||
|
||||
# Find minimum wavelength
|
||||
@@ -125,11 +127,9 @@ def dispersion_check(waveforms, materials, dx, dy, dz):
|
||||
|
||||
# Test for numerical dispersion
|
||||
if max((dx, dy, dz)) > (minwavelength / resolution):
|
||||
dispersionwarning = True
|
||||
return True
|
||||
else:
|
||||
dispersionwarning = False
|
||||
|
||||
return dispersionwarning
|
||||
return False
|
||||
|
||||
|
||||
def get_other_directions(direction):
|
||||
|
在新工单中引用
屏蔽一个用户