emsig / empymod

Full 3D electromagnetic modeller for 1D VTI media
https://empymod.emsig.xyz
Apache License 2.0
85 stars 22 forks source link

Accuracy problems #166

Closed liuzg-23 closed 2 years ago

liuzg-23 commented 2 years ago

Hello Dieter,

Recently, I calculate an isotropic model for frequency-domain CSEM using empymod software. I do not know why I cannot get a correct result. Can you help me ? The following code is my setting parameters for the empymod:

src = [-50, 50, 0, 0, 0, 0]
# current of the source
strength=1
# x-directed dipole receiver-array: x, y, z, azimuth, dip
x_axis=np.arange(-20, 21)*500
y_axis=5000*np.ones(41)
rec = [x_axis,y_axis,0, 0, 0]
# layer boundaries
depth = [0,1000,4000]
# layer resistivities
res = [1e8,500,20,100]
# anisotropic
aniso=[1,1,1,1]
# Frequency
frequency=10
emfield =empymod.bipole(src, rec, depth, res, freqtime=frequency, aniso=aniso,strength=strength,verb=4)

Best regards, Zhengguang.

prisae commented 2 years ago

Hi Zhengguan,

Thanks for getting in touch. I run your example, and I cannot see any issues with it. What is, in your opinion, incorrect in the result?

Just to confirm a few things, you have:

If you can tell me what you expect to be different and why I might be able to help more.

I can see two potential points of confusion.

strength

One thing that might be confusing is the source strength. From the docstring:

strength : float, default: 0.0
    Source strength (A):

    - If 0, output is normalized to source and receiver of 1 m length, and
      source strength of 1 A.
    - If != 0, output is returned for given source and receiver length, and
      source strength.

You provide strength=1, which means that the returned result corresponds to a 100 Am source (100 m long, 1 A strong).

srcpts

The number of source points is by default set to 1. That means that your 100 m long dipole source is approximated by a single point source at (0,0,0). If you set srcpts=3, for instance, it uses Gaussian Quadrature to approximate the finite length dipole with three points.

However, given your source-receiver distances this will hardly make any difference at all, and approximating it with a point source is absolutely fine.

liuzg-23 commented 2 years ago

Hi Dieter,

Thanks very much for your detailed response. You are so kind. According to your answers, I have checked my code again. I made a particularly small mistake about my code.

Best Regards, Zhengguang.

prisae commented 2 years ago

You're welcome Zhengguang. I assume it works now, great!