From 526dbf2fc240b7f0f96f32625db8ff0e219ebcc6 Mon Sep 17 00:00:00 2001 From: Miriam Rathbun Date: Fri, 26 Feb 2021 12:01:29 -0700 Subject: [PATCH] Made requested changes --- docs/source/examples/CAPI.ipynb | 48 ++++++++++++++++----------------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/docs/source/examples/CAPI.ipynb b/docs/source/examples/CAPI.ipynb index bd8b3d0ebc..eab0604da0 100644 --- a/docs/source/examples/CAPI.ipynb +++ b/docs/source/examples/CAPI.ipynb @@ -131,7 +131,7 @@ "gap_list = []\n", "clad_list = []\n", "water_list = []\n", - "for i in range(1,11):\n", + "for i in range(1, 11):\n", " fuel_list.append(openmc.Cell(cell_id=i))\n", " gap_list.append(openmc.Cell(cell_id=i+10))\n", " clad_list.append(openmc.Cell(cell_id=i+20))\n", @@ -243,7 +243,7 @@ }, { "cell_type": "code", - "execution_count": 9, + "execution_count": 13, "metadata": {}, "outputs": [], "source": [ @@ -254,7 +254,7 @@ "settings_file = openmc.Settings()\n", "settings_file.batches = 100\n", "settings_file.inactive = 10\n", - "settings_file.particles = 200\n", + "settings_file.particles = 10000\n", "settings_file.temperature = {'multipole': True, 'method': 'interpolation', 'range': [290, 2500]}\n", "settings_file.source = openmc.source.Source(space=uniform_dist)\n", "settings_file.export_to_xml()" @@ -270,7 +270,7 @@ }, { "cell_type": "code", - "execution_count": 10, + "execution_count": 14, "metadata": {}, "outputs": [], "source": [ @@ -287,7 +287,7 @@ }, { "cell_type": "code", - "execution_count": 11, + "execution_count": 15, "metadata": {}, "outputs": [], "source": [ @@ -304,23 +304,23 @@ }, { "cell_type": "code", - "execution_count": 12, + "execution_count": 16, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ - "[[ 2223721.47896785]\n", - " [11295743.41566435]\n", - " [13759978.74467681]\n", - " [ 9233589.77281075]\n", - " [ 7989194.12896278]\n", - " [ 5473333.88363707]\n", - " [ 5016644.0905246 ]\n", - " [ 8729254.15260335]\n", - " [21998939.80880332]\n", - " [13424679.19319787]]\n" + "[[ 4178272.4202991 ]\n", + " [ 9595363.82759911]\n", + " [12307462.30060902]\n", + " [11772927.66594472]\n", + " [11892601.29001472]\n", + " [12203397.88895767]\n", + " [12851791.20965905]\n", + " [11760027.45873386]\n", + " [ 9293110.94735569]\n", + " [ 4511597.61592287]]\n" ] } ], @@ -338,7 +338,7 @@ }, { "cell_type": "code", - "execution_count": 13, + "execution_count": 17, "metadata": {}, "outputs": [ { @@ -369,7 +369,7 @@ }, { "cell_type": "code", - "execution_count": 14, + "execution_count": 18, "metadata": {}, "outputs": [], "source": [ @@ -380,7 +380,7 @@ }, { "cell_type": "code", - "execution_count": 15, + "execution_count": 19, "metadata": {}, "outputs": [ { @@ -394,7 +394,7 @@ ], "source": [ "print(\"fuel temperature is: \")\n", - "print(openmc.lib.Cell(new=False, index=5).get_temperature())" + "print(openmc.lib.cells[5].get_temperature())" ] }, { @@ -406,11 +406,11 @@ }, { "cell_type": "code", - "execution_count": 16, + "execution_count": 20, "metadata": {}, "outputs": [], "source": [ - "for i in range(4,14):\n", + "for i in range(4, 14):\n", " density = 0.65\n", " openmc.lib.materials[i].set_density(density, units='g/cm3')" ] @@ -424,7 +424,7 @@ }, { "cell_type": "code", - "execution_count": 17, + "execution_count": 21, "metadata": {}, "outputs": [], "source": [ @@ -441,7 +441,7 @@ }, { "cell_type": "code", - "execution_count": 18, + "execution_count": 22, "metadata": {}, "outputs": [], "source": [