mirror of
https://github.com/galera951/experiment-automation.git
synced 2024-11-22 21:55:52 +03:00
140 lines
24 KiB
Plaintext
140 lines
24 KiB
Plaintext
|
{
|
||
|
"cells": [
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 17,
|
||
|
"id": "65a1d145-551e-436d-977f-0b9e15aa66a3",
|
||
|
"metadata": {
|
||
|
"tags": []
|
||
|
},
|
||
|
"outputs": [],
|
||
|
"source": [
|
||
|
"# %load /home/glebi/git/experiment-automation/processing_tools.py\n",
|
||
|
"import numpy as np\n",
|
||
|
"from scipy.optimize import curve_fit\n",
|
||
|
"import pandas as pd\n",
|
||
|
"\n",
|
||
|
"import matplotlib.pyplot as plt\n",
|
||
|
"import matplotlib\n",
|
||
|
"import scienceplots\n",
|
||
|
"\n",
|
||
|
"plt.style.use(['science', 'russian-font'])\n",
|
||
|
"\n",
|
||
|
"matplotlib.rcParams.update({\n",
|
||
|
" 'figure.figsize': [6, 4],\n",
|
||
|
" 'savefig.facecolor': 'white',\n",
|
||
|
" 'figure.dpi': 150.0,\n",
|
||
|
" 'font.size': 12.0,\n",
|
||
|
"})\n"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 50,
|
||
|
"id": "027f3055-bd02-4cf0-9f6a-8ca35e6b36c8",
|
||
|
"metadata": {
|
||
|
"tags": []
|
||
|
},
|
||
|
"outputs": [],
|
||
|
"source": [
|
||
|
"df = pd.read_csv(\"data.csv\")\n",
|
||
|
"cols = df.columns\n",
|
||
|
"\n",
|
||
|
"U = df[cols[0]] # +- 0.01 mV\n",
|
||
|
"I = df[cols[1]] # +- 0.001 mA"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 51,
|
||
|
"id": "1a1b6e09-f30a-4e32-b1c3-1097d9d0295c",
|
||
|
"metadata": {
|
||
|
"tags": []
|
||
|
},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"text/plain": [
|
||
|
"[<matplotlib.lines.Line2D at 0x7f526dba2d70>]"
|
||
|
]
|
||
|
},
|
||
|
"execution_count": 51,
|
||
|
"metadata": {},
|
||
|
"output_type": "execute_result"
|
||
|
},
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAtsAAAH9CAYAAADLbbAeAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMSwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy/bCgiHAAAACXBIWXMAABcSAAAXEgFnn9JSAAA/aklEQVR4nO3db2wb+Z3n+Y+qVJXEJcyybceDBEvcmUb2fECwDZAdBH3zJw8srWeuj4c8kKaB7d191hbOOGAR4Fp0T9CTztQF07IOGAxw0K3cDxb3x4fplnEYrOBLdJIfzOwguaCbBLQzwAnTMB0cgc2cI9vEncvJqlzFe6AUm6JIFimRxX/vF0AkJin/frR+LX7407e+v5larVYTAAAAgL4zhj0BAAAAYFIRtgEAAIABIWwDAAAAA0LYBgAAAAaEsA0AAAAMCGEbAAAAGBDCNgAAADAgs71+QaFQUKlUUiqVkiQtLy9rfn6+3/MCAAAAxl7XYbtcLmthYUGFQkGrq6v1+5eWlpTJZJTJZDp+fRiG+tWvfqXZ2VnNzMycfsYAAADAiKjVanr58qW++MUvyjBaFI3UuvDs2bNaKpWqbWxsHLt/c3OzJqm2uroa+3d4nleTxI0bN27cuHHjxo3bxN08z2uZgbva2f6TP/kTnT9/Xjdu3Dh2fyqVUiqVUjabjf07ZmePhvI8T5Zlyfd9OY5T//MgJTnWpI/HaxvP8XhtjDdqYyU9Hq9tPMeb5NeW9Hi8tsGNF/05yrrNYsN2tVrV7du3tbKycuKx+fl5PXv2rKuJRaUjlmUd+4do/vMgJTnWpI/HaxvP8XhtjDdqYyU9Hq9tPMeb5NeW9Hi8tsGN165MOrYbyZ07dyRJCwsLfZrarwc2DH3ve99rXdsy5pJ+bUmON8mvLWl838ZvrGGY5H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AAAABhXXV8gee/ePd27d+/YfZlMRsVise+TAgAAACZB12F7cXFR5XJZ1WpV2WxWCwsLunHjxiDnBgAAAIy1rsP26uqqMpnMIOcCAAAATBQukAQAAAAGhLANAAAADEjXZSTValW3b9/WkydP6n9eWFjQ4uLiwCYHAAAAjLOuw3ahUNDm5qZSqVT9vitXrqhcLmtlZaXrAX3fP3GfYRhdHXcJAAAADEsQBArD8Nh9rbJto67KSBYXF7Wzs3MsaEtHAbxQKKhUKnU9ScdxZNv2sZvrul1/PQAAADAMruueyLGO43T8mplarVY77YDlcllXrlzR4uKiNjc3Oz7X933Zti3P82RZ1rHH2NkGAADAqGu3s+04jg4PD09kXKmHMpJWzp8/L0k97WxbltVyIgAAAMAoM02z5w3i2DKS27dv65VXXqkf097K06dPexoUAAAAmAaxYXtnZ0fValXVavXEY1HIfu211/o+MQAAAGDcxYbtbDarYrGobDZ74rHd3V1J0sLCQv9nBgAAAIy52LC9vLysjz76qOVjm5ubymQyPbX+AwAAAKZFbNjOZDK6cOGCbt++fez+QqGgTz/9NLYLCQAAADCtum79t7u7q83NTT19+lTValWZTEarq6snem+3E7X+a9cWBf2xvr2vfC6t9MXOPR8rB562ihXdvH41oZkBAABMnriMe6Y+2/2cCM5ufXtfhbslXb40p/u3rrUN3JUDT2988ECPHj/X6ltZAjcAAMApxWXcrk6QxOhb395XLnNBly/N6dHj53rjgweqHHgnnvfTz36h3/6jH+rR4+e6fGlO+Vx6CLMFAACYDoTtCRDtaL+98RN9uPx628D9089+od/7wa6ePj/U+Tm74+43AAAAzo6wPQHyuXQ9YLcL3FHQfhnWNGvM6OPvfIugDQAAMGDUbE+Ixjrsy5fm9OHy63p74yd69Pi5Zs0ZvQyOvs2zxox+9N15ffNrXx7yjAEAAMbfyNV
|
||
|
"text/plain": [
|
||
|
"<Figure size 900x600 with 1 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"plt.plot(U, I, \"x\")"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 67,
|
||
|
"id": "048c8b91-5acd-4705-9989-a543d212c68c",
|
||
|
"metadata": {
|
||
|
"tags": []
|
||
|
},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"name": "stdout",
|
||
|
"output_type": "stream",
|
||
|
"text": [
|
||
|
"xi = 4.26e+18\n",
|
||
|
"En_max = 4.26e+18\n"
|
||
|
]
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"Up = 46e-3\n",
|
||
|
"Ip = 4.8e-3\n",
|
||
|
"Uv = 340.6e-3\n",
|
||
|
"Iv = 0.5e-3\n",
|
||
|
"e = 1.6e-19\n",
|
||
|
"\n",
|
||
|
"xi = 2*Uv/e\n",
|
||
|
"En_max = xi - Up*e\n",
|
||
|
"print(f\"xi = {xi:.2e}\\nEn_max = {En_max:.2e}\")"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": null,
|
||
|
"id": "a4878798-dbe1-47f5-adae-cc6a2e58bf27",
|
||
|
"metadata": {},
|
||
|
"outputs": [],
|
||
|
"source": []
|
||
|
}
|
||
|
],
|
||
|
"metadata": {
|
||
|
"kernelspec": {
|
||
|
"display_name": "Python 3 (ipykernel)",
|
||
|
"language": "python",
|
||
|
"name": "python3"
|
||
|
},
|
||
|
"language_info": {
|
||
|
"codemirror_mode": {
|
||
|
"name": "ipython",
|
||
|
"version": 3
|
||
|
},
|
||
|
"file_extension": ".py",
|
||
|
"mimetype": "text/x-python",
|
||
|
"name": "python",
|
||
|
"nbconvert_exporter": "python",
|
||
|
"pygments_lexer": "ipython3",
|
||
|
"version": "3.10.12"
|
||
|
}
|
||
|
},
|
||
|
"nbformat": 4,
|
||
|
"nbformat_minor": 5
|
||
|
}
|