Skip to content

Commit

Permalink
Merge pull request #187 from shac170/dev
Browse files Browse the repository at this point in the history
Added documentation for dd and reorganized other docs
  • Loading branch information
jpmorgan98 committed Apr 27, 2024
2 parents 9b0a6df + c276422 commit 8a805cc
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 19 deletions.
28 changes: 14 additions & 14 deletions docs/source/pythonapi/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,10 @@ Defining geometry
:nosignatures:
:template: omcfunction.rst

mcdc.surface
mcdc.cell
mcdc.universe
mcdc.lattice


mcdc.surface
mcdc.universe

Defining simulation
-------------------
Expand All @@ -42,12 +40,10 @@ Defining simulation
:nosignatures:
:template: omcfunction.rst

mcdc.source
mcdc.tally
mcdc.eigenmode
mcdc.setting


mcdc.source
mcdc.tally

Defining techniques
-------------------
Expand All @@ -57,16 +53,20 @@ Defining techniques
:nosignatures:
:template: omcfunction.rst

mcdc.branchless_collision
mcdc.domain_decomposition
mcdc.dsm
mcdc.IC_generator
mcdc.iQMC
mcdc.implicit_capture
mcdc.weighted_emission
mcdc.population_control
mcdc.branchless_collision
mcdc.time_census
mcdc.weight_window
mcdc.iQMC
mcdc.weighted_emission
mcdc.weight_roulette
mcdc.IC_generator
mcdc.dsm
mcdc.weight_window






Expand Down
26 changes: 21 additions & 5 deletions mcdc/input_.py
Original file line number Diff line number Diff line change
Expand Up @@ -1392,12 +1392,31 @@ def domain_decomposition(
x=None,
y=None,
z=None,
t=None,
exchange_rate=100,
bank_size=1e5,
work_ratio=None,
repro=True,
):
"""
Activate domain decomposition.
Parameters
----------
x : array_like[float], optional
Location of subdomain boundaries in x (default None).
y : array_like[float], optional
Location of subdomain boundaries in y (default None).
z : array_like[float], optional
Location of subdomain boundaries in z (default None).
exchange_rate : float, optional
number of particles to acumulate in the domain banks before sending.
work_ratio : array_like[integer], optional
Inte
Returns
-------
A domain decomposition card.
"""
card = mcdc.input_deck.technique
card["domain_decomposition"] = True
card["domain_bank_size"] = int(1e5)
Expand All @@ -1414,9 +1433,6 @@ def domain_decomposition(
if z is not None:
card["dd_mesh"]["z"] = z
dom_num += len(z)
if t is not None:
card["dd_mesh"]["t"] = t
dom_num += len(t)
# Set work ratio
if work_ratio is None:
card["dd_work_ratio"] = None
Expand Down

0 comments on commit 8a805cc

Please sign in to comment.