#!/usr/bin/env python # coding: utf-8 # This is the Jupyter Notebook, an interactive coding and computation environment. For this lab, you do not have to write any code, you will only be running it. # # To use the notebook: # - "Shift + Enter" runs the code within the cell (so does the forward arrow button near the top of the document) # - You can alter variables and re-run cells # - If you want to start with a clean slate, restart the Kernel either by going to the top, clicking on Kernel: Restart, or by "esc + 00" (if you do this, you will need to re-run the following block of code before running any other cells in the notebook) # In[1]: get_ipython().run_line_magic('matplotlib', 'inline') from em_examples.DipoleWidgetFD import DipoleWidgetFD, InteractiveDipoleProfile from em_examples.VolumeWidget import InteractivePlanes, plotObj3D from IPython.display import display # # Title: Magnetic Dipole in a Whole-space (frequency-domain) # # Purpose # # By using an analytic solution electromagnetic (EM) fields from magnetic dipole in a Whole-space, we present some fundamentals of EM responses in the context of crosswell EM survey. # # Set up # # For frequency domain EM method using inductive source, we inject sinusoidal currents to an induction coil, which will generate time varying magnetic field in the earth. # # # # ## Crosswell EM set-up # # Here, we choose geometric parameters for a crosswell EM set-up having two boreholes for Tx and Rx. In the Tx hole, a VMD source is located at (0m, 0m, 0m), and it is fixed. Horizontal location of the Rx hole is fixed to 50m apart from the source location in x-direction. # In[2]: ax = plotObj3D() # ## Background # # When using crosswell electromagnetic (EM) survey, we inject sinusoidal currents to the earth using induction coil, and measure magnetic field at receiver locations. A common goal here is imaging conductivity structure of the earth by interpreting measured magnetic field. However, to accomplish that task well, we first need to understand physical behavior of EM responses for the given survey set-up. # # Assuming length of the current elecrodes are small enough, this can be assumed as magnetic dipole (MD). For a croswell set-up, let we have a vertical electic dipole (VED) source in a homogeneous earth with sinusodal currents, then we can have analytic solution of EM fields in frequency domain (WH1988). Solution of of arbitrary EM fields, $\mathbf{F}$, will be a function of # # $$ \mathbf{F} (x, y, z; \sigma, f),$$ # # where $\sigma$ is conductivity of homogenous earth (S/m), and $f$ is transmitting frequency (Hz). Here $\mathbf{F}$ can be electic ($\mathbf{E}$) or magnetic field ($\mathbf{H}$), or current density ($\mathbf{J}$). Now, you will explore how EM responses behaves as a function of space, $\sigma$, and $f$ for the given crosswell EM set-up . # # Geometry app # # Choose an plane of interest and the number of receivers. # # ## Parameters: # # - plane: Choose either "XZ" or "YZ" plane # - offset: Offset from a source plane (m) # - nRx: The number of receivers in the Rx hole # # Chosen geometric parameters will be used in the Electric Dipole widget below. # In[3]: Q0 = InteractivePlanes() display(Q0) # # Magnetic Dipole app # # Explore behavior of EM fields, $\mathbf{F} (x, y, z; \sigma, f)$ on 2D plane chosen in the above app. And also at the receiver locations. # # ## Parameters: # # # - Field: Type of EM fields ("E": electric field, "H": magnetic field, "J": current density) # - AmpDir: Type of the vectoral EM fields # # None: $F_x$ or $F_y$ or $F_z$ # # Amp: $\mathbf{F} \cdot \mathbf{F}^* = |\mathbf{F}|^2$ # # Dir: Real part of a vectoral EM fields, $\Re[\mathbf{F}]$ # # - Comp.: Direction of $\mathbf{F}$ at Rx locations # - ComplexNumber: Type of complex data ("Re", "Im", "Amp", "Phase") # - $f$: Transmitting frequency (Hz) # - $\sigma$: Conductivity of homogeneous earth (S/m) # - Offset: Offset from a source plane # - Scale: Choose "log" or "linear" scale # - Slider: When it is checked, it activates "flog" and "siglog" sliders above. # - FreqLog: A float slider for log10 frequency (only activated when slider is checked) # - SigLog: A float slider for log10 conductivity (only activated when slider is checked) # # In[4]: dwidget = DipoleWidgetFD() Q1 = dwidget.InteractiveDipoleBH(nRx=Q0.kwargs["nRx"], plane=Q0.kwargs["Plane"], offset_plane=Q0.kwargs["Offset"], SrcType="MD",fieldvalue="H",compvalue="z") display(Q1) # # Proflie app # # Here we focuson data, which can be measured at receiver locations. We limit our attention to three different profile shown in **Geometry** app: Rxhole (red), Txhole (black), TxProfile (blue). # # ## Parameters: # # - Comp.: Direction of $\mathbf{F}$ at Rx locations # - ComplexNumber: Type of complex data ("Re", "Im", "Amp", "Phase") # - $f_1$: Freuency (Hz) # - $f_2$: Freuency (Hz) # - $f_3$: Freuency (Hz) # - Profile: Type of profile line ("Rxhole", "Txhole", "TxProfile") # - Scale: Choose "log" or "linear" scale # In[5]: Q2 = InteractiveDipoleProfile(dwidget, Q1.kwargs["Sigma"], Q1.kwargs["Field"], Q1.kwargs["Scale"]) display(Q2) # In[ ]: