On the solvability of the discrete conductivity and Schrödinger inverse problems
This is code accompanying the paper entitled
"On the solvability of the discrete conductivity and Schrödinger inverse problems"
by
Justin Boyer, Jack J. Garzella and Fernando Guevara Vasquez.
Preprint avaiable here: arXiv:1510.02848
For questions please contact Fernando Guevara Vasquez fguevara (at) math (dot) utah (dot) edu
This code is written in Julia and allows to reproduce the figures and other numerical results in the paper described above.
This code, documentation and datasets can be found at http://www.math.utah.edu/~fguevara/recov
All the files including this documentation are in recov.tar.gz. Last updated: October 11 2015.
Required Julia packages
HDF5
LightXML
PyPlot
(requires matplotlib to be installed)
To install type the following in the Julia REPL
Pkg.add("HDF5")
Pkg.add("LightXML")
Pkg.add("PyPlot")
This code has been tested with Julia v0.4 on Mac OS X 10.10.5.
Reproducing results
All the numerics in the paper can be reproduced by issuing the following commands in the shell.
# create directory to store output files
mkdir paper
# generates HDF5 files with the computation results
julia paper_comp.jl
# plots info in the HDF5 files
julia paper_plots.jl
The expensive part of the calculation is the statistical study of graphs. This can be sped up in machines with multiple cores, e.g. when 4 cores are available:
julia -p 4 paper_comp.jl
More recoverability studies
Standalone recoverability study for Schrödinger can also be done via the shell. For example to run the study with 10 internal nodes on a machine with 4 cores
julia -p 4 qrecov_comp.jl 10
Similarly the recoverability study for e.g. 11 edges on 4 cores can be computed by
julia -p 4 srecov_comp.jl 11
Both of these commands support being called on a single core by removing the
-p 4
option.
Finally the is a script doall.sh
to do many recoverability studies. This
takes a few hours to compute and the script may need to be edited to include
the number of cores to be used.
Data sets included
Graphs with boundary are stored using
GraphML, an XML based graph format. An
integer node based attribute bdry
is used to determine whether the node is on
the boundary (bdry==1
) or not (bdry==0
).
Some graphs are also available in the native Gephi format, an interactive graph visualization platform that can also import GraphML files.
The graphs included in GraphML format are: cube.graphml
, cube2.graphml
,
cubetop.graphml
and k5lll.graphml
. The files in Gephi format are:
cube2.gephi
and cubetop.gephi
.
Code structure
- module
recov
does all the computations - module
recov_io
can read/write GraphML files from graphs with boundary and also export to asymptote. - module
recov_plot
has the code for plotting.
Generating Documentation
To regenerate the documentation one needs:
- the Python package
mkdocs
(install withpip install mkdocs
) - the Python package
python-markdown-math
(install withpip install python-markdown-math
)
To compile the documentation issue the following commands in the shell
julia gendoc.jl
mkdocs build
Note: The output is very bare bones for now. This will be fixed once the doc system in Julia is finalized.
License
The code, documentation and data sets provided here are subject to the MIT license:
Copyright (c) 2015 Fernando Guevara Vasquez and other contributors
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Contributors to this code and datasets are
- Justin Boyer
- Jack J. Garzella