{ "cells": [ { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Requirement already up-to-date: pip in c:\\users\\devin\\anaconda2\\lib\\site-packages\n", "Requirement already satisfied: em_examples in c:\\users\\devin\\anaconda2\\lib\\site-packages\n", "Requirement already satisfied: scipy>=0.13 in c:\\users\\devin\\anaconda2\\lib\\site-packages (from em_examples)\n", "Requirement already satisfied: SimPEG in c:\\users\\devin\\documents\\simpeg (from em_examples)\n", "Requirement already satisfied: future in c:\\users\\devin\\anaconda2\\lib\\site-packages (from em_examples)\n", "Requirement already satisfied: ipywidgets in c:\\users\\devin\\anaconda2\\lib\\site-packages (from em_examples)\n", "Requirement already satisfied: numpy>=1.7 in c:\\users\\devin\\anaconda2\\lib\\site-packages (from em_examples)\n", "Requirement already satisfied: cython in c:\\users\\devin\\anaconda2\\lib\\site-packages (from SimPEG->em_examples)\n", "Requirement already satisfied: ipython in c:\\users\\devin\\anaconda2\\lib\\site-packages (from SimPEG->em_examples)\n", "Requirement already satisfied: matplotlib in c:\\users\\devin\\anaconda2\\lib\\site-packages (from SimPEG->em_examples)\n", "Requirement already satisfied: properties[math] in c:\\users\\devin\\anaconda2\\lib\\site-packages (from SimPEG->em_examples)\n", "Requirement already satisfied: six>=1.10 in c:\\users\\devin\\anaconda2\\lib\\site-packages (from matplotlib->SimPEG->em_examples)\n", "Requirement already satisfied: python-dateutil in c:\\users\\devin\\anaconda2\\lib\\site-packages (from matplotlib->SimPEG->em_examples)\n", "Requirement already satisfied: functools32 in c:\\users\\devin\\anaconda2\\lib\\site-packages (from matplotlib->SimPEG->em_examples)\n", "Requirement already satisfied: pytz in c:\\users\\devin\\anaconda2\\lib\\site-packages (from matplotlib->SimPEG->em_examples)\n", "Requirement already satisfied: cycler>=0.10 in c:\\users\\devin\\anaconda2\\lib\\site-packages (from matplotlib->SimPEG->em_examples)\n", "Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=1.5.6 in c:\\users\\devin\\anaconda2\\lib\\site-packages (from matplotlib->SimPEG->em_examples)\n", "Requirement already satisfied: vectormath>=0.1.1; extra == \"math\" in c:\\users\\devin\\anaconda2\\lib\\site-packages (from properties[math]->SimPEG->em_examples)\n" ] } ], "source": [ "!pip install --upgrade pip\n", "!pip install em_examples" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Efficiency Warning: Interpolation will be slow, use setup.py!\n", "\n", " python setup.py build_ext --inplace\n", " \n" ] } ], "source": [ "from em_examples.Base import widgetify\n", "import em_examples.InductionSphereFEM as IND\n", "from ipywidgets import interact, FloatSlider, FloatText, ToggleButtons" ] }, { "cell_type": "markdown", "metadata": { "collapsed": true }, "source": [ "## Sphere FEM Response for EM-31\n", "\n", "Here, we simulate the response observed over a conductive and magnetically permeable sphere by an EM-31. In the leftmost plot, the regional primary or secondary field is plotted in 2D along with the survey geometry. In the rightmost plot, the response at the receiver coil is plotted as a function of frequency. The parameters for the app are summarized below:\n", "\n", "* $x_{Tx}$: Horizontal location of the EM-31 (halfway between Tx and Rx coils)\n", "* $z_{Tx}$: Vertical location of the EM-31\n", "* $L$: Horizontal transmitter-receiver separation\n", "* $m$: Transmitter dipole moment\n", "* $Orientation$: The EM-31 configuration may be set to vertical coaxial or horizontal coplaner\n", "* $x_s$: Horizontal location of the sphere\n", "* $z_s$: Vertical location of the sphere\n", "* $R$: Radius of the sphere\n", "* $log_{10}(\\sigma)$: Conductivity of the sphere\n", "* $\\mu_r$: Relative permeability of the sphere\n", "* $log_{10}(f)$: Set to visualize the response for a specific frequency\n", "* $Field \\; Type$: View the 2D regional primary field, real component of the secondary field or imaginary component of the secondary field." ] }, { "cell_type": "code", "execution_count": 8, "metadata": {}, "outputs": [ { "data": { "application/vnd.jupyter.widget-view+json": { "model_id": "03c6002f7e9d4902ae82ea28d7694cb9" } }, "metadata": {}, "output_type": "display_data" } ], "source": [ "widgetify(IND.fcn_FDEM_InductionSphereProfileEM31Widget,xtx=FloatSlider(min=-20, max=20., value=0., step=2., continuous_update=False, description = \"$x_{Tx}$\"),\\\n", " ztx=FloatSlider(min=0., max=10., value=2., step=1., continuous_update=False, description = \"$z_{Tx}$\"),\\\n", " L=FloatSlider(min=0., max=25., value=20., step=5., continuous_update=False, description = \"$L$\"),\\\n", " m=FloatSlider(min=1., max=5.,value=1.,step=1.,continuous_update=False,description = \"$m$\"),\\\n", " orient=ToggleButtons(options=['Vert. Coaxial','Horiz. Coplanar'],value='Horiz. Coplanar',description = \"$Configuration$\"),\\\n", " x0=FloatSlider(min=-20., max=20., value=0., step=1., continuous_update=False, description = \"$x_s$\"),\\\n", " z0=FloatSlider(min=-20., max=0., value=-8., step=1., continuous_update=False, description = \"$z_s$\"),\\\n", " a=FloatSlider(min=0.5, max=5., value=3., step=0.5, continuous_update=False, description = \"$R$\"),\\\n", " sig=FloatSlider(min=0., max=6., value=2., step=0.5, continuous_update=False, description = \"$log_{10}(\\sigma)$\"),\\\n", " mur=FloatSlider(min=1., max=5., value=1., step=0.25, continuous_update=False, description = \"$\\mu_r$\"),\\\n", " logf=FloatSlider(min=0., max=8., value=5., step=1., continuous_update=False, description = \"$log_{10}(f)$\"),\\\n", " Flag=ToggleButtons(options=['Hp','Hs_real','Hs_imag'],value='Hp',description = \"$Field \\; Type$\"))\n", " " ] }, { "cell_type": "markdown", "metadata": { "collapsed": true }, "source": [ "## Sphere FEM Response for Arbitrary Configuration\n", "\n", "Here, we simulate the response observed over a conductive and magnetically permeable sphere. The parameters are relaxed so that the transmitter-receiver separation is no longer fixed. In the leftmost plot, the regional primary or secondary field is plotted in 2D along with the survey geometry. In the rightmost plot, the response at the receiver coil is plotted as a function of frequency. The parameters for the app are summarized below:\n", "\n", "* $x_{Tx}$: Horizontal location of the transmitter coil\n", "* $z_{Tx}$: Vertical location of the transmitter coil\n", "* $m$: Transmitter dipole moment\n", "* $Orientation$: The transmitter-receiver configuration may be set to vertical coaxial or horizontal coplaner\n", "* $x_s$: Horizontal location of the sphere\n", "* $z_s$: Vertical location of the sphere\n", "* $R$: Radius of the sphere\n", "* $log_{10}(\\sigma)$: Conductivity of the sphere\n", "* $\\mu_r$: Relative permeability of the sphere\n", "* $x_{Rx}$: Horizontal location of the receiver coil\n", "* $z_{Rx}$: Vertical location of the receiver coil\n", "* $log_{10}(f)$: Set to visualize the response for a specific frequency\n", "* $Field \\; Type$: View the 2D regional primary field, real component of the secondary field or imaginary component of the secondary field." ] }, { "cell_type": "code", "execution_count": 9, "metadata": {}, "outputs": [ { "data": { "application/vnd.jupyter.widget-view+json": { "model_id": "bd4fee06a2b346cdb099a31f89e1d706" } }, "metadata": {}, "output_type": "display_data" } ], "source": [ "widgetify(IND.fcn_FDEM_InductionSphereProfileWidget,xtx=FloatSlider(min=-20, max=20., value=-10., step=2., continuous_update=False, description = \"$x_{Tx}$\"),\\\n", " ztx=FloatSlider(min=0., max=10., value=2., step=1., continuous_update=False, description = \"$z_{Tx}$\"),\\\n", " m=FloatSlider(min=1., max=5.,value=1.,step=1.,continuous_update=False,description = \"$m$\"),\\\n", " orient=ToggleButtons(options=['Vert. Coaxial','Horiz. Coplanar'],value='Horiz. Coplanar',description = \"$Configuration$\"),\\\n", " x0=FloatSlider(min=-20., max=20., value=0., step=1., continuous_update=False, description = \"$x_s$\"),\\\n", " z0=FloatSlider(min=-20., max=0., value=-10., step=1., continuous_update=False, description = \"$z_s$\"),\\\n", " a=FloatSlider(min=0.5, max=5., value=3., step=0.5, continuous_update=False, description = \"$R$\"),\\\n", " sig=FloatSlider(min=0., max=6., value=2., step=0.5, continuous_update=False, description = \"$log_{10}(\\sigma)$\"),\\\n", " mur=FloatSlider(min=1., max=5., value=1., step=0.25, continuous_update=False, description = \"$\\mu_r$\"),\\\n", " xrx=FloatSlider(min=-20., max=20., value=10., step=1., continuous_update=False, description = \"$x_{Rx}$\"),\\\n", " zrx=FloatSlider(min=0., max=10., value=2., step=1., continuous_update=False, description = \"$z_{Rx}$\"),\\\n", " logf=FloatSlider(min=0., max=8., value=5., step=1., continuous_update=False, description = \"$log_{10}(f)$\"),\\\n", " Flag=ToggleButtons(options=['Hp','Hs_real','Hs_imag'],value='Hp',description = \"$Field \\; Type$\"))\n", " " ] }, { "cell_type": "markdown", "metadata": { "collapsed": true }, "source": [ "## Sphere FEM Anomaly for Arbitrary Configuration\n", "\n", "Here, we simulate the response observed over a conductive and magnetically permeable sphere. The transmitter, receiver and sphere locations can be set anywhere in 3D space. The orientation of the transmitter can also be changed. In the leftmost plot, FEM anomaly is plotted on the XY-plane at the same height as the receiver coil. In the rightmost plot, the response at the receiver coil is plotted as a function of frequency. The parameters for the app are summarized below:\n", "\n", "* $x_{Tx}$: X-location of the transmitter coil\n", "* $y_{Tx}$: Y-location of the transmitter coil\n", "* $z_{Tx}$: Z-location of the transmitter coil\n", "* $m$: Transmitter dipole moment\n", "* $Orientation$: The orientation of the transmitter's dipole moment can be set along 'x', 'y' or 'z'\n", "* $x_s$: X-location of the sphere\n", "* $y_s$: Y-location of the sphere\n", "* $z_s$: Z-location of the sphere\n", "* $R$: Radius of the sphere\n", "* $log_{10}(\\sigma)$: Conductivity of the sphere\n", "* $\\mu_r$: Relative permeability of the sphere\n", "* $x_{Rx}$: X-location of the receiver coil\n", "* $y_{Rx}$: Y-location of the receiver coil\n", "* $z_{Rx}$: Z-location of the receiver coil\n", "* $log_{10}(f)$: Set to visualize the response for a specific frequency\n", "* $Component$: Examine the 'x', 'y' or 'z' component of the response at the receiver coil\n", "* $Field \\; Type$: Examine the real or imaginary component of the FEM anomaly specified by '$Component$'" ] }, { "cell_type": "code", "execution_count": 11, "metadata": {}, "outputs": [ { "data": { "application/vnd.jupyter.widget-view+json": { "model_id": "80c32e830bab4612a3120cafb9094fba" } }, "metadata": {}, "output_type": "display_data" } ], "source": [ "widgetify(IND.fcn_FDEM_InductionSpherePlaneWidget,xtx=FloatSlider(min=-20, max=20., value=0., step=1., continuous_update=False, description = \"$x_{Tx}$\"),\\\n", " ytx=FloatSlider(min=-20, max=20., value=0., step=1., continuous_update=False, description = \"$y_{Tx}$\"),\\\n", " ztx=FloatSlider(min=0., max=10., value=2., step=1., continuous_update=False, description = \"$z_{Tx}$\"),\\\n", " m=FloatSlider(min=1., max=5.,value=2.,step=1.,continuous_update=False,description = \"$m$\"),\\\n", " orient=ToggleButtons(options=['x','y','z'],value='z'),\\\n", " x0=FloatSlider(min=-20., max=20., value=0., step=1., continuous_update=False, description = \"$x_s$\"),\\\n", " y0=FloatSlider(min=-20., max=20., value=0., step=1., continuous_update=False, description = \"$y_s$\"),\\\n", " z0=FloatSlider(min=-20., max=-2., value=-5., step=1., continuous_update=False, description = \"$z_s$\"),\\\n", " a=FloatSlider(min=0.5, max=5., value=2., step=0.5, continuous_update=False, description = \"$R$\"),\\\n", " sig=FloatSlider(min=0., max=6., value=2., step=0.5, continuous_update=False, description = \"$log_{10}(\\sigma)$\"),\\\n", " mur=FloatSlider(min=1., max=5., value=1., step=0.25, continuous_update=False, description = \"$\\mu_r$\"),\\\n", " xrx=FloatSlider(min=-20., max=20., value=10., step=1., continuous_update=False, description = \"$x_{Rx}$\"),\\\n", " yrx=FloatSlider(min=-20., max=20., value=10., step=1., continuous_update=False, description = \"$y_{Rx}$\"),\\\n", " zrx=FloatSlider(min=0., max=10., value=2., step=1., continuous_update=False, description = \"$z_{Rx}$\"),\\\n", " logf=FloatSlider(min=0., max=8., value=5., step=1., continuous_update=False, description = \"$log_{10}(f)$\"),\\\n", " Comp=ToggleButtons(options=['x','y','z'],value='z',description = \"$Component$\"),\\\n", " Phase=ToggleButtons(options=['Real','Imag'],value='Real',description = \"$Field \\; Type$\"))" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [] } ], "metadata": { "anaconda-cloud": {}, "kernelspec": { "display_name": "Python [default]", "language": "python", "name": "python2" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 2 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython2", "version": "2.7.13" } }, "nbformat": 4, "nbformat_minor": 1 }