Factoratio

Calculate optimal ratios for feeding recipes, search through the research-tree, specialized tools to view game-information.
synopia
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sat Jun 28, 2014 10:32 pm
Contact:

Factoratio

Post by synopia »

Hey everyone,

I just want to show you my little tool Factoratio.

It helps calculating good ratios between different factory types.

To do that, you first choose a recipe in the select box and set target speed using the slider (units per minute).
By clicking into any Factory cell, you may choose a factory to use. Now more columns in the table get filled:
  • u/m/factory - The number of items produced by one of the chosen factories per minute. If inserters are selected, their speed is taken into account too.
  • Count - the number of factories required to build items at chosen speed.
There are actually two views:
  • Recipe view - shows a tree of all required items to produce the chosen recipe.
  • Ratio view - for each type of items needed to produce the chosen recipe, show to where and how fast they needs to be delivered.
By using the Optimize button, the whole tables are filled automatically. This is very experimental, but it basically selects the slowest combination of factory type and inserters, so that only one factory is needed (if that is possible with the fastest combination).

Notice: Everything is work in progress. So expect bugs and report them ;-)

If interested, source code can be found in my github repo.
synopia
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sat Jun 28, 2014 10:32 pm
Contact:

Re: Factoratio

Post by synopia »

Ok, update news:

The most important change is, you now can add multiple recipes and see the totals for each required item to produce.

I also removed the Optimize button - this is done whenever you change anything. Using the new Setup button you can select which factories to use for optimization. The optimization simply selects the slowest factory, so that you produce enough items with only one of these factory (if that is possible). The inserters are chosen by the same algorithm. Right now, you cannot specify to use more than one input/output inserter.

To verify the numbers a bit, I just startet a fresh game and built a line to produce science pack 1 and 2. So, in Factoratio I setup to use only assembling machine 1 and 2, normal/fast inserter and stone furnace. Then, I added science pack 1 and 2 and moved to slider on top to 24u/m (units per minute).

In the table columns you can see several information:
  • u/m: required total speed to get selected items at selected speed
  • Count: number of factories needed, to get enough items
  • u/m/factory: speed of one factory. This value depends on the three following columns. Hover a cell of this column to get advanced information
  • Factory: the factory to produce the item.
  • Input/Output inserters: the inserter type to use to get items into (out of) the factory.
Factories and inserters can be changed by clicking into the cell. Changed cells will not be optimized, when you move the speed slider.

I attached a screenshot of the production line as suggested by the tool and the ingame production view. Notice how nicely (of course not exactly) the numbers matches with the theoretical, calculated values :-)
Production View
Production View
production_view.jpg (352.6 KiB) Viewed 37877 times
Production Line
Production Line
production_line.jpg (498.06 KiB) Viewed 37877 times
shrimposh
Burner Inserter
Burner Inserter
Posts: 6
Joined: Wed May 14, 2014 5:23 pm
Contact:

Re: Factoratio

Post by shrimposh »

This is awesome!

Do you consider adding the options of inserters with stack bonus for the possiblity of container -> Assembling Machine?
Also, do you consider adding Productivity Modules and Speed Modules?
-
ray4ever
Long Handed Inserter
Long Handed Inserter
Posts: 88
Joined: Sun Jan 12, 2014 9:22 am
Contact:

Re: Factoratio

Post by ray4ever »

I realy like your website and will definetly use it!
User avatar
GewaltSam
Filter Inserter
Filter Inserter
Posts: 345
Joined: Thu May 08, 2014 5:42 pm
Contact:

Re: Factoratio

Post by GewaltSam »

This sounds fantastic, exactly what I was looking for! I'll definitely try it out when i come back to some more Factorio :) Keep up the good work!
User avatar
-root
Filter Inserter
Filter Inserter
Posts: 651
Joined: Tue Jul 01, 2014 11:24 pm
Contact:

Re: Factoratio

Post by -root »

This. Is. Excellent.

My OCD just got put into a whole new level :D
synopia
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sat Jun 28, 2014 10:32 pm
Contact:

Re: Factoratio

Post by synopia »

Thanks for your nice feedback :-)

Currently I am working on multiple inserters, since this is whats missing for my current factorio game right now ;-)

Modules and stack bonus (which may be seen as a module for inserters) should be easy to add as special factories/inserters - but to make it really useful, some other rework is required beforehand. I need to find an easy way to define targets/sources for individual inserters. Then, rather complex setups (like putting items from belts into chests, from chests to belts or from factory to factory) are possible.

Another thing to fix is the speed slider. This is not really useful anymore, since you cannot specify different speeds for several recipes. So I will drop the slider and open the first column, so that you can enter whatever speed you need. Also the count column should be opened, so that you can use the tool to calculate the output for your current factorio design.

I will keep you updated ;-)
User avatar
cube
Former Staff
Former Staff
Posts: 1111
Joined: Tue Mar 05, 2013 8:14 pm
Contact:

Re: Factoratio

Post by cube »

-root wrote:This. Is. Excellent.

My OCD just got put into a whole new level :D
+1 :-)
I have no idea what I'm talking about.
jeroon
Filter Inserter
Filter Inserter
Posts: 351
Joined: Sun Jan 26, 2014 10:18 am
Contact:

Re: Factoratio

Post by jeroon »

Really like what you've done here :D I'm currently creating something similar in C#, and I'm using your output to see if I'm on the right path :D

Few things I noticed in your script, in Ratio View:
- Electronic Circuits is limited to 31.5 u/m, because the input inserter can't keep up. (Took me quite long to figure out why it was using lvl 1 Assembly Machines there.. and then I noticed you mentioned only being able to choose 1 inserter per side in your second post..)
- Smart Inserter is chosen over Fast Inserter (I know the speed is the same, but the power usage is not ;) Plus, it looks weird :P )
- Choosing Long Handed Inserters over normal Inserters is understandable because of the speed increase, but I think most people won't do it in their factory :)

I guess I will keep using this while trying to optimizing my factory :D
User avatar
y.petremann
Filter Inserter
Filter Inserter
Posts: 421
Joined: Mon Mar 17, 2014 4:24 pm
Contact:

Re: Factoratio

Post by y.petremann »

jeroon wrote:Really like what you've done here :D I'm currently creating something similar in C#, and I'm using your output to see if I'm on the right path :D

Few things I noticed in your script, in Ratio View:
- Electronic Circuits is limited to 31.5 u/m, because the input inserter can't keep up. (Took me quite long to figure out why it was using lvl 1 Assembly Machines there.. and then I noticed you mentioned only being able to choose 1 inserter per side in your second post..)
- Smart Inserter is chosen over Fast Inserter (I know the speed is the same, but the power usage is not ;) Plus, it looks weird :P )
- Choosing Long Handed Inserters over normal Inserters is understandable because of the speed increase, but I think most people won't do it in their factory :)

I guess I will keep using this while trying to optimizing my factory :D
Few interresting ideas.

I really like this tool and really would like to see it having some evolutions :
  1. Loading data files instead of a custom format or at least a dump done by a mod. his would permit to keep compatibility with factorio evolution and mods.
  2. In factory column, possibility to adds modules (speed modules)
  3. In inserters column, possibility to say how many inserters to put (considering we can put a maximum of 2*(width+height)*(inserter+long inserter) for automatic calculation)
  4. In u/m column, possibility to modify the number if it's top recipe
  5. Adding an option for showing integer numbers of machines and showing production values depending of integer numbers (maybe in parenthesis)
  6. Posibility to have a more compact view (using a proper table instead of some divs ... think it's webix fault)
User avatar
y.petremann
Filter Inserter
Filter Inserter
Posts: 421
Joined: Mon Mar 17, 2014 4:24 pm
Contact:

Re: Factoratio

Post by y.petremann »

y.petremann wrote:
jeroon wrote:Really like what you've done here :D I'm currently creating something similar in C#, and I'm using your output to see if I'm on the right path :D

Few things I noticed in your script, in Ratio View:
- Electronic Circuits is limited to 31.5 u/m, because the input inserter can't keep up. (Took me quite long to figure out why it was using lvl 1 Assembly Machines there.. and then I noticed you mentioned only being able to choose 1 inserter per side in your second post..)
- Smart Inserter is chosen over Fast Inserter (I know the speed is the same, but the power usage is not ;) Plus, it looks weird :P )
- Choosing Long Handed Inserters over normal Inserters is understandable because of the speed increase, but I think most people won't do it in their factory :)

I guess I will keep using this while trying to optimizing my factory :D
Few interresting ideas.

I really like this tool and really would like to see it having some evolutions :
  1. Loading data files instead of a custom format or at least a dump done by a mod. his would permit to keep compatibility with factorio evolution and mods.
  2. In factory column, possibility to adds modules (speed modules)
  3. In inserters column, possibility to say how many inserters to put (considering we can put a maximum of 2*(width+height)*(inserter+long inserter) for automatic calculation)
  4. In u/m column, possibility to modify the number if it's top recipe
  5. Adding an option for showing integer numbers of machines and showing production values depending of integer numbers (maybe in parenthesis)
  6. Posibility to have a more compact view (using a proper table instead of some divs ... think it's webix fault)
I present you my version of factoratio
FRodrigues
Burner Inserter
Burner Inserter
Posts: 6
Joined: Mon Feb 02, 2015 1:37 pm
Contact:

Re: Factoratio

Post by FRodrigues »

The transport belt throughput is 803.475 u/m! 112.5 t/m is the speed of the transport belt. The same for the other types of belt.
Thank you! This is a great app and I can use it on linux! :D
User avatar
y.petremann
Filter Inserter
Filter Inserter
Posts: 421
Joined: Mon Mar 17, 2014 4:24 pm
Contact:

Re: Factoratio

Post by y.petremann »

FRodrigues wrote:The transport belt throughput is 803.475 u/m! 112.5 t/m is the speed of the transport belt. The same for the other types of belt.
Thank you! This is a great app and I can use it on linux! :D
Have you the possibility to give the exact values for other belts ? I could make the changes on my version ...
FRodrigues
Burner Inserter
Burner Inserter
Posts: 6
Joined: Mon Feb 02, 2015 1:37 pm
Contact:

Re: Factoratio

Post by FRodrigues »

You should read this!
https://forums.factorio.com/wiki/inde ... ts/Physics

In theory the numbers are: basic 803.475, fast 1606.95, express 2410.425 unit/min.
But in practice the throughput can be much lower...
FRodrigues
Burner Inserter
Burner Inserter
Posts: 6
Joined: Mon Feb 02, 2015 1:37 pm
Contact:

Re: Factoratio

Post by FRodrigues »

synopia and y.petremann, what source code license do you use?
User avatar
y.petremann
Filter Inserter
Filter Inserter
Posts: 421
Joined: Mon Mar 17, 2014 4:24 pm
Contact:

Re: Factoratio

Post by y.petremann »

FRodrigues wrote:synopia and y.petremann, what source code license do you use?
For my case I've just done things to updates the tool and simply expected that it would be integrated in regular build I didn't expected to particularly choose a source code license since I've not done something really big and that not originaly my program, so it would be to Synopia to choose, but I generaly choose the GNU GPLv3 license if applicable to the context.
FRodrigues
Burner Inserter
Burner Inserter
Posts: 6
Joined: Mon Feb 02, 2015 1:37 pm
Contact:

Re: Factoratio

Post by FRodrigues »

y.petremann wrote:
FRodrigues wrote:synopia and y.petremann, what source code license do you use?
For my case I've just done things to updates the tool and simply expected that it would be integrated in regular build I didn't expected to particularly choose a source code license since I've not done something really big and that not originaly my program, so it would be to Synopia to choose, but I generaly choose the GNU GPLv3 license if applicable to the context.
I forked your repo and made some changes for me (like removing inserters). Because I publish it in the github website and everybody can see, I could be doing something illegal.
Chuske
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sun May 17, 2015 2:31 pm
Contact:

Re: Factoratio

Post by Chuske »

I've noticed the chemical plant production is badly under estimated

For example a chemical plant producing plastic bars can in game with fast inserters make ~130 plastic bars per minute but the factoratio the game reckon 31.5 u/m/factory, which is less than a quarter of true value. The mouseover suggests this is something to do with 1 inserter for multiple inputs.

The game recipe for plastic bars is 2 plastic bars produced with a time of 1 second but chem plant has a crafting speed of 1.25, so in theory you can get 150 u/m/factory if you have multiple input and output inserters

EDIT: Ok this seems to be generally the way this tool calculates the inserters as looking at the code it seems to divide inserter speed by the number of inputs and takes no account of fluid pipes for fluid inputs or multiple inserter setups, for me this negates most of usefulness of this tool and I'll switch to using the Foreman tool. I don't know Javascrpt but if I do have some time coming up I may see if I can learn it enough to fork the code and improve the inserter logic, perhaps offering more options on inserter limiting on multiple inputs/outputs
kalzekdor
Burner Inserter
Burner Inserter
Posts: 6
Joined: Fri Mar 18, 2016 12:20 am
Contact:

Re: Factoratio

Post by kalzekdor »

This is interesting, but the lack of consideration for varied input scenarios ends up bottle-necking production at the input inserter, which makes it not very useful as an actual tool.

A couple of minor tweaks can greatly improve its utility:
  1. Allow for up to 9 Inserters for input, if the bottleneck is input. Start with 1 Inserter, and then add one more until Input is no longer the bottleneck, or you hit the max. (You could allow for 11 Input Inserters, but that would make organization of the factory more difficult. You could go even higher by mixing in long-handed inserters, but I doubt any machine is ever going to need more than 6 or so Fast Inserters in order to operate optimally.)
  2. Liquid inputs don't use Inserters, they use Pipes. A good average rate is 7200 units per minutes (120 units per second). That can be up to doubled if you go crazy with pumps, but I doubt liquid throughput is going to be a major bottleneck.
Maddhawk
Fast Inserter
Fast Inserter
Posts: 125
Joined: Sat May 05, 2018 6:53 am
Contact:

Re: Factoratio

Post by Maddhawk »

Unless Synopia is planning to update this, this needs to be unpinned and allowed to fall off the front page. The tool is wildly out of date now. Not only are recipes incorrect, but so are the names of many things.
Post Reply

Return to “Cheatsheets / Calculators / Viewers”