diff --git a/.gitignore b/.gitignore
index 0ca13cda..77c73061 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,5 @@
deploy
/bin
+*~
+
+
diff --git a/README.md b/README.md
index 897eeb06..386f64fa 100644
--- a/README.md
+++ b/README.md
@@ -7,7 +7,7 @@ Cyclist is a visual interface companion for the Cyclus project. It provides an i
### Dependencies:
| package | version | download
| ------- | ------- | --------
-| Java | 8.0 | https://jdk8.java.net/download.html
+| Java | 8.0_25 | http://www.oracle.com/technetwork/java/javase/downloads/index-jsp-138363.html
| JavaFX | 8.0 | (JavaFX is part of Java 8)
| Ant | 1.9+ | http://ant.apache.org/bindownload.cgi
diff --git a/build.xml b/build.xml
index 29a3adba..14799d7e 100644
--- a/build.xml
+++ b/build.xml
@@ -5,6 +5,7 @@
+
@@ -35,7 +36,7 @@
-
+
@@ -45,7 +46,7 @@
-
+
@@ -126,6 +127,7 @@
+
@@ -160,7 +162,6 @@
-
@@ -168,12 +169,6 @@
-
-
-
-
-
-
@@ -212,7 +207,7 @@
-
+
@@ -224,6 +219,7 @@
+
+
+
diff --git a/cyclist/.classpath b/cyclist/.classpath
index a91821f3..f4206804 100644
--- a/cyclist/.classpath
+++ b/cyclist/.classpath
@@ -5,16 +5,16 @@
-
-
-
+
-
+
+
+
diff --git a/cyclist/.classpath.orig b/cyclist/.classpath.orig
index b27ba589..bd8ee54a 100644
--- a/cyclist/.classpath.orig
+++ b/cyclist/.classpath.orig
@@ -5,20 +5,19 @@
-
-
-
-
-
-<<<<<<< HEAD
+
+
+
-
+<<<<<<< HEAD
=======
->>>>>>> upstream/master
+
+
+>>>>>>> d1089b11dcdf5ed055565977412869ee90c1a44b
diff --git a/cyclist/.classpath~ b/cyclist/.classpath~
deleted file mode 100644
index ae6dc9ff..00000000
--- a/cyclist/.classpath~
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/cyclist/cyclus.sqlite b/cyclist/cyclus.sqlite
deleted file mode 100644
index 1b9a0e4b..00000000
Binary files a/cyclist/cyclus.sqlite and /dev/null differ
diff --git a/cyclist/default-metadata.json b/cyclist/default-metadata.json
deleted file mode 100644
index 5edb40ef..00000000
--- a/cyclist/default-metadata.json
+++ /dev/null
@@ -1,713 +0,0 @@
-{
- "annotations": {
- ":agents:KFacility": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader"
- ],
- "doc": "A facility designed for integration tests that both provides and consumes commodities. It changes its request and offer amounts based on a power law with respect to time.",
- "entity": "facility",
- "name": "cyclus::KFacility",
- "parents": ["cyclus::Facility"],
- "vars": {
- "current_capacity": {
- "default": 0,
- "doc": "number of output commodity units that can be supplied at the current time step (infinite capacity can be represented by a very large number",
- "index": 5,
- "tooltip": "current output capacity",
- "type": "double"
- },
- "in_capacity": {
- "doc": "number of commodity units that can be taken at each time step (infinite capacity can be represented by a very large number",
- "index": 3,
- "tooltip": "input commodity capacity",
- "type": "double"
- },
- "in_commod": {
- "doc": "commodity that the k-facility consumes",
- "index": 0,
- "schematype": "token",
- "tooltip": "input commodity",
- "type": "std::string",
- "uitype": "incommodity"
- },
- "inventory": {
- "capacity": "max_inv_size",
- "index": 7,
- "type": "cyclus::toolkit::ResourceBuff"
- },
- "k_factor_in": {
- "doc": "conversion factor that governs the behavior of the k-facility's input commodity capacity",
- "index": 8,
- "tooltip": "input k-factor",
- "type": "double"
- },
- "k_factor_out": {
- "doc": "conversion factor that governs the behavior of the k-facility's output commodity capacity",
- "index": 9,
- "tooltip": "output k-factor",
- "type": "double"
- },
- "max_inv_size": {
- "default": 1.000000000000000e+299,
- "doc": "total maximum inventory size of the k-facility",
- "index": 6,
- "tooltip": "k-facility maximum inventory size",
- "type": "double"
- },
- "out_capacity": {
- "doc": "number of commodity units that can be supplied at each time step (infinite capacity can be represented by a very large number",
- "index": 4,
- "tooltip": "output commodity capacity",
- "type": "double"
- },
- "out_commod": {
- "doc": "commodity that the k-facility supplies",
- "index": 1,
- "schematype": "token",
- "tooltip": "output commodity",
- "type": "std::string",
- "uitype": "outcommodity"
- },
- "recipe_name": {
- "doc": "recipe name for the k-facility's in-commodity",
- "index": 2,
- "schematype": "token",
- "shape": [50],
- "tooltip": "in-commodity recipe name",
- "type": "std::string",
- "uitype": "recipe"
- }
- }
- },
- ":agents:NullInst": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Ider",
- "cyclus::Institution",
- "cyclus::StateWrangler",
- "cyclus::TimeListener"
- ],
- "doc": "An instition that owns facilities in the simulation but exhibits null behavior. No parameters are given when using the null institution.",
- "entity": "institution",
- "name": "cyclus::NullInst",
- "parents": ["cyclus::Institution"],
- "vars": {}
- },
- ":agents:NullRegion": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Ider",
- "cyclus::Region",
- "cyclus::StateWrangler",
- "cyclus::TimeListener"
- ],
- "doc": "A region that owns the simulation's institutions but exhibits null behavior. No parameters are given when using the null region.",
- "entity": "region",
- "name": "cyclus::NullRegion",
- "parents": ["cyclus::Region"],
- "vars": {}
- },
- ":agents:Predator": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader"
- ],
- "doc": "A facility that represents predators in the Lotka-Volterra integration tests",
- "entity": "facility",
- "name": "cyclus::Predator",
- "parents": ["cyclus::Facility"],
- "vars": {
- "age": {
- "default": 0,
- "doc": "age of predator at beginning of simulation",
- "index": 7,
- "tooltip": "predator age",
- "type": "int"
- },
- "birth_and_death": {
- "default": 0,
- "doc": "whether or not simultaneous birth and and death are allowed (i.e., can a facility give birth and die in the same time step?)",
- "index": 11,
- "tooltip": "simultaneous birth and death?",
- "type": "bool"
- },
- "commod": {
- "doc": "commodity that the predator supplies",
- "index": 0,
- "schematype": "token",
- "tooltip": "predator commodity",
- "type": "std::string",
- "uitype": "outcommodity"
- },
- "consumed": {
- "default": 0,
- "doc": "how many units of prey consumed per time step",
- "index": 12,
- "tooltip": "prey consumed",
- "type": "double"
- },
- "dead": {
- "default": 0,
- "doc": "flag for whether predator is currently dead",
- "index": 9,
- "tooltip": "dead?",
- "type": "bool"
- },
- "full": {
- "default": 1,
- "doc": "how many units of prey a predator consumes until it is satisfied",
- "index": 2,
- "tooltip": "feast size",
- "type": "double"
- },
- "hunt_cap": {
- "default": 1,
- "doc": "how many units of prey a predator can catch during a hunt",
- "index": 3,
- "tooltip": "hunting yield",
- "type": "double"
- },
- "hunt_factor": {
- "default": 0,
- "doc": "whether or not to base hunting success on relative predator/prey populations",
- "index": 10,
- "tooltip": "hunting success factor",
- "type": "bool"
- },
- "hunt_freq": {
- "default": 1,
- "doc": "how often a predator needs to hunt",
- "index": 4,
- "tooltip": "hunting frequency",
- "type": "int"
- },
- "lifespan": {
- "default": 1,
- "doc": "how long a predator lives",
- "index": 8,
- "tooltip": "predator lifespan",
- "type": "int"
- },
- "nchildren": {
- "default": 1,
- "doc": "number of predator children born at each birthing instance",
- "index": 6,
- "tooltip": "number of children",
- "type": "double"
- },
- "prey": {
- "doc": "prey that the predator hunts",
- "index": 1,
- "schematype": "token",
- "tooltip": "predator's prey",
- "type": "std::string",
- "uitype": "incommodity"
- },
- "success": {
- "default": 1,
- "doc": "fraction of hunting success on a scale from 0 to 1",
- "index": 5,
- "tooltip": "hunting success fraction",
- "type": "double"
- }
- }
- },
- ":agents:Prey": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader"
- ],
- "doc": "A facility that represents prey in the Lotka-Volterra integration tests",
- "entity": "facility",
- "name": "cyclus::Prey",
- "parents": ["cyclus::Facility"],
- "vars": {
- "age": {
- "default": 0,
- "doc": "age of prey at start of simulation",
- "index": 3,
- "tooltip": "prey age",
- "type": "int"
- },
- "birth_and_death": {
- "default": 1,
- "doc": "whether or not simultaneous birth and and death are allowed (i.e., can a facility give birth and die in the same time step?)",
- "index": 5,
- "tooltip": "simultaneous birth and death?",
- "type": "bool"
- },
- "birth_freq": {
- "default": 1,
- "doc": "number of time steps between birth of children",
- "index": 1,
- "tooltip": "birth frequency",
- "type": "int"
- },
- "commod": {
- "index": 0,
- "schematype": "token",
- "type": "std::string",
- "uitype": "outcommodity"
- },
- "dead": {
- "default": 0,
- "doc": "flag for whether prey is currently dead",
- "index": 4,
- "tooltip": "dead?",
- "type": "bool"
- },
- "nchildren": {
- "default": 1,
- "doc": "number of children born at each birthing instance",
- "index": 2,
- "tooltip": "number of children",
- "type": "int"
- }
- }
- },
- ":agents:Sink": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader"
- ],
- "doc": "A minimum implementation sink facility that accepts specified amounts of commodities from other agents",
- "entity": "facility",
- "name": "cyclus::Sink",
- "parents": ["cyclus::Facility"],
- "vars": {
- "capacity": {
- "doc": "capacity the sink facility can accept at each time step",
- "index": 1,
- "tooltip": "sink capacity",
- "type": "double"
- },
- "in_commods": {
- "doc": "commodities that the sink facility accepts",
- "index": 0,
- "schematype": "token",
- "tooltip": "input commodities for the sink",
- "type": ["std::vector", "std::string"],
- "uitype": "incommodity"
- },
- "inventory": {
- "capacity": "max_inv_size",
- "index": 3,
- "type": "cyclus::toolkit::ResourceBuff"
- },
- "max_inv_size": {
- "default": 1.000000000000000e+299,
- "doc": "total maximum inventory size of sink facility",
- "index": 2,
- "tooltip": "sink maximum inventory size",
- "type": "double"
- }
- }
- },
- ":agents:Source": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader"
- ],
- "doc": "A minimum implementation source facility that provides a commodity with a given capacity",
- "entity": "facility",
- "name": "cyclus::Source",
- "parents": ["cyclus::Facility"],
- "vars": {
- "capacity": {
- "doc": "amount of commodity that can be supplied at each time step",
- "index": 2,
- "tooltip": "source capacity",
- "type": "double"
- },
- "commod": {
- "doc": "commodity that the source facility supplies",
- "index": 0,
- "schematype": "token",
- "tooltip": "source commodity",
- "type": "std::string",
- "uitype": "outcommodity"
- },
- "recipe_name": {
- "doc": "recipe name for source facility's commodity",
- "index": 1,
- "schematype": "token",
- "tooltip": "commodity recipe name",
- "type": "std::string",
- "uitype": "recipe"
- }
- }
- },
- ":cycaless:BatchReactor": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader",
- "cyclus::toolkit::AgentManaged",
- "cyclus::toolkit::CommodityProducer"
- ],
- "doc": "A reactor facility that has three storage areas that hold batches of materials: reserves, core, and storage. It can manage multiple input-output commodity pairs.",
- "entity": "facility",
- "name": "cycaless::BatchReactor",
- "niche": "reactor",
- "parents": ["cyclus::Facility", "cyclus::toolkit::CommodityProducer"],
- "vars": {
- "crctx_": {
- "alias": "fuel",
- "doc": "in-out commodity and fuel recipe mappings",
- "index": 0,
- "type": ["std::vector", "CommodityRecipeContext"],
- "uitype": ["oneormore", "incommodity", "recipe", "outcommodity", "recipe"]
- },
- "fuel": "crctx_"
- }
- },
- ":cycaless:DeployInst": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Ider",
- "cyclus::Institution",
- "cyclus::StateWrangler",
- "cyclus::TimeListener"
- ],
- "doc": "An institution that owns, operates, and deploys facilities manually defined in the input file.",
- "entity": "institution",
- "name": "cycamore::DeployInst",
- "parents": ["cyclus::Institution"],
- "vars": {
- "build_sched_": {
- "alias": "buildorder",
- "doc": "list of times to build specific facilities",
- "index": 0,
- "type": ["std::map", "int", ["std::vector", "std::string"]],
- "uitype": ["oneormore", "prototype", "null", "null"]
- },
- "buildorder": "build_sched_"
- }
- },
- ":cycamore:BatchReactor": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader",
- "cyclus::toolkit::AgentManaged",
- "cyclus::toolkit::CommodityProducer"
- ],
- "doc": "A reactor facility that has three storage areas that hold batches of materials: reserves, core, and storage. It can manage multiple input-output commodity pairs.",
- "entity": "facility",
- "name": "cycamore::BatchReactor",
- "parents": ["cyclus::Facility", "cyclus::toolkit::CommodityProducer"],
- "vars": {}
- },
- ":cycamore:DeployInst": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Ider",
- "cyclus::Institution",
- "cyclus::StateWrangler",
- "cyclus::TimeListener"
- ],
- "doc": "An institution that owns, operates, and deploys facilities manually defined in the input file.",
- "entity": "institution",
- "name": "cycamore::DeployInst",
- "parents": ["cyclus::Institution"],
- "vars": {}
- },
- ":cycamore:EnrichmentFacility": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader"
- ],
- "doc": "An enrichment facility that intakes a commodity (usually natural uranium) and supplies a user-specified enriched product based on SWU capacity",
- "entity": "facility",
- "name": "cycamore::EnrichmentFacility",
- "niche": "enrichment",
- "parents": ["cyclus::Facility"],
- "vars": {
- "current_swu_capacity": {
- "derived_init": "current_swu_capacity = swu_capacity;",
- "index": 7,
- "type": "double"
- },
- "feed_assay": {
- "derived_init": "cyclus::Material::Ptr feed = cyclus::Material::CreateUntracked(0, context()->GetRecipe(in_recipe)); feed_assay = cyclus::toolkit::UraniumAssay(feed);",
- "doc": "feed assay for the enrichment process",
- "index": 8,
- "tooltip": "feed assay",
- "type": "double"
- },
- "in_commod": {
- "doc": "commodity that the enrichment facility accepts",
- "index": 0,
- "tooltip": "input commodity",
- "type": "std::string",
- "uitype": "incommodity"
- },
- "in_recipe": {
- "doc": "recipe for enrichment facility's input commodity",
- "index": 2,
- "tooltip": "input commodity recipe",
- "type": "std::string",
- "uitype": "recipe"
- },
- "initial_reserves": {
- "default": 0,
- "doc": "amount of natural uranium stored at the enrichment facility at the beginning of the simulation",
- "index": 6,
- "tooltip": "initial uranium reserves",
- "type": "double"
- },
- "inventory": {
- "capacity": "max_inv_size",
- "index": 9,
- "type": "cyclus::toolkit::ResourceBuff"
- },
- "max_inv_size": {
- "default": 1.000000000000000e+299,
- "doc": "maximum inventory capacity of natural uranium in the enrichment facility",
- "index": 5,
- "tooltip": "maximum inventory size",
- "type": "double"
- },
- "out_commod": {
- "doc": "commodity that the enrichment facility supplies",
- "index": 1,
- "tooltip": "output commodity",
- "type": "std::string",
- "uitype": "outcommodity"
- },
- "swu_capacity": {
- "default": 1.000000000000000e+299,
- "doc": "separative work unit (SWU) capcity of enrichment facility",
- "index": 4,
- "tooltip": "SWU capacity",
- "type": "double"
- },
- "tails_assay": {
- "default": 0.030,
- "doc": "tails assay from the enrichment process",
- "index": 3,
- "tooltip": "tails assay",
- "type": "double"
- }
- }
- },
- ":cycamore:GrowthRegion": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Ider",
- "cyclus::Region",
- "cyclus::StateWrangler",
- "cyclus::TimeListener"
- ],
- "doc": "A region that governs a scenario in which there is growth in demand for a commodity. ",
- "entity": "region",
- "name": "cycamore::GrowthRegion",
- "parents": ["cyclus::Region"],
- "vars": {
- "commodity_name": {
- "doc": "name of the commodity experiencing a growth in demand",
- "index": 0,
- "tooltip": "commodity in demand",
- "type": "std::string",
- "uitype": "commodity"
- },
- "demand_params": {
- "doc": "parameters that define the behavior of the demand type function",
- "index": 2,
- "tooltip": "demand parameters",
- "type": ["std::vector", "std::string"]
- },
- "demand_times": {
- "doc": "vector describing the length of times regarding the piecewise demand type",
- "index": 3,
- "tooltip": "demand times",
- "type": ["std::vector", "int"]
- },
- "demand_types": {
- "doc": "mathematical description of demand growth (i.e., linear, exponential, piecewise)",
- "index": 1,
- "tooltip": "demand type",
- "type": ["std::vector", "std::string"]
- }
- }
- },
- ":cycamore:ManagerInst": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Ider",
- "cyclus::Institution",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::toolkit::AgentManaged",
- "cyclus::toolkit::Builder",
- "cyclus::toolkit::CommodityProducerManager"
- ],
- "doc": "An institution that owns and operates a manually entered list of facilities in the input file",
- "entity": "institution",
- "name": "cycamore::ManagerInst",
- "parents": [
- "cyclus::Institution",
- "cyclus::toolkit::Builder",
- "cyclus::toolkit::CommodityProducerManager"
- ],
- "vars": {
- "prototypes": {
- "doc": "a facility to be managed by the institution",
- "index": 0,
- "tooltip": "facility prototypes",
- "type": ["std::vector", "std::string"],
- "uitype": "prototype"
- }
- }
- },
- ":cycamore:Sink": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader"
- ],
- "doc": "A sink facility that accepts specified amounts of commodities from other agents",
- "entity": "facility",
- "name": "cycamore::Sink",
- "parents": ["cyclus::Facility"],
- "vars": {
- "capacity": {
- "default": 1.000000000000000e+299,
- "doc": "capacity the sink facility can accept at each time step",
- "index": 1,
- "tooltip": "sink capacity",
- "type": "double"
- },
- "in_commods": {
- "doc": "commodities that the sink facility accepts",
- "index": 0,
- "tooltip": "input commodities",
- "type": ["std::vector", "std::string"],
- "uitype": ["oneormore", "incommodity"]
- },
- "inventory": {
- "capacity": "max_inv_size",
- "index": 3,
- "type": "cyclus::toolkit::ResourceBuff"
- },
- "max_inv_size": {
- "default": 1.000000000000000e+299,
- "doc": "total maximum inventory size of sink facility",
- "index": 2,
- "tooltip": "sink maximum inventory size",
- "type": "double"
- }
- }
- },
- ":cycamore:Source": {
- "all_parents": [
- "cyclus::Agent",
- "cyclus::Facility",
- "cyclus::Ider",
- "cyclus::StateWrangler",
- "cyclus::TimeListener",
- "cyclus::Trader",
- "cyclus::toolkit::AgentManaged",
- "cyclus::toolkit::CommodityProducer"
- ],
- "doc": "A source facility that provides a commodity with a given capacity",
- "entity": "facility",
- "name": "cycamore::Source",
- "parents": ["cyclus::Facility", "cyclus::toolkit::CommodityProducer"],
- "vars": {
- "capacity": {
- "default": 1.000000000000000e+299,
- "doc": "amount of commodity that can be supplied at each time step",
- "index": 2,
- "tooltip": "source capacity",
- "type": "double"
- },
- "current_capacity": {"derived_init": "current_capacity = capacity;", "index": 3, "type": "double"},
- "out_commod": {
- "doc": "output commodity that the source facility supplies",
- "index": 0,
- "tooltip": "source output commodity",
- "type": "std::string",
- "uitype": "outcommodity"
- },
- "recipe_name": {
- "doc": "recipe name for source facility's commodity",
- "index": 1,
- "tooltip": "commodity recipe name",
- "type": "std::string",
- "uitype": "recipe"
- }
- }
- }
- },
- "schema": {
- ":agents:KFacility": "\n\n \n\n\n \n\n\n \n\n\n \n\n\n \n\n\n \n \n \n\n\n \n \n \n\n\n \n\n\n \n\n\n",
- ":agents:NullInst": "",
- ":agents:NullRegion": "",
- ":agents:Predator": "\n\n \n\n\n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n",
- ":agents:Prey": "\n\n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n",
- ":agents:Sink": "\n\n \n \n \n \n \n\n\n \n\n\n \n \n \n\n\n",
- ":agents:Source": "\n\n \n\n\n \n\n\n \n\n\n",
- ":cycaless:BatchReactor": " \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n",
- ":cycaless:DeployInst": " \n \n \n \n \n \n \n \n \n \n \n \n \n",
- ":cycamore:BatchReactor": " \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n",
- ":cycamore:DeployInst": " \n \n \n \n \n \n \n \n \n \n \n \n \n",
- ":cycamore:EnrichmentFacility": "\n\n \n\n\n \n\n\n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n",
- ":cycamore:GrowthRegion": "\n\n \n\n\n \n \n \n \n \n\n\n \n \n \n \n \n\n\n \n \n \n \n \n\n\n",
- ":cycamore:ManagerInst": "\n\n \n \n \n \n \n\n\n",
- ":cycamore:Sink": "\n\n \n \n \n \n \n\n\n \n \n \n\n\n \n \n \n\n\n",
- ":cycamore:Source": "\n\n \n\n\n \n\n\n \n \n \n\n\n"
- },
- "specs": [
- ":agents:KFacility",
- ":agents:NullInst",
- ":agents:NullRegion",
- ":agents:Predator",
- ":agents:Prey",
- ":agents:Sink",
- ":agents:Source",
- ":cycaless:BatchReactor",
- ":cycaless:DeployInst",
- ":cycamore:BatchReactor",
- ":cycamore:DeployInst",
- ":cycamore:EnrichmentFacility",
- ":cycamore:GrowthRegion",
- ":cycamore:ManagerInst",
- ":cycamore:Sink",
- ":cycamore:Source"
- ]
-}
diff --git a/cyclist/externalApps/cycpost-darwin-386 b/cyclist/externalApps/cycpost-darwin-386
index b51c076a..a61db23d 100644
Binary files a/cyclist/externalApps/cycpost-darwin-386 and b/cyclist/externalApps/cycpost-darwin-386 differ
diff --git a/cyclist/externalApps/cycpost-darwin-amd64 b/cyclist/externalApps/cycpost-darwin-amd64
index ac94dcf4..22e5d32c 100755
Binary files a/cyclist/externalApps/cycpost-darwin-amd64 and b/cyclist/externalApps/cycpost-darwin-amd64 differ
diff --git a/cyclist/externalApps/cycpost-linux-386 b/cyclist/externalApps/cycpost-linux-386
index 3e7af471..1173f7f6 100644
Binary files a/cyclist/externalApps/cycpost-linux-386 and b/cyclist/externalApps/cycpost-linux-386 differ
diff --git a/cyclist/externalApps/cycpost-linux-amd64 b/cyclist/externalApps/cycpost-linux-amd64
index bad6a378..1a7f694e 100755
Binary files a/cyclist/externalApps/cycpost-linux-amd64 and b/cyclist/externalApps/cycpost-linux-amd64 differ
diff --git a/cyclist/externalApps/cycpost-linux-arm b/cyclist/externalApps/cycpost-linux-arm
index 54e48d11..6dcc8879 100644
Binary files a/cyclist/externalApps/cycpost-linux-arm and b/cyclist/externalApps/cycpost-linux-arm differ
diff --git a/cyclist/externalApps/cycpost-windows-386.exe b/cyclist/externalApps/cycpost-windows-386.exe
index 72e3a8bd..495cf0f6 100644
Binary files a/cyclist/externalApps/cycpost-windows-386.exe and b/cyclist/externalApps/cycpost-windows-386.exe differ
diff --git a/cyclist/externalApps/cycpost-windows-amd64.exe b/cyclist/externalApps/cycpost-windows-amd64.exe
index c53fa720..6e0cb168 100644
Binary files a/cyclist/externalApps/cycpost-windows-amd64.exe and b/cyclist/externalApps/cycpost-windows-amd64.exe differ
diff --git a/cyclist/lib/json-simple-1.1.1.jar b/cyclist/lib/json-simple-1.1.1.jar
new file mode 100644
index 00000000..66347a6c
Binary files /dev/null and b/cyclist/lib/json-simple-1.1.1.jar differ
diff --git a/cyclist/lib/sqlite-jdbc-3.8.10.1.jar b/cyclist/lib/sqlite-jdbc-3.8.10.1.jar
new file mode 100644
index 00000000..971a81f3
Binary files /dev/null and b/cyclist/lib/sqlite-jdbc-3.8.10.1.jar differ
diff --git a/cyclist/lib/sqlite-jdbc-3.8.7.jar b/cyclist/lib/sqlite-jdbc-3.8.7.jar
new file mode 100644
index 00000000..22acadde
Binary files /dev/null and b/cyclist/lib/sqlite-jdbc-3.8.7.jar differ
diff --git a/cyclist/skinImages/reactorSC2.jpg b/cyclist/skinImages/reactorSC2.jpg
deleted file mode 100644
index 0a9129a3..00000000
Binary files a/cyclist/skinImages/reactorSC2.jpg and /dev/null differ
diff --git a/cyclist/skinImages/sourceFacSC2.jpg b/cyclist/skinImages/sourceFacSC2.jpg
deleted file mode 100644
index 13c563c7..00000000
Binary files a/cyclist/skinImages/sourceFacSC2.jpg and /dev/null differ
diff --git a/cyclist/src/edu/utah/sci/cyclist/Cyclist.java b/cyclist/src/edu/utah/sci/cyclist/Cyclist.java
index 9e65334e..bc03fc88 100755
--- a/cyclist/src/edu/utah/sci/cyclist/Cyclist.java
+++ b/cyclist/src/edu/utah/sci/cyclist/Cyclist.java
@@ -31,6 +31,7 @@
import edu.utah.sci.cyclist.core.ui.MainScreen;
import javafx.application.Application;
import javafx.scene.Scene;
+import javafx.scene.image.Image;
import javafx.scene.layout.Pane;
import javafx.scene.layout.StackPane;
import javafx.stage.Stage;
@@ -62,6 +63,7 @@ public void start(Stage primaryStage) throws Exception {
primaryStage.setTitle(TITLE);
primaryStage.setScene(scene);
+ primaryStage.getIcons().add(new Image(Cyclist.class.getResourceAsStream("assets/cyclist.png")));
MainScreen root = new MainScreen(primaryStage);
diff --git a/cyclist/src/edu/utah/sci/cyclist/ToolsLibrary.java b/cyclist/src/edu/utah/sci/cyclist/ToolsLibrary.java
index 62d445d5..31bea0c2 100644
--- a/cyclist/src/edu/utah/sci/cyclist/ToolsLibrary.java
+++ b/cyclist/src/edu/utah/sci/cyclist/ToolsLibrary.java
@@ -22,69 +22,118 @@
*******************************************************************************/
package edu.utah.sci.cyclist;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.stream.Collectors;
+
import edu.utah.sci.cyclist.core.tools.SimpleToolFactory;
import edu.utah.sci.cyclist.core.tools.Tool;
import edu.utah.sci.cyclist.core.tools.ToolFactory;
import edu.utah.sci.cyclist.core.util.AwesomeIcon;
import edu.utexas.cycic.tools.CycicToolFactory;
-import edu.utexas.cycic.tools.FacilitySorterToolFactory;
-import edu.utexas.cycic.tools.InstitutionViewToolFactory;
+import edu.utexas.cycic.tools.InstitutionCorralViewToolFactory;
+//import edu.utexas.cycic.tools.InstitutionCorralViewToolFactory;
import edu.utexas.cycic.tools.RecipeFormToolFactory;
import edu.utexas.cycic.tools.RegionCorralViewToolFactory;
-import edu.utexas.cycic.tools.SimulationInfoToolFactory;
-import edu.utexas.cycic.tools.TimelineDisplayToolFactory;
public class ToolsLibrary {
-
- public static final ToolFactory[] factories = {
- new SimpleToolFactory("edu.utah.sci.cyclist.core",
- "Table", AwesomeIcon.LIST_ALT,
- "ui.views.SimpleTableView",
- "presenter.TablePresenter"),
-
- new SimpleToolFactory("edu.utah.sci.cyclist.core",
- "Plot", AwesomeIcon.BAR_CHART_ALT,
- "ui.views.ChartView",
- "presenter.ChartPresenter"),
-
- new SimpleToolFactory("edu.utah.sci.cyclist.neup",
- "Flow", AwesomeIcon.RANDOM,
- "ui.views.flow.FlowView",
- "presenter.NEUPPresenter"),
-
- new SimpleToolFactory("edu.utah.sci.cyclist.neup",
- "Inventory", AwesomeIcon.BOOK,
- "ui.views.inventory.InventoryView",
- "presenter.NEUPPresenter"),
-
- new SimpleToolFactory("edu.utah.sci.cyclist.core",
- "Workspace", AwesomeIcon.DESKTOP,
- "ui.views.Workspace",
- "presenter.WorkspacePresenter")
- };
-
- public static final ToolFactory[] inputFactories = {
- new CycicToolFactory(),
- new InstitutionViewToolFactory(),
- new RecipeFormToolFactory(),
- new RegionCorralViewToolFactory(),
- //new TimelineDisplayToolFactory()
- };
+ public static final String VIS_TOOL = "vis_tool";
+ public static final String SCENARIO_TOOL = "scenario_tool";
+
+ private static List factories = new ArrayList<>();
+
+ public static void register(ToolFactory... list) {
+ for (ToolFactory factory : list)
+ factories.add(factory);
+ }
+
- public static ToolFactory findFactory(String name) {
- for (int i=0; i f.getToolName().equals(name))
+ .findFirst()
+ .get();
+ }
+
+ public static List getFactoriesOfType(String type) {
+ return factories
+ .stream()
+ .filter(f -> f.getToolType().equals(type))
+ .collect(Collectors.toList());
+ }
+
+ public static List getFactoriesOfType(String type, boolean level) {
+ return factories
+ .stream()
+ .filter(f -> f.getToolType().equals(type))
+ .filter(f -> f.isUserLevel() == level)
+ .collect(Collectors.toList());
}
public static Tool createTool(String name) throws InstantiationException, IllegalAccessException, ClassNotFoundException {
Tool tool = null;
- ToolFactory factory = findFactory(name);
+ ToolFactory factory = getFactory(name);
if (factory != null)
tool = factory.create();
return tool;
}
+
+ static {
+ register(
+ new SimpleToolFactory("edu.utah.sci.cyclist.core",
+ "Table", VIS_TOOL, true, AwesomeIcon.LIST_ALT,
+ "ui.views.SimpleTableView",
+ "presenter.TablePresenter"),
+
+ new SimpleToolFactory("edu.utah.sci.cyclist.core",
+ "Plot", VIS_TOOL, true, AwesomeIcon.BAR_CHART_ALT,
+ "ui.views.ChartView",
+ "presenter.ChartPresenter"),
+
+ new SimpleToolFactory("edu.utah.sci.cyclist.neup",
+ "Flow", VIS_TOOL, true, AwesomeIcon.RANDOM,
+ "ui.views.flow.FlowView",
+ "presenter.NEUPPresenter"),
+
+ new SimpleToolFactory("edu.utah.sci.cyclist.neup",
+ "Inventory", VIS_TOOL, true, AwesomeIcon.BOOK,
+ "ui.views.inventory.InventoryView",
+ "presenter.NEUPPresenter"),
+
+ new SimpleToolFactory("edu.utah.sci.cyclist.core",
+ "Workspace", VIS_TOOL, true, AwesomeIcon.DESKTOP,
+ "ui.views.VisWorkspace",
+ "presenter.VisWorkspacePresenter")
+ );
+
+ register(
+ new SimpleToolFactory("edu.utexas.cycic",
+ "Cycic", SCENARIO_TOOL, false, AwesomeIcon.EYE,
+ "Cycic",
+ "presenter.CycicPresenter"
+ ),
+ new SimpleToolFactory("edu.utexas.cycic",
+ "Institution Corral", SCENARIO_TOOL, true, AwesomeIcon.GLOBE,
+ "InstitutionCorralView",
+ "presenter.InstitutionCorralViewPresenter"
+ ),
+ new SimpleToolFactory("edu.utexas.cycic",
+ "Recipe Builder", SCENARIO_TOOL, true, AwesomeIcon.SORT_ALPHA_DESC,
+ "RecipeForm",
+ "presenter.RecipeFormPresenter"
+ ),
+ new SimpleToolFactory("edu.utexas.cycic",
+ "Region Corral", SCENARIO_TOOL, true, AwesomeIcon.GLOBE,
+ "RegionCorralView",
+ "presenter.RegionCorralViewPresenter"
+ )
+// new CycicToolFactory(),
+// new InstitutionCorralViewToolFactory(),
+// new RecipeFormToolFactory(),
+// new RegionCorralViewToolFactory()
+ );
+ }
+
}
diff --git a/cyclist/src/edu/utah/sci/cyclist/assets/cyclist.png b/cyclist/src/edu/utah/sci/cyclist/assets/cyclist.png
new file mode 100644
index 00000000..d433b849
Binary files /dev/null and b/cyclist/src/edu/utah/sci/cyclist/assets/cyclist.png differ
diff --git a/cyclist/src/edu/utah/sci/cyclist/assets/default-metadata.json b/cyclist/src/edu/utah/sci/cyclist/assets/default-metadata.json
new file mode 100644
index 00000000..7f91dcdf
--- /dev/null
+++ b/cyclist/src/edu/utah/sci/cyclist/assets/default-metadata.json
@@ -0,0 +1,1377 @@
+{
+ "annotations": {
+ ":agents:KFacility": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader"
+ ],
+ "doc": "A facility designed for integration tests that both provides and consumes commodities. It changes its request and offer amounts based on a power law with respect to time.",
+ "entity": "facility",
+ "name": "cyclus::KFacility",
+ "parents": ["cyclus::Facility"],
+ "vars": {
+ "current_capacity": {
+ "alias": "current_capacity",
+ "default": 0,
+ "doc": "number of output commodity units that can be supplied at the current time step (infinite capacity can be represented by a very large number )",
+ "index": 5,
+ "tooltip": "current output capacity",
+ "type": "double",
+ "uilabel": "Current Capacity"
+ },
+ "in_capacity": {
+ "alias": "in_capacity",
+ "doc": "number of commodity units that can be taken at each timestep (infinite capacity can be represented by a very large number)",
+ "index": 3,
+ "tooltip": "input commodity capacity",
+ "type": "double",
+ "uilabel": "Incoming Throughput"
+ },
+ "in_commod": {
+ "alias": "in_commod",
+ "doc": "commodity that the k-facility consumes",
+ "index": 0,
+ "schematype": "token",
+ "tooltip": "input commodity",
+ "type": "std::string",
+ "uilabel": "Input Commodity",
+ "uitype": "incommodity"
+ },
+ "inventory": {
+ "alias": "inventory",
+ "capacity": "max_inv_size",
+ "index": 7,
+ "tooltip": "inventory",
+ "type": "cyclus::toolkit::ResourceBuff",
+ "uilabel": "inventory"
+ },
+ "k_factor_in": {
+ "alias": "k_factor_in",
+ "doc": "conversion factor that governs the behavior of the k-facility's input commodity capacity",
+ "index": 8,
+ "tooltip": "input k-factor",
+ "type": "double",
+ "uilabel": "Input K-Factor"
+ },
+ "k_factor_out": {
+ "alias": "k_factor_out",
+ "doc": "conversion factor that governs the behavior of the k-facility's output commodity capacity",
+ "index": 9,
+ "tooltip": "output k-factor",
+ "type": "double",
+ "uilabel": "Output K-Factor"
+ },
+ "max_inv_size": {
+ "alias": "max_inv_size",
+ "default": 1.000000000000000e+299,
+ "doc": "total maximum inventory size of the k-facility",
+ "index": 6,
+ "tooltip": "k-facility maximum inventory size",
+ "type": "double",
+ "uilabel": "Maximum Inventory"
+ },
+ "out_capacity": {
+ "alias": "out_capacity",
+ "doc": "number of commodity units that can be supplied at each timestep (infinite capacity can be represented by a very large number)",
+ "index": 4,
+ "tooltip": "output commodity capacity",
+ "type": "double",
+ "uilabel": "Outgoing Throughput"
+ },
+ "out_commod": {
+ "alias": "out_commod",
+ "doc": "commodity that the k-facility supplies",
+ "index": 2,
+ "schematype": "token",
+ "tooltip": "output commodity",
+ "type": "std::string",
+ "uilabel": "Output Commodity",
+ "uitype": "outcommodity"
+ },
+ "recipe_name": {
+ "alias": "recipe_name",
+ "doc": "recipe name for the k-facility's in-commodity",
+ "index": 1,
+ "schematype": "token",
+ "shape": [50],
+ "tooltip": "in-commodity recipe name",
+ "type": "std::string",
+ "uilabel": "Input Recipe",
+ "uitype": "recipe"
+ }
+ }
+ },
+ ":agents:NullInst": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Ider",
+ "cyclus::Institution",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener"
+ ],
+ "doc": "An instition that owns facilities in the simulation but exhibits null behavior. No parameters are given when using the null institution.",
+ "entity": "institution",
+ "name": "cyclus::NullInst",
+ "parents": ["cyclus::Institution"],
+ "vars": {}
+ },
+ ":agents:NullRegion": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Ider",
+ "cyclus::Region",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener"
+ ],
+ "doc": "A region that owns the simulation's institutions but exhibits null behavior. No parameters are given when using the null region.",
+ "entity": "region",
+ "name": "cyclus::NullRegion",
+ "parents": ["cyclus::Region"],
+ "vars": {}
+ },
+ ":agents:Predator": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader"
+ ],
+ "doc": "A facility that represents predators in the Lotka-Volterra integration tests",
+ "entity": "facility",
+ "name": "cyclus::Predator",
+ "parents": ["cyclus::Facility"],
+ "vars": {
+ "age": {
+ "alias": "age",
+ "default": 0,
+ "doc": "age of predator at beginning of simulation",
+ "index": 8,
+ "tooltip": "predator age",
+ "type": "int",
+ "uilabel": "Predator Age"
+ },
+ "birth_and_death": {
+ "alias": "birth_and_death",
+ "default": 0,
+ "doc": "whether or not simultaneous birth and death are allowed (i.e., can a facility give birth and die in the same time step?)",
+ "index": 12,
+ "tooltip": "simultaneous birth and death?",
+ "type": "bool",
+ "uilabel": "Simultaneous Birth and Death?"
+ },
+ "commod": {
+ "alias": "commod",
+ "doc": "commodity that the predator supplies",
+ "index": 0,
+ "schematype": "token",
+ "tooltip": "predator commodity",
+ "type": "std::string",
+ "uilabel": "Predator Commodity",
+ "uitype": "outcommodity"
+ },
+ "consumed": {
+ "alias": "consumed",
+ "default": 0,
+ "doc": "how many units of prey consumed per time step",
+ "index": 6,
+ "tooltip": "prey consumed",
+ "type": "double",
+ "uilabel": "Prey Consumed"
+ },
+ "dead": {
+ "alias": "dead",
+ "default": 0,
+ "doc": "flag for whether predator is currently dead",
+ "index": 10,
+ "tooltip": "dead?",
+ "type": "bool",
+ "uilabel": "Predator Dead?"
+ },
+ "full": {
+ "alias": "full",
+ "default": 1,
+ "doc": "how many units of prey a predator consumes until it is satisfied",
+ "index": 2,
+ "tooltip": "feast size",
+ "type": "double",
+ "uilabel": "Feast Size"
+ },
+ "hunt_cap": {
+ "alias": "hunt_cap",
+ "default": 1,
+ "doc": "how many units of prey a predator can catch during a hunt",
+ "index": 4,
+ "tooltip": "hunting yield",
+ "type": "double",
+ "uilabel": "Hunting Yield"
+ },
+ "hunt_factor": {
+ "alias": "hunt_factor",
+ "default": 0,
+ "doc": "whether or not to base hunting success on relative predator/prey populations",
+ "index": 7,
+ "tooltip": "hunting success factor",
+ "type": "bool",
+ "uilabel": "Hunting Success Factor"
+ },
+ "hunt_freq": {
+ "alias": "hunt_freq",
+ "default": 1,
+ "doc": "how often a predator needs to hunt",
+ "index": 3,
+ "tooltip": "hunting frequency",
+ "type": "int",
+ "uilabel": "Hunting Frequency"
+ },
+ "lifespan": {
+ "alias": "lifespan",
+ "default": 1,
+ "doc": "how long a predator lives",
+ "index": 9,
+ "tooltip": "predator lifespan",
+ "type": "int",
+ "uilabel": "Predator Lifespan"
+ },
+ "nchildren": {
+ "alias": "nchildren",
+ "default": 1,
+ "doc": "number of predator children born at each birthing instance",
+ "index": 11,
+ "tooltip": "number of children",
+ "type": "double",
+ "uilabel": "Number Predator Children"
+ },
+ "prey": {
+ "alias": "prey",
+ "doc": "prey that the predator hunts",
+ "index": 1,
+ "schematype": "token",
+ "tooltip": "predator's prey",
+ "type": "std::string",
+ "uilabel": "Prey Commodity",
+ "uitype": "incommodity"
+ },
+ "success": {
+ "alias": "success",
+ "default": 1,
+ "doc": "fraction of hunting success on a scale from 0 to 1",
+ "index": 5,
+ "tooltip": "hunting success fraction",
+ "type": "double",
+ "uilabel": "Hunting Success Fraction"
+ }
+ }
+ },
+ ":agents:Prey": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader"
+ ],
+ "doc": "A facility that represents prey in the Lotka-Volterra integration tests",
+ "entity": "facility",
+ "name": "cyclus::Prey",
+ "parents": ["cyclus::Facility"],
+ "vars": {
+ "age": {
+ "alias": "age",
+ "default": 0,
+ "doc": "age of prey at start of simulation",
+ "index": 1,
+ "tooltip": "prey age",
+ "type": "int",
+ "uilabel": "Prey Age"
+ },
+ "birth_and_death": {
+ "alias": "birth_and_death",
+ "default": 1,
+ "doc": "whether or not simultaneous birth and death are allowed (i.e., can a facility give birth and die in the same time step?)",
+ "index": 5,
+ "tooltip": "simultaneous birth and death?",
+ "type": "bool",
+ "uilabel": "Simultaneous Birth and Death?"
+ },
+ "birth_freq": {
+ "alias": "birth_freq",
+ "default": 1,
+ "doc": "number of time steps between birth of children",
+ "index": 4,
+ "tooltip": "birth frequency",
+ "type": "int",
+ "uilabel": "Birth Frequency"
+ },
+ "commod": {
+ "alias": "commod",
+ "index": 0,
+ "schematype": "token",
+ "tooltip": "commod",
+ "type": "std::string",
+ "uilabel": "Prey Commodity",
+ "uitype": "outcommodity"
+ },
+ "dead": {
+ "alias": "dead",
+ "default": 0,
+ "doc": "flag for whether prey is currently dead",
+ "index": 2,
+ "tooltip": "dead?",
+ "type": "bool",
+ "uilabel": "Dead?"
+ },
+ "nchildren": {
+ "alias": "nchildren",
+ "default": 1,
+ "doc": "number of children born at each birthing instance",
+ "index": 3,
+ "tooltip": "number of children",
+ "type": "int",
+ "uilabel": "Number of Children"
+ }
+ }
+ },
+ ":agents:Sink": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader"
+ ],
+ "doc": "A minimum implementation sink facility that accepts specified amounts of commodities from other agents",
+ "entity": "facility",
+ "name": "cyclus::Sink",
+ "parents": ["cyclus::Facility"],
+ "vars": {
+ "capacity": {
+ "alias": "capacity",
+ "doc": "capacity the sink facility can accept at each time step",
+ "index": 3,
+ "tooltip": "sink capacity",
+ "type": "double",
+ "uilabel": "Maximum Throughput"
+ },
+ "in_commods": {
+ "alias": ["in_commods", "val"],
+ "doc": "commodities that the sink facility accepts ",
+ "index": 0,
+ "tooltip": ["input commodities for the sink", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["List of Input Commodities", ""],
+ "uitype": ["oneormore", "incommodity"]
+ },
+ "inventory": {
+ "alias": "inventory",
+ "capacity": "max_inv_size",
+ "index": 4,
+ "tooltip": "inventory",
+ "type": "cyclus::toolkit::ResourceBuff",
+ "uilabel": "inventory"
+ },
+ "max_inv_size": {
+ "alias": "max_inv_size",
+ "default": 1.000000000000000e+299,
+ "doc": "total maximum inventory size of sink facility",
+ "index": 2,
+ "tooltip": "sink maximum inventory size",
+ "type": "double",
+ "uilabel": "Maximum Inventory"
+ },
+ "recipe_name": {
+ "alias": "recipe_name",
+ "default": "",
+ "doc": "Name of recipe to request.If empty, sink requests material no particular composition.",
+ "index": 1,
+ "tooltip": "input/request recipe name",
+ "type": "std::string",
+ "uilabel": "Input Recipe",
+ "uitype": "recipe"
+ }
+ }
+ },
+ ":agents:Source": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader"
+ ],
+ "doc": "A minimum implementation source facility that provides a commodity with a given capacity",
+ "entity": "facility",
+ "name": "cyclus::Source",
+ "parents": ["cyclus::Facility"],
+ "vars": {
+ "capacity": {
+ "alias": "capacity",
+ "doc": "amount of commodity that can be supplied at each time step",
+ "index": 2,
+ "tooltip": "source capacity",
+ "type": "double",
+ "uilabel": "Maximum Throughput"
+ },
+ "commod": {
+ "alias": "commod",
+ "doc": "commodity that the source facility supplies",
+ "index": 0,
+ "schematype": "token",
+ "tooltip": "source commodity",
+ "type": "std::string",
+ "uilabel": "Commodity",
+ "uitype": "outcommodity"
+ },
+ "recipe_name": {
+ "alias": "recipe_name",
+ "default": "",
+ "doc": "Recipe name for source facility's commodity.If empty, source supplies material with requested compositions.",
+ "index": 1,
+ "schematype": "token",
+ "tooltip": "commodity recipe name",
+ "type": "std::string",
+ "uilabel": "Recipe",
+ "uitype": "recipe"
+ }
+ }
+ },
+ ":cycamore:DeployInst": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Ider",
+ "cyclus::Institution",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener"
+ ],
+ "doc": "Builds and manages agents (facilities) according to a manually specified deployment schedule. Deployed agents are automatically decommissioned at the end of their lifetime. The user specifies a list of prototypes for each and corresponding build times, number to build, and (optionally) lifetimes. The same prototype can be specified multiple times with any combination of the same or different build times, build number, and lifetimes. ",
+ "entity": "institution",
+ "name": "cycamore::DeployInst",
+ "parents": ["cyclus::Institution"],
+ "vars": {
+ "build_times": {
+ "alias": ["build_times", "val"],
+ "doc": "Time step on which to deploy agents given in prototype list (same order).",
+ "index": 1,
+ "tooltip": ["build_times", ""],
+ "type": ["std::vector", "int"],
+ "uilabel": ["Deployment times", ""]
+ },
+ "lifetimes": {
+ "alias": ["lifetimes", "val"],
+ "default": [],
+ "doc": "Lifetimes for each prototype in prototype list (same order). These lifetimes override the lifetimes in the original prototype definition. If unspecified, lifetimes from the original prototype definitions are used. Although a new prototype is created in the Prototypes table for each lifetime with the suffix '_life_[lifetime]', all deployed agents themselves will have the same original prototype name (and so will the Agents tables).",
+ "index": 3,
+ "tooltip": ["lifetimes", ""],
+ "type": ["std::vector", "int"],
+ "uilabel": ["Lifetimes", ""]
+ },
+ "n_build": {
+ "alias": ["n_build", "val"],
+ "doc": "Number of each prototype given in prototype list that should be deployed (same order).",
+ "index": 2,
+ "tooltip": ["n_build", ""],
+ "type": ["std::vector", "int"],
+ "uilabel": ["Number to deploy", ""]
+ },
+ "prototypes": {
+ "alias": ["prototypes", "val"],
+ "doc": "Ordered list of prototypes to build.",
+ "index": 0,
+ "tooltip": ["prototypes", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Prototypes to deploy", ""],
+ "uitype": ["oneormore", "prototype"]
+ }
+ }
+ },
+ ":cycamore:Enrichment": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader"
+ ],
+ "doc": "The Enrichment facility is a simple agent that enriches natural uranium in a Cyclus simulation. It does not explicitly compute the physical enrichment process, rather it calculates the SWU required to convert an source uranium recipe (i.e. natural uranium) into a requested enriched recipe (i.e. 4% enriched uranium), given the natural uranium inventory constraint and its SWU capacity constraint.\n\nThe Enrichment facility requests an input commodity and associated recipe whose quantity is its remaining inventory capacity. All facilities trading the same input commodity (even with different recipes) will offer materials for trade. The Enrichment facility accepts any input materials with enrichments less than its tails assay, as long as some U235 is present, and preference increases with U235 content. If no U235 is present in the offered material, the trade preference is set to -1 and the material is not accepted. Any material components other than U235 and U238 are sent directly to the tails buffer.\n\nThe Enrichment facility will bid on any request for its output commodity up to the maximum allowed enrichment (if not specified, default is 100%) It bids on either the request quantity, or the maximum quanity allowed by its SWU constraint or natural uranium inventory, whichever is lower. If multiple output commodities with different enrichment levels are requested and the facility does not have the SWU or quantity capacity to meet all requests, the requests are fully, then partially filled in unspecified but repeatable order.\n\nAccumulated tails inventory is offered for trading as a specifiable output commodity.",
+ "entity": "facility",
+ "name": "cycamore::Enrichment",
+ "niche": "enrichment facility",
+ "parents": ["cyclus::Facility"],
+ "vars": {
+ "feed_commod": {
+ "alias": "feed_commod",
+ "doc": "feed commodity that the enrichment facility accepts",
+ "index": 0,
+ "tooltip": "feed commodity",
+ "type": "std::string",
+ "uilabel": "Feed Commodity",
+ "uitype": "incommodity"
+ },
+ "feed_recipe": {
+ "alias": "feed_recipe",
+ "doc": "recipe for enrichment facility feed commodity",
+ "index": 1,
+ "tooltip": "feed recipe",
+ "type": "std::string",
+ "uilabel": "Feed Recipe",
+ "uitype": "recipe"
+ },
+ "initial_feed": {
+ "alias": "initial_feed",
+ "default": 0,
+ "doc": "amount of natural uranium stored at the enrichment facility at the beginning of the simulation (kg)",
+ "index": 5,
+ "tooltip": "initial uranium reserves (kg)",
+ "type": "double",
+ "uilabel": "Initial Feed Inventory"
+ },
+ "inventory": {
+ "capacity": "max_feed_inventory",
+ "index": 10,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]
+ },
+ "max_enrich": {
+ "alias": "max_enrich",
+ "default": 1.0,
+ "doc": "maximum allowed weight fraction of U235 in product",
+ "index": 7,
+ "schema": " 0 1 ",
+ "tooltip": "maximum allowed enrichment fraction",
+ "type": "double",
+ "uilabel": "Maximum Allowed Enrichment"
+ },
+ "max_feed_inventory": {
+ "alias": "max_feed_inventory",
+ "default": 1.000000000000000e+299,
+ "doc": "maximum total inventory of natural uranium in the enrichment facility (kg)",
+ "index": 6,
+ "tooltip": "max inventory of feed material (kg)",
+ "type": "double",
+ "uilabel": "Maximum Feed Inventory"
+ },
+ "order_prefs": {
+ "alias": "order_prefs",
+ "default": 1,
+ "doc": "turn on preference ordering for input material so that EF chooses higher U235 content first",
+ "index": 8,
+ "tooltip": "Rank Material Requests by U235 Content",
+ "type": "bool",
+ "uilabel": "Prefer feed with higher U235 content",
+ "userlevel": 10
+ },
+ "product_commod": {
+ "alias": "product_commod",
+ "doc": "product commodity that the enrichment facility generates",
+ "index": 2,
+ "tooltip": "product commodity",
+ "type": "std::string",
+ "uilabel": "Product Commodity",
+ "uitype": "outcommodity"
+ },
+ "swu_capacity": {
+ "alias": "swu_capacity",
+ "default": 1.000000000000000e+299,
+ "doc": "separative work unit (SWU) capacity of enrichment facility (kgSWU/timestep) ",
+ "index": 9,
+ "tooltip": "SWU capacity (kgSWU/month)",
+ "type": "double",
+ "uilabel": "SWU Capacity"
+ },
+ "tails": {"index": 11, "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]},
+ "tails_assay": {
+ "alias": "tails_assay",
+ "default": 0.0030,
+ "doc": "tails assay from the enrichment process",
+ "index": 4,
+ "tooltip": "tails assay",
+ "type": "double",
+ "uilabel": "Tails Assay"
+ },
+ "tails_commod": {
+ "alias": "tails_commod",
+ "doc": "tails commodity supplied by enrichment facility",
+ "index": 3,
+ "tooltip": "tails commodity",
+ "type": "std::string",
+ "uilabel": "Tails Commodity",
+ "uitype": "outcommodity"
+ }
+ }
+ },
+ ":cycamore:FuelFab": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader"
+ ],
+ "doc": "FuelFab takes in 2 streams of material and mixes them in ratios in order to supply material that matches some neutronics properties of reqeusted material. It uses an equivalence type method [1] inspired by a similar approach in the COSI fuel cycle simulator.\n\nThe FuelFab has 3 input inventories: fissile stream, filler stream, and an optional top-up inventory. All materials received into each inventory are always combined into a single material (i.e. a single fissile material, a single filler material, etc.). The input streams and requested fuel composition are each assigned weights based on summing:\n\n N * (p_i - p_U238) / (p_Pu239 - p_U238)\n\nfor each nuclide where:\n\n - p = nu*sigma_f - sigma_a for the nuclide\n - p_U238 is p for pure U238\n - p_Pu239 is p for pure Pu239\n - N is the nuclide's atom fraction\n - nu is the average # neutrons per fission\n - sigma_f is the microscopic fission cross-section\n - sigma_a is the microscopic neutron absorption cross-section\n\nThe cross sections are from the simple cross section library in PyNE. They can be set to either a thermal or fast neutron spectrum. A linear interpolation is performed using the weights of the fissile, filler, and target streams. The interpolation is used to compute a mixing ratio of the input streams that matches the target weight. In the event that the target weight is higher than the fissile stream weight, the FuelFab will attempt to use the top-up and fissile input streams together instead of the fissile and filler streams. All supplied material will always have the same weight as the requested material.\n\nThe supplying of mixed material is constrained by available inventory quantities and a per time step throughput limit. Requests for fuel material larger than the throughput can never be met. Fissile inventory can be requested/received via one or more commodities. The DRE request preference for each of these commodities can also optionally be specified. By default, the top-up inventory size is zero, and it is not used for mixing. \n\n[1] Baker, A. R., and R. W. Ross. \"Comparison of the value of plutonium and uranium isotopes in fast reactors.\" Proceedings of the Conference on Breeding. Economics, and Safety in Large Fast Power Reactors. 1963.",
+ "entity": "facility",
+ "name": "cycamore::FuelFab",
+ "niche": "fabrication",
+ "parents": ["cyclus::Facility"],
+ "vars": {
+ "fill": {
+ "capacity": "fill_size",
+ "index": 4,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]
+ },
+ "fill_commod_prefs": {
+ "alias": ["fill_commod_prefs", "val"],
+ "default": [],
+ "doc": "Filler stream commodity request preferences for each of the given filler commodities (same order). If unspecified, default is to use 1.0 for all preferences.",
+ "index": 1,
+ "tooltip": ["fill_commod_prefs", ""],
+ "type": ["std::vector", "double"],
+ "uilabel": ["Filler Stream Preferences", ""]
+ },
+ "fill_commods": {
+ "alias": ["fill_commods", "val"],
+ "doc": "Ordered list of commodities on which to requesting filler stream material.",
+ "index": 0,
+ "tooltip": ["fill_commods", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Filler Stream Commodities", ""],
+ "uitype": ["oneormore", "incommodity"]
+ },
+ "fill_recipe": {
+ "alias": "fill_recipe",
+ "doc": "Name of recipe to be used in filler material stream requests.",
+ "index": 2,
+ "tooltip": "fill_recipe",
+ "type": "std::string",
+ "uilabel": "Filler Stream Recipe",
+ "uitype": "recipe"
+ },
+ "fill_size": {
+ "alias": "fill_size",
+ "doc": "Size of filler material stream inventory.",
+ "index": 3,
+ "tooltip": "fill_size",
+ "type": "double",
+ "uilabel": "Filler Stream Inventory Capacity",
+ "units": "kg"
+ },
+ "fiss": {
+ "capacity": "fiss_size",
+ "index": 9,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]
+ },
+ "fiss_commod_prefs": {
+ "alias": ["fiss_commod_prefs", "val"],
+ "default": [],
+ "doc": "Fissile stream commodity request preferences for each of the given fissile commodities (same order). If unspecified, default is to use 1.0 for all preferences.",
+ "index": 6,
+ "tooltip": ["fiss_commod_prefs", ""],
+ "type": ["std::vector", "double"],
+ "uilabel": ["Fissile Stream Preferences", ""]
+ },
+ "fiss_commods": {
+ "alias": ["fiss_commods", "val"],
+ "doc": "Ordered list of commodities on which to requesting fissile stream material.",
+ "index": 5,
+ "tooltip": ["fiss_commods", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Fissile Stream Commodities", ""],
+ "uitype": ["oneormore", "incommodity"]
+ },
+ "fiss_recipe": {
+ "alias": "fiss_recipe",
+ "default": "",
+ "doc": "Name for recipe to be used in fissile stream requests. Empty string results in use of an empty dummy recipe.",
+ "index": 7,
+ "tooltip": "fiss_recipe",
+ "type": "std::string",
+ "uilabel": "Fissile Stream Recipe",
+ "uitype": "recipe"
+ },
+ "fiss_size": {
+ "alias": "fiss_size",
+ "doc": "Size of fissile material stream inventory.",
+ "index": 8,
+ "tooltip": "fiss_size",
+ "type": "double",
+ "uilabel": "Fissile Stream Inventory Capacity",
+ "units": "kg"
+ },
+ "outcommod": {
+ "alias": "outcommod",
+ "doc": "Commodity on which to offer/supply mixed fuel material.",
+ "index": 15,
+ "tooltip": "outcommod",
+ "type": "std::string",
+ "uilabel": "Output Commodity",
+ "uitype": "outcommodity"
+ },
+ "spectrum": {
+ "alias": "spectrum",
+ "categorical": ["fission_spectrum_ave", "thermal"],
+ "doc": "The type of cross-sections to use for composition property calculation. Use 'fission_spectrum_ave' for fast reactor compositions or 'thermal' for thermal reactors.",
+ "index": 17,
+ "tooltip": "spectrum",
+ "type": "std::string",
+ "uilabel": "Spectrum type"
+ },
+ "throughput": {
+ "alias": "throughput",
+ "doc": "Maximum number of kg of fuel material that can be supplied per time step.",
+ "index": 16,
+ "tooltip": "throughput",
+ "type": "double",
+ "uilabel": "Maximum Throughput",
+ "units": "kg"
+ },
+ "topup": {
+ "capacity": "topup_size",
+ "index": 14,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]
+ },
+ "topup_commod": {
+ "alias": "topup_commod",
+ "default": "",
+ "doc": "Commodity on which to request material for top-up stream. This MUST be set if 'topup_size > 0'.",
+ "index": 10,
+ "tooltip": "topup_commod",
+ "type": "std::string",
+ "uilabel": "Top-up Stream Commodity",
+ "uitype": "incommodity"
+ },
+ "topup_pref": {
+ "alias": "topup_pref",
+ "default": 0,
+ "doc": "Top-up material stream request preference.",
+ "index": 11,
+ "tooltip": "topup_pref",
+ "type": "double",
+ "uilabel": "Top-up Stream Preference"
+ },
+ "topup_recipe": {
+ "alias": "topup_recipe",
+ "default": "",
+ "doc": "Name of recipe to be used in top-up material stream requests. This MUST be set if 'topup_size > 0'.",
+ "index": 12,
+ "tooltip": "topup_recipe",
+ "type": "std::string",
+ "uilabel": "Top-up Stream Recipe",
+ "uitype": "recipe"
+ },
+ "topup_size": {
+ "alias": "topup_size",
+ "default": 0,
+ "doc": "Size of top-up material stream inventory.",
+ "index": 13,
+ "tooltip": "topup_size",
+ "type": "double",
+ "uilabel": "Top-up Stream Inventory Capacity",
+ "units": "kg"
+ }
+ }
+ },
+ ":cycamore:GrowthRegion": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Ider",
+ "cyclus::Region",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener"
+ ],
+ "doc": "A region that governs a scenario in which there is growth in demand for a commodity. ",
+ "entity": "region",
+ "name": "cycamore::GrowthRegion",
+ "parents": ["cyclus::Region"],
+ "vars": {
+ "commodity_demand": {
+ "alias": [
+ ["growth", "item"],
+ "commod",
+ ["piecewise_function", ["piece", "start", ["function", "type", "params"]]]
+ ],
+ "doc": "Nameplate capacity demand functions.\n\nEach demand type must be for a commodity for which capacity can be built (e.g., 'power' from cycamore::Reactors). Any archetype that implements the cyclus::toolkit::CommodityProducer interface can interact with the GrowthRegion in the manner.\n\nDemand functions are defined as piecewise functions. Each piece must be provided a starting time and function description. Each function description is comprised of a function type and associated parameters. \n\n * Start times are inclusive. For a start time :math:`t_0`, the demand function is evaluated on :math:`[t_0, \\infty)`.\n\n * Supported function types are based on the `cyclus::toolkit::BasicFunctionFactory types `_. \n\n * The type name is the lower-case name of the function (e.g., 'linear', 'exponential', etc.).\n\n * The parameters associated with each function type can be found on their respective documentation pages.",
+ "index": 0,
+ "tooltip": [["commodity_demand", ""], "", ["", ["", "", ["", "", ""]]]],
+ "type": [
+ "std::map",
+ "std::string",
+ [
+ "std::vector",
+ ["std::pair", "int", ["std::pair", "std::string", "std::string"]]
+ ]
+ ],
+ "uilabel": [["Growth Demand Curves", ""], "", ["", ["", "", ["", "", ""]]]],
+ "uitype": [
+ "oneormore",
+ "string",
+ ["oneormore", ["pair", "int", ["pair", "string", "string"]]]
+ ]
+ },
+ "growth": "commodity_demand"
+ }
+ },
+ ":cycamore:ManagerInst": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Ider",
+ "cyclus::Institution",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::toolkit::AgentManaged",
+ "cyclus::toolkit::Builder",
+ "cyclus::toolkit::CommodityProducerManager"
+ ],
+ "doc": "An institution that owns and operates a manually entered list of facilities in the input file",
+ "entity": "institution",
+ "name": "cycamore::ManagerInst",
+ "parents": [
+ "cyclus::Institution",
+ "cyclus::toolkit::Builder",
+ "cyclus::toolkit::CommodityProducerManager"
+ ],
+ "vars": {
+ "prototypes": {
+ "alias": ["prototypes", "val"],
+ "doc": "A set of facility prototypes that this institution can build. All prototypes in this list must be based on an archetype that implements the cyclus::toolkit::CommodityProducer interface",
+ "index": 0,
+ "tooltip": ["producer facility prototypes", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Producer Prototype List", ""],
+ "uitype": ["oneormore", "prototype"]
+ }
+ }
+ },
+ ":cycamore:Reactor": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader",
+ "cyclus::toolkit::AgentManaged",
+ "cyclus::toolkit::CommodityProducer"
+ ],
+ "doc": "Reactor is a simple, general reactor based on static compositional transformations to model fuel burnup. The user specifies a set of input fuels and corresponding burnt compositions that fuel is transformed to when it is discharged from the core. No incremental transmutation takes place. Rather, at the end of an operational cycle, the batch being discharged from the core is instantaneously transmuted from its original fresh fuel composition into its spent fuel form.\n\nEach fuel is identified by a specific input commodity and has an associated input recipe (nuclide composition), output recipe, output commidity, and preference. The preference identifies which input fuels are preferred when requesting. Changes in these preferences can be specified as a function of time using the pref_change variables. Changes in the input-output recipe compositions can also be specified as a function of time using the recipe_change variables.\n\nThe reactor treats fuel as individual assemblies that are never split, combined or otherwise treated in any non-discrete way. Fuel is requested in full-or-nothing assembly sized quanta. If real-world assembly modeling is unnecessary, parameters can be adjusted (e.g. n_assem_core, assem_size, n_assem_batch). At the end of every cycle, a full batch is discharged from the core consisting of n_assem_batch assemblies of assem_size kg. The reactor also has a specifiable refueling time period following the end of each cycle at the end of which it will resume operation on the next cycle *if* it has enough fuel for a full core; otherwise it waits until it has enough fresh fuel assemblies.\n\nIn addition to its core, the reactor has an on-hand fresh fuel inventory and a spent fuel inventory whose capacities are specified by n_assem_fresh and n_assem_spent respectively. Each time step the reactor will attempt to acquire enough fresh fuel to fill its fresh fuel inventory (and its core if the core isn't currently full). If the fresh fuel inventory has zero capacity, fuel will be ordered just-in-time after the end of each operational cycle before the next begins. If the spent fuel inventory becomes full, the reactor will halt operation at the end of the next cycle until there is more room. Each time step, the reactor will try to trade away as much of its spent fuel inventory as possible.\n\nWhen the reactor reaches the end of its lifetime, it will discharge all material from its core and trade away all its spent fuel as quickly as possible. Full decommissioning will be delayed until all spent fuel is gone. If the reactor has a full core when it is decommissioned (i.e. is mid-cycle) when the reactor is decommissioned, half (rounded up to nearest int) of its assemblies are transmuted to their respective burnt compositions.",
+ "entity": "facility",
+ "name": "cycamore::Reactor",
+ "niche": "reactor",
+ "parents": ["cyclus::Facility", "cyclus::toolkit::CommodityProducer"],
+ "vars": {
+ "assem_size": {
+ "alias": "assem_size",
+ "doc": "Mass (kg) of a single assembly.",
+ "index": 9,
+ "tooltip": "assem_size",
+ "type": "double",
+ "uilabel": "Assembly Mass",
+ "units": "kg"
+ },
+ "core": {
+ "capacity": "n_assem_core * assem_size",
+ "index": 23,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]
+ },
+ "cycle_step": {
+ "alias": "cycle_step",
+ "default": 0,
+ "doc": "Number of time steps since the start of the last cycle. Only set this if you know what you are doing",
+ "index": 16,
+ "tooltip": "cycle_step",
+ "type": "int",
+ "uilabel": "Time Since Start of Last Cycle",
+ "units": "time steps"
+ },
+ "cycle_time": {
+ "alias": "cycle_time",
+ "doc": "The duration of a full operational cycle (excluding refueling time) in time steps.",
+ "index": 14,
+ "tooltip": "cycle_time",
+ "type": "int",
+ "uilabel": "Cycle Length",
+ "units": "time steps"
+ },
+ "discharged": {
+ "alias": "discharged",
+ "default": 0,
+ "doc": "This should NEVER be set manually",
+ "index": 25,
+ "internal": true,
+ "tooltip": "discharged",
+ "type": "bool",
+ "uilabel": "discharged"
+ },
+ "fresh": {
+ "capacity": "n_assem_fresh * assem_size",
+ "index": 22,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]
+ },
+ "fuel_incommods": {
+ "alias": ["fuel_incommods", "val"],
+ "doc": "Ordered list of input commodities on which to requesting fuel.",
+ "index": 0,
+ "tooltip": ["fuel_incommods", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Fresh Fuel Commodity List", ""],
+ "uitype": ["oneormore", "incommodity"]
+ },
+ "fuel_inrecipes": {
+ "alias": ["fuel_inrecipes", "val"],
+ "doc": "Fresh fuel recipes to request for each of the given fuel input commodities (same order).",
+ "index": 1,
+ "tooltip": ["fuel_inrecipes", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Fresh Fuel Recipe List", ""],
+ "uitype": ["oneormore", "recipe"]
+ },
+ "fuel_outcommods": {
+ "alias": ["fuel_outcommods", "val"],
+ "doc": "Output commodities on which to offer spent fuel originally received as each particular input commodity (same order).",
+ "index": 3,
+ "tooltip": ["fuel_outcommods", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Spent Fuel Commodity List", ""],
+ "uitype": ["oneormore", "outcommodity"]
+ },
+ "fuel_outrecipes": {
+ "alias": ["fuel_outrecipes", "val"],
+ "doc": "Spent fuel recipes corresponding to the given fuel input commodities (same order). Fuel received via a particular input commodity is transmuted to the recipe specified here after being burned during a cycle.",
+ "index": 4,
+ "tooltip": ["fuel_outrecipes", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Spent Fuel Recipe List", ""],
+ "uitype": ["oneormore", "recipe"]
+ },
+ "fuel_prefs": {
+ "alias": ["fuel_prefs", "val"],
+ "default": [],
+ "doc": "The preference for each type of fresh fuel requested corresponding to each input commodity (same order). If no preferences are specified, zero is used for all fuel requests (default).",
+ "index": 2,
+ "tooltip": ["fuel_prefs", ""],
+ "type": ["std::vector", "double"],
+ "uilabel": ["Fresh Fuel Preference List", ""]
+ },
+ "n_assem_batch": {
+ "alias": "n_assem_batch",
+ "doc": "Number of assemblies that constitute a single batch. This is the number of assemblies discharged from the core fully burned each cycle.Batch size is equivalent to ``n_assem_batch / n_assem_core``.",
+ "index": 10,
+ "tooltip": "n_assem_batch",
+ "type": "int",
+ "uilabel": "Number of Assemblies per Batch"
+ },
+ "n_assem_core": {
+ "alias": "n_assem_core",
+ "doc": "Number of assemblies that constitute a full core.",
+ "index": 11,
+ "tooltip": "n_assem_core",
+ "type": "int",
+ "uilabel": "Number of Assemblies in Core"
+ },
+ "n_assem_fresh": {
+ "alias": "n_assem_fresh",
+ "default": 0,
+ "doc": "Number of fresh fuel assemblies to keep on-hand if possible.",
+ "index": 12,
+ "tooltip": "n_assem_fresh",
+ "type": "int",
+ "uilabel": "Minimum Fresh Fuel Inventory",
+ "units": "assemblies"
+ },
+ "n_assem_spent": {
+ "alias": "n_assem_spent",
+ "default": 1000000000,
+ "doc": "Number of spent fuel assemblies that can be stored on-site before reactor operation stalls.",
+ "index": 13,
+ "tooltip": "n_assem_spent",
+ "type": "int",
+ "uilabel": "Maximum Spent Fuel Inventory",
+ "units": "assemblies"
+ },
+ "power_cap": {
+ "alias": "power_cap",
+ "default": 0,
+ "doc": "Amount of electrical power the facility produces when operating normally.",
+ "index": 17,
+ "tooltip": "power_cap",
+ "type": "double",
+ "uilabel": "Nominal Reactor Power",
+ "units": "MWe"
+ },
+ "power_name": {
+ "alias": "power_name",
+ "default": "power",
+ "doc": "The name of the 'power' commodity used in conjunction with a deployment curve.",
+ "index": 18,
+ "tooltip": "power_name",
+ "type": "std::string",
+ "uilabel": "Power Commodity Name"
+ },
+ "pref_change_commods": {
+ "alias": ["pref_change_commods", "val"],
+ "default": [],
+ "doc": "The input commodity for a particular fuel preference change. Same order as and direct correspondence to the specified preference change times.",
+ "index": 20,
+ "tooltip": ["pref_change_commods", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Commodity for Changed Fresh Fuel Preference", ""],
+ "uitype": ["oneormore", "incommodity"]
+ },
+ "pref_change_times": {
+ "alias": ["pref_change_times", "val"],
+ "default": [],
+ "doc": "A time step on which to change the request preference for a particular fresh fuel type.",
+ "index": 19,
+ "tooltip": ["pref_change_times", ""],
+ "type": ["std::vector", "int"],
+ "uilabel": ["Time to Change Fresh Fuel Preference", ""]
+ },
+ "pref_change_values": {
+ "alias": ["pref_change_values", "val"],
+ "default": [],
+ "doc": "The new/changed request preference for a particular fresh fuel. Same order as and direct correspondence to the specified preference change times.",
+ "index": 21,
+ "tooltip": ["pref_change_values", ""],
+ "type": ["std::vector", "double"],
+ "uilabel": ["Changed Fresh Fuel Preference", ""]
+ },
+ "recipe_change_commods": {
+ "alias": ["recipe_change_commods", "val"],
+ "default": [],
+ "doc": "The input commodity indicating fresh fuel for which recipes will be changed. Same order as and direct correspondence to the specified recipe change times.",
+ "index": 6,
+ "tooltip": ["recipe_change_commods", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Commodity for Changed Fresh/Spent Fuel Recipe", ""],
+ "uitype": ["oneormore", "incommodity"]
+ },
+ "recipe_change_in": {
+ "alias": ["recipe_change_in", "val"],
+ "default": [],
+ "doc": "The new input recipe to use for this recipe change. Same order as and direct correspondence to the specified recipe change times.",
+ "index": 7,
+ "tooltip": ["recipe_change_in", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["New Recipe for Fresh Fuel", ""],
+ "uitype": ["oneormore", "recipe"]
+ },
+ "recipe_change_out": {
+ "alias": ["recipe_change_out", "val"],
+ "default": [],
+ "doc": "The new output recipe to use for this recipe change. Same order as and direct correspondence to the specified recipe change times.",
+ "index": 8,
+ "tooltip": ["recipe_change_out", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["New Recipe for Spent Fuel", ""],
+ "uitype": ["oneormore", "recipe"]
+ },
+ "recipe_change_times": {
+ "alias": ["recipe_change_times", "val"],
+ "default": [],
+ "doc": "A time step on which to change the input-output recipe pair for a requested fresh fuel.",
+ "index": 5,
+ "tooltip": ["recipe_change_times", ""],
+ "type": ["std::vector", "int"],
+ "uilabel": ["Time to Change Fresh/Spent Fuel Recipe", ""]
+ },
+ "refuel_time": {
+ "alias": "refuel_time",
+ "doc": "The duration of a full refueling period - the minimum time between the end of a cycle and the start of the next cycle.",
+ "index": 15,
+ "tooltip": "refuel_time",
+ "type": "int",
+ "uilabel": "Refueling Outage Duration",
+ "units": "time steps"
+ },
+ "res_indexes": {
+ "alias": [["res_indexes", "item"], "key", "val"],
+ "default": {},
+ "doc": "This should NEVER be set manually",
+ "index": 26,
+ "internal": true,
+ "tooltip": [["res_indexes", ""], "", ""],
+ "type": ["std::map", "int", "int"],
+ "uilabel": [["res_indexes", ""], "", ""]
+ },
+ "spent": {
+ "capacity": "n_assem_spent * assem_size",
+ "index": 24,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]
+ }
+ }
+ },
+ ":cycamore:Separations": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader"
+ ],
+ "doc": "Separations processes feed material into one or more streams containing specific elements and/or nuclides. It uses mass-based efficiencies.\n\nUser defined separations streams are specified as groups of component-efficiency pairs where 'component' means either a particular element or a particular nuclide. Each component's paired efficiency represents the mass fraction of that component in the feed that is separated into that stream. The efficiencies of a particular component across all streams must sum up to less than or equal to one. If less than one, the remainining material is sent to a waste inventory and (potentially) traded away from there.\n\nThe facility receives material into a feed inventory that it processes with a specified throughput each time step. Each output stream has a corresponding output inventory size/limit. If the facility is unable to reduce its stocks by trading and hits this limit for any of its output streams, further processing/separations of feed material will halt until room is again available in the output streams.",
+ "entity": "facility",
+ "name": "cycamore::Separations",
+ "niche": "separations",
+ "parents": ["cyclus::Facility"],
+ "vars": {
+ "feed": {
+ "capacity": "feedbuf_size",
+ "index": 4,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]
+ },
+ "feed_commod_prefs": {
+ "alias": ["feed_commod_prefs", "val"],
+ "default": [],
+ "doc": "Feed commodity request preferences for each of the given feed commodities (same order). If unspecified, default is to use zero for all preferences.",
+ "index": 1,
+ "tooltip": ["feed_commod_prefs", ""],
+ "type": ["std::vector", "double"],
+ "uilabel": ["Feed Commodity Preference List", ""]
+ },
+ "feed_commods": {
+ "alias": ["feed_commods", "val"],
+ "doc": "Ordered list of commodities on which to request feed material to separate. Order only matters for matching up with feed commodity preferences if specified.",
+ "index": 0,
+ "tooltip": ["feed_commods", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["Feed Commodity List", ""],
+ "uitype": ["oneormore", "incommodity"]
+ },
+ "feed_recipe": {
+ "alias": "feed_recipe",
+ "default": "",
+ "doc": "Name for recipe to be used in feed requests. Empty string results in use of a dummy recipe.",
+ "index": 2,
+ "tooltip": "feed_recipe",
+ "type": "std::string",
+ "uilabel": "Feed Commodity Recipe List",
+ "uitype": "recipe"
+ },
+ "feedbuf_size": {
+ "alias": "feedbuf_size",
+ "doc": "Maximum amount of feed material to keep on hand.",
+ "index": 3,
+ "tooltip": "feedbuf_size",
+ "type": "double",
+ "uilabel": "Maximum Feed Inventory",
+ "units": "kg"
+ },
+ "leftover": {
+ "capacity": "leftoverbuf_size",
+ "index": 8,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Material"]
+ },
+ "leftover_commod": {
+ "alias": "leftover_commod",
+ "default": "default-waste-stream",
+ "doc": "Commodity on which to trade the leftover separated material stream. This MUST NOT be the same as any commodity used to define the other separations streams.",
+ "index": 6,
+ "tooltip": "leftover_commod",
+ "type": "std::string",
+ "uilabel": "Leftover Commodity",
+ "uitype": "outcommodity"
+ },
+ "leftoverbuf_size": {
+ "alias": "leftoverbuf_size",
+ "default": 1.000000000000000e+299,
+ "doc": "Maximum amount of leftover separated material (not included in any other stream) that can be stored. If full, the facility halts operation until space becomes available.",
+ "index": 7,
+ "tooltip": "leftoverbuf_size",
+ "type": "double",
+ "uilabel": "Maximum Leftover Inventory",
+ "units": "kg"
+ },
+ "streams": "streams_",
+ "streams_": {
+ "alias": [
+ ["streams", "item"],
+ "commod",
+ ["info", "buf_size", [["efficiencies", "item"], "comp", "eff"]]
+ ],
+ "doc": "Output streams for separations. Each stream must have a unique name identifying the commodity on which its material is traded, a max buffer capacity in kg (neg values indicate infinite size), and a set of component efficiencies. 'comp' is a component to be separated into the stream (e.g. U, Pu, etc.) and 'eff' is the mass fraction of the component that is separated from the feed into this output stream. If any stream buffer is full, the facility halts operation until space becomes available. The sum total of all component efficiencies across streams must be less than or equal to 1 (e.g. sum of U efficiencies for all streams must be <= 1).",
+ "index": 9,
+ "tooltip": [["streams_", ""], "", ["", "", [["", ""], "", ""]]],
+ "type": [
+ "std::map",
+ "std::string",
+ ["std::pair", "double", ["std::map", "int", "double"]]
+ ],
+ "uilabel": [["Separations Streams and Efficiencies", ""], "", ["", "", [["", ""], "", ""]]],
+ "uitype": [
+ "oneormore",
+ "outcommodity",
+ ["pair", "double", ["oneormore", "nuclide", "double"]]
+ ]
+ },
+ "throughput": {
+ "alias": "throughput",
+ "doc": "Maximum quantity of feed material that can be processed per time step.",
+ "index": 5,
+ "tooltip": "throughput",
+ "type": "double",
+ "uilabel": "Maximum Separations Throughput",
+ "units": "kg"
+ }
+ }
+ },
+ ":cycamore:Sink": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader"
+ ],
+ "doc": " A sink facility that accepts materials and products with a fixed\n throughput (per time step) capacity and a lifetime capacity defined by\n a total inventory size. The inventory size and throughput capacity\n both default to infinite. If a recipe is provided, it will request\n material with that recipe. Requests are made for any number of\n specified commodities.\n",
+ "entity": "facility",
+ "name": "cycamore::Sink",
+ "parents": ["cyclus::Facility"],
+ "vars": {
+ "capacity": {
+ "alias": "capacity",
+ "default": 1.000000000000000e+299,
+ "doc": "capacity the sink facility can accept at each time step",
+ "index": 3,
+ "tooltip": "sink capacity",
+ "type": "double",
+ "uilabel": "Maximum Throughput"
+ },
+ "in_commods": {
+ "alias": ["in_commods", "val"],
+ "doc": "commodities that the sink facility accepts",
+ "index": 0,
+ "tooltip": ["input commodities", ""],
+ "type": ["std::vector", "std::string"],
+ "uilabel": ["List of Input Commodities", ""],
+ "uitype": ["oneormore", "incommodity"]
+ },
+ "inventory": {
+ "capacity": "max_inv_size",
+ "index": 4,
+ "type": ["cyclus::toolkit::ResBuf", "cyclus::Resource"]
+ },
+ "max_inv_size": {
+ "alias": "max_inv_size",
+ "default": 1.000000000000000e+299,
+ "doc": "total maximum inventory size of sink facility",
+ "index": 2,
+ "tooltip": "sink maximum inventory size",
+ "type": "double",
+ "uilabel": "Maximum Inventory"
+ },
+ "recipe_name": {
+ "alias": "recipe_name",
+ "default": "",
+ "doc": "name of recipe to use for material requests, where the default (empty string) is to accept everything",
+ "index": 1,
+ "tooltip": "requested composition",
+ "type": "std::string",
+ "uilabel": "Input Recipe",
+ "uitype": "recipe"
+ }
+ }
+ },
+ ":cycamore:Source": {
+ "all_parents": [
+ "cyclus::Agent",
+ "cyclus::Facility",
+ "cyclus::Ider",
+ "cyclus::StateWrangler",
+ "cyclus::TimeListener",
+ "cyclus::Trader",
+ "cyclus::toolkit::AgentManaged",
+ "cyclus::toolkit::CommodityProducer"
+ ],
+ "doc": "This facility acts as a source of material with a fixed throughput (per\ntime step) capacity and a lifetime capacity defined by a total inventory\nsize. It offers its material as a single commodity. If a composition\nrecipe is specified, it provides that single material composition to\nrequesters. If unspecified, the source provides materials with the exact\nrequested compositions. The inventory size and throughput both default to\ninfinite. Supplies material results in corresponding decrease in\ninventory, and when the inventory size reaches zero, the source can provide\nno more material.\n",
+ "entity": "facility",
+ "name": "cycamore::Source",
+ "parents": ["cyclus::Facility", "cyclus::toolkit::CommodityProducer"],
+ "vars": {
+ "inventory_size": {
+ "alias": "inventory_size",
+ "default": 1.000000000000000e+299,
+ "doc": "Total amount of material this source has remaining. Every trade decreases this value by the supplied material quantity. When it reaches zero, the source cannot provide any more material.",
+ "index": 2,
+ "tooltip": "inventory_size",
+ "type": "double",
+ "uilabel": "Initial Inventory",
+ "units": "kg"
+ },
+ "outcommod": {
+ "alias": "outcommod",
+ "doc": "Output commodity on which the source offers material.",
+ "index": 0,
+ "tooltip": "source output commodity",
+ "type": "std::string",
+ "uilabel": "Output Commodity",
+ "uitype": "outcommodity"
+ },
+ "outrecipe": {
+ "alias": "outrecipe",
+ "default": "",
+ "doc": "Name of composition recipe that this source provides regardless of requested composition. If empty, source creates and provides whatever compositions are requested.",
+ "index": 1,
+ "tooltip": "name of material recipe to provide",
+ "type": "std::string",
+ "uilabel": "Output Recipe",
+ "uitype": "recipe"
+ },
+ "throughput": {
+ "alias": "throughput",
+ "default": 1.000000000000000e+299,
+ "doc": "amount of commodity that can be supplied at each time step",
+ "index": 3,
+ "tooltip": "per time step throughput",
+ "type": "double",
+ "uilabel": "Maximum Throughput",
+ "units": "kg/(time step)"
+ }
+ }
+ }
+ },
+ "schema": {
+ ":agents:KFacility": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":agents:NullInst": "",
+ ":agents:NullRegion": "",
+ ":agents:Predator": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":agents:Prey": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":agents:Sink": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":agents:Source": "\n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":cycamore:DeployInst": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":cycamore:Enrichment": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n 0\n 1\n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":cycamore:FuelFab": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":cycamore:GrowthRegion": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":cycamore:ManagerInst": "\n \n \n \n \n \n \n \n\n",
+ ":cycamore:Reactor": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":cycamore:Separations": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":cycamore:Sink": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n",
+ ":cycamore:Source": "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n"
+ },
+ "specs": [
+ ":agents:KFacility",
+ ":agents:NullInst",
+ ":agents:NullRegion",
+ ":agents:Predator",
+ ":agents:Prey",
+ ":agents:Sink",
+ ":agents:Source",
+ ":cycamore:DeployInst",
+ ":cycamore:Enrichment",
+ ":cycamore:FuelFab",
+ ":cycamore:GrowthRegion",
+ ":cycamore:ManagerInst",
+ ":cycamore:Reactor",
+ ":cycamore:Separations",
+ ":cycamore:Sink",
+ ":cycamore:Source"
+ ]
+}
diff --git a/cyclist/src/edu/utah/sci/cyclist/assets/process_sqlite.sql b/cyclist/src/edu/utah/sci/cyclist/assets/process_sqlite.sql
new file mode 100644
index 00000000..a0b658d4
--- /dev/null
+++ b/cyclist/src/edu/utah/sci/cyclist/assets/process_sqlite.sql
@@ -0,0 +1,80 @@
+-- VERSION: 1.0
+
+-- Cyclist info
+CREATE table if not exists Cyclist (
+ Version TEXT primary key,
+ Date Date);
+
+-- Ensure Agents compatibility
+UPDATE Agents set ExitTime = EnterTime+(select Duration from Info where Agents.SimId=Info.SimId )
+ WHERE ExitTime is null and Lifetime = -1;
+
+UPDATE Agents set ExitTime=(EnterTime+Lifetime) where ExitTime is null and Lifetime != -1;
+
+-- Create Facilities
+create table if not exists Facilities (
+ SimID BLOB,
+ AgentId INTEGER,
+ Spec TEXT,
+ Prototype TEXT,
+ InstitutionId INTEGER,
+ RegionId INTEGER,
+ EnterTime INTEGER,
+ ExitTime INTEGER,
+ Lifetime INTEGER);
+
+REPLACE into Facilities(SimID,AgentId,Spec,Prototype,InstitutionId,RegionId,EnterTime,ExitTime,Lifetime)
+ select f.SimId, f.AgentId, f.Spec, f.Prototype, i.AgentId,
+ cast(-1 as INTEGER), f.EnterTime, f.ExitTime, f.Lifetime from Agents as f, Agents as i
+ where f.Kind = 'Facility' and i.Kind = 'Inst' and f.ParentId = i.AgentId and f.SimId = i.SimId;
+
+CREATE INDEX if not exists Facilities_idx on Facilities (SimId ASC, AgentId ASC);
+
+-- Inventory
+CREATE table if not exists QuantityInventoryBase as
+ SELECT inv.SimId as SimId, tl.Time AS Time,cmp.NucId AS NucId,ag.AgentID as AgentID,
+ cast(SUM(inv.Quantity*cmp.MassFrac) as REAL) AS Quantity
+ FROM
+ Timelist AS tl
+ INNER JOIN Inventories AS inv ON inv.StartTime <= tl.Time AND inv.EndTime > tl.Time
+ INNER JOIN Agents AS ag ON ag.AgentId = inv.AgentId
+ INNER JOIN Compositions AS cmp ON cmp.QualId = inv.QualId
+ WHERE
+ inv.SimId = cmp.SimId AND inv.SimId = ag.SimId and tl.SimId=inv.SimId
+ GROUP BY inv.SimId, tl.Time, cmp.NucId, ag.AgentID;
+
+CREATE INDEX IF NOT EXISTS QuantityInventoryBase_idx ON QuantityInventoryBase (simid,agentid,time,nucid,quantity);
+
+CREATE view if not exists QuantityInventory as
+ SELECT base.SimID as SimID, Time, Quantity, NucId, base.AgentId as AgentId, Kind, Spec, Prototype
+ FROM
+ QuantityInventoryBase as base, Agents ag
+ WHERE
+ base.SimID = ag.SimID
+ AND base.AgentId = ag.AgentId;
+
+-- Transacted
+CREATE table if not exists QuantityTransactedBase as
+ SELECT res.SimId as SimId, tr.Time AS Time,cmp.NucId AS NucId, ag.AgentID as AgentID,
+ cast(SUM(cmp.MassFrac * res.Quantity) AS REAL) AS Quantity
+ FROM
+ Resources AS res
+ INNER JOIN Transactions AS tr ON tr.ResourceId = res.ResourceId
+ INNER JOIN Agents AS ag ON ag.AgentId = tr.SenderID
+ INNER JOIN Compositions AS cmp ON cmp.QualId = res.QualId
+ WHERE
+ tr.SimId = res.SimId AND ag.SimId = tr.SimId and cmp.SimId=res.SimId
+ GROUP BY res.SimId, cmp.NucId, tr.Time, ag.AgentID
+ ORDER BY tr.Time ASC;
+
+CREATE INDEX IF NOT EXISTS QuantityTransactedBase_idx ON QuantityTransactedBase (simid,agentid,time,nucid,quantity); ;
+
+CREATE view if not exists QuantityTransacted as
+ SELECT base.SimID as SimID, Time, Quantity, NucId, base.AgentId as AgentId, Kind, Spec, Prototype
+ FROM
+ QuantityTransactedBase as base, Agents ag
+ WHERE
+ base.SimID = ag.SimID
+ AND base.AgentId = ag.AgentId;
+
+
diff --git a/cyclist/skinImages/fuelcycle_abr.png b/cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_abr.png
similarity index 100%
rename from cyclist/skinImages/fuelcycle_abr.png
rename to cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_abr.png
diff --git a/cyclist/skinImages/fuelcycle_enr.png b/cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_enr.png
similarity index 100%
rename from cyclist/skinImages/fuelcycle_enr.png
rename to cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_enr.png
diff --git a/cyclist/skinImages/fuelcycle_fab.png b/cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_fab.png
similarity index 100%
rename from cyclist/skinImages/fuelcycle_fab.png
rename to cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_fab.png
diff --git a/cyclist/skinImages/fuelcycle_geo.png b/cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_geo.png
similarity index 100%
rename from cyclist/skinImages/fuelcycle_geo.png
rename to cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_geo.png
diff --git a/cyclist/skinImages/fuelcycle_mine.png b/cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_mine.png
similarity index 100%
rename from cyclist/skinImages/fuelcycle_mine.png
rename to cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_mine.png
diff --git a/cyclist/skinImages/fuelcycle_rxtr.png b/cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_rxtr.png
similarity index 100%
rename from cyclist/skinImages/fuelcycle_rxtr.png
rename to cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_rxtr.png
diff --git a/cyclist/skinImages/fuelcycle_sep.png b/cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_sep.png
similarity index 100%
rename from cyclist/skinImages/fuelcycle_sep.png
rename to cyclist/src/edu/utah/sci/cyclist/assets/skinImages/fuelcycle_sep.png
diff --git a/cyclist/skinImages/reactor.png b/cyclist/src/edu/utah/sci/cyclist/assets/skinImages/reactor.png
similarity index 100%
rename from cyclist/skinImages/reactor.png
rename to cyclist/src/edu/utah/sci/cyclist/assets/skinImages/reactor.png
diff --git a/cyclist/src/edu/utah/sci/cyclist/core/controller/CyclistController.java b/cyclist/src/edu/utah/sci/cyclist/core/controller/CyclistController.java
index 0e89cd33..ecc2a91a 100755
--- a/cyclist/src/edu/utah/sci/cyclist/core/controller/CyclistController.java
+++ b/cyclist/src/edu/utah/sci/cyclist/core/controller/CyclistController.java
@@ -29,6 +29,9 @@
import java.io.InputStream;
import java.io.PrintWriter;
import java.io.Reader;
+import java.nio.file.FileSystems;
+import java.nio.file.Files;
+import java.nio.file.Path;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
@@ -45,8 +48,8 @@
import javafx.event.ActionEvent;
import javafx.event.EventHandler;
import javafx.scene.control.MenuItem;
+import javafx.scene.control.Tab;
import javafx.stage.DirectoryChooser;
-import javafx.stage.FileChooser;
import javafx.stage.Stage;
import javafx.stage.WindowEvent;
@@ -60,6 +63,7 @@
import edu.utah.sci.cyclist.core.model.CyclistDatasource;
import edu.utah.sci.cyclist.core.model.Field;
import edu.utah.sci.cyclist.core.model.Model;
+import edu.utah.sci.cyclist.core.model.Perspective;
import edu.utah.sci.cyclist.core.model.Preferences;
import edu.utah.sci.cyclist.core.model.Simulation;
import edu.utah.sci.cyclist.core.model.Table;
@@ -68,21 +72,19 @@
import edu.utah.sci.cyclist.core.presenter.SchemaPresenter;
import edu.utah.sci.cyclist.core.presenter.SimulationPresenter;
import edu.utah.sci.cyclist.core.presenter.ToolsPresenter;
-import edu.utah.sci.cyclist.core.presenter.WorkspacePresenter;
+import edu.utah.sci.cyclist.core.presenter.VisWorkspacePresenter;
import edu.utah.sci.cyclist.core.services.CyclusService;
import edu.utah.sci.cyclist.core.tools.ToolFactory;
import edu.utah.sci.cyclist.core.ui.MainScreen;
+import edu.utah.sci.cyclist.core.ui.components.ViewBase;
import edu.utah.sci.cyclist.core.ui.panels.JobsPanel;
-import edu.utah.sci.cyclist.core.ui.views.Workspace;
+import edu.utah.sci.cyclist.core.ui.views.VisWorkspace;
import edu.utah.sci.cyclist.core.ui.wizards.DatatableWizard;
-import edu.utah.sci.cyclist.core.ui.wizards.ManageRemoteServersWizard;
import edu.utah.sci.cyclist.core.ui.wizards.PreferencesWizard;
-import edu.utah.sci.cyclist.core.ui.wizards.RemoteServerWizard;
import edu.utah.sci.cyclist.core.ui.wizards.SaveWsWizard;
import edu.utah.sci.cyclist.core.ui.wizards.SimulationWizard;
import edu.utah.sci.cyclist.core.ui.wizards.SqliteLoaderWizard;
import edu.utah.sci.cyclist.core.util.LoadSqlite;
-import edu.utah.sci.cyclist.core.util.StreamUtils;
public class CyclistController {
@@ -91,14 +93,20 @@ public class CyclistController {
private final EventBus _eventBus;
private MainScreen _screen;
- public static WorkspacePresenter _presenter;
+ public static VisWorkspacePresenter _presenter;
private Model _model = new Model();
private String SAVE_FILE = "workspace-config.xml";
- private WorkDirectoryController _workDirectoryController;
+ private SessionController _sessionController;
private Boolean _dirtyFlag = false;
public static CyclusService _cyclusService;
- private static final String SIMULATIONS_TABLES_FILE = "assets/SimulationTablesDef.xml";
+ private static final String SIMULATIONS_TABLES_FILE = "SimulationTablesDef.xml";
+
+ private Perspective _perspectives[] = {
+ new Perspective(0, "Scenario Builder", ToolsLibrary.SCENARIO_TOOL, Arrays.asList("Builder", "Jobs")),
+ new Perspective(1, "Data Exploration", ToolsLibrary.VIS_TOOL, Arrays.asList("Simulations", "Tables", "Fields", "Filters", "Jobs"))
+ };
+ private Perspective _currentPerspective = null;
/**
* Constructor
@@ -118,20 +126,20 @@ public void invalidated(Observable observable) {
// TODO: fix this hack. We need a better way of passing around the list of datasources
LoadSqlite.setSources(_model.getSources());
- _workDirectoryController = new WorkDirectoryController();
+ _sessionController = new SessionController();
// If the save directory does not exist, create it
- File saveDir = new File(WorkDirectoryController.CYCLIST_DIR);
+ File saveDir = new File(SessionController.CYCLIST_DIR);
if (!saveDir.exists())
saveDir.mkdir();
- File defaultWs = new File(WorkDirectoryController.DEFAULT_WORKSPACE);
+ File defaultWs = new File(SessionController.DEFAULT_WORKSPACE);
if (!defaultWs.exists())
defaultWs.mkdir();
- if (_workDirectoryController.initGeneralConfigFile())
+ if (_sessionController.initGeneralConfigFile())
{
- _workDirectoryController.restoreGeneralConfigFile();
+ _sessionController.restoreGeneralConfigFile();
}
}
@@ -153,6 +161,17 @@ public void setScreen(final MainScreen screen) {
ds.setTables(_model.getTables());
ds.setPanel(screen.getDatasourcesPanel());
+ screen.getDatasourcesPanel().setTableActions(Arrays.asList("Plot"),
+ action -> {
+ try {
+ _presenter
+ .addTool(ToolsLibrary.getFactory(action.v1).create())
+ .addTable(action.v2);
+ } catch (Exception e) {
+ log.error("internal error: ",e);
+ }
+ });
+
// Schema panel
SchemaPresenter sp = new SchemaPresenter(_eventBus);
sp.setPanel(screen.getFieldsPanel());
@@ -176,24 +195,72 @@ public void call(List list) {
// ToolsLibrary panel
ToolsPresenter tp = new ToolsPresenter(_eventBus);
tp.setPanel(screen.getToolsPanel());
- tp.setFactories(Arrays.asList(ToolsLibrary.factories));
+ tp.setFactories(ToolsLibrary.getFactoriesOfType(ToolsLibrary.VIS_TOOL, true));
// InputLibrary panel
InputPresenter ip = new InputPresenter(_eventBus);
ip.setPanel(screen.getInputPanel());
- ip.setFactories(Arrays.asList(ToolsLibrary.inputFactories));
+ ip.setFactories(ToolsLibrary.getFactoriesOfType(ToolsLibrary.SCENARIO_TOOL, true));
- // set up the main workspace
- Workspace workspace = new Workspace(true);
-// workspace.setWorkDirPath(getLastChosenWorkDirectory());
- screen.setWorkspace(workspace);
+ // Builder perspectives
+
+ for (Perspective p : _perspectives) {
+ ViewBase workspace = new VisWorkspace(true);
+ p.presenter = new VisWorkspacePresenter(_eventBus);
+ p.presenter.setView(workspace);
+
+ Tab tab = new Tab();
+ tab.setText(p.name);
+ tab.setClosable(false);
+ tab.setContent(workspace);
+ screen.getTabPane().getTabs().add(tab);
+
+//
+ }
- _presenter = new WorkspacePresenter(_eventBus);
- _presenter.setView(workspace);
+ screen.getTabPane().getSelectionModel().selectedIndexProperty().addListener(new ChangeListener() {
+ @Override
+ public void changed(ObservableValue extends Number> o, Number prev, Number id) {
+ perspectiveChanged(id.intValue());
+
+ }
+ });
- // do something?
- //selectWorkspace();
restore();
+
+ selectPerspective(_currentPerspective.id);
+ if (_currentPerspective.id == 0)
+ perspectiveChanged(_currentPerspective.id);
+ }
+
+ private void selectPerspective(int id) {
+ _screen.getTabPane().getSelectionModel().select(id);
+ }
+
+ private void perspectiveChanged(int id) {
+ if (_currentPerspective != null && _currentPerspective.id != id) {
+ _currentPerspective.setToolsPositions(_screen.getToolsPositions());
+ _presenter.getWorkspace().getConsole().setActive(false);
+ }
+
+ _currentPerspective = _perspectives[id];
+ if (!_currentPerspective.initialized) {
+ _currentPerspective.init();
+ if (id == 0) {
+ try {
+ if (!_perspectives[0].presenter.hasTool("Cycic")) {
+ ToolFactory factory = ToolsLibrary.getFactory("Cycic");
+ _perspectives[0].presenter.addTool(factory.create(), 0, 0);
+ }
+ } catch (Exception e) {
+ log.error("Can create scenario builder");
+ }
+ }
+ }
+ _presenter = _currentPerspective.presenter;
+ _presenter.getWorkspace().getConsole().setActive(true);
+ _screen.showPanels(_currentPerspective.tools, _currentPerspective.toolsPositions);
+ _screen.selectTools( _currentPerspective.type);
}
/**
@@ -202,31 +269,24 @@ public void call(List list) {
*/
public void selectWorkspace() {
- if(_workDirectoryController == null){
+ if(_sessionController == null){
return;
}
- ObservableList selection = _screen.selectWorkspace(_workDirectoryController.getWorkDirectories(),
- _workDirectoryController.getLastChosenIndex());
+ ObservableList selection = _screen.selectWorkspace(_sessionController.getWorkDirectories(),
+ _sessionController.getLastChosenIndex());
selection.addListener(new ListChangeListener(){
@Override
public void onChanged(Change extends String> list ){
- if(_workDirectoryController != null){
- if(_workDirectoryController.handleWorkDirectoriesListChangedEvent(list)){
+ if(_sessionController != null){
+ if(_sessionController.handleWorkDirectoriesListChangedEvent(list)){
restore();
//Set all the views to match the new tables.
ObservableList emptyList = FXCollections.observableArrayList();
_screen.getFieldsPanel().setFields(emptyList);
-
-// //Set the workspace to display the new path at the title.
-// Workspace workspace = _screen.getWorkspace();
-// if(workspace != null){
-// workspace.setWorkDirPath(getLastChosenWorkDirectory());
-// }
-
}
}
@@ -292,7 +352,6 @@ public void onChanged(ListChangeListener.Change extends Simulation> newList) {
Simulation sim = simulation.clone();
Simulation existingSim = _model.simExists(simulation);
if(existingSim==null){
-// _model.getSimulations().add(sim);
newSimulations.add(sim);
_dirtyFlag = true;
}else if(!existingSim.getAlias().equals(simulation.getAlias())){
@@ -338,7 +397,6 @@ public void onChanged(ListChangeListener.Change extends Simulation> newList) {
Simulation existingSim = _model.simExists(simulation);
if(existingSim == null){
newSimulations.add(sim);
-// _model.getSimulations().add(sim);
_dirtyFlag = true;
}else if(!existingSim.getAlias().equals(simulation.getAlias())){
existingSim.setAlias(simulation.getAlias());
@@ -358,80 +416,80 @@ public void onChanged(ListChangeListener.Change extends Simulation> newList) {
}
});
- _screen.onRun().set(new EventHandler() {
- @Override
- public void handle(ActionEvent event) {
- String server = "";
- if(event.getSource() instanceof MenuItem){
- server = (String) ((MenuItem)event.getSource()).getUserData();
- if(server.isEmpty()){
- server = Preferences.getInstance().getDefaultServer();
- }
- }
- FileChooser chooser = new FileChooser();
- chooser.getExtensionFilters().add( new FileChooser.ExtensionFilter("Cyclus files (*.xml)", "*.xml") );
- File file = chooser.showOpenDialog(Cyclist.cyclistStage);
- if (file != null) {
- _cyclusService.submit(file, server);
- }
- }
- });
-
- _screen.onManage().set(new EventHandler() {
- @Override
- public void handle(ActionEvent event) {
- ManageRemoteServersWizard wizard = new ManageRemoteServersWizard(_model.getRemoteServersList());
- ObservableList deletedServers = wizard.show(_screen.getParent().getScene().getWindow());
- deletedServers.addListener(new ListChangeListener() {
- @Override
- public void onChanged(ListChangeListener.Change extends String> listChange) {
- List