import numpy as np
import escape as esc
from escape.utils.widgets import show
esc.require('0.9.7')
Loading material database from /home/dkor/Data/Development/workspace_escape/escape/python/src/escape/scattering/../data/mdb/materials.db
Interfacial Roughness and Proximity Effects in Superconductor/Ferromagnet CuNi/Nb Heterostructures¶
Authors: Yu. Khaydukov, R. Morari, O. Soltwedel, T. Keller, G. Christiani, G. Logvenov, M. Kupriyanov, A. Sidorenko, and B. Keimer
Citation: Journal of Applied Physics 118, 213905 (2015); doi: 10.1063/1.4936789
In this study, we present the results of fitting experimental data from the publication mentioned above. We selected data from two samples, where the CuNi layers differ in terms of thickness and roughness, to showcase the capabilities of a simultaneous fit with shared parameters. Rather than fitting the Scattering Length Densities (SLDs), we will focus on fitting the mass densities of the layer compounds.
This notebook also demonstrates how to add temporary records to the default material database. This approach allows new material records to be kept within the notebook alongside the code, rather than creating a new local material database.
src = esc.xrays(0.1540562, "nm")
Capping = {
"name": "Capping",
"type": "amorphous",
"density": 2.32,
"atoms": [
{"Si": {"repeat": 1}},
],
}
CuNi = {
"name": "CuNi",
"type": "amorphous",
"density": 8.93,
"atoms": [
{"Cu": {"repeat": 1}},
{"Ni": {"repeat": 1}},
],
}
SiO2 = {
"name": "SiO2",
"type": "amorphous",
"density": 2.62,
"atoms": [
{"Si": {"repeat": 1}},
{"O": {"repeat": 2}},
],
}
from escape.scattering.mdb import default_mdb
default_mdb.add(Capping)
default_mdb.add(CuNi)
default_mdb.add(SiO2)
Cap_common = esc.amorphous("Capping", density="mdb")
CuNi_common = esc.amorphous("CuNi", density="mdb")
SiO2Lay = esc.layer("Layer: SiO2", "SiO2", thkn="3+-2nm", rough="1+-1nm", bydensity=True)
NbLay = esc.layer("Layer: nb", "Nb", thkn="10+-2nm", rough="1+-1nm", bydensity=True)
Sub = esc.substrate("Substrate: Si", "Si", rough="1+-1nm", bydensity=True)
sample_10 = esc.multilayer("CuNi/Nb/Si_10", formula="Cap_common(10+-8nm,1+-1nm)/CuNi_common(10+-5nm,1+-1nm)/NbLay/SiO2Lay//Sub", bydensity=True, globals=globals())
sample_21 = esc.multilayer("CuNi/Nb/Si_21", formula="Cap_common(10+-8nm,1+-1nm)/CuNi_common(30+-5nm,1+-1nm)/NbLay/SiO2Lay//Sub", bydensity=True, globals=globals())
show(sample_10, source=src, figtitle="Sample 10")
show(sample_21, source=src, figtitle="Sample 21")
Qz=esc.var("qz")
Qz0=esc.var("qz0")
fwhm_10=esc.par("FWHM_10", 0.005, userlim=[0.003, 0.03], fixed=False)
fwhm_21=esc.par("FWHM_21", 0.005, userlim=[0.003, 0.03], fixed=False)
specrefl_10 = esc.specrefl("Specrefl_10", Qz, sample_10, "matrix", source=src)
specrefl_10 = esc.average_normal(specrefl_10, fwhm_10, Qz, Qz0)
specrefl_21 = esc.specrefl("Specrefl_21", Qz, sample_21, "matrix", source=src)
specrefl_21 = esc.average_normal(specrefl_21, fwhm_21, Qz, Qz0)
B10=esc.par("Bgr 10", 1, scale=1e-6, userlim=[0, 5])
B21=esc.par("Bgr 21", 1, scale=1e-6, userlim=[0, 5])
I10=specrefl_10+B10
I21=specrefl_21+B21
qz, y, err=np.loadtxt("data/JAP15/XRR/Silicon/s10/ASCII/Si10.dat", unpack=True, skiprows=2)
qz=qz*10
dobj10 = esc.data("S10.dat", qz, y, err, copy=True)
qz, y, err=np.loadtxt("data/JAP15/XRR/Silicon/s21/ASCII/Si21.dat", unpack=True, skiprows=2)
qz=qz*10
dobj21 = esc.data("S21.dat", qz, y, err, copy=True)
mobj10 = esc.model("Model 10", I10, dobj10, residuals_scale="q4", weight_type="data")
mobj21 = esc.model("Model 21", I21, dobj21, residuals_scale="q4", weight_type="data")
opt = esc.diffevol("DiffEvol", [mobj10, mobj21], popsize=5, maxiter=70,
mutation=0.5, crossover=0.5, minconv=1e-3, nupdate=5,
polish_final_maxiter=50, polish_candidate_maxiter=0)
#opt()
show(opt, ylog=True)
opt
Name: DiffEvol Parameters number: 22 Parameter Value +- Error Units Fixed FWHM_10 0.011843 +- 0.0009844 0 Capping density 3.2719 +- 0.0070195 g/cm^3 0 Layer-Capping: Thickness 12.293 +- 0.0092808 nm 0 Layer-Capping: Roughness Sigma 1.5528 +- 0.0062791 nm 0 CuNi density 9.4879 +- 0.0021899 g/cm^3 0 Layer-CuNi: Thickness 13.648 +- 0.0062589 nm 0 Layer-CuNi: Roughness Sigma 0.55935 +- 0.0010004 nm 0 Nb density 9.1846 +- 0.0062983 g/cm^3 0 Layer: nb: Thickness 12 +- 0 nm 0 Layer: nb: Roughness Sigma 2 +- 0 nm 0 SiO2 density 3.0469 +- 0.070247 g/cm^3 0 Layer: SiO2: Thickness 4.3487 +- 0.034003 nm 0 Layer: SiO2: Roughness Sigma 1.2464 +- 0.0070056 nm 0 Si density 2.5843 +- 0.11571 g/cm^3 0 Substrate: Si: Roughness Sigma 0.97898 +- 0.050044 nm 0 Bgr 10 1.5168 +- 0.013591 x1e-06 0 FWHM_21 0.015814 +- 0.00045991 0 Layer-Capping: Thickness 8.728 +- 0.01174 nm 0 Layer-Capping: Roughness Sigma 1.6869 +- 0.0072767 nm 0 Layer-CuNi: Thickness 32.713 +- 0.0067099 nm 0 Layer-CuNi: Roughness Sigma 0.50413 +- 0.0011366 nm 0 Bgr 21 1.4718 +- 0.030647 x1e-06 0
show(sample_10, source=src, figtitle="Sample 10")
show(sample_21, source=src, figtitle="Sample 21")