<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.factorio.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=AnthonyQBachler</id>
	<title>Official Factorio Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.factorio.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=AnthonyQBachler"/>
	<link rel="alternate" type="text/html" href="https://wiki.factorio.com/Special:Contributions/AnthonyQBachler"/>
	<updated>2026-06-04T15:46:40Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159498</id>
		<title>Power production</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159498"/>
		<updated>2018-05-20T22:42:56Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Ensuring enough energy is produced */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
Electricity has to be produced before it can be transferred to consumers over the [[electric system]]. There are multiple methods to produce electricity:&lt;br /&gt;
&lt;br /&gt;
== Steam engine power ==&lt;br /&gt;
Each [[steam engine]] needs exactly 0.5 [[boiler]]s when running at full capacity. One [[offshore pump]] can supply 20 boilers and 40 steam engines.&lt;br /&gt;
&lt;br /&gt;
The above ratio can be calculated from information available in-game: One boiler consumes 3.6MW and produces energy stored in steam at 50% efficiency, so 1.8MW. One steam engine consumes 900kW of energy stored in steam, so each boiler can supply 2 steam engines: &amp;lt;code&amp;gt;1.8MW ÷ 0.9MW = 2&amp;lt;/code&amp;gt;. One steam engine consumes 30 steam per second, and one offshore pump produces 1200 water per second, so each offshore pump produces enough water to supply 40 steam engines: &amp;lt;code&amp;gt;1200 unit/s ÷ 30 units/s = 40&amp;lt;/code&amp;gt;. The number of boilers can be derived from the number of steam engines: &amp;lt;code&amp;gt;40 ÷ 2 = 20&amp;lt;/code&amp;gt;. This produces the 1:20:40 ratio.&lt;br /&gt;
&lt;br /&gt;
[[File:SteamSetupExample.png|center|600px|thumb|A possible setup]]&lt;br /&gt;
&lt;br /&gt;
== Solar panels and accumulators ==&lt;br /&gt;
&lt;br /&gt;
=== Optimal ratio ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio is 0.84 (21:25) [[accumulator]]s per [[solar panel]], and 23.8 solar panels per megawatt required by your factory (this ratio accounts for solar panels needed to charge the accumulators). This means that you need 1.428 MW of production (of solar panels) and 100MJ of storage to provide 1 MW of power over one day-night cycle.&lt;br /&gt;
&lt;br /&gt;
A &amp;quot;close enough&amp;quot; ratio is 20:24:1 accumulators to solar panels to megawatts required (for example, a factory requiring 10 MW can be approximately entirely powered, day and night, by 200 accumulators and 240 solar panels - this approximation differs from optimal only in that it calls for 20 extra solar panels, which is negligible but remember that the difference between the &amp;quot;close enough&amp;quot; ratio and the optimal ratio increases as you add more solar panels). &lt;br /&gt;
&lt;br /&gt;
This is taken from [http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5594 Accumulator / Solar Panel Ratio] (which calculates this in an impressive mathematical way!) and [https://forums.factorio.com/viewtopic.php?p=143317#p143317 another post in that thread] (which calculates the solar panel to megawatt ratio in a different way).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;float:right; padding-left:10px; padding-right:10px;&amp;quot;&amp;gt;&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:9x9_accumulator_solar_panel_example.jpg|300px|thumb|top|A small 9x9 blueprint demonstrating the 20:24 &amp;quot;close enough&amp;quot; ratio above.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:28x28_accumulator_solar_panel_example.jpg|300px|thumb|top|A medium 28x28 blueprint with a nearly optimal ratio.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:48x48_accumulator_solar_panel_example.jpg|300px|thumb|top|A large 48x48 blueprint with a nearly optimal ratio. It also contains a roboport in the center to repair itself and automatically construct adjacent blueprint copies.]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Calculations ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio of accumulators per solar panel relies on many values in the game. These include the power generation of a solar panel, the energy storage of an accumulator, the length of a [[day]], and the length of a night. There are also times between day and night called dusk and dawn which complicate the calculations. In vanilla factorio, without mods which change any of these values, the optimal ratio will be the same. This ratio is&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels =&lt;br /&gt;
    (day + dawn) × (night + dawn × (day + dawn) / game_day) / game_day&lt;br /&gt;
    × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
which, given the default time lengths of: day = 17500/60 s; dawn or dusk = 5000/60 s; night = 2500/60 s, and the default: Solar_power = 60 kW; Accumulator_energy = 5 MJ = 5000 kJ, gives the optimal ratio of 0.84 accumulators per solar panel. If the player uses mods which change the power generation of solar panels, or the energy storage of accumulators, but &amp;lt;b&amp;gt;not&amp;lt;/b&amp;gt; the length of days, a simplified version of this equation can be used.&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 70 s × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This equation could also be used to remember the vanilla optimal ratio given its simplicity. If the only effect the mod has on the game is it changes the total length of one day, without changing the ratio of dusk : day : dawn : night, then the equation can be simplified as&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 0.002016 /s × game_day &amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where game_day is the number of seconds in the game day which is 25000/60 s by default.&lt;br /&gt;
&lt;br /&gt;
=== See also ===&lt;br /&gt;
&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5168&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=18&amp;amp;t=5394&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=7619&lt;br /&gt;
&lt;br /&gt;
== Nuclear power ==&lt;br /&gt;
:&#039;&#039;See also: [[Tutorial:Nuclear power]]&#039;&#039;&lt;br /&gt;
In general, nuclear power is produced by the following production chain: [[Uranium ore]] is mined and [[Uranium processing|processed]] to [[uranium-235]] and [[uranium-238]], then [[uranium fuel cell]]s are created from the two. These fuel cells are then burned in a [[nuclear reactor]] to create heat. The heat can be used to convert [[water]] to [[steam]] using a [[heat exchanger]] and the steam can be consumed by [[steam turbine]]s to produce power.&lt;br /&gt;
&lt;br /&gt;
A reactor without neighbor bonus needs 4 heat exchangers so that all its heat gets consumed. For each 100% neighbor bonus, the reactor needs 4 more heat exchangers.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Ideal Ratio !! Simple Ratio !! Building&lt;br /&gt;
|-&lt;br /&gt;
| 25 || 1 ||{{imagelink|Offshore pump}}&lt;br /&gt;
|-&lt;br /&gt;
| 291 || 12 || {{imagelink|Heat exchanger}}&lt;br /&gt;
|-&lt;br /&gt;
| 500 || 20 || {{imagelink|Steam turbine}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Ensuring enough energy is produced ==&lt;br /&gt;
&lt;br /&gt;
Try this checklist before you completely revamp your power source. You may also use this to rectify [[Wikipedia:Feedback|brownouts/blackouts]].&lt;br /&gt;
&lt;br /&gt;
* Did you connect the steam engine to the [[electric system]]? If not, a small yellow triangle will flash. To fix, Add some [[Small electric pole|power poles]] near the steam engines that go to machines needing that power. Any size will work.&lt;br /&gt;
* Is steam able to reach all steam engines?&lt;br /&gt;
* Do your pipes have water? Look at the windows in the pipes, hover over the pipes! Place some pipes or a tank at the end to see if there is really water coming through. If not, ensure all [[pipe]]s or [[Pipe to ground|underground pipes]] are connected together.&lt;br /&gt;
* Is the factory producing enough fuel (coal, solid fuel, uranium fuel cells)&lt;br /&gt;
* Are there enough steam generators (boilers, heat exchangers)?&lt;br /&gt;
* Are there enough steam engines/turbines?&lt;br /&gt;
* Have you tried decoupling the fuel production from the rest of the factory and running it on its own separate power grid?&lt;br /&gt;
&lt;br /&gt;
See also the [[Tutorial:Applied_power_math|applied power math tutorial]] to answer the question &#039;&#039;how much coal do I need?&#039;&#039;&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=User_talk:SafwatHalaby&amp;diff=159497</id>
		<title>User talk:SafwatHalaby</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=User_talk:SafwatHalaby&amp;diff=159497"/>
		<updated>2018-05-20T21:29:02Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Welcome to the Official Factorio Wiki!&#039;&#039;&#039; Now that you have an account, there are a few key places on this Wiki that will be helpful in your efforts to improve it. &amp;lt;br&amp;gt;&lt;br /&gt;
First and foremost, please be sure to read and understand the [[Factorio:Wiki rules|rules of this Wiki]]. If you have any questions or concerns with these rules, please don&#039;t hesitate to ask an Admin. &amp;lt;br&amp;gt;&lt;br /&gt;
Secondly, if you&#039;re new to editing Wikis and are unfamiliar with MediaWiki&#039;s formatting, please be sure to read the [https://www.mediawiki.org/wiki/Special:MyLanguage/Help:Contents help pages]. In addition to the help provided by MW, we also provide a [[Factorio:Style guide|style guide]] that we enforce. &amp;lt;br&amp;gt;&lt;br /&gt;
If you&#039;re unsure where to begin, please see the [[Factorio:Editor_noticeboard|editor noticeboard]], where information on the current objectives and projects of the Wiki may be found. &amp;lt;br&amp;gt;&lt;br /&gt;
Again, welcome, we hope you contribute as much high quality information as you can. :) [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 12:36, 21 December 2017 (UTC)&lt;br /&gt;
&lt;br /&gt;
== Your userpage ==&lt;br /&gt;
&lt;br /&gt;
Hey, I saw that you link your userpage as a central place for your creations/tutorials on the forums. While creating such content on your userpage is acceptable in general, you are not allowed to link it from outside sources as by rule 7 of the [[Factorio:Wiki rules#Page creation|page creation section]]. So, please refrain from linking your userpage from outside sources. Instead you could simply make a forum thread as a central place for your creations and tutorials, and link that. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 12:55, 15 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
:I have removed the content from the Wiki, and will look for a suitable place. Thanks for notifying me of the rule. -- [[User:SafwatHalaby|SafwatHalaby]] ([[User talk:SafwatHalaby|talk]]) 13:54, 15 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
== Power Production - feedback positive/negative ==&lt;br /&gt;
&lt;br /&gt;
Again, only in limited circumstances where you are artificially limiting the system to the power production cycle. in a real system e.g. where increased power may cause circuit network controlled power switches to activate large parts of the factory, increasing power production can in fact lead to reduced power availability, leading to reduced fuel production and reduced power. In addition, if the factory manufactures and autoinserts logistic robots then increased power leads to more robots which leads to less power. Both of these very common, very realistic scenarios make it a negative feedback loop. That is why I linked the article on general feedback, so the reader cna get context on the fact that real systems are rarely so easily pigeon holed into being &#039;positive&#039; or &#039;negative&#039; feedback loops. [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 21:29, 20 May 2018 (UTC)&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=User_talk:AnthonyQBachler&amp;diff=159496</id>
		<title>User talk:AnthonyQBachler</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=User_talk:AnthonyQBachler&amp;diff=159496"/>
		<updated>2018-05-20T21:26:27Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Power production - positive/negative feedback loops */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Power production - positive/negative feedback loops ==&lt;br /&gt;
&lt;br /&gt;
Hey, I wanted to remind you of rule 1 concerning editing which states that you should not edit war. Concerning the topic: The feedback loop when steam engines run out of coal is positive, since it reinforces itself, instead of correcting itself. Another way to describe it would be that the gap in demand and production widens (you produce less and less) instead of narrowing (you recover). This is positive feedback by the first definition [https://en.wikipedia.org/wiki/Feedback#Terminology here]. I don&#039;t think we should consider the second definition on a wiki since it refers to emotional connotation. You can also find an explanation directly for factorio [https://www.reddit.com/r/factorio/comments/4eqapf/experiencing_and_recovering_from_a_negative/d22nsvp/ here]. I hope you now understand why I reverted your first edit, and hope that we can come to an agreement on whether the feedback loop is positive or negative. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 11:56, 17 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
:I discuss the edits on the pages talk page, btu my intention is not an edit war, rather that the page be technically correct.  That is why I linked it to the more general wikipedia article on feedback, rather than positive or negative, since the feedback referenced is a special case which can be considered both negative because the system acts to reduce output rather than increase it, and positive with less than unity gain (gain &amp;lt; 1.0).  As stated I explained the situation in more detail on the articles talk page.  [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 12:06, 17 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
::Since you removed the wrong information from the page, I will let this topic go. But I recommend you to also read the first few paragraphs of [[Wikipedia:Negative feedback]]. These should further explain why the feedback loops we see in power production during brownouts/blackouts are not negative. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 12:21, 17 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
::If lack of power leads to even greater lack of power, that&#039;s a positive feedback loop. If lack of power lead to a self-correcting process which re-stablizes the power, that&#039;s a negative loop. In factorio, a lack of power makes drillers, inserters, etc, work slower, not faster, leading to less fuel, leading to even more lack of power. That&#039;s a positive loop. -- [[User:SafwatHalaby|SafwatHalaby]] ([[User talk:SafwatHalaby|talk]]) 20:32, 19 May 2018 (UTC)&lt;br /&gt;
:::Again, only in limited circumstances where you are artificially limiting the system to the power production cycle.  in  a real system e.g. where increased power may cause circuit network controlled power switches to activate large parts of the factory, increasing power production can in fact lead to reduced power availability, leading to reduced fuel production and reduced power.  In addition, if the factory manufactures and autoinserts  logistic robots then increased power leads to more robots which leads to less power.  Both of these very common, very realistic scenarios make it a negative feedback loop.  That is why I linked the article on general feedback, so the reader cna get context on the fact that real systems are rarely so easily pigeon holed into being &#039;positive&#039; or &#039;negative&#039; feedback loops. [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 21:26, 20 May 2018 (UTC)&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=User_talk:AnthonyQBachler&amp;diff=159495</id>
		<title>User talk:AnthonyQBachler</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=User_talk:AnthonyQBachler&amp;diff=159495"/>
		<updated>2018-05-20T21:25:12Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Power production - positive/negative feedback loops */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Power production - positive/negative feedback loops ==&lt;br /&gt;
&lt;br /&gt;
Hey, I wanted to remind you of rule 1 concerning editing which states that you should not edit war. Concerning the topic: The feedback loop when steam engines run out of coal is positive, since it reinforces itself, instead of correcting itself. Another way to describe it would be that the gap in demand and production widens (you produce less and less) instead of narrowing (you recover). This is positive feedback by the first definition [https://en.wikipedia.org/wiki/Feedback#Terminology here]. I don&#039;t think we should consider the second definition on a wiki since it refers to emotional connotation. You can also find an explanation directly for factorio [https://www.reddit.com/r/factorio/comments/4eqapf/experiencing_and_recovering_from_a_negative/d22nsvp/ here]. I hope you now understand why I reverted your first edit, and hope that we can come to an agreement on whether the feedback loop is positive or negative. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 11:56, 17 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
:I discuss the edits on the pages talk page, btu my intention is not an edit war, rather that the page be technically correct.  That is why I linked it to the more general wikipedia article on feedback, rather than positive or negative, since the feedback referenced is a special case which can be considered both negative because the system acts to reduce output rather than increase it, and positive with less than unity gain (gain &amp;lt; 1.0).  As stated I explained the situation in more detail on the articles talk page.  [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 12:06, 17 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
::Since you removed the wrong information from the page, I will let this topic go. But I recommend you to also read the first few paragraphs of [[Wikipedia:Negative feedback]]. These should further explain why the feedback loops we see in power production during brownouts/blackouts are not negative. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 12:21, 17 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
::If lack of power leads to even greater lack of power, that&#039;s a positive feedback loop. If lack of power lead to a self-correcting process which re-stablizes the power, that&#039;s a negative loop. In factorio, a lack of power makes drillers, inserters, etc, work slower, not faster, leading to less fuel, leading to even more lack of power. That&#039;s a positive loop. -- [[User:SafwatHalaby|SafwatHalaby]] ([[User talk:SafwatHalaby|talk]]) 20:32, 19 May 2018 (UTC)&lt;br /&gt;
:::Again, only in limited circumstances where you are artificially limiting the system to the power production cycle.  in  a real system e.g. where increased power may cause circuit network controlled power switches to activate large parts of the factory, increasing power production can in fact lead to reduced power availability.  In addition, if the factory manufactures and autoinserts  logistic robots then increased power leads to more robots which leads to less power.  Both of these very common, very realistic scenarios make it a negative feedback loop.  That is why I linked the article on general feedback, so the reader cna get context on the fact that real systems are rarely so easily pigeon holed into being &#039;positive&#039; or &#039;negative&#039; feedback loops. [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 21:25, 20 May 2018 (UTC)&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Talk:Power_production&amp;diff=159305</id>
		<title>Talk:Power production</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Talk:Power_production&amp;diff=159305"/>
		<updated>2018-05-17T12:20:19Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Power Production - Feedback loop */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;http://www.factorioforums.com/forum/viewtopic.php?f=6&amp;amp;t=2015&amp;amp;p=14783#p14783&lt;br /&gt;
&lt;br /&gt;
Posting For Discussion&lt;br /&gt;
http://www.factorioforums.com/forum/viewtopic.php?f=8&amp;amp;t=5585&lt;br /&gt;
&lt;br /&gt;
== Move proposal ==&lt;br /&gt;
&lt;br /&gt;
In order to be consistent with other wikis, I recommend moving &amp;quot;Power production&amp;quot; to &amp;quot;Power Production&amp;quot;. Most wikis capitalize each word in the title. It&#039;s not really necessary, but it&#039;s nice to be consistent. Also, it seems that page &amp;quot;Power Production&amp;quot; has a redirect to Power production, so it&#039;s not like links are going to fail, but as I said, it&#039;s best to be consistent.--[[User:Twisted Code|Twisted Code]] ([[User talk:Twisted Code|talk]]) 11:25, 7 June 2015 (CEST)&lt;br /&gt;
&lt;br /&gt;
: The discussion for this decision is here: http://www.factorioforums.com/forum/viewtopic.php?f=50&amp;amp;t=6111&lt;br /&gt;
: I added a posting there! [[User:Ssilk|Ssilk]] ([[User talk:Ssilk|talk]]) 15:14, 8 June 2015 (CEST)&lt;br /&gt;
&lt;br /&gt;
== Remove/move/rewrite/rename/merge proposal ==&lt;br /&gt;
&lt;br /&gt;
It is not clear what makes this different from [[Electric system]]. Perhaps these should be merged, or perhaps the difference should be clarified. -- [[User:SafwatHalaby|SafwatHalaby]] ([[User talk:SafwatHalaby|talk]]) 13:49, 10 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
:The differnece is rather clear: One is about producing power, one is about transporting power and the mechanics of it. Another example of that is [[oil processing]] and [[fluid system]], one is about production of certain fluids, one about transportation of fluids. Due to this being a common pattern, the page being popular and long, the pages will not be merged. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 14:59, 10 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
== Power Production - Feedback loop ==&lt;br /&gt;
The situation discussed is a feedback loop.  In a limited boiler, steam engine, mining drill (or pumpjack/refinery/chemical plant) system it would be a positive feedback loop due to the fact the fuel production cycle in and of itself produces sufficient, indeed more, fuel than is needed to produce that fuel.  However, in a real system that is overloaded, the overloading elements (the factory) change the amplification factor in the fuel production cycle so that it requires more energy production than the fuel cycle makes available.  That is, even thought he mining drill is a net gain in energy, it is not producing enough net gain to overcome the drain on the power grid from the rest of the factory, leading to a situation where there is less and less power available to the mining drill over time.  This reduction of the amplification ratio is what makes it a negative feedback system  not positive.  The simplified model of only the fuel cycle and the power conversion cycle starts with a positive feedback ratio.  That is mining drill mines coal at a base rate of 0.525/s  Yielding 8 MJ at a cost of 47250 J  or an amplification factor of (8MJ / 47250 J) = 169.312.   however, the conversion in a boiler is only 50% efficient meaning the 8 MJ of coal only produces 4MJ of power reducing the amplification to (4 MJ / 47250 J) = 84.656.  If we further consider the use of at least 1 additional iron mine and one copper mine, the amplification is now 4 MJ / (3 * 47250 ) = 28.218.  As more systems are added to the power grid  the power consumption begins to exceed the net power yield of this system leading to a negative feedback situation or more specifically a gain of &amp;lt; 1.0.  [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 11:48, 17 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
Sorry, just woke up.  The number 47250 above should be 171428.571, so the amplification ratios are ~ 3.6 times worse.  Nothing else is off.  [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 12:20, 17 May 2018 (UTC)&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159304</id>
		<title>Power production</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159304"/>
		<updated>2018-05-17T12:14:52Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Ensuring enough energy is produced */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
Electricity has to be produced before it can be transferred to consumers over the [[electric system]]. There are multiple methods to produce electricity:&lt;br /&gt;
&lt;br /&gt;
== Steam engine power ==&lt;br /&gt;
Each [[steam engine]] needs exactly 0.5 [[boiler]]s when running at full capacity. One [[offshore pump]] can supply 20 boilers and 40 steam engines.&lt;br /&gt;
&lt;br /&gt;
The above ratio can be calculated from information available in-game: One boiler consumes 3.6MW and produces energy stored in steam at 50% efficiency, so 1.8MW. One steam engine consumes 900kW of energy stored in steam, so each boiler can supply 2 steam engines: &amp;lt;code&amp;gt;1.8MW ÷ 0.9MW = 2&amp;lt;/code&amp;gt;. One steam engine consumes 30 steam per second, and one offshore pump produces 1200 water per second, so each offshore pump produces enough water to supply 40 steam engines: &amp;lt;code&amp;gt;1200 unit/s ÷ 30 units/s = 40&amp;lt;/code&amp;gt;. The number of boilers can be derived from the number of steam engines: &amp;lt;code&amp;gt;40 ÷ 2 = 20&amp;lt;/code&amp;gt;. This produces the 1:20:40 ratio.&lt;br /&gt;
&lt;br /&gt;
[[File:SteamSetupExample.png|center|600px|thumb|A possible setup]]&lt;br /&gt;
&lt;br /&gt;
== Solar panels and accumulators ==&lt;br /&gt;
&lt;br /&gt;
=== Optimal ratio ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio is 0.84 (21:25) [[accumulator]]s per [[solar panel]], and 23.8 solar panels per megawatt required by your factory (this ratio accounts for solar panels needed to charge the accumulators). This means that you need 1.428 MW of production (of solar panels) and 100MJ of storage to provide 1 MW of power over one day-night cycle.&lt;br /&gt;
&lt;br /&gt;
A &amp;quot;close enough&amp;quot; ratio is 20:24:1 accumulators to solar panels to megawatts required (for example, a factory requiring 10 MW can be approximately entirely powered, day and night, by 200 accumulators and 240 solar panels - this approximation differs from optimal only in that it calls for 20 extra solar panels, which is negligible but remember that the difference between the &amp;quot;close enough&amp;quot; ratio and the optimal ratio increases as you add more solar panels). &lt;br /&gt;
&lt;br /&gt;
This is taken from [http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5594 Accumulator / Solar Panel Ratio] (which calculates this in an impressive mathematical way!) and [https://forums.factorio.com/viewtopic.php?p=143317#p143317 another post in that thread] (which calculates the solar panel to megawatt ratio in a different way).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;float:right; padding-left:10px; padding-right:10px;&amp;quot;&amp;gt;&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:9x9_accumulator_solar_panel_example.jpg|300px|thumb|top|A small 9x9 blueprint demonstrating the 20:24 &amp;quot;close enough&amp;quot; ratio above.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:28x28_accumulator_solar_panel_example.jpg|300px|thumb|top|A medium 28x28 blueprint with a nearly optimal ratio.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:48x48_accumulator_solar_panel_example.jpg|300px|thumb|top|A large 48x48 blueprint with a nearly optimal ratio. It also contains a roboport in the center to repair itself and automatically construct adjacent blueprint copies.]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Calculations ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio of accumulators per solar panel relies on many values in the game. These include the power generation of a solar panel, the energy storage of an accumulator, the length of a [[day]], and the length of a night. There are also times between day and night called dusk and dawn which complicate the calculations. In vanilla factorio, without mods which change any of these values, the optimal ratio will be the same. This ratio is&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels =&lt;br /&gt;
    (day + dawn) × (night + dawn × (day + dawn) / game_day) / game_day&lt;br /&gt;
    × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
which, given the default time lengths of: day = 17500/60 s; dawn or dusk = 5000/60 s; night = 2500/60 s, and the default: Solar_power = 60 kW; Accumulator_energy = 5 MJ = 5000 kJ, gives the optimal ratio of 0.84 accumulators per solar panel. If the player uses mods which change the power generation of solar panels, or the energy storage of accumulators, but &amp;lt;b&amp;gt;not&amp;lt;/b&amp;gt; the length of days, a simplified version of this equation can be used.&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 70 s × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This equation could also be used to remember the vanilla optimal ratio given its simplicity. If the only effect the mod has on the game is it changes the total length of one day, without changing the ratio of dusk : day : dawn : night, then the equation can be simplified as&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 0.002016 /s × game_day &amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where game_day is the number of seconds in the game day which is 25000/60 s by default.&lt;br /&gt;
&lt;br /&gt;
=== See also ===&lt;br /&gt;
&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5168&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=18&amp;amp;t=5394&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=7619&lt;br /&gt;
&lt;br /&gt;
== Nuclear power ==&lt;br /&gt;
:&#039;&#039;See also: [[Tutorial:Nuclear power]]&#039;&#039;&lt;br /&gt;
In general, nuclear power is produced by the following production chain: [[Uranium ore]] is mined and [[Uranium processing|processed]] to [[uranium-235]] and [[uranium-238]], then [[uranium fuel cell]]s are created from the two. These fuel cells are then burned in a [[nuclear reactor]] to create heat. The heat can be used to convert [[water]] to [[steam]] using a [[heat exchanger]] and the steam can be consumed by [[steam turbine]]s to produce power.&lt;br /&gt;
&lt;br /&gt;
A reactor without neighbor bonus needs 4 heat exchangers so that all its heat gets consumed. For each 100% neighbor bonus, the reactor needs 4 more heat exchangers.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Ideal Ratio !! Simple Ratio !! Building&lt;br /&gt;
|-&lt;br /&gt;
| 25 || 1 ||{{imagelink|Offshore pump}}&lt;br /&gt;
|-&lt;br /&gt;
| 291 || 12 || {{imagelink|Heat exchanger}}&lt;br /&gt;
|-&lt;br /&gt;
| 500 || 20 || {{imagelink|Steam turbine}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Ensuring enough energy is produced ==&lt;br /&gt;
&lt;br /&gt;
Try this checklist before you completely revamp your power source. You may also use this to rectify [https://en.wikipedia.org/wiki/Feedback brownouts/blackouts].&lt;br /&gt;
&lt;br /&gt;
* Did you connect the steam engine to the [[Electric system]]? If not, a small yellow triangle will flash. To fix, Add some [[Small electric pole|power poles]] near the steam engines that go to machines needing that power. Any size will work.&lt;br /&gt;
* Is steam able to reach all steam engines?&lt;br /&gt;
* Do your pipes have water? Look at the glass windows in the pipes, hover over the pipes! Place some pipes or a tank at the end to see if there is really water coming through. If not, ensure all [[pipe]]s or [https://wiki.factorio.com/index.php?title=Pipe-to-Ground underground pipes] are connected together.&lt;br /&gt;
* Is your factory producing enough fuel (coal, solid fuel, uranium fuel rods)&lt;br /&gt;
* Are there enough steam generators (boilers, heat exchangers)?&lt;br /&gt;
* Are there enough steam engines/turbines?&lt;br /&gt;
&lt;br /&gt;
See also the [[Tutorial:Applied_Power_Math|applied power math tutorial]] to answer the question &#039;&#039;how much coal do I need?&#039;&#039;&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=User_talk:AnthonyQBachler&amp;diff=159303</id>
		<title>User talk:AnthonyQBachler</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=User_talk:AnthonyQBachler&amp;diff=159303"/>
		<updated>2018-05-17T12:06:48Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Power production - positive/negative feedback loops ==&lt;br /&gt;
&lt;br /&gt;
Hey, I wanted to remind you of rule 1 concerning editing which states that you should not edit war. Concerning the topic: The feedback loop when steam engines run out of coal is positive, since it reinforces itself, instead of correcting itself. Another way to describe it would be that the gap in demand and production widens (you produce less and less) instead of narrowing (you recover). This is positive feedback by the first definition [https://en.wikipedia.org/wiki/Feedback#Terminology here]. I don&#039;t think we should consider the second definition on a wiki since it refers to emotional connotation. You can also find an explanation directly for factorio [https://www.reddit.com/r/factorio/comments/4eqapf/experiencing_and_recovering_from_a_negative/d22nsvp/ here]. I hope you now understand why I reverted your first edit, and hope that we can come to an agreement on whether the feedback loop is positive or negative. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 11:56, 17 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
I discuss the edits on the pages talk page, btu my intention is not an edit war, rather that the page be technically correct.  That is why I linked it to the more general wikipedia article on feedback, rather than positive or negative, since the feedback referenced is a special case which can be considered both negative because the system acts to reduce output rather than increase it, and positive with less than unity gain (gain &amp;lt; 1.0).  As stated I explained the situation in more detail on the articles talk page.  [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 12:06, 17 May 2018 (UTC)&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=User_talk:AnthonyQBachler&amp;diff=159302</id>
		<title>User talk:AnthonyQBachler</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=User_talk:AnthonyQBachler&amp;diff=159302"/>
		<updated>2018-05-17T12:06:22Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Power production - positive/negative feedback loops */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Welcome to the Official Factorio Wiki!&#039;&#039;&#039; Now that you have an account, there are a few key places on this Wiki that will be helpful in your efforts to improve it. &amp;lt;br&amp;gt;&lt;br /&gt;
First and foremost, please be sure to read and understand the [[Factorio:Wiki rules|rules of this Wiki]]. If you have any questions or concerns with these rules, please don&#039;t hesitate to ask an Admin. &amp;lt;br&amp;gt;&lt;br /&gt;
Secondly, if you&#039;re new to editing Wikis and are unfamiliar with MediaWiki&#039;s formatting, please be sure to read the [https://www.mediawiki.org/wiki/Special:MyLanguage/Help:Contents help pages]. In addition to the help provided by MW, we also provide a [[Factorio:Style guide|style guide]] that we enforce. &amp;lt;br&amp;gt;&lt;br /&gt;
If you&#039;re unsure where to begin, please see the [[Factorio:Editor_noticeboard|editor noticeboard]], where information on the current objectives and projects of the Wiki may be found. &amp;lt;br&amp;gt;&lt;br /&gt;
Again, welcome, we hope you contribute as much high quality information as you can. :) [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 08:56, 7 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
== Power production - positive/negative feedback loops ==&lt;br /&gt;
&lt;br /&gt;
Hey, I wanted to remind you of rule 1 concerning editing which states that you should not edit war. Concerning the topic: The feedback loop when steam engines run out of coal is positive, since it reinforces itself, instead of correcting itself. Another way to describe it would be that the gap in demand and production widens (you produce less and less) instead of narrowing (you recover). This is positive feedback by the first definition [https://en.wikipedia.org/wiki/Feedback#Terminology here]. I don&#039;t think we should consider the second definition on a wiki since it refers to emotional connotation. You can also find an explanation directly for factorio [https://www.reddit.com/r/factorio/comments/4eqapf/experiencing_and_recovering_from_a_negative/d22nsvp/ here]. I hope you now understand why I reverted your first edit, and hope that we can come to an agreement on whether the feedback loop is positive or negative. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 11:56, 17 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
I discuss the edits on the pages talk page, btu my intention is not an edit war, rather that the page be technically correct.  That is why I linked it to the more general wikipedia article on feedback, rather than positive or negative, since the feedback referenced is a special case which can be considered both negative because the system acts to reduce output rather than increase it, and positive with less than unity gain (gain &amp;lt; 1.0).  As stated I explained the situation in more detail on the articles talk page.  [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 12:06, 17 May 2018 (UTC)&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Talk:Power_production&amp;diff=159299</id>
		<title>Talk:Power production</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Talk:Power_production&amp;diff=159299"/>
		<updated>2018-05-17T11:48:07Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Power Production - Feedback loop */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;http://www.factorioforums.com/forum/viewtopic.php?f=6&amp;amp;t=2015&amp;amp;p=14783#p14783&lt;br /&gt;
&lt;br /&gt;
Posting For Discussion&lt;br /&gt;
http://www.factorioforums.com/forum/viewtopic.php?f=8&amp;amp;t=5585&lt;br /&gt;
&lt;br /&gt;
== Move proposal ==&lt;br /&gt;
&lt;br /&gt;
In order to be consistent with other wikis, I recommend moving &amp;quot;Power production&amp;quot; to &amp;quot;Power Production&amp;quot;. Most wikis capitalize each word in the title. It&#039;s not really necessary, but it&#039;s nice to be consistent. Also, it seems that page &amp;quot;Power Production&amp;quot; has a redirect to Power production, so it&#039;s not like links are going to fail, but as I said, it&#039;s best to be consistent.--[[User:Twisted Code|Twisted Code]] ([[User talk:Twisted Code|talk]]) 11:25, 7 June 2015 (CEST)&lt;br /&gt;
&lt;br /&gt;
: The discussion for this decision is here: http://www.factorioforums.com/forum/viewtopic.php?f=50&amp;amp;t=6111&lt;br /&gt;
: I added a posting there! [[User:Ssilk|Ssilk]] ([[User talk:Ssilk|talk]]) 15:14, 8 June 2015 (CEST)&lt;br /&gt;
&lt;br /&gt;
== Remove/move/rewrite/rename/merge proposal ==&lt;br /&gt;
&lt;br /&gt;
It is not clear what makes this different from [[Electric system]]. Perhaps these should be merged, or perhaps the difference should be clarified. -- [[User:SafwatHalaby|SafwatHalaby]] ([[User talk:SafwatHalaby|talk]]) 13:49, 10 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
:The differnece is rather clear: One is about producing power, one is about transporting power and the mechanics of it. Another example of that is [[oil processing]] and [[fluid system]], one is about production of certain fluids, one about transportation of fluids. Due to this being a common pattern, the page being popular and long, the pages will not be merged. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 14:59, 10 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
== Power Production - Feedback loop ==&lt;br /&gt;
The situation discussed is a feedback loop.  In a limited boiler, steam engine, mining drill (or pumpjack/refinery/chemical plant) system it would be a positive feedback loop due to the fact the fuel production cycle in and of itself produces sufficient, indeed more, fuel than is needed to produce that fuel.  However, in a real system that is overloaded, the overloading elements (the factory) change the amplification factor in the fuel production cycle so that it requires more energy production than the fuel cycle makes available.  That is, even thought he mining drill is a net gain in energy, it is not producing enough net gain to overcome the drain on the power grid from the rest of the factory, leading to a situation where there is less and less power available to the mining drill over time.  This reduction of the amplification ratio is what makes it a negative feedback system  not positive.  The simplified model of only the fuel cycle and the power conversion cycle starts with a positive feedback ratio.  That is mining drill mines coal at a base rate of 0.525/s  Yielding 8 MJ at a cost of 47250 J  or an amplification factor of (8MJ / 47250 J) = 169.312.   however, the conversion in a boiler is only 50% efficient meaning the 8 MJ of coal only produces 4MJ of power reducing the amplification to (4 MJ / 47250 J) = 84.656.  If we further consider the use of at least 1 additional iron mine and one copper mine, the amplification is now 4 MJ / (3 * 47250 ) = 28.218.  As more systems are added to the power grid  the power consumption begins to exceed the net power yield of this system leading to a negative feedback situation or more specifically a gain of &amp;lt; 1.0.  [[User:AnthonyQBachler|AnthonyQBachler]] ([[User talk:AnthonyQBachler|talk]]) 11:48, 17 May 2018 (UTC)&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Talk:Power_production&amp;diff=159298</id>
		<title>Talk:Power production</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Talk:Power_production&amp;diff=159298"/>
		<updated>2018-05-17T11:47:52Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;http://www.factorioforums.com/forum/viewtopic.php?f=6&amp;amp;t=2015&amp;amp;p=14783#p14783&lt;br /&gt;
&lt;br /&gt;
Posting For Discussion&lt;br /&gt;
http://www.factorioforums.com/forum/viewtopic.php?f=8&amp;amp;t=5585&lt;br /&gt;
&lt;br /&gt;
== Move proposal ==&lt;br /&gt;
&lt;br /&gt;
In order to be consistent with other wikis, I recommend moving &amp;quot;Power production&amp;quot; to &amp;quot;Power Production&amp;quot;. Most wikis capitalize each word in the title. It&#039;s not really necessary, but it&#039;s nice to be consistent. Also, it seems that page &amp;quot;Power Production&amp;quot; has a redirect to Power production, so it&#039;s not like links are going to fail, but as I said, it&#039;s best to be consistent.--[[User:Twisted Code|Twisted Code]] ([[User talk:Twisted Code|talk]]) 11:25, 7 June 2015 (CEST)&lt;br /&gt;
&lt;br /&gt;
: The discussion for this decision is here: http://www.factorioforums.com/forum/viewtopic.php?f=50&amp;amp;t=6111&lt;br /&gt;
: I added a posting there! [[User:Ssilk|Ssilk]] ([[User talk:Ssilk|talk]]) 15:14, 8 June 2015 (CEST)&lt;br /&gt;
&lt;br /&gt;
== Remove/move/rewrite/rename/merge proposal ==&lt;br /&gt;
&lt;br /&gt;
It is not clear what makes this different from [[Electric system]]. Perhaps these should be merged, or perhaps the difference should be clarified. -- [[User:SafwatHalaby|SafwatHalaby]] ([[User talk:SafwatHalaby|talk]]) 13:49, 10 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
:The differnece is rather clear: One is about producing power, one is about transporting power and the mechanics of it. Another example of that is [[oil processing]] and [[fluid system]], one is about production of certain fluids, one about transportation of fluids. Due to this being a common pattern, the page being popular and long, the pages will not be merged. -- [[User:Bilka|Bilka]] ([[User talk:Bilka|talk]]) - &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;Admin&amp;lt;/span&amp;gt; 14:59, 10 May 2018 (UTC)&lt;br /&gt;
&lt;br /&gt;
== Power Production - Feedback loop ==&lt;br /&gt;
The situation discussed is a feedback loop.  In a limited boiler, steam engine, mining drill (or pumpjack/refinery/chemical plant) system it would be a positive feedback loop due to the fact the fuel production cycle in and of itself produces sufficient, indeed more, fuel than is needed to produce that fuel.  However, in a real system that is overloaded, the overloading elements (the factory) change the amplification factor in the fuel production cycle so that it requires more energy production than the fuel cycle makes available.  That is, even thought he mining drill is a net gain in energy, it is not producing enough net gain to overcome the drain on the power grid from the rest of the factory, leading to a situation where there is less and less power available to the mining drill over time.  This reduction of the amplification ratio is what makes it a negative feedback system  not positive.  The simplified model of only the fuel cycle and the power conversion cycle starts with a positive feedback ratio.  That is mining drill mines coal at a base rate of 0.525/s  Yielding 8 MJ at a cost of 47250 J  or an amplification factor of (8MJ / 47250 J) = 169.312.   however, the conversion in a boiler is only 50% efficient meaning the 8 MJ of coal only produces 4MJ of power reducing the amplification to (4 MJ / 47250 J) = 84.656.  If we further consider the use of at least 1 additional iron mine and one copper mine, the amplification is now 4 MJ / (3 * 47250 ) = 28.218.  As more systems are added to the power grid  the power consumption begins to exceed the net power yield of this system leading to a negative feedback situation or more specifically a gain of &amp;lt; 1.0.&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159295</id>
		<title>Power production</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159295"/>
		<updated>2018-05-17T11:24:11Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Ensuring enough energy is produced */  fixed page doesnt exist link, pointed towards wikipedia Feedback article, which discusses both positive and negative feedback as well as the complexities of determingin which a system is.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
Electricity has to be produced before it can be transferred to consumers over the [[electric system]]. There are multiple methods to produce electricity:&lt;br /&gt;
&lt;br /&gt;
== Steam engine power ==&lt;br /&gt;
Each [[steam engine]] needs exactly 0.5 [[boiler]]s when running at full capacity. One [[offshore pump]] can supply 20 boilers and 40 steam engines.&lt;br /&gt;
&lt;br /&gt;
The above ratio can be calculated from information available in-game: One boiler consumes 3.6MW and produces energy stored in steam at 50% efficiency, so 1.8MW. One steam engine consumes 900kW of energy stored in steam, so each boiler can supply 2 steam engines: &amp;lt;code&amp;gt;1.8MW ÷ 0.9MW = 2&amp;lt;/code&amp;gt;. One steam engine consumes 30 steam per second, and one offshore pump produces 1200 water per second, so each offshore pump produces enough water to supply 40 steam engines: &amp;lt;code&amp;gt;1200 unit/s ÷ 30 units/s = 40&amp;lt;/code&amp;gt;. The number of boilers can be derived from the number of steam engines: &amp;lt;code&amp;gt;40 ÷ 2 = 20&amp;lt;/code&amp;gt;. This produces the 1:20:40 ratio.&lt;br /&gt;
&lt;br /&gt;
[[File:SteamSetupExample.png|center|600px|thumb|A possible setup]]&lt;br /&gt;
&lt;br /&gt;
== Solar panels and accumulators ==&lt;br /&gt;
&lt;br /&gt;
=== Optimal ratio ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio is 0.84 (21:25) [[accumulator]]s per [[solar panel]], and 23.8 solar panels per megawatt required by your factory (this ratio accounts for solar panels needed to charge the accumulators). This means that you need 1.428 MW of production (of solar panels) and 100MJ of storage to provide 1 MW of power over one day-night cycle.&lt;br /&gt;
&lt;br /&gt;
A &amp;quot;close enough&amp;quot; ratio is 20:24:1 accumulators to solar panels to megawatts required (for example, a factory requiring 10 MW can be approximately entirely powered, day and night, by 200 accumulators and 240 solar panels - this approximation differs from optimal only in that it calls for 20 extra solar panels, which is negligible but remember that the difference between the &amp;quot;close enough&amp;quot; ratio and the optimal ratio increases as you add more solar panels). &lt;br /&gt;
&lt;br /&gt;
This is taken from [http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5594 Accumulator / Solar Panel Ratio] (which calculates this in an impressive mathematical way!) and [https://forums.factorio.com/viewtopic.php?p=143317#p143317 another post in that thread] (which calculates the solar panel to megawatt ratio in a different way).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;float:right; padding-left:10px; padding-right:10px;&amp;quot;&amp;gt;&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:9x9_accumulator_solar_panel_example.jpg|300px|thumb|top|A small 9x9 blueprint demonstrating the 20:24 &amp;quot;close enough&amp;quot; ratio above.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:28x28_accumulator_solar_panel_example.jpg|300px|thumb|top|A medium 28x28 blueprint with a nearly optimal ratio.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:48x48_accumulator_solar_panel_example.jpg|300px|thumb|top|A large 48x48 blueprint with a nearly optimal ratio. It also contains a roboport in the center to repair itself and automatically construct adjacent blueprint copies.]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Calculations ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio of accumulators per solar panel relies on many values in the game. These include the power generation of a solar panel, the energy storage of an accumulator, the length of a [[day]], and the length of a night. There are also times between day and night called dusk and dawn which complicate the calculations. In vanilla factorio, without mods which change any of these values, the optimal ratio will be the same. This ratio is&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels =&lt;br /&gt;
    (day + dawn) × (night + dawn × (day + dawn) / game_day) / game_day&lt;br /&gt;
    × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
which, given the default time lengths of: day = 17500/60 s; dawn or dusk = 5000/60 s; night = 2500/60 s, and the default: Solar_power = 60 kW; Accumulator_energy = 5 MJ = 5000 kJ, gives the optimal ratio of 0.84 accumulators per solar panel. If the player uses mods which change the power generation of solar panels, or the energy storage of accumulators, but &amp;lt;b&amp;gt;not&amp;lt;/b&amp;gt; the length of days, a simplified version of this equation can be used.&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 70 s × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This equation could also be used to remember the vanilla optimal ratio given its simplicity. If the only effect the mod has on the game is it changes the total length of one day, without changing the ratio of dusk : day : dawn : night, then the equation can be simplified as&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 0.002016 /s × game_day &amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where game_day is the number of seconds in the game day which is 25000/60 s by default.&lt;br /&gt;
&lt;br /&gt;
=== See also ===&lt;br /&gt;
&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5168&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=18&amp;amp;t=5394&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=7619&lt;br /&gt;
&lt;br /&gt;
== Nuclear power ==&lt;br /&gt;
:&#039;&#039;See also: [[Tutorial:Nuclear power]]&#039;&#039;&lt;br /&gt;
In general, nuclear power is produced by the following production chain: [[Uranium ore]] is mined and [[Uranium processing|processed]] to [[uranium-235]] and [[uranium-238]], then [[uranium fuel cell]]s are created from the two. These fuel cells are then burned in a [[nuclear reactor]] to create heat. The heat can be used to convert [[water]] to [[steam]] using a [[heat exchanger]] and the steam can be consumed by [[steam turbine]]s to produce power.&lt;br /&gt;
&lt;br /&gt;
A reactor without neighbor bonus needs 4 heat exchangers so that all its heat gets consumed. For each 100% neighbor bonus, the reactor needs 4 more heat exchangers.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Ideal Ratio !! Simple Ratio !! Building&lt;br /&gt;
|-&lt;br /&gt;
| 25 || 1 ||{{imagelink|Offshore pump}}&lt;br /&gt;
|-&lt;br /&gt;
| 291 || 12 || {{imagelink|Heat exchanger}}&lt;br /&gt;
|-&lt;br /&gt;
| 500 || 20 || {{imagelink|Steam turbine}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Ensuring enough energy is produced ==&lt;br /&gt;
&lt;br /&gt;
Try this checklist before you completely revamp your power source. You may also use this to rectify [https://en.wikipedia.org/wiki/Feedback negative feedback loops].&lt;br /&gt;
&lt;br /&gt;
* Did you connect the steam engine to the [[Electric system]]? If not, a small yellow triangle will flash. To fix, Add some [[Small electric pole|power poles]] near the steam engines that go to machines needing that power. Any size will work.&lt;br /&gt;
* Is steam able to reach all steam engines?&lt;br /&gt;
* Do your pipes have water? Look at the glass windows in the pipes, hover over the pipes! Place some pipes or a tank at the end to see if there is really water coming through. If not, ensure all [[pipe]]s or [https://wiki.factorio.com/index.php?title=Pipe-to-Ground underground pipes] are connected together.&lt;br /&gt;
&lt;br /&gt;
See also the [[Tutorial:Applied_Power_Math|applied power math tutorial]] to answer the question &#039;&#039;how much coal do I need?&#039;&#039;&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=User:AnthonyQBachler&amp;diff=159294</id>
		<title>User:AnthonyQBachler</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=User:AnthonyQBachler&amp;diff=159294"/>
		<updated>2018-05-17T11:21:00Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;I am a semi-retired software engineer.  I matriculated from U.S. Army Signal School, ITT Technical Institute, and have worked as a professional research engineer for 20+ years.  I like playing games like factorio because I like solving puzzles.  In my spare time I like building amateur rockets.  I am currently building my first O class engine, and the last one before I get my FAA license.&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159293</id>
		<title>Power production</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159293"/>
		<updated>2018-05-17T11:05:58Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: Undo revision 159288 by Bilka (talk)  Positive feedback loops are not an issue and nto the topic referred to.  Positive feedback results in maximized power output, negative feedback loops, in this conteo&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
Electricity has to be produced before it can be transferred to consumers over the [[electric system]]. There are multiple methods to produce electricity:&lt;br /&gt;
&lt;br /&gt;
== Steam engine power ==&lt;br /&gt;
Each [[steam engine]] needs exactly 0.5 [[boiler]]s when running at full capacity. One [[offshore pump]] can supply 20 boilers and 40 steam engines.&lt;br /&gt;
&lt;br /&gt;
The above ratio can be calculated from information available in-game: One boiler consumes 3.6MW and produces energy stored in steam at 50% efficiency, so 1.8MW. One steam engine consumes 900kW of energy stored in steam, so each boiler can supply 2 steam engines: &amp;lt;code&amp;gt;1.8MW ÷ 0.9MW = 2&amp;lt;/code&amp;gt;. One steam engine consumes 30 steam per second, and one offshore pump produces 1200 water per second, so each offshore pump produces enough water to supply 40 steam engines: &amp;lt;code&amp;gt;1200 unit/s ÷ 30 units/s = 40&amp;lt;/code&amp;gt;. The number of boilers can be derived from the number of steam engines: &amp;lt;code&amp;gt;40 ÷ 2 = 20&amp;lt;/code&amp;gt;. This produces the 1:20:40 ratio.&lt;br /&gt;
&lt;br /&gt;
[[File:SteamSetupExample.png|center|600px|thumb|A possible setup]]&lt;br /&gt;
&lt;br /&gt;
== Solar panels and accumulators ==&lt;br /&gt;
&lt;br /&gt;
=== Optimal ratio ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio is 0.84 (21:25) [[accumulator]]s per [[solar panel]], and 23.8 solar panels per megawatt required by your factory (this ratio accounts for solar panels needed to charge the accumulators). This means that you need 1.428 MW of production (of solar panels) and 100MJ of storage to provide 1 MW of power over one day-night cycle.&lt;br /&gt;
&lt;br /&gt;
A &amp;quot;close enough&amp;quot; ratio is 20:24:1 accumulators to solar panels to megawatts required (for example, a factory requiring 10 MW can be approximately entirely powered, day and night, by 200 accumulators and 240 solar panels - this approximation differs from optimal only in that it calls for 20 extra solar panels, which is negligible but remember that the difference between the &amp;quot;close enough&amp;quot; ratio and the optimal ratio increases as you add more solar panels). &lt;br /&gt;
&lt;br /&gt;
This is taken from [http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5594 Accumulator / Solar Panel Ratio] (which calculates this in an impressive mathematical way!) and [https://forums.factorio.com/viewtopic.php?p=143317#p143317 another post in that thread] (which calculates the solar panel to megawatt ratio in a different way).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;float:right; padding-left:10px; padding-right:10px;&amp;quot;&amp;gt;&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:9x9_accumulator_solar_panel_example.jpg|300px|thumb|top|A small 9x9 blueprint demonstrating the 20:24 &amp;quot;close enough&amp;quot; ratio above.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:28x28_accumulator_solar_panel_example.jpg|300px|thumb|top|A medium 28x28 blueprint with a nearly optimal ratio.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:48x48_accumulator_solar_panel_example.jpg|300px|thumb|top|A large 48x48 blueprint with a nearly optimal ratio. It also contains a roboport in the center to repair itself and automatically construct adjacent blueprint copies.]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Calculations ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio of accumulators per solar panel relies on many values in the game. These include the power generation of a solar panel, the energy storage of an accumulator, the length of a [[day]], and the length of a night. There are also times between day and night called dusk and dawn which complicate the calculations. In vanilla factorio, without mods which change any of these values, the optimal ratio will be the same. This ratio is&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels =&lt;br /&gt;
    (day + dawn) × (night + dawn × (day + dawn) / game_day) / game_day&lt;br /&gt;
    × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
which, given the default time lengths of: day = 17500/60 s; dawn or dusk = 5000/60 s; night = 2500/60 s, and the default: Solar_power = 60 kW; Accumulator_energy = 5 MJ = 5000 kJ, gives the optimal ratio of 0.84 accumulators per solar panel. If the player uses mods which change the power generation of solar panels, or the energy storage of accumulators, but &amp;lt;b&amp;gt;not&amp;lt;/b&amp;gt; the length of days, a simplified version of this equation can be used.&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 70 s × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This equation could also be used to remember the vanilla optimal ratio given its simplicity. If the only effect the mod has on the game is it changes the total length of one day, without changing the ratio of dusk : day : dawn : night, then the equation can be simplified as&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 0.002016 /s × game_day &amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where game_day is the number of seconds in the game day which is 25000/60 s by default.&lt;br /&gt;
&lt;br /&gt;
=== See also ===&lt;br /&gt;
&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5168&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=18&amp;amp;t=5394&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=7619&lt;br /&gt;
&lt;br /&gt;
== Nuclear power ==&lt;br /&gt;
:&#039;&#039;See also: [[Tutorial:Nuclear power]]&#039;&#039;&lt;br /&gt;
In general, nuclear power is produced by the following production chain: [[Uranium ore]] is mined and [[Uranium processing|processed]] to [[uranium-235]] and [[uranium-238]], then [[uranium fuel cell]]s are created from the two. These fuel cells are then burned in a [[nuclear reactor]] to create heat. The heat can be used to convert [[water]] to [[steam]] using a [[heat exchanger]] and the steam can be consumed by [[steam turbine]]s to produce power.&lt;br /&gt;
&lt;br /&gt;
A reactor without neighbor bonus needs 4 heat exchangers so that all its heat gets consumed. For each 100% neighbor bonus, the reactor needs 4 more heat exchangers.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Ideal Ratio !! Simple Ratio !! Building&lt;br /&gt;
|-&lt;br /&gt;
| 25 || 1 ||{{imagelink|Offshore pump}}&lt;br /&gt;
|-&lt;br /&gt;
| 291 || 12 || {{imagelink|Heat exchanger}}&lt;br /&gt;
|-&lt;br /&gt;
| 500 || 20 || {{imagelink|Steam turbine}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Ensuring enough energy is produced ==&lt;br /&gt;
&lt;br /&gt;
Try this checklist before you completely revamp your power source. You may also use this to rectify [[negative feedback loops]].&lt;br /&gt;
&lt;br /&gt;
* Did you connect the steam engine to the [[Electric system]]? If not, a small yellow triangle will flash. To fix, Add some [[Small electric pole|power poles]] near the steam engines that go to machines needing that power. Any size will work.&lt;br /&gt;
* Is steam able to reach all steam engines?&lt;br /&gt;
* Do your pipes have water? Look at the glass windows in the pipes, hover over the pipes! Place some pipes or a tank at the end to see if there is really water coming through. If not, ensure all [[pipe]]s or [https://wiki.factorio.com/index.php?title=Pipe-to-Ground underground pipes] are connected together.&lt;br /&gt;
&lt;br /&gt;
See also the [[Tutorial:Applied_Power_Math|applied power math tutorial]] to answer the question &#039;&#039;how much coal do I need?&#039;&#039;&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159279</id>
		<title>Power production</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Power_production&amp;diff=159279"/>
		<updated>2018-05-16T20:18:45Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Ensuring enough energy is produced */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
Electricity has to be produced before it can be transferred to consumers over the [[electric system]]. There are multiple methods to produce electricity:&lt;br /&gt;
&lt;br /&gt;
== Steam engine power ==&lt;br /&gt;
Each [[steam engine]] needs exactly 0.5 [[boiler]]s when running at full capacity. One [[offshore pump]] can supply 20 boilers and 40 steam engines.&lt;br /&gt;
&lt;br /&gt;
The above ratio can be calculated from information available in-game: One boiler consumes 3.6MW and produces energy stored in steam at 50% efficiency, so 1.8MW. One steam engine consumes 900kW of energy stored in steam, so each boiler can supply 2 steam engines: &amp;lt;code&amp;gt;1.8MW ÷ 0.9MW = 2&amp;lt;/code&amp;gt;. One steam engine consumes 30 steam per second, and one offshore pump produces 1200 water per second, so each offshore pump produces enough water to supply 40 steam engines: &amp;lt;code&amp;gt;1200 unit/s ÷ 30 units/s = 40&amp;lt;/code&amp;gt;. The number of boilers can be derived from the number of steam engines: &amp;lt;code&amp;gt;40 ÷ 2 = 20&amp;lt;/code&amp;gt;. This produces the 1:20:40 ratio.&lt;br /&gt;
&lt;br /&gt;
[[File:SteamSetupExample.png|center|600px|thumb|A possible setup]]&lt;br /&gt;
&lt;br /&gt;
== Solar panels and accumulators ==&lt;br /&gt;
&lt;br /&gt;
=== Optimal ratio ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio is 0.84 (21:25) [[accumulator]]s per [[solar panel]], and 23.8 solar panels per megawatt required by your factory (this ratio accounts for solar panels needed to charge the accumulators). This means that you need 1.428 MW of production (of solar panels) and 100MJ of storage to provide 1 MW of power over one day-night cycle.&lt;br /&gt;
&lt;br /&gt;
A &amp;quot;close enough&amp;quot; ratio is 20:24:1 accumulators to solar panels to megawatts required (for example, a factory requiring 10 MW can be approximately entirely powered, day and night, by 200 accumulators and 240 solar panels - this approximation differs from optimal only in that it calls for 20 extra solar panels, which is negligible but remember that the difference between the &amp;quot;close enough&amp;quot; ratio and the optimal ratio increases as you add more solar panels). &lt;br /&gt;
&lt;br /&gt;
This is taken from [http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5594 Accumulator / Solar Panel Ratio] (which calculates this in an impressive mathematical way!) and [https://forums.factorio.com/viewtopic.php?p=143317#p143317 another post in that thread] (which calculates the solar panel to megawatt ratio in a different way).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;float:right; padding-left:10px; padding-right:10px;&amp;quot;&amp;gt;&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:9x9_accumulator_solar_panel_example.jpg|300px|thumb|top|A small 9x9 blueprint demonstrating the 20:24 &amp;quot;close enough&amp;quot; ratio above.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:28x28_accumulator_solar_panel_example.jpg|300px|thumb|top|A medium 28x28 blueprint with a nearly optimal ratio.]]&lt;br /&gt;
| style=&amp;quot;padding-right:1em&amp;quot; | [[File:48x48_accumulator_solar_panel_example.jpg|300px|thumb|top|A large 48x48 blueprint with a nearly optimal ratio. It also contains a roboport in the center to repair itself and automatically construct adjacent blueprint copies.]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Calculations ===&lt;br /&gt;
&lt;br /&gt;
The optimal ratio of accumulators per solar panel relies on many values in the game. These include the power generation of a solar panel, the energy storage of an accumulator, the length of a [[day]], and the length of a night. There are also times between day and night called dusk and dawn which complicate the calculations. In vanilla factorio, without mods which change any of these values, the optimal ratio will be the same. This ratio is&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels =&lt;br /&gt;
    (day + dawn) × (night + dawn × (day + dawn) / game_day) / game_day&lt;br /&gt;
    × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
which, given the default time lengths of: day = 17500/60 s; dawn or dusk = 5000/60 s; night = 2500/60 s, and the default: Solar_power = 60 kW; Accumulator_energy = 5 MJ = 5000 kJ, gives the optimal ratio of 0.84 accumulators per solar panel. If the player uses mods which change the power generation of solar panels, or the energy storage of accumulators, but &amp;lt;b&amp;gt;not&amp;lt;/b&amp;gt; the length of days, a simplified version of this equation can be used.&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 70 s × Solar_power / Accumulator_energy&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This equation could also be used to remember the vanilla optimal ratio given its simplicity. If the only effect the mod has on the game is it changes the total length of one day, without changing the ratio of dusk : day : dawn : night, then the equation can be simplified as&lt;br /&gt;
&amp;lt;pre&amp;gt;Accumulators / Solar_panels = 0.002016 /s × game_day &amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where game_day is the number of seconds in the game day which is 25000/60 s by default.&lt;br /&gt;
&lt;br /&gt;
=== See also ===&lt;br /&gt;
&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=5168&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=18&amp;amp;t=5394&lt;br /&gt;
* http://www.factorioforums.com/forum/viewtopic.php?f=5&amp;amp;t=7619&lt;br /&gt;
&lt;br /&gt;
== Nuclear power ==&lt;br /&gt;
:&#039;&#039;See also: [[Tutorial:Nuclear power]]&#039;&#039;&lt;br /&gt;
In general, nuclear power is produced by the following production chain: [[Uranium ore]] is mined and [[Uranium processing|processed]] to [[uranium-235]] and [[uranium-238]], then [[uranium fuel cell]]s are created from the two. These fuel cells are then burned in a [[nuclear reactor]] to create heat. The heat can be used to convert [[water]] to [[steam]] using a [[heat exchanger]] and the steam can be consumed by [[steam turbine]]s to produce power.&lt;br /&gt;
&lt;br /&gt;
A reactor without neighbor bonus needs 4 heat exchangers so that all its heat gets consumed. For each 100% neighbor bonus, the reactor needs 4 more heat exchangers.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Ideal Ratio !! Simple Ratio !! Building&lt;br /&gt;
|-&lt;br /&gt;
| 25 || 1 ||{{imagelink|Offshore pump}}&lt;br /&gt;
|-&lt;br /&gt;
| 291 || 12 || {{imagelink|Heat exchanger}}&lt;br /&gt;
|-&lt;br /&gt;
| 500 || 20 || {{imagelink|Steam turbine}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Ensuring enough energy is produced ==&lt;br /&gt;
&lt;br /&gt;
Try this checklist before you completely revamp your power source. You may also use this to rectify [[negative feedback loops]].&lt;br /&gt;
&lt;br /&gt;
* Did you connect the steam engine to the [[Electric system]]? If not, a small yellow triangle will flash. To fix, Add some [[Small electric pole|power poles]] near the steam engines that go to machines needing that power. Any size will work.&lt;br /&gt;
* Is steam able to reach all steam engines?&lt;br /&gt;
* Do your pipes have water? Look at the glass windows in the pipes, hover over the pipes! Place some pipes or a tank at the end to see if there is really water coming through. If not, ensure all [[pipe]]s or [https://wiki.factorio.com/index.php?title=Pipe-to-Ground underground pipes] are connected together.&lt;br /&gt;
&lt;br /&gt;
See also the [[Tutorial:Applied_Power_Math|applied power math tutorial]] to answer the question &#039;&#039;how much coal do I need?&#039;&#039;&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Tutorial:Circuit_network_cookbook&amp;diff=159168</id>
		<title>Tutorial:Circuit network cookbook</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Tutorial:Circuit_network_cookbook&amp;diff=159168"/>
		<updated>2018-05-12T23:38:22Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Usage of SR latch */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
== Foreword == &lt;br /&gt;
&lt;br /&gt;
This page provides examples of simple circuit network designs and some not so simple designs that others can use, combine and modify. They are designed to be as easy to understand as possible.  To see the settings of combinators without opening them, the option &amp;quot;Show combinator settings when detailed info is on&amp;quot; in the graphics options has to be checked and detailed info has to be turned on.&lt;br /&gt;
&lt;br /&gt;
==Lamp showing chest content condition==&lt;br /&gt;
[[File:LightWiredToChest.png|right|218 × 412px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is the simplest possible use of circuit-network. A lamp is light depending on the number of goods (in this example  empty barrels) in a chest.&lt;br /&gt;
&lt;br /&gt;
===Setting up circuit connection===&lt;br /&gt;
* The lamp is connected to the chest&lt;br /&gt;
* the lamp is set to light if the chest contain less than 10 empty barrels.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:LamponBarrelCondition.png|right|400x400px]]&lt;br /&gt;
===To set the light condition===&lt;br /&gt;
# open the lamp (left click on it)&lt;br /&gt;
# Set the input to barrels&lt;br /&gt;
# Set the operator to &amp;lt; (less than)&lt;br /&gt;
# Set the constant number:&lt;br /&gt;
## Left click on the constant number&lt;br /&gt;
## Move the slider until 10 is shown, or edit the value box directly&lt;br /&gt;
## Press set&lt;br /&gt;
&lt;br /&gt;
Depending on the condition you set, the lamp may light if the chest is empty, or if it contains the required quantity of items.&lt;br /&gt;
&lt;br /&gt;
The drawback with this scenario is that the lamp has a white light , and is therefore difficult to differentiate from an ordinary lamp at night.&lt;br /&gt;
&lt;br /&gt;
== Oil Setups ==&lt;br /&gt;
[[File:LgtOilCracking.png|left|400x400px]]&lt;br /&gt;
=== Light Oil Cracking ===&lt;br /&gt;
* This circuit provides balanced light oil and petroleum gas production by cracking excess light oil into gas. &lt;br /&gt;
* The [[Pump]] is connected to the [[Storage tank]] by a [[Red wire]]. &lt;br /&gt;
* The [[small pump]] has an enabled condition set to &#039;&#039;&#039;Light Oil &amp;gt; 2000&#039;&#039;&#039;.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:HvyOilCracking.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Heavy Oil Cracking ===&lt;br /&gt;
* This circuit extends on the previous circuit by adding optional heavy oil cracking to provide lubricant etc.&lt;br /&gt;
* The [[Pump]] has an enabled condition set to &#039;&#039;&#039;Heavy oil &amp;gt; 2000&#039;&#039;&#039;.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[file:BalancedPlasticSulfur.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Petroleum split evenly between plastic and sulphuric acid ===&lt;br /&gt;
* This circuit buffers gas in the tank until there is at least 100, then it lets the tank drain until there is less than 50 and the cycle repeats.&lt;br /&gt;
* It has a few elements that work together to do achieve this. &lt;br /&gt;
* Firstly the [[Pump]] is connected to the [[Wooden chest]] by a [[Red wire]] and the enabled condition on the [[Pump]] is set to &#039;&#039;&#039;Raw wood &amp;gt; 0&#039;&#039;&#039;.&lt;br /&gt;
* Both of the [[Inserter]]s are connected to the [[Storage tank]] by [[Red wire]]s. &lt;br /&gt;
* The enabled condition on the left inserter is &#039;&#039;&#039;Petroleum gas &amp;gt; 100&#039;&#039;&#039; &lt;br /&gt;
* The enabled condition on the right inserter is &#039;&#039;&#039;Petroleum gas &amp;lt; 50&#039;&#039;&#039;. &lt;br /&gt;
* You will need to insert a single &amp;quot;Raw wood&amp;quot; into the chest to make it all work. &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
* It is also possible to do this with [[decider combinator]]s instead of the inserters, belt and the Wood chest or even just belts.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Lights ==&lt;br /&gt;
[[File:ConditionalLights.png|left|400x400px]]&lt;br /&gt;
=== Conditional Lights ===&lt;br /&gt;
* In this circuit we connect a series of [[lamp]]s to a [[Storage tank]].&lt;br /&gt;
* By setting different conditions on each [[lamp]] we can build an indicator strip. &lt;br /&gt;
* The Enabled condition of the first [[lamp]] is &#039;&#039;&#039;Petroleum gas &amp;gt; 100&#039;&#039;&#039;.&lt;br /&gt;
* The others light up when gas is greater than 200, 300, 400 and 500 respectively.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
In this scenario you can connect the storage tank to the lamps directly.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:ColoredLights.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Colored Lights ===&lt;br /&gt;
* To light a [[lamp]] with a color rather than white, you need an intermediate device like an [[Arithmetic combinator]] that can send a color signal.  &lt;br /&gt;
Instead of directly connect  the the [[Lamp]] and the [[Storage tank]] you need:&amp;lt;BR&amp;gt;&lt;br /&gt;
1 Add the [[Arithmetic combinator]].&amp;lt;BR&amp;gt;&lt;br /&gt;
2 Connect the [[Storage tank]] with the input of the  [[Arithmetic combinator]].&amp;lt;BR&amp;gt;&lt;br /&gt;
3 Connect the  output of the [[Arithmetic combinator]] with the [[lamp]].&amp;lt;BR&amp;gt;&lt;br /&gt;
4 Set up the [[Arithmetic combinator]]:&amp;lt;BR&amp;gt;&lt;br /&gt;
4.1 Setting the input to Petroleum Gas + 0 (the constant 0 not the signal 0)&amp;lt;BR&amp;gt;&lt;br /&gt;
4.2 Set the output to the Pink signal (on the bottom row of the last tab of signals.)&amp;lt;BR&amp;gt;&lt;br /&gt;
5 Set up the [[lamp]]:&amp;lt;BR&amp;gt;&lt;br /&gt;
5.1  Select the &amp;quot;Use colors&amp;quot; check box on the lamp.&amp;lt;BR&amp;gt;&lt;br /&gt;
5.2 Set the condition to the Pink signal, and what value you want (i.e. &amp;gt; 100)&amp;lt;BR&amp;gt;&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Misc ==&lt;br /&gt;
[[file:MulitipleChestsAndPoles.png|left|400x400px]]&lt;br /&gt;
=== Multiple Storages === &lt;br /&gt;
* If you connect multiple chests to a pole, the pole displays the sum of items in all the chests. &lt;br /&gt;
* This also works with [[Storage tank]]s and [[roboport]]s.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:ConstantComb.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Constant combinator ===&lt;br /&gt;
* With a [[constant combinator]] you can generate any signals you may need. &lt;br /&gt;
* In this example we have generated a signal of 50 Laser turrets and 200 Piercing round magazine. &lt;br /&gt;
* Constant combinators are not of much use on their own but we shall use them later.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:LogicGates.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Logic gates ===&lt;br /&gt;
* In each case the two inputs can be connected with the same color wire or different colors. The inputs are powered by two [[Constant combinator]]s each of them output an A signal with value 1 for true and nothing or false.&lt;br /&gt;
* You can use [[Decider combinator]]s to make all of the common logic gates.&lt;br /&gt;
* The output for each should be set to 1 and the signal of your choice.&lt;br /&gt;
* Use the following settings to create different gates:&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
    NOT  A=0&lt;br /&gt;
    NOR  A=0&lt;br /&gt;
    NAND A&amp;lt;2&lt;br /&gt;
    XOR  A=1&lt;br /&gt;
    AND  A=2&lt;br /&gt;
    OR   A&amp;gt;0&lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:ThisASign.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Constant combinator signs ===&lt;br /&gt;
* You can use [[Constant combinator]]s to make signs, just set the letter signals in the combinator, each combinator can display 2 characters side by side.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:MemoryCell.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Memory Cell / Counter ===&lt;br /&gt;
* Basic memory cell that counts all the items moved by the inserter&lt;br /&gt;
* The [[Fast inserter]] is connected to &#039;&#039;&#039;BOTH&#039;&#039;&#039; ends of the arithmetic combinator.&lt;br /&gt;
&lt;br /&gt;
* If the [[Fast inserter]] hasn&#039;t picked anything up this tick the input to the Arithmetic combinator is the same as and output and hence the values are persisted. &lt;br /&gt;
* When the [[Fast inserter]] does pick something up its value is added to the output from the previous tick thus incrementing that item. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:BeltCache.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Automatic Belt-Cache ===&lt;br /&gt;
* Some intermediate products are huge in demand during peak-production only. To bypass the need of providing a huge amount of factories in order to cover that peaks, a cache-unit can be used. The unit stores items while the belt has backed up (so there&#039;s obviously no current demand downstream) and releases items as soon as the belt gets too empty.&lt;br /&gt;
* The blue area is 3 parts of Express belts. According to the wiki, each belt can hold up to 7.11 items. This means the feeding fast belt can not provide 7.11 items for the express belts as long as the belt is moving. (And while the belt is moving, we don&#039;t want to cache items, but let regular production run, or even release items from the cache.)&lt;br /&gt;
* This means, once the counters on the two express belts are 7.11 each, the belt has backed up, so we can start &amp;quot;caching&amp;quot; items into our storage array. &lt;br /&gt;
* For this purpose, the counters are connected to the arithmetic combinator (A) which multiples the input (*100) into green signals. So, if the belt has backed up, B shows &amp;quot;&amp;gt;1422&amp;quot; green signals.&lt;br /&gt;
* This is the activation condition for the Belt (C), which will redirect the input tp the storage array.&lt;br /&gt;
* Since items should only be released if the belt starts to clear, the counter (D) is evaluated by the belt (E) which is only activated, if item-count on (D) is smaller than 6 (this number has to be adjusted to personal needs, when the cache should become &amp;quot;active&amp;quot; and release items)&lt;br /&gt;
* The layout can be extended to cache whatever amount of items is required. (Some balancing for the release-method would be required of course.)&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:combinatorMultiplierDetailed.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Multiplier and Dictionaries/Arrays ===&lt;br /&gt;
* Multiplying two signals together is simple and requires only a single combinator, however multiplying a set of signals is more complicated.&lt;br /&gt;
* A proof is shown below for the equation and why it works.&lt;br /&gt;
* A dictionary is a system that allows a value on a specific signal to be accessed. For example, A can contain many signals (either from a constant combinator or memory cell) and B can contain 1 of a specific signal (such as blue signal). What remains is the blue-signal value from A. This is because all the other signals are multiplied by 0.&lt;br /&gt;
* Arrays are similar to dictionaries, but instead of using a signal as a key, we use a number. Constant combinators are placed mapping each signal to a unique number (such as 1 yellow belt, 2 red belt, 3 blue belt, 4 burner inserter, etc). Then, use a combinator of &amp;quot;each = index OUTPUT 1 of each&amp;quot; and plug that in as the input to a dictionary.&lt;br /&gt;
[[File:combinatorMultiplierMath.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
    ((A+B)^2 - (A-B)^2)/4 = AB&lt;br /&gt;
    (A+B)^2 - (A-B)^2 = 4AB&lt;br /&gt;
    (A^2 + 2AB + B^2) - (A^2 - 2AB + B^2) = 4AB&lt;br /&gt;
    4AB = 4AB&lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Inserters ==&lt;br /&gt;
[[File:LimitItemsPlacedIntoAChest.png|left|400x400px]]&lt;br /&gt;
=== Limit items placed into a chest ===&lt;br /&gt;
*  The [[Inserter]] is connected to the [[Wooden chest]] using a [[Red wire]]. &lt;br /&gt;
*  The inserter&#039;s enabled condition is &#039;&#039;&#039;Advanced Circuit &amp;lt; 10&#039;&#039;&#039;. &lt;br /&gt;
*  In reality this means the inserter may place more than 10 Advanced circuits in the chest because it could pick up to 3 at once due to stack size bonuses.&lt;br /&gt;
*  This effect can be even greater with Stack inserters because of their large carrying capacity. &lt;br /&gt;
*  This technique still gives far greater control than limiting the inventory on the chest.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
=== Balanced chest insert ===&lt;br /&gt;
Goal: Load n chests with approximately the same number of items.&lt;br /&gt;
*  Place n chests and n inserters. &lt;br /&gt;
*  Place 1 [[Arithmetic combinator]]&lt;br /&gt;
*  Set the combinator to take Each (yellow star) and divide by the negative number of chests. ie &amp;amp;minus;n.&lt;br /&gt;
*  Connect all chests to each other and to the input of the combinator using red wire.&lt;br /&gt;
*  Connect all inserters to each other and to the output of the combinator using red wire.&lt;br /&gt;
*  Connect each inserter to the box it inserts into with green wire.&lt;br /&gt;
*  Set the enable condition on each inserter to be Everything (red star) &amp;lt; 0.&lt;br /&gt;
&lt;br /&gt;
The combinator calculates the average number of items in the chests, and makes it negative. Each inserter gets the amount in the chest it is inserting to and adds the negative average, ie it calculates how many more than the average it has in its chest. Thus if that number is negative, it has less than the average in the chest and it enables. &lt;br /&gt;
&lt;br /&gt;
Due to inserter stack bonus the count is not exact. If a precise count is needed, set the inserter stack size to 1. &lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SmartOutpostUnloader.png|left|400x400px]]&lt;br /&gt;
=== Keeping outpost stocked with specified items ===&lt;br /&gt;
*  This circuit keeps a [[Storage chest]] at an outpost stocked with customized levels of different items. &lt;br /&gt;
*  For example you could keep an outpost stocked with 50 laser turrets and 200 piercing magazine rounds but not have to worry about it being over filled. &lt;br /&gt;
*  The [[storage chest]] is attached to the input of the [[Arithmetic combinator]] (left side in the picture) with a [[Red wire]]. &lt;br /&gt;
*  Another couple of [[Red wire]]s join the output of the [[Arithmetic combinator]] (right side) to the [[constant combinator]] and to the [[stack filter inserter]]. &lt;br /&gt;
*  The [[Arithmetic combinator]] &#039;&#039;&#039;multiplies&#039;&#039;&#039; each input value (from the storage chest) by &#039;&#039;&#039;-1&#039;&#039;&#039;. &lt;br /&gt;
*  Finally the filter stack inserter&#039;s mode of operation is set to &#039;&#039;&#039;Set filters&#039;&#039;&#039;.&lt;br /&gt;
*  So the input to the [[stack filter inserter]] is &#039;&#039;&#039;&amp;lt;Constant combinator&amp;gt; - &amp;lt;Storage chest contents&amp;gt;&#039;&#039;&#039; and the filter is set to filter the item of greatest demand.   &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SolarAccumalatorBalancer.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Balanced Solar panel / Accumulator Production ===&lt;br /&gt;
* This circuit balances production of [[Solar panel]]s and [[Accumulator]]s to a desired ratio in my case 24:20.&lt;br /&gt;
* The first [[Arithmetic combinator]] takes the number of accumulators in the chest and &#039;&#039;&#039;multiplies&#039;&#039;&#039; it by &#039;&#039;&#039;24&#039;&#039;&#039;. &lt;br /&gt;
* The second [[Arithmetic combinator]] takes the output of the first combinator and &#039;&#039;&#039;divides&#039;&#039;&#039; it by &#039;&#039;&#039;20&#039;&#039;&#039;. &lt;br /&gt;
* This gives us the number of accumulators that we can directly compare to the number of Solar panels in both inserters. &lt;br /&gt;
* If the number of accumulators is greater we enable the Solar panels inserter, if the number of Solar panels is greater we enable the accumulators inserter. &lt;br /&gt;
* However, if they are equal, neither machine does anything. So we add a single accumulator to one of the inserters using a constant combinator and a wire of the other color, therefore breaking the deadlock.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Sushi Belts ==&lt;br /&gt;
[[File:SushiScience1.png|left|400x400px]]&lt;br /&gt;
=== Reading Belt Design ===&lt;br /&gt;
* Six belts in a row are connected with Red wire and set to &#039;&#039;&#039;Read belts contents&#039;&#039;&#039; and &#039;&#039;&#039;Hold&#039;&#039;&#039; &lt;br /&gt;
* This [[Red wire]] is then connected to the inserters that insert onto the belt. &lt;br /&gt;
* Read hand contents is unselected for all inserters.&lt;br /&gt;
* Mode of operation is set to &#039;&#039;&#039;Enable/Disable&#039;&#039;&#039; on all inserters. &lt;br /&gt;
* The first inserter is enabled when &#039;&#039;&#039;Science pack 1 = 0&#039;&#039;&#039;&lt;br /&gt;
* The other inserters are set similarly for the other science packs. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SushiScience2.png|left|400x400px]]&lt;br /&gt;
=== Memory Cell Design ===&lt;br /&gt;
* This circuit counts the number of items of each type on a looping belt by counting the numbers that are added and removed from the belt by inserters.&lt;br /&gt;
* Each inserter that takes items off the belt is connected together with Red wire and each of these inserters is set to &#039;&#039;&#039;Mode of operation none, Read hand content selected&#039;&#039;&#039; and &#039;&#039;&#039;Hand read mode pulse&#039;&#039;&#039;. &lt;br /&gt;
* These inserters are connected to the input of the left arithmetic combinator. &lt;br /&gt;
* The left [[Arithmetic combinator]] multiples &#039;&#039;&#039;each&#039;&#039;&#039; input by &#039;&#039;&#039;-1&#039;&#039;&#039; and outputs it to &#039;&#039;&#039;each&#039;&#039;&#039;. &lt;br /&gt;
* The right [[Arithmetic combinator]] is a &#039;&#039;&#039;memory cell&#039;&#039;&#039; as above.&lt;br /&gt;
* The memory cell&#039;s input is connected to the inserters that are placing items on the belt and the output of the left [[Arithmetic combinator]]. &lt;br /&gt;
* The inserters that place items onto the belt have an enabled condition that is based on the number of items on the belt.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Splitters ==&lt;br /&gt;
[[file:CondSplitter.png|left|400x400px]]&lt;br /&gt;
=== Conditional splitter ===&lt;br /&gt;
* This is the simplest circuit you can have for &amp;quot;controlling&amp;quot; a splitter.&lt;br /&gt;
* A signal X=1 is transmitted from off screen when the items need to be sent down the belt.&lt;br /&gt;
* The belt on the left is enabled when X=1.&lt;br /&gt;
* The belt on the right is enabled when X=0.&lt;br /&gt;
* The two belts are wired together and to a pole. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:PrioritySplitter.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Priority Splitter ===&lt;br /&gt;
* This circuit prioritizes items to the belt going of the screen to the left but will send items straight on if the belt to the left is backed up.&lt;br /&gt;
* Its not perfect and will leak some items but its good enough for most applications. &lt;br /&gt;
* The balancer means it will work even if the supply or demand is uneven. &lt;br /&gt;
* It is critical that the belts are setup as in this picture otherwise it may not work. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Power ==&lt;br /&gt;
[[File:SteamBackup.png|left|400x400px]]&lt;br /&gt;
=== Backup steam power ===&lt;br /&gt;
* The [[steam engine]]s are not directly connected to the power network. They are connected to the power network through a [[Power switch]]. &lt;br /&gt;
* The [[power switch]] is connected to one of the [[accumulator]]s in the main network. &lt;br /&gt;
* The [[power switch]] turns on when A &amp;lt; 10. That is when the [[accumulator]]s are less than 10% full.&lt;br /&gt;
{{clear}}&lt;br /&gt;
=== Optimal usage of fuel for nuclear power ===&lt;br /&gt;
Unlike the normal steam power that adjusts fuel usage based on power usage, the [[Power_production#Nuclear_power|nuclear reactors]] spend fuel in fixed units of time. To be exact, the consumption of 1 fuel cell takes exactly 200 seconds.&lt;br /&gt;
&lt;br /&gt;
Combined with the fact that creating the nuclear fuel cells are time consuming and expensive to create, it is therefore beneficial to optimize their use to match the actual consumed power.&lt;br /&gt;
&lt;br /&gt;
[[File:NuclearCircuits.jpg]]&lt;br /&gt;
&lt;br /&gt;
The above picture shows a setup with 4 reactors, that spend only 1 fuel cell each whenever steam runs low.&lt;br /&gt;
&lt;br /&gt;
There are a few elements in this setup:&lt;br /&gt;
&lt;br /&gt;
* Storage tank that provides the [[Steam]] signal.  You should only read from one storage tank, and it should have pipe connections to all your other steam storage tanks.&lt;br /&gt;
* Chests containing [[Uranium_fuel_cell|Uranium fuel cells]] for the reactor.&lt;br /&gt;
* Output inserters that take [[Used_up_uranium_fuel_cell|Empty fuel cells]] from the reactor. This is connected to the storage tank to listen for the steam signal, and to the chests to listen for the uranium fuel cell signal. If the steam level is low and there are uranium fuel cells available, it removes the empty fuel cells from the reactor and sends an empty fuel cell signal (since &amp;quot;Read hand contents&amp;quot; is checked).&lt;br /&gt;
* Input inserters that put uranium fuel cells into the reactor. This is connected to the output inserters and listens for the empty fuel cell signal. The &amp;quot;Override stack size&amp;quot; is set to 1, so that it only inserts 1 fuel cell at a time.&lt;br /&gt;
&lt;br /&gt;
Since this design uses empty fuel cells as a signal to fill the reactor, you need to manually insert 1 uranium fuel cell into the reactor to get it started.&lt;br /&gt;
&lt;br /&gt;
== Latches ==&lt;br /&gt;
=== RS latch - single decider version ===&lt;br /&gt;
[https://forums.factorio.com/viewtopic.php?f=193&amp;amp;t=14556 This discussion] on the Factorio forums starts with the common 2 decider RS latch version, but the thread goes on to explain why this single decider version is better.&lt;br /&gt;
==== Backup steam example ====&lt;br /&gt;
This example will turn on the steam generator when the Accumulator charge drops to 20%, but will &amp;quot;latch&amp;quot; (remember) the On state until the accumulator is charged to 90%.&lt;br /&gt;
&lt;br /&gt;
Latching is used to introduce [[Wikipedia:hysteresis|hysteresis]] and avoid the power switch rapidly cycling on and off (as the accumulator falls to 19%, charges to 20%, falls to 19% and so on).&lt;br /&gt;
[[File:SR-01-Layout.png|left]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br clear=all&amp;gt; &lt;br /&gt;
&amp;lt;div class=&amp;quot;toccolours mw-collapsible mw-collapsed&amp;quot; style=&amp;quot;width:50em;&amp;quot;&amp;gt;&lt;br /&gt;
Blueprint string for above backup steam example&lt;br /&gt;
&amp;lt;div class=&amp;quot;mw-collapsible-content&amp;quot;&amp;gt;&amp;lt;pre style=&amp;quot;white-space: pre-wrap; &lt;br /&gt;
 white-space: -moz-pre-wrap; &lt;br /&gt;
 white-space: -pre-wrap; &lt;br /&gt;
 white-space: -o-pre-wrap; &lt;br /&gt;
 word-wrap: break-word;&amp;quot;&amp;gt;&lt;br /&gt;
0eNrFVk1vozAQ/SuVz1ABCaRBq5WqXntKjqsKOTBJR8IGGTtpFPHfd+w0HyU0G6pVewkxnnmemfdmzI4tSgO1QqlZumOYV7Jh6Z8da3AleWnf6W0NLGVrVNrQG49JLuyLvYU/Z63HUBbwxtKw9QZ4zs48o15P1CBObgXkWIDy80osUHJdqTOAUfviMZAaNcI+A7fYZtKIBSiK7YgjoEAjfCgh1wpzv65KoFPqqiHnStrzCdAPA49t6Rm1NrYOWjQY7QrY6FQZwcvyX1jJFajxEYrnuRGmdGW6DCe+jx1KcB9TDYl1raoyW8ArXyM5kFVldG10djObj6zdI0kKHp2Mdiy0PysFIM8pwYKldHyOKjeo3TI8y8Wup93tl7Yv3fiaOC6zjt6z9uk4VqDaR+rY7CvBO2ZGewUec1qiaobVxaE3mtseiwK7EjVXLsaU/SKPobWe7zHrLYVmpM6WqhIZSsJg6ZKXDQyiYkzF9Vhk9xUU3d3kNiaSQUwEB/l9Hw+uZg1YjGzYiPpA1+/vpKuHjk7fRNf7JrJTsZf05MLwoIFbzLvtOvlEFZNjKepqQ5poNqjz10s9jA6N+fk8Ohx/FMFXNXDqxeCC20F901vCJxN07UjVG9K4+x9YQp5M2LUZfbTpq+XDKRsNnG4cuULZcz089HZWD+D0a8Pz52bnNPgPzTj76dlJAnDfNenZp5fHSr4ACp/NZ3fPnHrkDt64qN31vwbVuFIn43GUjCdxHIVt+xcL2lBp&amp;lt;/pre&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-02-Accumulator.png|left]]Accumulator outputs the current charge level as % on signal [[File:Signal-A.png]]&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-03-RangeDeciders.png|left]]First decider outputs &amp;quot;Set&amp;quot; ([[File:Signal-S.png]] = 1) if Accumulator is less than 20%.&lt;br /&gt;
Second decider outputs &amp;quot;Reset&amp;quot; ([[File:Signal-R.png]] = 1) once Accumulator is more than 90% full.&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-04-SRLatch.png|left]]&lt;br /&gt;
==== RS Latch configuration ====&lt;br /&gt;
&#039;&#039;&#039;The central decider and green feedback wire is the actual RS Latch.&#039;&#039;&#039;&lt;br /&gt;
It latches the Set signal [[File:Signal-S.png]] until the Reset signal [[File:Signal-R.png]] is received (and vice-versa).&amp;lt;br /&amp;gt;&lt;br /&gt;
NB: the latch expects binary inputs ([[File:Signal-S.png]] &amp;amp; [[File:Signal-R.png]] must be 0 or 1) - this is why the previous two deciders are required.&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-05-PowerSwitch.png|left]]The Power switch isolates the generator from the rest of the factory until [[File:Signal-S.png]] = 1&lt;br /&gt;
&amp;lt;br clear=all&amp;gt; &lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== RS latch ===&lt;br /&gt;
[[File:SRLatch.png|left|400x400px]]&lt;br /&gt;
* This should be familiar to anyone with any background in electronics. &lt;br /&gt;
* The signal is set and reset with the [[constant combinator]]s on the left by setting an A=1 signal. &lt;br /&gt;
* The latch &amp;quot;remembers&amp;quot; which one was last set and the light stays on until another signal is received.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SRlatchinaction.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Usage of RS latch ===&lt;br /&gt;
* Here is an example of how you could use an RS latch.&lt;br /&gt;
* The two extra [[Decider combinator]]s provide the set and reset conditions. &lt;br /&gt;
* Petroleum gas &amp;lt; 50 and petroleum gas &amp;gt; 100. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:BeltLatch.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Belt only latch ===&lt;br /&gt;
* This is the most compact latch I am aware of. &lt;br /&gt;
* To make it work you need to place &#039;&#039;&#039;3&#039;&#039;&#039; raw wood on the inside lane of the belt.&lt;br /&gt;
* I believe it will have higher latency than the combinator version but in most situations you will not notice the difference. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Displays ==&lt;br /&gt;
[[File:5digitDisplay.png|left|400x400px]]&lt;br /&gt;
=== Numerical Display ===&lt;br /&gt;
* Each digit is driven by its own [[Green wire]], that wire holds 15 signals one for each lamp used in the digit.&lt;br /&gt;
* [[Constant combinator]]s are used to define which lamp should light up for each value. &lt;br /&gt;
* Blueprint string including decoder [https://www.dropbox.com/s/5o13xuwthalzzfe/Brain2.txt?dl=0]&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:BWDisplay.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Black and White Grid Display ===&lt;br /&gt;
* Each row has its own [[Red wire]] connection and within that row each light has a numbered signal 0-9.&lt;br /&gt;
* We turn each light on by just setting or clearing the relevant signal.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:MultiColoredDisplay.png|left|400x400px]]&lt;br /&gt;
=== Multicolor Display by DaveMcW ===&lt;br /&gt;
* To understand how this works, you first need to understand how color lights choose which color to light up when there are multiple colored signals. &lt;br /&gt;
* The [[lamp]] will light up with the colored signal that is greater than zero and earliest in this list: Red, Green, Blue, Yellow, Pink, Cyan, White.  &lt;br /&gt;
* We have a [[Red wire]] per column, that wire has each of the colored signals on it at different values and a numbered signal for each row. &lt;br /&gt;
* There is a [[Arithmetic combinator]] for each cell that subtracts the &amp;quot;row&amp;quot; value from each of the colored signals. &lt;br /&gt;
* And this enables us to choose the color for each cell. &lt;br /&gt;
* Simple!&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
* [[Arithmetic combinator]]&lt;br /&gt;
* [[Constant combinator]]&lt;br /&gt;
* [[Decider combinator]]&lt;br /&gt;
* [[Circuit network]]&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Tutorial:Circuit_network_cookbook&amp;diff=159167</id>
		<title>Tutorial:Circuit network cookbook</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Tutorial:Circuit_network_cookbook&amp;diff=159167"/>
		<updated>2018-05-12T23:37:55Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* SR latch */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
== Foreword == &lt;br /&gt;
&lt;br /&gt;
This page provides examples of simple circuit network designs and some not so simple designs that others can use, combine and modify. They are designed to be as easy to understand as possible.  To see the settings of combinators without opening them, the option &amp;quot;Show combinator settings when detailed info is on&amp;quot; in the graphics options has to be checked and detailed info has to be turned on.&lt;br /&gt;
&lt;br /&gt;
==Lamp showing chest content condition==&lt;br /&gt;
[[File:LightWiredToChest.png|right|218 × 412px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is the simplest possible use of circuit-network. A lamp is light depending on the number of goods (in this example  empty barrels) in a chest.&lt;br /&gt;
&lt;br /&gt;
===Setting up circuit connection===&lt;br /&gt;
* The lamp is connected to the chest&lt;br /&gt;
* the lamp is set to light if the chest contain less than 10 empty barrels.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:LamponBarrelCondition.png|right|400x400px]]&lt;br /&gt;
===To set the light condition===&lt;br /&gt;
# open the lamp (left click on it)&lt;br /&gt;
# Set the input to barrels&lt;br /&gt;
# Set the operator to &amp;lt; (less than)&lt;br /&gt;
# Set the constant number:&lt;br /&gt;
## Left click on the constant number&lt;br /&gt;
## Move the slider until 10 is shown, or edit the value box directly&lt;br /&gt;
## Press set&lt;br /&gt;
&lt;br /&gt;
Depending on the condition you set, the lamp may light if the chest is empty, or if it contains the required quantity of items.&lt;br /&gt;
&lt;br /&gt;
The drawback with this scenario is that the lamp has a white light , and is therefore difficult to differentiate from an ordinary lamp at night.&lt;br /&gt;
&lt;br /&gt;
== Oil Setups ==&lt;br /&gt;
[[File:LgtOilCracking.png|left|400x400px]]&lt;br /&gt;
=== Light Oil Cracking ===&lt;br /&gt;
* This circuit provides balanced light oil and petroleum gas production by cracking excess light oil into gas. &lt;br /&gt;
* The [[Pump]] is connected to the [[Storage tank]] by a [[Red wire]]. &lt;br /&gt;
* The [[small pump]] has an enabled condition set to &#039;&#039;&#039;Light Oil &amp;gt; 2000&#039;&#039;&#039;.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:HvyOilCracking.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Heavy Oil Cracking ===&lt;br /&gt;
* This circuit extends on the previous circuit by adding optional heavy oil cracking to provide lubricant etc.&lt;br /&gt;
* The [[Pump]] has an enabled condition set to &#039;&#039;&#039;Heavy oil &amp;gt; 2000&#039;&#039;&#039;.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[file:BalancedPlasticSulfur.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Petroleum split evenly between plastic and sulphuric acid ===&lt;br /&gt;
* This circuit buffers gas in the tank until there is at least 100, then it lets the tank drain until there is less than 50 and the cycle repeats.&lt;br /&gt;
* It has a few elements that work together to do achieve this. &lt;br /&gt;
* Firstly the [[Pump]] is connected to the [[Wooden chest]] by a [[Red wire]] and the enabled condition on the [[Pump]] is set to &#039;&#039;&#039;Raw wood &amp;gt; 0&#039;&#039;&#039;.&lt;br /&gt;
* Both of the [[Inserter]]s are connected to the [[Storage tank]] by [[Red wire]]s. &lt;br /&gt;
* The enabled condition on the left inserter is &#039;&#039;&#039;Petroleum gas &amp;gt; 100&#039;&#039;&#039; &lt;br /&gt;
* The enabled condition on the right inserter is &#039;&#039;&#039;Petroleum gas &amp;lt; 50&#039;&#039;&#039;. &lt;br /&gt;
* You will need to insert a single &amp;quot;Raw wood&amp;quot; into the chest to make it all work. &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
* It is also possible to do this with [[decider combinator]]s instead of the inserters, belt and the Wood chest or even just belts.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Lights ==&lt;br /&gt;
[[File:ConditionalLights.png|left|400x400px]]&lt;br /&gt;
=== Conditional Lights ===&lt;br /&gt;
* In this circuit we connect a series of [[lamp]]s to a [[Storage tank]].&lt;br /&gt;
* By setting different conditions on each [[lamp]] we can build an indicator strip. &lt;br /&gt;
* The Enabled condition of the first [[lamp]] is &#039;&#039;&#039;Petroleum gas &amp;gt; 100&#039;&#039;&#039;.&lt;br /&gt;
* The others light up when gas is greater than 200, 300, 400 and 500 respectively.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
In this scenario you can connect the storage tank to the lamps directly.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:ColoredLights.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Colored Lights ===&lt;br /&gt;
* To light a [[lamp]] with a color rather than white, you need an intermediate device like an [[Arithmetic combinator]] that can send a color signal.  &lt;br /&gt;
Instead of directly connect  the the [[Lamp]] and the [[Storage tank]] you need:&amp;lt;BR&amp;gt;&lt;br /&gt;
1 Add the [[Arithmetic combinator]].&amp;lt;BR&amp;gt;&lt;br /&gt;
2 Connect the [[Storage tank]] with the input of the  [[Arithmetic combinator]].&amp;lt;BR&amp;gt;&lt;br /&gt;
3 Connect the  output of the [[Arithmetic combinator]] with the [[lamp]].&amp;lt;BR&amp;gt;&lt;br /&gt;
4 Set up the [[Arithmetic combinator]]:&amp;lt;BR&amp;gt;&lt;br /&gt;
4.1 Setting the input to Petroleum Gas + 0 (the constant 0 not the signal 0)&amp;lt;BR&amp;gt;&lt;br /&gt;
4.2 Set the output to the Pink signal (on the bottom row of the last tab of signals.)&amp;lt;BR&amp;gt;&lt;br /&gt;
5 Set up the [[lamp]]:&amp;lt;BR&amp;gt;&lt;br /&gt;
5.1  Select the &amp;quot;Use colors&amp;quot; check box on the lamp.&amp;lt;BR&amp;gt;&lt;br /&gt;
5.2 Set the condition to the Pink signal, and what value you want (i.e. &amp;gt; 100)&amp;lt;BR&amp;gt;&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Misc ==&lt;br /&gt;
[[file:MulitipleChestsAndPoles.png|left|400x400px]]&lt;br /&gt;
=== Multiple Storages === &lt;br /&gt;
* If you connect multiple chests to a pole, the pole displays the sum of items in all the chests. &lt;br /&gt;
* This also works with [[Storage tank]]s and [[roboport]]s.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:ConstantComb.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Constant combinator ===&lt;br /&gt;
* With a [[constant combinator]] you can generate any signals you may need. &lt;br /&gt;
* In this example we have generated a signal of 50 Laser turrets and 200 Piercing round magazine. &lt;br /&gt;
* Constant combinators are not of much use on their own but we shall use them later.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:LogicGates.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Logic gates ===&lt;br /&gt;
* In each case the two inputs can be connected with the same color wire or different colors. The inputs are powered by two [[Constant combinator]]s each of them output an A signal with value 1 for true and nothing or false.&lt;br /&gt;
* You can use [[Decider combinator]]s to make all of the common logic gates.&lt;br /&gt;
* The output for each should be set to 1 and the signal of your choice.&lt;br /&gt;
* Use the following settings to create different gates:&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
    NOT  A=0&lt;br /&gt;
    NOR  A=0&lt;br /&gt;
    NAND A&amp;lt;2&lt;br /&gt;
    XOR  A=1&lt;br /&gt;
    AND  A=2&lt;br /&gt;
    OR   A&amp;gt;0&lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:ThisASign.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Constant combinator signs ===&lt;br /&gt;
* You can use [[Constant combinator]]s to make signs, just set the letter signals in the combinator, each combinator can display 2 characters side by side.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:MemoryCell.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Memory Cell / Counter ===&lt;br /&gt;
* Basic memory cell that counts all the items moved by the inserter&lt;br /&gt;
* The [[Fast inserter]] is connected to &#039;&#039;&#039;BOTH&#039;&#039;&#039; ends of the arithmetic combinator.&lt;br /&gt;
&lt;br /&gt;
* If the [[Fast inserter]] hasn&#039;t picked anything up this tick the input to the Arithmetic combinator is the same as and output and hence the values are persisted. &lt;br /&gt;
* When the [[Fast inserter]] does pick something up its value is added to the output from the previous tick thus incrementing that item. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:BeltCache.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Automatic Belt-Cache ===&lt;br /&gt;
* Some intermediate products are huge in demand during peak-production only. To bypass the need of providing a huge amount of factories in order to cover that peaks, a cache-unit can be used. The unit stores items while the belt has backed up (so there&#039;s obviously no current demand downstream) and releases items as soon as the belt gets too empty.&lt;br /&gt;
* The blue area is 3 parts of Express belts. According to the wiki, each belt can hold up to 7.11 items. This means the feeding fast belt can not provide 7.11 items for the express belts as long as the belt is moving. (And while the belt is moving, we don&#039;t want to cache items, but let regular production run, or even release items from the cache.)&lt;br /&gt;
* This means, once the counters on the two express belts are 7.11 each, the belt has backed up, so we can start &amp;quot;caching&amp;quot; items into our storage array. &lt;br /&gt;
* For this purpose, the counters are connected to the arithmetic combinator (A) which multiples the input (*100) into green signals. So, if the belt has backed up, B shows &amp;quot;&amp;gt;1422&amp;quot; green signals.&lt;br /&gt;
* This is the activation condition for the Belt (C), which will redirect the input tp the storage array.&lt;br /&gt;
* Since items should only be released if the belt starts to clear, the counter (D) is evaluated by the belt (E) which is only activated, if item-count on (D) is smaller than 6 (this number has to be adjusted to personal needs, when the cache should become &amp;quot;active&amp;quot; and release items)&lt;br /&gt;
* The layout can be extended to cache whatever amount of items is required. (Some balancing for the release-method would be required of course.)&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:combinatorMultiplierDetailed.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Multiplier and Dictionaries/Arrays ===&lt;br /&gt;
* Multiplying two signals together is simple and requires only a single combinator, however multiplying a set of signals is more complicated.&lt;br /&gt;
* A proof is shown below for the equation and why it works.&lt;br /&gt;
* A dictionary is a system that allows a value on a specific signal to be accessed. For example, A can contain many signals (either from a constant combinator or memory cell) and B can contain 1 of a specific signal (such as blue signal). What remains is the blue-signal value from A. This is because all the other signals are multiplied by 0.&lt;br /&gt;
* Arrays are similar to dictionaries, but instead of using a signal as a key, we use a number. Constant combinators are placed mapping each signal to a unique number (such as 1 yellow belt, 2 red belt, 3 blue belt, 4 burner inserter, etc). Then, use a combinator of &amp;quot;each = index OUTPUT 1 of each&amp;quot; and plug that in as the input to a dictionary.&lt;br /&gt;
[[File:combinatorMultiplierMath.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
    ((A+B)^2 - (A-B)^2)/4 = AB&lt;br /&gt;
    (A+B)^2 - (A-B)^2 = 4AB&lt;br /&gt;
    (A^2 + 2AB + B^2) - (A^2 - 2AB + B^2) = 4AB&lt;br /&gt;
    4AB = 4AB&lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Inserters ==&lt;br /&gt;
[[File:LimitItemsPlacedIntoAChest.png|left|400x400px]]&lt;br /&gt;
=== Limit items placed into a chest ===&lt;br /&gt;
*  The [[Inserter]] is connected to the [[Wooden chest]] using a [[Red wire]]. &lt;br /&gt;
*  The inserter&#039;s enabled condition is &#039;&#039;&#039;Advanced Circuit &amp;lt; 10&#039;&#039;&#039;. &lt;br /&gt;
*  In reality this means the inserter may place more than 10 Advanced circuits in the chest because it could pick up to 3 at once due to stack size bonuses.&lt;br /&gt;
*  This effect can be even greater with Stack inserters because of their large carrying capacity. &lt;br /&gt;
*  This technique still gives far greater control than limiting the inventory on the chest.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
=== Balanced chest insert ===&lt;br /&gt;
Goal: Load n chests with approximately the same number of items.&lt;br /&gt;
*  Place n chests and n inserters. &lt;br /&gt;
*  Place 1 [[Arithmetic combinator]]&lt;br /&gt;
*  Set the combinator to take Each (yellow star) and divide by the negative number of chests. ie &amp;amp;minus;n.&lt;br /&gt;
*  Connect all chests to each other and to the input of the combinator using red wire.&lt;br /&gt;
*  Connect all inserters to each other and to the output of the combinator using red wire.&lt;br /&gt;
*  Connect each inserter to the box it inserts into with green wire.&lt;br /&gt;
*  Set the enable condition on each inserter to be Everything (red star) &amp;lt; 0.&lt;br /&gt;
&lt;br /&gt;
The combinator calculates the average number of items in the chests, and makes it negative. Each inserter gets the amount in the chest it is inserting to and adds the negative average, ie it calculates how many more than the average it has in its chest. Thus if that number is negative, it has less than the average in the chest and it enables. &lt;br /&gt;
&lt;br /&gt;
Due to inserter stack bonus the count is not exact. If a precise count is needed, set the inserter stack size to 1. &lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SmartOutpostUnloader.png|left|400x400px]]&lt;br /&gt;
=== Keeping outpost stocked with specified items ===&lt;br /&gt;
*  This circuit keeps a [[Storage chest]] at an outpost stocked with customized levels of different items. &lt;br /&gt;
*  For example you could keep an outpost stocked with 50 laser turrets and 200 piercing magazine rounds but not have to worry about it being over filled. &lt;br /&gt;
*  The [[storage chest]] is attached to the input of the [[Arithmetic combinator]] (left side in the picture) with a [[Red wire]]. &lt;br /&gt;
*  Another couple of [[Red wire]]s join the output of the [[Arithmetic combinator]] (right side) to the [[constant combinator]] and to the [[stack filter inserter]]. &lt;br /&gt;
*  The [[Arithmetic combinator]] &#039;&#039;&#039;multiplies&#039;&#039;&#039; each input value (from the storage chest) by &#039;&#039;&#039;-1&#039;&#039;&#039;. &lt;br /&gt;
*  Finally the filter stack inserter&#039;s mode of operation is set to &#039;&#039;&#039;Set filters&#039;&#039;&#039;.&lt;br /&gt;
*  So the input to the [[stack filter inserter]] is &#039;&#039;&#039;&amp;lt;Constant combinator&amp;gt; - &amp;lt;Storage chest contents&amp;gt;&#039;&#039;&#039; and the filter is set to filter the item of greatest demand.   &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SolarAccumalatorBalancer.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Balanced Solar panel / Accumulator Production ===&lt;br /&gt;
* This circuit balances production of [[Solar panel]]s and [[Accumulator]]s to a desired ratio in my case 24:20.&lt;br /&gt;
* The first [[Arithmetic combinator]] takes the number of accumulators in the chest and &#039;&#039;&#039;multiplies&#039;&#039;&#039; it by &#039;&#039;&#039;24&#039;&#039;&#039;. &lt;br /&gt;
* The second [[Arithmetic combinator]] takes the output of the first combinator and &#039;&#039;&#039;divides&#039;&#039;&#039; it by &#039;&#039;&#039;20&#039;&#039;&#039;. &lt;br /&gt;
* This gives us the number of accumulators that we can directly compare to the number of Solar panels in both inserters. &lt;br /&gt;
* If the number of accumulators is greater we enable the Solar panels inserter, if the number of Solar panels is greater we enable the accumulators inserter. &lt;br /&gt;
* However, if they are equal, neither machine does anything. So we add a single accumulator to one of the inserters using a constant combinator and a wire of the other color, therefore breaking the deadlock.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Sushi Belts ==&lt;br /&gt;
[[File:SushiScience1.png|left|400x400px]]&lt;br /&gt;
=== Reading Belt Design ===&lt;br /&gt;
* Six belts in a row are connected with Red wire and set to &#039;&#039;&#039;Read belts contents&#039;&#039;&#039; and &#039;&#039;&#039;Hold&#039;&#039;&#039; &lt;br /&gt;
* This [[Red wire]] is then connected to the inserters that insert onto the belt. &lt;br /&gt;
* Read hand contents is unselected for all inserters.&lt;br /&gt;
* Mode of operation is set to &#039;&#039;&#039;Enable/Disable&#039;&#039;&#039; on all inserters. &lt;br /&gt;
* The first inserter is enabled when &#039;&#039;&#039;Science pack 1 = 0&#039;&#039;&#039;&lt;br /&gt;
* The other inserters are set similarly for the other science packs. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SushiScience2.png|left|400x400px]]&lt;br /&gt;
=== Memory Cell Design ===&lt;br /&gt;
* This circuit counts the number of items of each type on a looping belt by counting the numbers that are added and removed from the belt by inserters.&lt;br /&gt;
* Each inserter that takes items off the belt is connected together with Red wire and each of these inserters is set to &#039;&#039;&#039;Mode of operation none, Read hand content selected&#039;&#039;&#039; and &#039;&#039;&#039;Hand read mode pulse&#039;&#039;&#039;. &lt;br /&gt;
* These inserters are connected to the input of the left arithmetic combinator. &lt;br /&gt;
* The left [[Arithmetic combinator]] multiples &#039;&#039;&#039;each&#039;&#039;&#039; input by &#039;&#039;&#039;-1&#039;&#039;&#039; and outputs it to &#039;&#039;&#039;each&#039;&#039;&#039;. &lt;br /&gt;
* The right [[Arithmetic combinator]] is a &#039;&#039;&#039;memory cell&#039;&#039;&#039; as above.&lt;br /&gt;
* The memory cell&#039;s input is connected to the inserters that are placing items on the belt and the output of the left [[Arithmetic combinator]]. &lt;br /&gt;
* The inserters that place items onto the belt have an enabled condition that is based on the number of items on the belt.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Splitters ==&lt;br /&gt;
[[file:CondSplitter.png|left|400x400px]]&lt;br /&gt;
=== Conditional splitter ===&lt;br /&gt;
* This is the simplest circuit you can have for &amp;quot;controlling&amp;quot; a splitter.&lt;br /&gt;
* A signal X=1 is transmitted from off screen when the items need to be sent down the belt.&lt;br /&gt;
* The belt on the left is enabled when X=1.&lt;br /&gt;
* The belt on the right is enabled when X=0.&lt;br /&gt;
* The two belts are wired together and to a pole. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:PrioritySplitter.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Priority Splitter ===&lt;br /&gt;
* This circuit prioritizes items to the belt going of the screen to the left but will send items straight on if the belt to the left is backed up.&lt;br /&gt;
* Its not perfect and will leak some items but its good enough for most applications. &lt;br /&gt;
* The balancer means it will work even if the supply or demand is uneven. &lt;br /&gt;
* It is critical that the belts are setup as in this picture otherwise it may not work. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Power ==&lt;br /&gt;
[[File:SteamBackup.png|left|400x400px]]&lt;br /&gt;
=== Backup steam power ===&lt;br /&gt;
* The [[steam engine]]s are not directly connected to the power network. They are connected to the power network through a [[Power switch]]. &lt;br /&gt;
* The [[power switch]] is connected to one of the [[accumulator]]s in the main network. &lt;br /&gt;
* The [[power switch]] turns on when A &amp;lt; 10. That is when the [[accumulator]]s are less than 10% full.&lt;br /&gt;
{{clear}}&lt;br /&gt;
=== Optimal usage of fuel for nuclear power ===&lt;br /&gt;
Unlike the normal steam power that adjusts fuel usage based on power usage, the [[Power_production#Nuclear_power|nuclear reactors]] spend fuel in fixed units of time. To be exact, the consumption of 1 fuel cell takes exactly 200 seconds.&lt;br /&gt;
&lt;br /&gt;
Combined with the fact that creating the nuclear fuel cells are time consuming and expensive to create, it is therefore beneficial to optimize their use to match the actual consumed power.&lt;br /&gt;
&lt;br /&gt;
[[File:NuclearCircuits.jpg]]&lt;br /&gt;
&lt;br /&gt;
The above picture shows a setup with 4 reactors, that spend only 1 fuel cell each whenever steam runs low.&lt;br /&gt;
&lt;br /&gt;
There are a few elements in this setup:&lt;br /&gt;
&lt;br /&gt;
* Storage tank that provides the [[Steam]] signal.  You should only read from one storage tank, and it should have pipe connections to all your other steam storage tanks.&lt;br /&gt;
* Chests containing [[Uranium_fuel_cell|Uranium fuel cells]] for the reactor.&lt;br /&gt;
* Output inserters that take [[Used_up_uranium_fuel_cell|Empty fuel cells]] from the reactor. This is connected to the storage tank to listen for the steam signal, and to the chests to listen for the uranium fuel cell signal. If the steam level is low and there are uranium fuel cells available, it removes the empty fuel cells from the reactor and sends an empty fuel cell signal (since &amp;quot;Read hand contents&amp;quot; is checked).&lt;br /&gt;
* Input inserters that put uranium fuel cells into the reactor. This is connected to the output inserters and listens for the empty fuel cell signal. The &amp;quot;Override stack size&amp;quot; is set to 1, so that it only inserts 1 fuel cell at a time.&lt;br /&gt;
&lt;br /&gt;
Since this design uses empty fuel cells as a signal to fill the reactor, you need to manually insert 1 uranium fuel cell into the reactor to get it started.&lt;br /&gt;
&lt;br /&gt;
== Latches ==&lt;br /&gt;
=== RS latch - single decider version ===&lt;br /&gt;
[https://forums.factorio.com/viewtopic.php?f=193&amp;amp;t=14556 This discussion] on the Factorio forums starts with the common 2 decider RS latch version, but the thread goes on to explain why this single decider version is better.&lt;br /&gt;
==== Backup steam example ====&lt;br /&gt;
This example will turn on the steam generator when the Accumulator charge drops to 20%, but will &amp;quot;latch&amp;quot; (remember) the On state until the accumulator is charged to 90%.&lt;br /&gt;
&lt;br /&gt;
Latching is used to introduce [[Wikipedia:hysteresis|hysteresis]] and avoid the power switch rapidly cycling on and off (as the accumulator falls to 19%, charges to 20%, falls to 19% and so on).&lt;br /&gt;
[[File:SR-01-Layout.png|left]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br clear=all&amp;gt; &lt;br /&gt;
&amp;lt;div class=&amp;quot;toccolours mw-collapsible mw-collapsed&amp;quot; style=&amp;quot;width:50em;&amp;quot;&amp;gt;&lt;br /&gt;
Blueprint string for above backup steam example&lt;br /&gt;
&amp;lt;div class=&amp;quot;mw-collapsible-content&amp;quot;&amp;gt;&amp;lt;pre style=&amp;quot;white-space: pre-wrap; &lt;br /&gt;
 white-space: -moz-pre-wrap; &lt;br /&gt;
 white-space: -pre-wrap; &lt;br /&gt;
 white-space: -o-pre-wrap; &lt;br /&gt;
 word-wrap: break-word;&amp;quot;&amp;gt;&lt;br /&gt;
0eNrFVk1vozAQ/SuVz1ABCaRBq5WqXntKjqsKOTBJR8IGGTtpFPHfd+w0HyU0G6pVewkxnnmemfdmzI4tSgO1QqlZumOYV7Jh6Z8da3AleWnf6W0NLGVrVNrQG49JLuyLvYU/Z63HUBbwxtKw9QZ4zs48o15P1CBObgXkWIDy80osUHJdqTOAUfviMZAaNcI+A7fYZtKIBSiK7YgjoEAjfCgh1wpzv65KoFPqqiHnStrzCdAPA49t6Rm1NrYOWjQY7QrY6FQZwcvyX1jJFajxEYrnuRGmdGW6DCe+jx1KcB9TDYl1raoyW8ArXyM5kFVldG10djObj6zdI0kKHp2Mdiy0PysFIM8pwYKldHyOKjeo3TI8y8Wup93tl7Yv3fiaOC6zjt6z9uk4VqDaR+rY7CvBO2ZGewUec1qiaobVxaE3mtseiwK7EjVXLsaU/SKPobWe7zHrLYVmpM6WqhIZSsJg6ZKXDQyiYkzF9Vhk9xUU3d3kNiaSQUwEB/l9Hw+uZg1YjGzYiPpA1+/vpKuHjk7fRNf7JrJTsZf05MLwoIFbzLvtOvlEFZNjKepqQ5poNqjz10s9jA6N+fk8Ohx/FMFXNXDqxeCC20F901vCJxN07UjVG9K4+x9YQp5M2LUZfbTpq+XDKRsNnG4cuULZcz089HZWD+D0a8Pz52bnNPgPzTj76dlJAnDfNenZp5fHSr4ACp/NZ3fPnHrkDt64qN31vwbVuFIn43GUjCdxHIVt+xcL2lBp&amp;lt;/pre&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-02-Accumulator.png|left]]Accumulator outputs the current charge level as % on signal [[File:Signal-A.png]]&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-03-RangeDeciders.png|left]]First decider outputs &amp;quot;Set&amp;quot; ([[File:Signal-S.png]] = 1) if Accumulator is less than 20%.&lt;br /&gt;
Second decider outputs &amp;quot;Reset&amp;quot; ([[File:Signal-R.png]] = 1) once Accumulator is more than 90% full.&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-04-SRLatch.png|left]]&lt;br /&gt;
==== RS Latch configuration ====&lt;br /&gt;
&#039;&#039;&#039;The central decider and green feedback wire is the actual RS Latch.&#039;&#039;&#039;&lt;br /&gt;
It latches the Set signal [[File:Signal-S.png]] until the Reset signal [[File:Signal-R.png]] is received (and vice-versa).&amp;lt;br /&amp;gt;&lt;br /&gt;
NB: the latch expects binary inputs ([[File:Signal-S.png]] &amp;amp; [[File:Signal-R.png]] must be 0 or 1) - this is why the previous two deciders are required.&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-05-PowerSwitch.png|left]]The Power switch isolates the generator from the rest of the factory until [[File:Signal-S.png]] = 1&lt;br /&gt;
&amp;lt;br clear=all&amp;gt; &lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== RS latch ===&lt;br /&gt;
[[File:SRLatch.png|left|400x400px]]&lt;br /&gt;
* This should be familiar to anyone with any background in electronics. &lt;br /&gt;
* The signal is set and reset with the [[constant combinator]]s on the left by setting an A=1 signal. &lt;br /&gt;
* The latch &amp;quot;remembers&amp;quot; which one was last set and the light stays on until another signal is received.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SRlatchinaction.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Usage of SR latch ===&lt;br /&gt;
* Here is an example of how you could use an SR latch.&lt;br /&gt;
* The two extra [[Decider combinator]]s provide the set and reset conditions. &lt;br /&gt;
* Petroleum gas &amp;lt; 50 and petroleum gas &amp;gt; 100. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:BeltLatch.png|left|400x400px]]&lt;br /&gt;
=== Belt only latch ===&lt;br /&gt;
* This is the most compact latch I am aware of. &lt;br /&gt;
* To make it work you need to place &#039;&#039;&#039;3&#039;&#039;&#039; raw wood on the inside lane of the belt.&lt;br /&gt;
* I believe it will have higher latency than the combinator version but in most situations you will not notice the difference. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Displays ==&lt;br /&gt;
[[File:5digitDisplay.png|left|400x400px]]&lt;br /&gt;
=== Numerical Display ===&lt;br /&gt;
* Each digit is driven by its own [[Green wire]], that wire holds 15 signals one for each lamp used in the digit.&lt;br /&gt;
* [[Constant combinator]]s are used to define which lamp should light up for each value. &lt;br /&gt;
* Blueprint string including decoder [https://www.dropbox.com/s/5o13xuwthalzzfe/Brain2.txt?dl=0]&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:BWDisplay.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Black and White Grid Display ===&lt;br /&gt;
* Each row has its own [[Red wire]] connection and within that row each light has a numbered signal 0-9.&lt;br /&gt;
* We turn each light on by just setting or clearing the relevant signal.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:MultiColoredDisplay.png|left|400x400px]]&lt;br /&gt;
=== Multicolor Display by DaveMcW ===&lt;br /&gt;
* To understand how this works, you first need to understand how color lights choose which color to light up when there are multiple colored signals. &lt;br /&gt;
* The [[lamp]] will light up with the colored signal that is greater than zero and earliest in this list: Red, Green, Blue, Yellow, Pink, Cyan, White.  &lt;br /&gt;
* We have a [[Red wire]] per column, that wire has each of the colored signals on it at different values and a numbered signal for each row. &lt;br /&gt;
* There is a [[Arithmetic combinator]] for each cell that subtracts the &amp;quot;row&amp;quot; value from each of the colored signals. &lt;br /&gt;
* And this enables us to choose the color for each cell. &lt;br /&gt;
* Simple!&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
* [[Arithmetic combinator]]&lt;br /&gt;
* [[Constant combinator]]&lt;br /&gt;
* [[Decider combinator]]&lt;br /&gt;
* [[Circuit network]]&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Tutorial:Circuit_network_cookbook&amp;diff=159166</id>
		<title>Tutorial:Circuit network cookbook</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Tutorial:Circuit_network_cookbook&amp;diff=159166"/>
		<updated>2018-05-12T23:37:20Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* SR Latch configuration */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
== Foreword == &lt;br /&gt;
&lt;br /&gt;
This page provides examples of simple circuit network designs and some not so simple designs that others can use, combine and modify. They are designed to be as easy to understand as possible.  To see the settings of combinators without opening them, the option &amp;quot;Show combinator settings when detailed info is on&amp;quot; in the graphics options has to be checked and detailed info has to be turned on.&lt;br /&gt;
&lt;br /&gt;
==Lamp showing chest content condition==&lt;br /&gt;
[[File:LightWiredToChest.png|right|218 × 412px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is the simplest possible use of circuit-network. A lamp is light depending on the number of goods (in this example  empty barrels) in a chest.&lt;br /&gt;
&lt;br /&gt;
===Setting up circuit connection===&lt;br /&gt;
* The lamp is connected to the chest&lt;br /&gt;
* the lamp is set to light if the chest contain less than 10 empty barrels.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:LamponBarrelCondition.png|right|400x400px]]&lt;br /&gt;
===To set the light condition===&lt;br /&gt;
# open the lamp (left click on it)&lt;br /&gt;
# Set the input to barrels&lt;br /&gt;
# Set the operator to &amp;lt; (less than)&lt;br /&gt;
# Set the constant number:&lt;br /&gt;
## Left click on the constant number&lt;br /&gt;
## Move the slider until 10 is shown, or edit the value box directly&lt;br /&gt;
## Press set&lt;br /&gt;
&lt;br /&gt;
Depending on the condition you set, the lamp may light if the chest is empty, or if it contains the required quantity of items.&lt;br /&gt;
&lt;br /&gt;
The drawback with this scenario is that the lamp has a white light , and is therefore difficult to differentiate from an ordinary lamp at night.&lt;br /&gt;
&lt;br /&gt;
== Oil Setups ==&lt;br /&gt;
[[File:LgtOilCracking.png|left|400x400px]]&lt;br /&gt;
=== Light Oil Cracking ===&lt;br /&gt;
* This circuit provides balanced light oil and petroleum gas production by cracking excess light oil into gas. &lt;br /&gt;
* The [[Pump]] is connected to the [[Storage tank]] by a [[Red wire]]. &lt;br /&gt;
* The [[small pump]] has an enabled condition set to &#039;&#039;&#039;Light Oil &amp;gt; 2000&#039;&#039;&#039;.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:HvyOilCracking.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Heavy Oil Cracking ===&lt;br /&gt;
* This circuit extends on the previous circuit by adding optional heavy oil cracking to provide lubricant etc.&lt;br /&gt;
* The [[Pump]] has an enabled condition set to &#039;&#039;&#039;Heavy oil &amp;gt; 2000&#039;&#039;&#039;.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[file:BalancedPlasticSulfur.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Petroleum split evenly between plastic and sulphuric acid ===&lt;br /&gt;
* This circuit buffers gas in the tank until there is at least 100, then it lets the tank drain until there is less than 50 and the cycle repeats.&lt;br /&gt;
* It has a few elements that work together to do achieve this. &lt;br /&gt;
* Firstly the [[Pump]] is connected to the [[Wooden chest]] by a [[Red wire]] and the enabled condition on the [[Pump]] is set to &#039;&#039;&#039;Raw wood &amp;gt; 0&#039;&#039;&#039;.&lt;br /&gt;
* Both of the [[Inserter]]s are connected to the [[Storage tank]] by [[Red wire]]s. &lt;br /&gt;
* The enabled condition on the left inserter is &#039;&#039;&#039;Petroleum gas &amp;gt; 100&#039;&#039;&#039; &lt;br /&gt;
* The enabled condition on the right inserter is &#039;&#039;&#039;Petroleum gas &amp;lt; 50&#039;&#039;&#039;. &lt;br /&gt;
* You will need to insert a single &amp;quot;Raw wood&amp;quot; into the chest to make it all work. &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
* It is also possible to do this with [[decider combinator]]s instead of the inserters, belt and the Wood chest or even just belts.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Lights ==&lt;br /&gt;
[[File:ConditionalLights.png|left|400x400px]]&lt;br /&gt;
=== Conditional Lights ===&lt;br /&gt;
* In this circuit we connect a series of [[lamp]]s to a [[Storage tank]].&lt;br /&gt;
* By setting different conditions on each [[lamp]] we can build an indicator strip. &lt;br /&gt;
* The Enabled condition of the first [[lamp]] is &#039;&#039;&#039;Petroleum gas &amp;gt; 100&#039;&#039;&#039;.&lt;br /&gt;
* The others light up when gas is greater than 200, 300, 400 and 500 respectively.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
In this scenario you can connect the storage tank to the lamps directly.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:ColoredLights.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Colored Lights ===&lt;br /&gt;
* To light a [[lamp]] with a color rather than white, you need an intermediate device like an [[Arithmetic combinator]] that can send a color signal.  &lt;br /&gt;
Instead of directly connect  the the [[Lamp]] and the [[Storage tank]] you need:&amp;lt;BR&amp;gt;&lt;br /&gt;
1 Add the [[Arithmetic combinator]].&amp;lt;BR&amp;gt;&lt;br /&gt;
2 Connect the [[Storage tank]] with the input of the  [[Arithmetic combinator]].&amp;lt;BR&amp;gt;&lt;br /&gt;
3 Connect the  output of the [[Arithmetic combinator]] with the [[lamp]].&amp;lt;BR&amp;gt;&lt;br /&gt;
4 Set up the [[Arithmetic combinator]]:&amp;lt;BR&amp;gt;&lt;br /&gt;
4.1 Setting the input to Petroleum Gas + 0 (the constant 0 not the signal 0)&amp;lt;BR&amp;gt;&lt;br /&gt;
4.2 Set the output to the Pink signal (on the bottom row of the last tab of signals.)&amp;lt;BR&amp;gt;&lt;br /&gt;
5 Set up the [[lamp]]:&amp;lt;BR&amp;gt;&lt;br /&gt;
5.1  Select the &amp;quot;Use colors&amp;quot; check box on the lamp.&amp;lt;BR&amp;gt;&lt;br /&gt;
5.2 Set the condition to the Pink signal, and what value you want (i.e. &amp;gt; 100)&amp;lt;BR&amp;gt;&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Misc ==&lt;br /&gt;
[[file:MulitipleChestsAndPoles.png|left|400x400px]]&lt;br /&gt;
=== Multiple Storages === &lt;br /&gt;
* If you connect multiple chests to a pole, the pole displays the sum of items in all the chests. &lt;br /&gt;
* This also works with [[Storage tank]]s and [[roboport]]s.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:ConstantComb.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Constant combinator ===&lt;br /&gt;
* With a [[constant combinator]] you can generate any signals you may need. &lt;br /&gt;
* In this example we have generated a signal of 50 Laser turrets and 200 Piercing round magazine. &lt;br /&gt;
* Constant combinators are not of much use on their own but we shall use them later.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:LogicGates.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Logic gates ===&lt;br /&gt;
* In each case the two inputs can be connected with the same color wire or different colors. The inputs are powered by two [[Constant combinator]]s each of them output an A signal with value 1 for true and nothing or false.&lt;br /&gt;
* You can use [[Decider combinator]]s to make all of the common logic gates.&lt;br /&gt;
* The output for each should be set to 1 and the signal of your choice.&lt;br /&gt;
* Use the following settings to create different gates:&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
    NOT  A=0&lt;br /&gt;
    NOR  A=0&lt;br /&gt;
    NAND A&amp;lt;2&lt;br /&gt;
    XOR  A=1&lt;br /&gt;
    AND  A=2&lt;br /&gt;
    OR   A&amp;gt;0&lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:ThisASign.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Constant combinator signs ===&lt;br /&gt;
* You can use [[Constant combinator]]s to make signs, just set the letter signals in the combinator, each combinator can display 2 characters side by side.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:MemoryCell.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Memory Cell / Counter ===&lt;br /&gt;
* Basic memory cell that counts all the items moved by the inserter&lt;br /&gt;
* The [[Fast inserter]] is connected to &#039;&#039;&#039;BOTH&#039;&#039;&#039; ends of the arithmetic combinator.&lt;br /&gt;
&lt;br /&gt;
* If the [[Fast inserter]] hasn&#039;t picked anything up this tick the input to the Arithmetic combinator is the same as and output and hence the values are persisted. &lt;br /&gt;
* When the [[Fast inserter]] does pick something up its value is added to the output from the previous tick thus incrementing that item. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:BeltCache.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Automatic Belt-Cache ===&lt;br /&gt;
* Some intermediate products are huge in demand during peak-production only. To bypass the need of providing a huge amount of factories in order to cover that peaks, a cache-unit can be used. The unit stores items while the belt has backed up (so there&#039;s obviously no current demand downstream) and releases items as soon as the belt gets too empty.&lt;br /&gt;
* The blue area is 3 parts of Express belts. According to the wiki, each belt can hold up to 7.11 items. This means the feeding fast belt can not provide 7.11 items for the express belts as long as the belt is moving. (And while the belt is moving, we don&#039;t want to cache items, but let regular production run, or even release items from the cache.)&lt;br /&gt;
* This means, once the counters on the two express belts are 7.11 each, the belt has backed up, so we can start &amp;quot;caching&amp;quot; items into our storage array. &lt;br /&gt;
* For this purpose, the counters are connected to the arithmetic combinator (A) which multiples the input (*100) into green signals. So, if the belt has backed up, B shows &amp;quot;&amp;gt;1422&amp;quot; green signals.&lt;br /&gt;
* This is the activation condition for the Belt (C), which will redirect the input tp the storage array.&lt;br /&gt;
* Since items should only be released if the belt starts to clear, the counter (D) is evaluated by the belt (E) which is only activated, if item-count on (D) is smaller than 6 (this number has to be adjusted to personal needs, when the cache should become &amp;quot;active&amp;quot; and release items)&lt;br /&gt;
* The layout can be extended to cache whatever amount of items is required. (Some balancing for the release-method would be required of course.)&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:combinatorMultiplierDetailed.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Multiplier and Dictionaries/Arrays ===&lt;br /&gt;
* Multiplying two signals together is simple and requires only a single combinator, however multiplying a set of signals is more complicated.&lt;br /&gt;
* A proof is shown below for the equation and why it works.&lt;br /&gt;
* A dictionary is a system that allows a value on a specific signal to be accessed. For example, A can contain many signals (either from a constant combinator or memory cell) and B can contain 1 of a specific signal (such as blue signal). What remains is the blue-signal value from A. This is because all the other signals are multiplied by 0.&lt;br /&gt;
* Arrays are similar to dictionaries, but instead of using a signal as a key, we use a number. Constant combinators are placed mapping each signal to a unique number (such as 1 yellow belt, 2 red belt, 3 blue belt, 4 burner inserter, etc). Then, use a combinator of &amp;quot;each = index OUTPUT 1 of each&amp;quot; and plug that in as the input to a dictionary.&lt;br /&gt;
[[File:combinatorMultiplierMath.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
    ((A+B)^2 - (A-B)^2)/4 = AB&lt;br /&gt;
    (A+B)^2 - (A-B)^2 = 4AB&lt;br /&gt;
    (A^2 + 2AB + B^2) - (A^2 - 2AB + B^2) = 4AB&lt;br /&gt;
    4AB = 4AB&lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Inserters ==&lt;br /&gt;
[[File:LimitItemsPlacedIntoAChest.png|left|400x400px]]&lt;br /&gt;
=== Limit items placed into a chest ===&lt;br /&gt;
*  The [[Inserter]] is connected to the [[Wooden chest]] using a [[Red wire]]. &lt;br /&gt;
*  The inserter&#039;s enabled condition is &#039;&#039;&#039;Advanced Circuit &amp;lt; 10&#039;&#039;&#039;. &lt;br /&gt;
*  In reality this means the inserter may place more than 10 Advanced circuits in the chest because it could pick up to 3 at once due to stack size bonuses.&lt;br /&gt;
*  This effect can be even greater with Stack inserters because of their large carrying capacity. &lt;br /&gt;
*  This technique still gives far greater control than limiting the inventory on the chest.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
=== Balanced chest insert ===&lt;br /&gt;
Goal: Load n chests with approximately the same number of items.&lt;br /&gt;
*  Place n chests and n inserters. &lt;br /&gt;
*  Place 1 [[Arithmetic combinator]]&lt;br /&gt;
*  Set the combinator to take Each (yellow star) and divide by the negative number of chests. ie &amp;amp;minus;n.&lt;br /&gt;
*  Connect all chests to each other and to the input of the combinator using red wire.&lt;br /&gt;
*  Connect all inserters to each other and to the output of the combinator using red wire.&lt;br /&gt;
*  Connect each inserter to the box it inserts into with green wire.&lt;br /&gt;
*  Set the enable condition on each inserter to be Everything (red star) &amp;lt; 0.&lt;br /&gt;
&lt;br /&gt;
The combinator calculates the average number of items in the chests, and makes it negative. Each inserter gets the amount in the chest it is inserting to and adds the negative average, ie it calculates how many more than the average it has in its chest. Thus if that number is negative, it has less than the average in the chest and it enables. &lt;br /&gt;
&lt;br /&gt;
Due to inserter stack bonus the count is not exact. If a precise count is needed, set the inserter stack size to 1. &lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SmartOutpostUnloader.png|left|400x400px]]&lt;br /&gt;
=== Keeping outpost stocked with specified items ===&lt;br /&gt;
*  This circuit keeps a [[Storage chest]] at an outpost stocked with customized levels of different items. &lt;br /&gt;
*  For example you could keep an outpost stocked with 50 laser turrets and 200 piercing magazine rounds but not have to worry about it being over filled. &lt;br /&gt;
*  The [[storage chest]] is attached to the input of the [[Arithmetic combinator]] (left side in the picture) with a [[Red wire]]. &lt;br /&gt;
*  Another couple of [[Red wire]]s join the output of the [[Arithmetic combinator]] (right side) to the [[constant combinator]] and to the [[stack filter inserter]]. &lt;br /&gt;
*  The [[Arithmetic combinator]] &#039;&#039;&#039;multiplies&#039;&#039;&#039; each input value (from the storage chest) by &#039;&#039;&#039;-1&#039;&#039;&#039;. &lt;br /&gt;
*  Finally the filter stack inserter&#039;s mode of operation is set to &#039;&#039;&#039;Set filters&#039;&#039;&#039;.&lt;br /&gt;
*  So the input to the [[stack filter inserter]] is &#039;&#039;&#039;&amp;lt;Constant combinator&amp;gt; - &amp;lt;Storage chest contents&amp;gt;&#039;&#039;&#039; and the filter is set to filter the item of greatest demand.   &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SolarAccumalatorBalancer.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Balanced Solar panel / Accumulator Production ===&lt;br /&gt;
* This circuit balances production of [[Solar panel]]s and [[Accumulator]]s to a desired ratio in my case 24:20.&lt;br /&gt;
* The first [[Arithmetic combinator]] takes the number of accumulators in the chest and &#039;&#039;&#039;multiplies&#039;&#039;&#039; it by &#039;&#039;&#039;24&#039;&#039;&#039;. &lt;br /&gt;
* The second [[Arithmetic combinator]] takes the output of the first combinator and &#039;&#039;&#039;divides&#039;&#039;&#039; it by &#039;&#039;&#039;20&#039;&#039;&#039;. &lt;br /&gt;
* This gives us the number of accumulators that we can directly compare to the number of Solar panels in both inserters. &lt;br /&gt;
* If the number of accumulators is greater we enable the Solar panels inserter, if the number of Solar panels is greater we enable the accumulators inserter. &lt;br /&gt;
* However, if they are equal, neither machine does anything. So we add a single accumulator to one of the inserters using a constant combinator and a wire of the other color, therefore breaking the deadlock.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Sushi Belts ==&lt;br /&gt;
[[File:SushiScience1.png|left|400x400px]]&lt;br /&gt;
=== Reading Belt Design ===&lt;br /&gt;
* Six belts in a row are connected with Red wire and set to &#039;&#039;&#039;Read belts contents&#039;&#039;&#039; and &#039;&#039;&#039;Hold&#039;&#039;&#039; &lt;br /&gt;
* This [[Red wire]] is then connected to the inserters that insert onto the belt. &lt;br /&gt;
* Read hand contents is unselected for all inserters.&lt;br /&gt;
* Mode of operation is set to &#039;&#039;&#039;Enable/Disable&#039;&#039;&#039; on all inserters. &lt;br /&gt;
* The first inserter is enabled when &#039;&#039;&#039;Science pack 1 = 0&#039;&#039;&#039;&lt;br /&gt;
* The other inserters are set similarly for the other science packs. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SushiScience2.png|left|400x400px]]&lt;br /&gt;
=== Memory Cell Design ===&lt;br /&gt;
* This circuit counts the number of items of each type on a looping belt by counting the numbers that are added and removed from the belt by inserters.&lt;br /&gt;
* Each inserter that takes items off the belt is connected together with Red wire and each of these inserters is set to &#039;&#039;&#039;Mode of operation none, Read hand content selected&#039;&#039;&#039; and &#039;&#039;&#039;Hand read mode pulse&#039;&#039;&#039;. &lt;br /&gt;
* These inserters are connected to the input of the left arithmetic combinator. &lt;br /&gt;
* The left [[Arithmetic combinator]] multiples &#039;&#039;&#039;each&#039;&#039;&#039; input by &#039;&#039;&#039;-1&#039;&#039;&#039; and outputs it to &#039;&#039;&#039;each&#039;&#039;&#039;. &lt;br /&gt;
* The right [[Arithmetic combinator]] is a &#039;&#039;&#039;memory cell&#039;&#039;&#039; as above.&lt;br /&gt;
* The memory cell&#039;s input is connected to the inserters that are placing items on the belt and the output of the left [[Arithmetic combinator]]. &lt;br /&gt;
* The inserters that place items onto the belt have an enabled condition that is based on the number of items on the belt.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Splitters ==&lt;br /&gt;
[[file:CondSplitter.png|left|400x400px]]&lt;br /&gt;
=== Conditional splitter ===&lt;br /&gt;
* This is the simplest circuit you can have for &amp;quot;controlling&amp;quot; a splitter.&lt;br /&gt;
* A signal X=1 is transmitted from off screen when the items need to be sent down the belt.&lt;br /&gt;
* The belt on the left is enabled when X=1.&lt;br /&gt;
* The belt on the right is enabled when X=0.&lt;br /&gt;
* The two belts are wired together and to a pole. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:PrioritySplitter.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Priority Splitter ===&lt;br /&gt;
* This circuit prioritizes items to the belt going of the screen to the left but will send items straight on if the belt to the left is backed up.&lt;br /&gt;
* Its not perfect and will leak some items but its good enough for most applications. &lt;br /&gt;
* The balancer means it will work even if the supply or demand is uneven. &lt;br /&gt;
* It is critical that the belts are setup as in this picture otherwise it may not work. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Power ==&lt;br /&gt;
[[File:SteamBackup.png|left|400x400px]]&lt;br /&gt;
=== Backup steam power ===&lt;br /&gt;
* The [[steam engine]]s are not directly connected to the power network. They are connected to the power network through a [[Power switch]]. &lt;br /&gt;
* The [[power switch]] is connected to one of the [[accumulator]]s in the main network. &lt;br /&gt;
* The [[power switch]] turns on when A &amp;lt; 10. That is when the [[accumulator]]s are less than 10% full.&lt;br /&gt;
{{clear}}&lt;br /&gt;
=== Optimal usage of fuel for nuclear power ===&lt;br /&gt;
Unlike the normal steam power that adjusts fuel usage based on power usage, the [[Power_production#Nuclear_power|nuclear reactors]] spend fuel in fixed units of time. To be exact, the consumption of 1 fuel cell takes exactly 200 seconds.&lt;br /&gt;
&lt;br /&gt;
Combined with the fact that creating the nuclear fuel cells are time consuming and expensive to create, it is therefore beneficial to optimize their use to match the actual consumed power.&lt;br /&gt;
&lt;br /&gt;
[[File:NuclearCircuits.jpg]]&lt;br /&gt;
&lt;br /&gt;
The above picture shows a setup with 4 reactors, that spend only 1 fuel cell each whenever steam runs low.&lt;br /&gt;
&lt;br /&gt;
There are a few elements in this setup:&lt;br /&gt;
&lt;br /&gt;
* Storage tank that provides the [[Steam]] signal.  You should only read from one storage tank, and it should have pipe connections to all your other steam storage tanks.&lt;br /&gt;
* Chests containing [[Uranium_fuel_cell|Uranium fuel cells]] for the reactor.&lt;br /&gt;
* Output inserters that take [[Used_up_uranium_fuel_cell|Empty fuel cells]] from the reactor. This is connected to the storage tank to listen for the steam signal, and to the chests to listen for the uranium fuel cell signal. If the steam level is low and there are uranium fuel cells available, it removes the empty fuel cells from the reactor and sends an empty fuel cell signal (since &amp;quot;Read hand contents&amp;quot; is checked).&lt;br /&gt;
* Input inserters that put uranium fuel cells into the reactor. This is connected to the output inserters and listens for the empty fuel cell signal. The &amp;quot;Override stack size&amp;quot; is set to 1, so that it only inserts 1 fuel cell at a time.&lt;br /&gt;
&lt;br /&gt;
Since this design uses empty fuel cells as a signal to fill the reactor, you need to manually insert 1 uranium fuel cell into the reactor to get it started.&lt;br /&gt;
&lt;br /&gt;
== Latches ==&lt;br /&gt;
=== RS latch - single decider version ===&lt;br /&gt;
[https://forums.factorio.com/viewtopic.php?f=193&amp;amp;t=14556 This discussion] on the Factorio forums starts with the common 2 decider RS latch version, but the thread goes on to explain why this single decider version is better.&lt;br /&gt;
==== Backup steam example ====&lt;br /&gt;
This example will turn on the steam generator when the Accumulator charge drops to 20%, but will &amp;quot;latch&amp;quot; (remember) the On state until the accumulator is charged to 90%.&lt;br /&gt;
&lt;br /&gt;
Latching is used to introduce [[Wikipedia:hysteresis|hysteresis]] and avoid the power switch rapidly cycling on and off (as the accumulator falls to 19%, charges to 20%, falls to 19% and so on).&lt;br /&gt;
[[File:SR-01-Layout.png|left]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br clear=all&amp;gt; &lt;br /&gt;
&amp;lt;div class=&amp;quot;toccolours mw-collapsible mw-collapsed&amp;quot; style=&amp;quot;width:50em;&amp;quot;&amp;gt;&lt;br /&gt;
Blueprint string for above backup steam example&lt;br /&gt;
&amp;lt;div class=&amp;quot;mw-collapsible-content&amp;quot;&amp;gt;&amp;lt;pre style=&amp;quot;white-space: pre-wrap; &lt;br /&gt;
 white-space: -moz-pre-wrap; &lt;br /&gt;
 white-space: -pre-wrap; &lt;br /&gt;
 white-space: -o-pre-wrap; &lt;br /&gt;
 word-wrap: break-word;&amp;quot;&amp;gt;&lt;br /&gt;
0eNrFVk1vozAQ/SuVz1ABCaRBq5WqXntKjqsKOTBJR8IGGTtpFPHfd+w0HyU0G6pVewkxnnmemfdmzI4tSgO1QqlZumOYV7Jh6Z8da3AleWnf6W0NLGVrVNrQG49JLuyLvYU/Z63HUBbwxtKw9QZ4zs48o15P1CBObgXkWIDy80osUHJdqTOAUfviMZAaNcI+A7fYZtKIBSiK7YgjoEAjfCgh1wpzv65KoFPqqiHnStrzCdAPA49t6Rm1NrYOWjQY7QrY6FQZwcvyX1jJFajxEYrnuRGmdGW6DCe+jx1KcB9TDYl1raoyW8ArXyM5kFVldG10djObj6zdI0kKHp2Mdiy0PysFIM8pwYKldHyOKjeo3TI8y8Wup93tl7Yv3fiaOC6zjt6z9uk4VqDaR+rY7CvBO2ZGewUec1qiaobVxaE3mtseiwK7EjVXLsaU/SKPobWe7zHrLYVmpM6WqhIZSsJg6ZKXDQyiYkzF9Vhk9xUU3d3kNiaSQUwEB/l9Hw+uZg1YjGzYiPpA1+/vpKuHjk7fRNf7JrJTsZf05MLwoIFbzLvtOvlEFZNjKepqQ5poNqjz10s9jA6N+fk8Ohx/FMFXNXDqxeCC20F901vCJxN07UjVG9K4+x9YQp5M2LUZfbTpq+XDKRsNnG4cuULZcz089HZWD+D0a8Pz52bnNPgPzTj76dlJAnDfNenZp5fHSr4ACp/NZ3fPnHrkDt64qN31vwbVuFIn43GUjCdxHIVt+xcL2lBp&amp;lt;/pre&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-02-Accumulator.png|left]]Accumulator outputs the current charge level as % on signal [[File:Signal-A.png]]&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-03-RangeDeciders.png|left]]First decider outputs &amp;quot;Set&amp;quot; ([[File:Signal-S.png]] = 1) if Accumulator is less than 20%.&lt;br /&gt;
Second decider outputs &amp;quot;Reset&amp;quot; ([[File:Signal-R.png]] = 1) once Accumulator is more than 90% full.&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-04-SRLatch.png|left]]&lt;br /&gt;
==== RS Latch configuration ====&lt;br /&gt;
&#039;&#039;&#039;The central decider and green feedback wire is the actual RS Latch.&#039;&#039;&#039;&lt;br /&gt;
It latches the Set signal [[File:Signal-S.png]] until the Reset signal [[File:Signal-R.png]] is received (and vice-versa).&amp;lt;br /&amp;gt;&lt;br /&gt;
NB: the latch expects binary inputs ([[File:Signal-S.png]] &amp;amp; [[File:Signal-R.png]] must be 0 or 1) - this is why the previous two deciders are required.&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-05-PowerSwitch.png|left]]The Power switch isolates the generator from the rest of the factory until [[File:Signal-S.png]] = 1&lt;br /&gt;
&amp;lt;br clear=all&amp;gt; &lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== SR latch ===&lt;br /&gt;
[[File:SRLatch.png|left|400x400px]]&lt;br /&gt;
* This should be familiar to anyone with any background in electronics. &lt;br /&gt;
* The signal is set and reset with the [[constant combinator]]s on the left by setting an A=1 signal. &lt;br /&gt;
* The latch &amp;quot;remembers&amp;quot; which one was last set and the light stays on until another signal is received.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SRlatchinaction.png|left|400x400px]]&lt;br /&gt;
=== Usage of SR latch ===&lt;br /&gt;
* Here is an example of how you could use an SR latch.&lt;br /&gt;
* The two extra [[Decider combinator]]s provide the set and reset conditions. &lt;br /&gt;
* Petroleum gas &amp;lt; 50 and petroleum gas &amp;gt; 100. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:BeltLatch.png|left|400x400px]]&lt;br /&gt;
=== Belt only latch ===&lt;br /&gt;
* This is the most compact latch I am aware of. &lt;br /&gt;
* To make it work you need to place &#039;&#039;&#039;3&#039;&#039;&#039; raw wood on the inside lane of the belt.&lt;br /&gt;
* I believe it will have higher latency than the combinator version but in most situations you will not notice the difference. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Displays ==&lt;br /&gt;
[[File:5digitDisplay.png|left|400x400px]]&lt;br /&gt;
=== Numerical Display ===&lt;br /&gt;
* Each digit is driven by its own [[Green wire]], that wire holds 15 signals one for each lamp used in the digit.&lt;br /&gt;
* [[Constant combinator]]s are used to define which lamp should light up for each value. &lt;br /&gt;
* Blueprint string including decoder [https://www.dropbox.com/s/5o13xuwthalzzfe/Brain2.txt?dl=0]&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:BWDisplay.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Black and White Grid Display ===&lt;br /&gt;
* Each row has its own [[Red wire]] connection and within that row each light has a numbered signal 0-9.&lt;br /&gt;
* We turn each light on by just setting or clearing the relevant signal.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:MultiColoredDisplay.png|left|400x400px]]&lt;br /&gt;
=== Multicolor Display by DaveMcW ===&lt;br /&gt;
* To understand how this works, you first need to understand how color lights choose which color to light up when there are multiple colored signals. &lt;br /&gt;
* The [[lamp]] will light up with the colored signal that is greater than zero and earliest in this list: Red, Green, Blue, Yellow, Pink, Cyan, White.  &lt;br /&gt;
* We have a [[Red wire]] per column, that wire has each of the colored signals on it at different values and a numbered signal for each row. &lt;br /&gt;
* There is a [[Arithmetic combinator]] for each cell that subtracts the &amp;quot;row&amp;quot; value from each of the colored signals. &lt;br /&gt;
* And this enables us to choose the color for each cell. &lt;br /&gt;
* Simple!&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
* [[Arithmetic combinator]]&lt;br /&gt;
* [[Constant combinator]]&lt;br /&gt;
* [[Decider combinator]]&lt;br /&gt;
* [[Circuit network]]&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Tutorial:Circuit_network_cookbook&amp;diff=159165</id>
		<title>Tutorial:Circuit network cookbook</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Tutorial:Circuit_network_cookbook&amp;diff=159165"/>
		<updated>2018-05-12T23:36:12Z</updated>

		<summary type="html">&lt;p&gt;AnthonyQBachler: /* Latches */  In electronics textbooks and literature this type of latch is properly referred to as an RS latch, not SR.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
== Foreword == &lt;br /&gt;
&lt;br /&gt;
This page provides examples of simple circuit network designs and some not so simple designs that others can use, combine and modify. They are designed to be as easy to understand as possible.  To see the settings of combinators without opening them, the option &amp;quot;Show combinator settings when detailed info is on&amp;quot; in the graphics options has to be checked and detailed info has to be turned on.&lt;br /&gt;
&lt;br /&gt;
==Lamp showing chest content condition==&lt;br /&gt;
[[File:LightWiredToChest.png|right|218 × 412px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is the simplest possible use of circuit-network. A lamp is light depending on the number of goods (in this example  empty barrels) in a chest.&lt;br /&gt;
&lt;br /&gt;
===Setting up circuit connection===&lt;br /&gt;
* The lamp is connected to the chest&lt;br /&gt;
* the lamp is set to light if the chest contain less than 10 empty barrels.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:LamponBarrelCondition.png|right|400x400px]]&lt;br /&gt;
===To set the light condition===&lt;br /&gt;
# open the lamp (left click on it)&lt;br /&gt;
# Set the input to barrels&lt;br /&gt;
# Set the operator to &amp;lt; (less than)&lt;br /&gt;
# Set the constant number:&lt;br /&gt;
## Left click on the constant number&lt;br /&gt;
## Move the slider until 10 is shown, or edit the value box directly&lt;br /&gt;
## Press set&lt;br /&gt;
&lt;br /&gt;
Depending on the condition you set, the lamp may light if the chest is empty, or if it contains the required quantity of items.&lt;br /&gt;
&lt;br /&gt;
The drawback with this scenario is that the lamp has a white light , and is therefore difficult to differentiate from an ordinary lamp at night.&lt;br /&gt;
&lt;br /&gt;
== Oil Setups ==&lt;br /&gt;
[[File:LgtOilCracking.png|left|400x400px]]&lt;br /&gt;
=== Light Oil Cracking ===&lt;br /&gt;
* This circuit provides balanced light oil and petroleum gas production by cracking excess light oil into gas. &lt;br /&gt;
* The [[Pump]] is connected to the [[Storage tank]] by a [[Red wire]]. &lt;br /&gt;
* The [[small pump]] has an enabled condition set to &#039;&#039;&#039;Light Oil &amp;gt; 2000&#039;&#039;&#039;.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:HvyOilCracking.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Heavy Oil Cracking ===&lt;br /&gt;
* This circuit extends on the previous circuit by adding optional heavy oil cracking to provide lubricant etc.&lt;br /&gt;
* The [[Pump]] has an enabled condition set to &#039;&#039;&#039;Heavy oil &amp;gt; 2000&#039;&#039;&#039;.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[file:BalancedPlasticSulfur.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Petroleum split evenly between plastic and sulphuric acid ===&lt;br /&gt;
* This circuit buffers gas in the tank until there is at least 100, then it lets the tank drain until there is less than 50 and the cycle repeats.&lt;br /&gt;
* It has a few elements that work together to do achieve this. &lt;br /&gt;
* Firstly the [[Pump]] is connected to the [[Wooden chest]] by a [[Red wire]] and the enabled condition on the [[Pump]] is set to &#039;&#039;&#039;Raw wood &amp;gt; 0&#039;&#039;&#039;.&lt;br /&gt;
* Both of the [[Inserter]]s are connected to the [[Storage tank]] by [[Red wire]]s. &lt;br /&gt;
* The enabled condition on the left inserter is &#039;&#039;&#039;Petroleum gas &amp;gt; 100&#039;&#039;&#039; &lt;br /&gt;
* The enabled condition on the right inserter is &#039;&#039;&#039;Petroleum gas &amp;lt; 50&#039;&#039;&#039;. &lt;br /&gt;
* You will need to insert a single &amp;quot;Raw wood&amp;quot; into the chest to make it all work. &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
* It is also possible to do this with [[decider combinator]]s instead of the inserters, belt and the Wood chest or even just belts.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Lights ==&lt;br /&gt;
[[File:ConditionalLights.png|left|400x400px]]&lt;br /&gt;
=== Conditional Lights ===&lt;br /&gt;
* In this circuit we connect a series of [[lamp]]s to a [[Storage tank]].&lt;br /&gt;
* By setting different conditions on each [[lamp]] we can build an indicator strip. &lt;br /&gt;
* The Enabled condition of the first [[lamp]] is &#039;&#039;&#039;Petroleum gas &amp;gt; 100&#039;&#039;&#039;.&lt;br /&gt;
* The others light up when gas is greater than 200, 300, 400 and 500 respectively.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
In this scenario you can connect the storage tank to the lamps directly.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:ColoredLights.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Colored Lights ===&lt;br /&gt;
* To light a [[lamp]] with a color rather than white, you need an intermediate device like an [[Arithmetic combinator]] that can send a color signal.  &lt;br /&gt;
Instead of directly connect  the the [[Lamp]] and the [[Storage tank]] you need:&amp;lt;BR&amp;gt;&lt;br /&gt;
1 Add the [[Arithmetic combinator]].&amp;lt;BR&amp;gt;&lt;br /&gt;
2 Connect the [[Storage tank]] with the input of the  [[Arithmetic combinator]].&amp;lt;BR&amp;gt;&lt;br /&gt;
3 Connect the  output of the [[Arithmetic combinator]] with the [[lamp]].&amp;lt;BR&amp;gt;&lt;br /&gt;
4 Set up the [[Arithmetic combinator]]:&amp;lt;BR&amp;gt;&lt;br /&gt;
4.1 Setting the input to Petroleum Gas + 0 (the constant 0 not the signal 0)&amp;lt;BR&amp;gt;&lt;br /&gt;
4.2 Set the output to the Pink signal (on the bottom row of the last tab of signals.)&amp;lt;BR&amp;gt;&lt;br /&gt;
5 Set up the [[lamp]]:&amp;lt;BR&amp;gt;&lt;br /&gt;
5.1  Select the &amp;quot;Use colors&amp;quot; check box on the lamp.&amp;lt;BR&amp;gt;&lt;br /&gt;
5.2 Set the condition to the Pink signal, and what value you want (i.e. &amp;gt; 100)&amp;lt;BR&amp;gt;&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Misc ==&lt;br /&gt;
[[file:MulitipleChestsAndPoles.png|left|400x400px]]&lt;br /&gt;
=== Multiple Storages === &lt;br /&gt;
* If you connect multiple chests to a pole, the pole displays the sum of items in all the chests. &lt;br /&gt;
* This also works with [[Storage tank]]s and [[roboport]]s.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:ConstantComb.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Constant combinator ===&lt;br /&gt;
* With a [[constant combinator]] you can generate any signals you may need. &lt;br /&gt;
* In this example we have generated a signal of 50 Laser turrets and 200 Piercing round magazine. &lt;br /&gt;
* Constant combinators are not of much use on their own but we shall use them later.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:LogicGates.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Logic gates ===&lt;br /&gt;
* In each case the two inputs can be connected with the same color wire or different colors. The inputs are powered by two [[Constant combinator]]s each of them output an A signal with value 1 for true and nothing or false.&lt;br /&gt;
* You can use [[Decider combinator]]s to make all of the common logic gates.&lt;br /&gt;
* The output for each should be set to 1 and the signal of your choice.&lt;br /&gt;
* Use the following settings to create different gates:&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
    NOT  A=0&lt;br /&gt;
    NOR  A=0&lt;br /&gt;
    NAND A&amp;lt;2&lt;br /&gt;
    XOR  A=1&lt;br /&gt;
    AND  A=2&lt;br /&gt;
    OR   A&amp;gt;0&lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:ThisASign.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Constant combinator signs ===&lt;br /&gt;
* You can use [[Constant combinator]]s to make signs, just set the letter signals in the combinator, each combinator can display 2 characters side by side.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:MemoryCell.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Memory Cell / Counter ===&lt;br /&gt;
* Basic memory cell that counts all the items moved by the inserter&lt;br /&gt;
* The [[Fast inserter]] is connected to &#039;&#039;&#039;BOTH&#039;&#039;&#039; ends of the arithmetic combinator.&lt;br /&gt;
&lt;br /&gt;
* If the [[Fast inserter]] hasn&#039;t picked anything up this tick the input to the Arithmetic combinator is the same as and output and hence the values are persisted. &lt;br /&gt;
* When the [[Fast inserter]] does pick something up its value is added to the output from the previous tick thus incrementing that item. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:BeltCache.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Automatic Belt-Cache ===&lt;br /&gt;
* Some intermediate products are huge in demand during peak-production only. To bypass the need of providing a huge amount of factories in order to cover that peaks, a cache-unit can be used. The unit stores items while the belt has backed up (so there&#039;s obviously no current demand downstream) and releases items as soon as the belt gets too empty.&lt;br /&gt;
* The blue area is 3 parts of Express belts. According to the wiki, each belt can hold up to 7.11 items. This means the feeding fast belt can not provide 7.11 items for the express belts as long as the belt is moving. (And while the belt is moving, we don&#039;t want to cache items, but let regular production run, or even release items from the cache.)&lt;br /&gt;
* This means, once the counters on the two express belts are 7.11 each, the belt has backed up, so we can start &amp;quot;caching&amp;quot; items into our storage array. &lt;br /&gt;
* For this purpose, the counters are connected to the arithmetic combinator (A) which multiples the input (*100) into green signals. So, if the belt has backed up, B shows &amp;quot;&amp;gt;1422&amp;quot; green signals.&lt;br /&gt;
* This is the activation condition for the Belt (C), which will redirect the input tp the storage array.&lt;br /&gt;
* Since items should only be released if the belt starts to clear, the counter (D) is evaluated by the belt (E) which is only activated, if item-count on (D) is smaller than 6 (this number has to be adjusted to personal needs, when the cache should become &amp;quot;active&amp;quot; and release items)&lt;br /&gt;
* The layout can be extended to cache whatever amount of items is required. (Some balancing for the release-method would be required of course.)&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:combinatorMultiplierDetailed.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Multiplier and Dictionaries/Arrays ===&lt;br /&gt;
* Multiplying two signals together is simple and requires only a single combinator, however multiplying a set of signals is more complicated.&lt;br /&gt;
* A proof is shown below for the equation and why it works.&lt;br /&gt;
* A dictionary is a system that allows a value on a specific signal to be accessed. For example, A can contain many signals (either from a constant combinator or memory cell) and B can contain 1 of a specific signal (such as blue signal). What remains is the blue-signal value from A. This is because all the other signals are multiplied by 0.&lt;br /&gt;
* Arrays are similar to dictionaries, but instead of using a signal as a key, we use a number. Constant combinators are placed mapping each signal to a unique number (such as 1 yellow belt, 2 red belt, 3 blue belt, 4 burner inserter, etc). Then, use a combinator of &amp;quot;each = index OUTPUT 1 of each&amp;quot; and plug that in as the input to a dictionary.&lt;br /&gt;
[[File:combinatorMultiplierMath.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
    ((A+B)^2 - (A-B)^2)/4 = AB&lt;br /&gt;
    (A+B)^2 - (A-B)^2 = 4AB&lt;br /&gt;
    (A^2 + 2AB + B^2) - (A^2 - 2AB + B^2) = 4AB&lt;br /&gt;
    4AB = 4AB&lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Inserters ==&lt;br /&gt;
[[File:LimitItemsPlacedIntoAChest.png|left|400x400px]]&lt;br /&gt;
=== Limit items placed into a chest ===&lt;br /&gt;
*  The [[Inserter]] is connected to the [[Wooden chest]] using a [[Red wire]]. &lt;br /&gt;
*  The inserter&#039;s enabled condition is &#039;&#039;&#039;Advanced Circuit &amp;lt; 10&#039;&#039;&#039;. &lt;br /&gt;
*  In reality this means the inserter may place more than 10 Advanced circuits in the chest because it could pick up to 3 at once due to stack size bonuses.&lt;br /&gt;
*  This effect can be even greater with Stack inserters because of their large carrying capacity. &lt;br /&gt;
*  This technique still gives far greater control than limiting the inventory on the chest.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
=== Balanced chest insert ===&lt;br /&gt;
Goal: Load n chests with approximately the same number of items.&lt;br /&gt;
*  Place n chests and n inserters. &lt;br /&gt;
*  Place 1 [[Arithmetic combinator]]&lt;br /&gt;
*  Set the combinator to take Each (yellow star) and divide by the negative number of chests. ie &amp;amp;minus;n.&lt;br /&gt;
*  Connect all chests to each other and to the input of the combinator using red wire.&lt;br /&gt;
*  Connect all inserters to each other and to the output of the combinator using red wire.&lt;br /&gt;
*  Connect each inserter to the box it inserts into with green wire.&lt;br /&gt;
*  Set the enable condition on each inserter to be Everything (red star) &amp;lt; 0.&lt;br /&gt;
&lt;br /&gt;
The combinator calculates the average number of items in the chests, and makes it negative. Each inserter gets the amount in the chest it is inserting to and adds the negative average, ie it calculates how many more than the average it has in its chest. Thus if that number is negative, it has less than the average in the chest and it enables. &lt;br /&gt;
&lt;br /&gt;
Due to inserter stack bonus the count is not exact. If a precise count is needed, set the inserter stack size to 1. &lt;br /&gt;
&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SmartOutpostUnloader.png|left|400x400px]]&lt;br /&gt;
=== Keeping outpost stocked with specified items ===&lt;br /&gt;
*  This circuit keeps a [[Storage chest]] at an outpost stocked with customized levels of different items. &lt;br /&gt;
*  For example you could keep an outpost stocked with 50 laser turrets and 200 piercing magazine rounds but not have to worry about it being over filled. &lt;br /&gt;
*  The [[storage chest]] is attached to the input of the [[Arithmetic combinator]] (left side in the picture) with a [[Red wire]]. &lt;br /&gt;
*  Another couple of [[Red wire]]s join the output of the [[Arithmetic combinator]] (right side) to the [[constant combinator]] and to the [[stack filter inserter]]. &lt;br /&gt;
*  The [[Arithmetic combinator]] &#039;&#039;&#039;multiplies&#039;&#039;&#039; each input value (from the storage chest) by &#039;&#039;&#039;-1&#039;&#039;&#039;. &lt;br /&gt;
*  Finally the filter stack inserter&#039;s mode of operation is set to &#039;&#039;&#039;Set filters&#039;&#039;&#039;.&lt;br /&gt;
*  So the input to the [[stack filter inserter]] is &#039;&#039;&#039;&amp;lt;Constant combinator&amp;gt; - &amp;lt;Storage chest contents&amp;gt;&#039;&#039;&#039; and the filter is set to filter the item of greatest demand.   &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SolarAccumalatorBalancer.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Balanced Solar panel / Accumulator Production ===&lt;br /&gt;
* This circuit balances production of [[Solar panel]]s and [[Accumulator]]s to a desired ratio in my case 24:20.&lt;br /&gt;
* The first [[Arithmetic combinator]] takes the number of accumulators in the chest and &#039;&#039;&#039;multiplies&#039;&#039;&#039; it by &#039;&#039;&#039;24&#039;&#039;&#039;. &lt;br /&gt;
* The second [[Arithmetic combinator]] takes the output of the first combinator and &#039;&#039;&#039;divides&#039;&#039;&#039; it by &#039;&#039;&#039;20&#039;&#039;&#039;. &lt;br /&gt;
* This gives us the number of accumulators that we can directly compare to the number of Solar panels in both inserters. &lt;br /&gt;
* If the number of accumulators is greater we enable the Solar panels inserter, if the number of Solar panels is greater we enable the accumulators inserter. &lt;br /&gt;
* However, if they are equal, neither machine does anything. So we add a single accumulator to one of the inserters using a constant combinator and a wire of the other color, therefore breaking the deadlock.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Sushi Belts ==&lt;br /&gt;
[[File:SushiScience1.png|left|400x400px]]&lt;br /&gt;
=== Reading Belt Design ===&lt;br /&gt;
* Six belts in a row are connected with Red wire and set to &#039;&#039;&#039;Read belts contents&#039;&#039;&#039; and &#039;&#039;&#039;Hold&#039;&#039;&#039; &lt;br /&gt;
* This [[Red wire]] is then connected to the inserters that insert onto the belt. &lt;br /&gt;
* Read hand contents is unselected for all inserters.&lt;br /&gt;
* Mode of operation is set to &#039;&#039;&#039;Enable/Disable&#039;&#039;&#039; on all inserters. &lt;br /&gt;
* The first inserter is enabled when &#039;&#039;&#039;Science pack 1 = 0&#039;&#039;&#039;&lt;br /&gt;
* The other inserters are set similarly for the other science packs. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SushiScience2.png|left|400x400px]]&lt;br /&gt;
=== Memory Cell Design ===&lt;br /&gt;
* This circuit counts the number of items of each type on a looping belt by counting the numbers that are added and removed from the belt by inserters.&lt;br /&gt;
* Each inserter that takes items off the belt is connected together with Red wire and each of these inserters is set to &#039;&#039;&#039;Mode of operation none, Read hand content selected&#039;&#039;&#039; and &#039;&#039;&#039;Hand read mode pulse&#039;&#039;&#039;. &lt;br /&gt;
* These inserters are connected to the input of the left arithmetic combinator. &lt;br /&gt;
* The left [[Arithmetic combinator]] multiples &#039;&#039;&#039;each&#039;&#039;&#039; input by &#039;&#039;&#039;-1&#039;&#039;&#039; and outputs it to &#039;&#039;&#039;each&#039;&#039;&#039;. &lt;br /&gt;
* The right [[Arithmetic combinator]] is a &#039;&#039;&#039;memory cell&#039;&#039;&#039; as above.&lt;br /&gt;
* The memory cell&#039;s input is connected to the inserters that are placing items on the belt and the output of the left [[Arithmetic combinator]]. &lt;br /&gt;
* The inserters that place items onto the belt have an enabled condition that is based on the number of items on the belt.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Splitters ==&lt;br /&gt;
[[file:CondSplitter.png|left|400x400px]]&lt;br /&gt;
=== Conditional splitter ===&lt;br /&gt;
* This is the simplest circuit you can have for &amp;quot;controlling&amp;quot; a splitter.&lt;br /&gt;
* A signal X=1 is transmitted from off screen when the items need to be sent down the belt.&lt;br /&gt;
* The belt on the left is enabled when X=1.&lt;br /&gt;
* The belt on the right is enabled when X=0.&lt;br /&gt;
* The two belts are wired together and to a pole. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:PrioritySplitter.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Priority Splitter ===&lt;br /&gt;
* This circuit prioritizes items to the belt going of the screen to the left but will send items straight on if the belt to the left is backed up.&lt;br /&gt;
* Its not perfect and will leak some items but its good enough for most applications. &lt;br /&gt;
* The balancer means it will work even if the supply or demand is uneven. &lt;br /&gt;
* It is critical that the belts are setup as in this picture otherwise it may not work. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Power ==&lt;br /&gt;
[[File:SteamBackup.png|left|400x400px]]&lt;br /&gt;
=== Backup steam power ===&lt;br /&gt;
* The [[steam engine]]s are not directly connected to the power network. They are connected to the power network through a [[Power switch]]. &lt;br /&gt;
* The [[power switch]] is connected to one of the [[accumulator]]s in the main network. &lt;br /&gt;
* The [[power switch]] turns on when A &amp;lt; 10. That is when the [[accumulator]]s are less than 10% full.&lt;br /&gt;
{{clear}}&lt;br /&gt;
=== Optimal usage of fuel for nuclear power ===&lt;br /&gt;
Unlike the normal steam power that adjusts fuel usage based on power usage, the [[Power_production#Nuclear_power|nuclear reactors]] spend fuel in fixed units of time. To be exact, the consumption of 1 fuel cell takes exactly 200 seconds.&lt;br /&gt;
&lt;br /&gt;
Combined with the fact that creating the nuclear fuel cells are time consuming and expensive to create, it is therefore beneficial to optimize their use to match the actual consumed power.&lt;br /&gt;
&lt;br /&gt;
[[File:NuclearCircuits.jpg]]&lt;br /&gt;
&lt;br /&gt;
The above picture shows a setup with 4 reactors, that spend only 1 fuel cell each whenever steam runs low.&lt;br /&gt;
&lt;br /&gt;
There are a few elements in this setup:&lt;br /&gt;
&lt;br /&gt;
* Storage tank that provides the [[Steam]] signal.  You should only read from one storage tank, and it should have pipe connections to all your other steam storage tanks.&lt;br /&gt;
* Chests containing [[Uranium_fuel_cell|Uranium fuel cells]] for the reactor.&lt;br /&gt;
* Output inserters that take [[Used_up_uranium_fuel_cell|Empty fuel cells]] from the reactor. This is connected to the storage tank to listen for the steam signal, and to the chests to listen for the uranium fuel cell signal. If the steam level is low and there are uranium fuel cells available, it removes the empty fuel cells from the reactor and sends an empty fuel cell signal (since &amp;quot;Read hand contents&amp;quot; is checked).&lt;br /&gt;
* Input inserters that put uranium fuel cells into the reactor. This is connected to the output inserters and listens for the empty fuel cell signal. The &amp;quot;Override stack size&amp;quot; is set to 1, so that it only inserts 1 fuel cell at a time.&lt;br /&gt;
&lt;br /&gt;
Since this design uses empty fuel cells as a signal to fill the reactor, you need to manually insert 1 uranium fuel cell into the reactor to get it started.&lt;br /&gt;
&lt;br /&gt;
== Latches ==&lt;br /&gt;
=== RS latch - single decider version ===&lt;br /&gt;
[https://forums.factorio.com/viewtopic.php?f=193&amp;amp;t=14556 This discussion] on the Factorio forums starts with the common 2 decider RS latch version, but the thread goes on to explain why this single decider version is better.&lt;br /&gt;
==== Backup steam example ====&lt;br /&gt;
This example will turn on the steam generator when the Accumulator charge drops to 20%, but will &amp;quot;latch&amp;quot; (remember) the On state until the accumulator is charged to 90%.&lt;br /&gt;
&lt;br /&gt;
Latching is used to introduce [[Wikipedia:hysteresis|hysteresis]] and avoid the power switch rapidly cycling on and off (as the accumulator falls to 19%, charges to 20%, falls to 19% and so on).&lt;br /&gt;
[[File:SR-01-Layout.png|left]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br clear=all&amp;gt; &lt;br /&gt;
&amp;lt;div class=&amp;quot;toccolours mw-collapsible mw-collapsed&amp;quot; style=&amp;quot;width:50em;&amp;quot;&amp;gt;&lt;br /&gt;
Blueprint string for above backup steam example&lt;br /&gt;
&amp;lt;div class=&amp;quot;mw-collapsible-content&amp;quot;&amp;gt;&amp;lt;pre style=&amp;quot;white-space: pre-wrap; &lt;br /&gt;
 white-space: -moz-pre-wrap; &lt;br /&gt;
 white-space: -pre-wrap; &lt;br /&gt;
 white-space: -o-pre-wrap; &lt;br /&gt;
 word-wrap: break-word;&amp;quot;&amp;gt;&lt;br /&gt;
0eNrFVk1vozAQ/SuVz1ABCaRBq5WqXntKjqsKOTBJR8IGGTtpFPHfd+w0HyU0G6pVewkxnnmemfdmzI4tSgO1QqlZumOYV7Jh6Z8da3AleWnf6W0NLGVrVNrQG49JLuyLvYU/Z63HUBbwxtKw9QZ4zs48o15P1CBObgXkWIDy80osUHJdqTOAUfviMZAaNcI+A7fYZtKIBSiK7YgjoEAjfCgh1wpzv65KoFPqqiHnStrzCdAPA49t6Rm1NrYOWjQY7QrY6FQZwcvyX1jJFajxEYrnuRGmdGW6DCe+jx1KcB9TDYl1raoyW8ArXyM5kFVldG10djObj6zdI0kKHp2Mdiy0PysFIM8pwYKldHyOKjeo3TI8y8Wup93tl7Yv3fiaOC6zjt6z9uk4VqDaR+rY7CvBO2ZGewUec1qiaobVxaE3mtseiwK7EjVXLsaU/SKPobWe7zHrLYVmpM6WqhIZSsJg6ZKXDQyiYkzF9Vhk9xUU3d3kNiaSQUwEB/l9Hw+uZg1YjGzYiPpA1+/vpKuHjk7fRNf7JrJTsZf05MLwoIFbzLvtOvlEFZNjKepqQ5poNqjz10s9jA6N+fk8Ohx/FMFXNXDqxeCC20F901vCJxN07UjVG9K4+x9YQp5M2LUZfbTpq+XDKRsNnG4cuULZcz089HZWD+D0a8Pz52bnNPgPzTj76dlJAnDfNenZp5fHSr4ACp/NZ3fPnHrkDt64qN31vwbVuFIn43GUjCdxHIVt+xcL2lBp&amp;lt;/pre&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-02-Accumulator.png|left]]Accumulator outputs the current charge level as % on signal [[File:Signal-A.png]]&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-03-RangeDeciders.png|left]]First decider outputs &amp;quot;Set&amp;quot; ([[File:Signal-S.png]] = 1) if Accumulator is less than 20%.&lt;br /&gt;
Second decider outputs &amp;quot;Reset&amp;quot; ([[File:Signal-R.png]] = 1) once Accumulator is more than 90% full.&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-04-SRLatch.png|left]]&lt;br /&gt;
==== SR Latch configuration ====&lt;br /&gt;
&#039;&#039;&#039;The central decider and green feedback wire is the actual SR Latch.&#039;&#039;&#039;&lt;br /&gt;
It latches the Set signal [[File:Signal-S.png]] until the Reset signal [[File:Signal-R.png]] is received (and vice-versa).&amp;lt;br /&amp;gt;&lt;br /&gt;
NB: the latch expects binary inputs ([[File:Signal-S.png]] &amp;amp; [[File:Signal-R.png]] must be 0 or 1) - this is why the previous two deciders are required.&lt;br /&gt;
&amp;lt;br clear=all&amp;gt;&lt;br /&gt;
[[File:SR-05-PowerSwitch.png|left]]The Power switch isolates the generator from the rest of the factory until [[File:Signal-S.png]] = 1&lt;br /&gt;
&amp;lt;br clear=all&amp;gt; &lt;br /&gt;
----&lt;br /&gt;
=== SR latch ===&lt;br /&gt;
[[File:SRLatch.png|left|400x400px]]&lt;br /&gt;
* This should be familiar to anyone with any background in electronics. &lt;br /&gt;
* The signal is set and reset with the [[constant combinator]]s on the left by setting an A=1 signal. &lt;br /&gt;
* The latch &amp;quot;remembers&amp;quot; which one was last set and the light stays on until another signal is received.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:SRlatchinaction.png|left|400x400px]]&lt;br /&gt;
=== Usage of SR latch ===&lt;br /&gt;
* Here is an example of how you could use an SR latch.&lt;br /&gt;
* The two extra [[Decider combinator]]s provide the set and reset conditions. &lt;br /&gt;
* Petroleum gas &amp;lt; 50 and petroleum gas &amp;gt; 100. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:BeltLatch.png|left|400x400px]]&lt;br /&gt;
=== Belt only latch ===&lt;br /&gt;
* This is the most compact latch I am aware of. &lt;br /&gt;
* To make it work you need to place &#039;&#039;&#039;3&#039;&#039;&#039; raw wood on the inside lane of the belt.&lt;br /&gt;
* I believe it will have higher latency than the combinator version but in most situations you will not notice the difference. &lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== Displays ==&lt;br /&gt;
[[File:5digitDisplay.png|left|400x400px]]&lt;br /&gt;
=== Numerical Display ===&lt;br /&gt;
* Each digit is driven by its own [[Green wire]], that wire holds 15 signals one for each lamp used in the digit.&lt;br /&gt;
* [[Constant combinator]]s are used to define which lamp should light up for each value. &lt;br /&gt;
* Blueprint string including decoder [https://www.dropbox.com/s/5o13xuwthalzzfe/Brain2.txt?dl=0]&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:BWDisplay.png|left|400x400px]]&lt;br /&gt;
&lt;br /&gt;
=== Black and White Grid Display ===&lt;br /&gt;
* Each row has its own [[Red wire]] connection and within that row each light has a numbered signal 0-9.&lt;br /&gt;
* We turn each light on by just setting or clearing the relevant signal.&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
[[File:MultiColoredDisplay.png|left|400x400px]]&lt;br /&gt;
=== Multicolor Display by DaveMcW ===&lt;br /&gt;
* To understand how this works, you first need to understand how color lights choose which color to light up when there are multiple colored signals. &lt;br /&gt;
* The [[lamp]] will light up with the colored signal that is greater than zero and earliest in this list: Red, Green, Blue, Yellow, Pink, Cyan, White.  &lt;br /&gt;
* We have a [[Red wire]] per column, that wire has each of the colored signals on it at different values and a numbered signal for each row. &lt;br /&gt;
* There is a [[Arithmetic combinator]] for each cell that subtracts the &amp;quot;row&amp;quot; value from each of the colored signals. &lt;br /&gt;
* And this enables us to choose the color for each cell. &lt;br /&gt;
* Simple!&lt;br /&gt;
{{clear}}&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
* [[Arithmetic combinator]]&lt;br /&gt;
* [[Constant combinator]]&lt;br /&gt;
* [[Decider combinator]]&lt;br /&gt;
* [[Circuit network]]&lt;/div&gt;</summary>
		<author><name>AnthonyQBachler</name></author>
	</entry>
</feed>