Improve some more stuff
This commit is contained in:
@@ -73,21 +73,102 @@ To collect input items, a node goes through its input slots in decreasing priori
|
||||
|
||||
To distribute the items, a node goes through its output slots in decreasing priority and puts as many items as possible in that slot.
|
||||
|
||||
# Running it manually
|
||||
## Constraints
|
||||
The idea with constraints is basically to have some logic formula that constraints the items and their rates along an edge.
|
||||
So for example if an inserter has a filter configured, its constraints will only allow the specific items as configured by the filter.
|
||||
Another example is an assembly machine, which will impose constraints on anything going into it, to only be the items that it needs for the recipe.
|
||||
|
||||
Constraints can then be propogated and combined upstream, so that an inserter going into an assembly machine also only selects the items that can actually go into that machine.
|
||||
For propogation, the constraints will be combined by either an intersection or a union.
|
||||
For example an inserter will perform an intersection, because it can only accept things that fit its specific configuration and any downstream configuration.
|
||||
But a belt will perform a union, because might have constraints coming from inserters taking from them and downstream belts so the items can take either path.
|
||||
Basically the constraints for every edge will be combined using an intersection with the constraints of the node itself, and then all downstream edge constraints will be combined using a union to form the final upstream constraint.
|
||||
|
||||
# Examples
|
||||
|
||||
## Belt Line with one slower belt
|
||||
{% carousel() %}
|
||||
|
||||
{% carousel_item() %}
|
||||
First - 1
|
||||
Initial configuration
|
||||
{% mermaid() %}
|
||||
flowchart LR
|
||||
Src
|
||||
T1
|
||||
T2
|
||||
T3
|
||||
Output
|
||||
|
||||
Src -->|x <= 20| T1
|
||||
T1 -->|x <= 20| T2
|
||||
T2 -->|x <= 10| T3
|
||||
T3 -->|x <= 20| Output
|
||||
{% end %}
|
||||
{% carousel_item() %}
|
||||
Second - 2
|
||||
{% end %}
|
||||
|
||||
{% carousel_item() %}
|
||||
Third - 3
|
||||
Raw Constraint Propogation
|
||||
{% mermaid() %}
|
||||
flowchart LR
|
||||
Src
|
||||
T1
|
||||
T2
|
||||
T3
|
||||
Output
|
||||
|
||||
Src -->|x <= 20 && x <= 20 && x <= 10 && x <= 20| T1
|
||||
T1 -->|x <= 20 && x <= 10 && x <= 20| T2
|
||||
T2 -->|x <= 10 && x <= 20| T3
|
||||
T3 -->|x <= 20| Output
|
||||
{% end %}
|
||||
{% end %}
|
||||
|
||||
{% carousel_item() %}
|
||||
Fourth - 4
|
||||
Simplified Constraint Propogation
|
||||
{% mermaid() %}
|
||||
flowchart LR
|
||||
Src
|
||||
T1
|
||||
T2
|
||||
T3
|
||||
Output
|
||||
|
||||
Src -->|x <= 10| T1
|
||||
T1 -->|x <= 10| T2
|
||||
T2 -->|x <= 10| T3
|
||||
T3 -->|x <= 20| Output
|
||||
{% end %}
|
||||
{% end %}
|
||||
|
||||
{% end %}
|
||||
|
||||
## TMP
|
||||
{% carousel() %}
|
||||
{% carousel_item() %}
|
||||
Initial Configuration
|
||||
{% mermaid() %}
|
||||
flowchart TD
|
||||
Src
|
||||
T1
|
||||
Splitter
|
||||
T2
|
||||
T3
|
||||
Output1
|
||||
Output2
|
||||
|
||||
Src --> T1
|
||||
T1 --> Splitter
|
||||
Splitter --> T2
|
||||
Splitter --> T3
|
||||
T2 --> Output1
|
||||
T3 --> Output2
|
||||
{% end %}
|
||||
{% end %}
|
||||
|
||||
{% carousel_item() %}
|
||||
Raw Propogation
|
||||
{% end %}
|
||||
|
||||
{% end %}
|
||||
|
||||
# Conclusion
|
||||
|
||||
Reference in New Issue
Block a user