terrapower / armi

An open-source nuclear reactor analysis automation framework that helps design teams increase efficiency and quality
https://terrapower.github.io/armi/
Apache License 2.0
232 stars 89 forks source link

Add some logic so HexAssemblies are hexagonal #1528

Closed john-science closed 3 weeks ago

john-science commented 11 months ago

Right now, the classes HexAssembly and CartesianAssembly are just empty slates:

https://github.com/terrapower/armi/blob/8b9873cfe9df8dac6a26b28a7520c45b65fa3a50/armi/reactor/assemblies.py#L1229-L1237

https://github.com/terrapower/armi/blob/8b9873cfe9df8dac6a26b28a7520c45b65fa3a50/armi/reactor/assemblies.py#L1240-L1241

But they give people the assumption they can trust these assemblies have a shape, or the blocks inside them do. But obviously no.

I recommend that we override the superclass method Assembly.add() here to check the shape of the Blocks added to assemblies of these types. That will give users some trust, anyway, that instances of these classes are what you'd think at first glance.

john-science commented 11 months ago

@jeffbaylor @alexhjames Here is our ticket.