merged with upstream/develop

This commit is contained in:
Sam Shaner 2016-11-02 13:29:26 -04:00
commit 4639fee7e1
33 changed files with 789 additions and 1585 deletions

View file

@ -45,18 +45,14 @@ sn119 = openmc.Nuclide('Sn119')
sn120 = openmc.Nuclide('Sn120')
sn122 = openmc.Nuclide('Sn122')
sn124 = openmc.Nuclide('Sn124')
u234 = openmc.Nuclide('U234')
u235 = openmc.Nuclide('U235')
u238 = openmc.Nuclide('U238')
u = openmc.Element('U')
o = openmc.Element('O')
# Instantiate some Materials and register the appropriate Nuclides
uo2 = openmc.Material(material_id=1, name='UO2 fuel at 2.4% wt enrichment')
uo2.set_density('g/cm3', 10.29769)
uo2.add_nuclide(u234, 4.4843e-6)
uo2.add_nuclide(u235, 5.5815e-4)
uo2.add_nuclide(u238, 2.2408e-2)
uo2.add_nuclide(o16, 4.5829e-2)
uo2.add_nuclide(o17, 1.1164e-4)
uo2.add_element(u, 1., enrichment=0.024)
uo2.add_element(o, 2.)
helium = openmc.Material(material_id=2, name='Helium for gap')
helium.set_density('g/cm3', 0.001598)

View file

@ -83,6 +83,7 @@ water.add_macroscopic(h2o_data)
# Instantiate a Materials collection and export to XML
materials_file = openmc.Materials([uo2, water])
materials_file.cross_sections = "./mgxs.h5"
materials_file.export_to_xml()
@ -132,7 +133,6 @@ geometry.export_to_xml()
# Instantiate a Settings object, set all runtime parameters, and export to XML
settings_file = openmc.Settings()
settings_file.energy_mode = "multi-group"
settings_file.cross_sections = "./mgxs.h5"
settings_file.batches = batches
settings_file.inactive = inactive
settings_file.particles = particles

View file

@ -1,10 +1,11 @@
<?xml version='1.0' encoding='utf-8'?>
<geometry>
<cell id="1" material="1" name="cell 1" region="-1" universe="0" />
<cell id="2" material="2" name="cell 2" region="((((1 4) -5) 6) -7)" universe="0" />
<cell id="2" material="7" name="cell 2" region="((((1 4) -5) 6) -7)" universe="0" />
<surface coeffs="0 0 0.54" id="1" name="Fuel OR" type="z-cylinder" />
<surface boundary="reflective" coeffs="-0.63" id="4" name="left" type="x-plane" />
<surface boundary="reflective" coeffs="0.63" id="5" name="right" type="x-plane" />
<surface boundary="reflective" coeffs="-0.63" id="4" name="left" type="x-plane" />
<surface boundary="reflective" coeffs=" 0.63" id="5" name="right" type="x-plane" />
<surface boundary="reflective" coeffs="-0.63" id="6" name="bottom" type="y-plane" />
<surface boundary="reflective" coeffs="0.63" id="7" name="top" type="y-plane" />
<surface boundary="reflective" coeffs=" 0.63" id="7" name="top" type="y-plane" />
</geometry>

View file

@ -1,11 +1,54 @@
<?xml version='1.0' encoding='utf-8'?>
<?xml version="1.0"?>
<materials>
<material id="1" name="UO2 fuel">
<density units="macro" value="1.0" />
<macroscopic name="UO2" />
</material>
<material id="2" name="Water">
<density units="macro" value="1.0" />
<macroscopic name="LWTR" />
</material>
<cross_sections>./mgxs.h5</cross_sections>
<!-- UO2 -->
<material id="1">
<density units="macro" value="1.0" />
<macroscopic name="UO2"/>
</material>
<!-- 4.3% MOX -->
<material id="2">
<density units="macro" value="1.0" />
<macroscopic name="MOX1"/>
</material>
<!-- 7.0 MOX -->
<material id="3">
<density units="macro" value="1.0" />
<macroscopic name="MOX2"/>
</material>
<!-- 8.0% MOX -->
<material id="4">
<density units="macro" value="1.0" />
<macroscopic name="MOX3"/>
</material>
<!-- Fission Chamber -->
<material id="5">
<density units="macro" value="1.0" />
<macroscopic name="FC"/>
</material>
<!-- Guide Tube -->
<material id="6">
<density units="macro" value="1.0" />
<macroscopic name="GT"/>
</material>
<!-- Water -->
<material id="7">
<density units="macro" value="1.0" />
<macroscopic name="LWTR"/>
</material>
<!-- Control Rod -->
<material id="8">
<density units="macro" value="1.0" />
<macroscopic name="CR"/>
</material>
</materials>

View file

@ -1,15 +1,37 @@
<?xml version='1.0' encoding='utf-8'?>
<?xml version="1.0"?>
<settings>
<eigenvalue>
<particles>1000</particles>
<batches>100</batches>
<inactive>10</inactive>
</eigenvalue>
<source strength="1.0">
<space type="box">
<parameters>-0.63 -0.63 -1 0.63 0.63 1</parameters>
</space>
</source>
<cross_sections>./mgxs.h5</cross_sections>
<energy_mode>multi-group</energy_mode>
<energy_mode>multi-group</energy_mode>
<!--
Define how many particles to run and for how many batches
in an eigenvalue calculation mode
-->
<eigenvalue>
<batches>100</batches>
<inactive>10</inactive>
<particles>1000</particles>
</eigenvalue>
<!--
Start with uniformally distributed neutron source
with the default energy spectrum of a Maxwellian
and isotropic distribution.
-->
<source>
<space type="box">
<parameters>
-0.63 -0.63 -1E50
0.63 0.63 1E50
</parameters>
</space>
</source>
<output>
<summary>true</summary>
<tallies>true</tallies>
</output>
<survival_biasing>false</survival_biasing>
</settings>