Independant Source Issues

I was reusing my simulation settings from another project but was running into an error with the lower left coordinate. I decided to change try a different initial source code (pasted below) and am getting the same error: ValueError: Unable to set “lower left coordinate” to “(-30.0, -30.0)” since it must be at least of length “3”

No matter what I set the lower left of the source to, it always says it is not of length 3, and I don’t know why. Below A_side is a float used elewhere in the code without issue.

source = openmc.IndependentSource()
source.space = openmc.stats.Box((-A_side/2, -A_side/2), (A_side/2, A_side/2))
source.angle = openmc.stats.Isotropic()
source.energy = openmc.stats.Discrete([10.0e6], [1.0])
source.time = openmc.stats.Uniform(0, 1e-6)
settings.source = source
settings.export_to_xml()

Nevermind, turns out you don’t need a source to run an eigenvalue sim anymore.

I believe this is because the Box method expsects coordiates to have 3 values (x,y,z). It looks like you just have 2 values.

https://docs.openmc.org/en/latest/pythonapi/generated/openmc.stats.Box.html