Skip to content

Commit

Permalink
fix: interface width is now expected within the interface definitions
Browse files Browse the repository at this point in the history
  • Loading branch information
aplowman committed Jan 8, 2024
1 parent 0eba178 commit da96a4a
Showing 1 changed file with 31 additions and 8 deletions.
39 changes: 31 additions & 8 deletions notebooks/demo_cipher_inputs.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "code",
"execution_count": null,
"execution_count": 1,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -12,7 +12,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 2,
"metadata": {},
"outputs": [],
"source": [
Expand Down Expand Up @@ -40,7 +40,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 3,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -51,10 +51,12 @@
"}\n",
"\n",
"int_props_1 = {\n",
" 'width': 4,\n",
" 'energy': {'e0': 5e+8},\n",
" 'mobility': {'m0': 1e-11},\n",
"}\n",
"int_props_2 = {\n",
" 'width': 4,\n",
" 'energy': {'e0': 5e+8},\n",
" 'mobility': {'m0': 1e-11},\n",
"}\n",
Expand All @@ -65,7 +67,6 @@
" 'initblocksize': [1, 1, 1],\n",
" 'initcoarsen': 6,\n",
" 'initrefine': 7,\n",
" 'interfacewidth': 4,\n",
" 'interpolation': 'cubic',\n",
" 'maxnrefine': 7,\n",
" 'minnrefine': 0,\n",
Expand Down Expand Up @@ -126,9 +127,20 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 4,
"metadata": {},
"outputs": [],
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Tessellating regions...done!\n",
"Finding neighbouring voxels...done!\n",
"Finding neighbour list...done!\n",
"Finding interface map matrix...done!\n"
]
}
],
"source": [
"# Define the material properties:\n",
"materials = [\n",
Expand Down Expand Up @@ -180,9 +192,20 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 5,
"metadata": {},
"outputs": [],
"outputs": [
{
"data": {
"text/plain": [
"WindowsPath('ex_1.1.yaml')"
]
},
"execution_count": 5,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"input_1_1.write_yaml(\"ex_1.1.yaml\")"
]
Expand Down

0 comments on commit da96a4a

Please sign in to comment.