Crafting speed math

Post all other topics which do not belong to any other category.
Post Reply
Nich
Fast Inserter
Fast Inserter
Posts: 171
Joined: Wed Jan 18, 2017 2:33 am
Contact:

Crafting speed math

Post by Nich »

So when I first started playing I thought I could handle just adding more as I need it. I have quickly learned that you will always be adding something. Add more green circuits... run out of copper. Add more copper....need more iron. Add more Iron... Need more belt bandwidth. It is a never ending loop.

I have decided I want to start building more intelligently. The problem is I am having trouble figuring out how crafting speed fits into the mix and I was wondering if you guys had any mental tricks for remembering how it works.

Some of the key numbers I think I need to memorize are:

Yellow belt 13.3 items/s
Red (double yellow)
Blue (triple yellow)

Assy 1 .5
Assy 2 .75
Assy 3 1.25

So If i want to fill a yellow belt with iron plates I will need

13.3 items/s /( 1 item/3.5 seconds) / 1 (crafting speed of stone furnaces) = stone furnaces?
46.5 furnaces?

Then if I want to use that full yellow belt in Green circuits
13.3 items/s / (1 item/.5 seconds) / .75 (Assy 2 crafting speed) = Green Circuit machines?
8.9 Green Circuits?

So Assuming I round down to 8 how much copper do I need?
8 *1.5 item/.5 seconds * .75 = 18 items/s or 1.35 yellow belts of copper?

18 items/s / (1 item/3.5 s) / 1 = 63 stone furnaces?

Xeanoa
Fast Inserter
Fast Inserter
Posts: 190
Joined: Tue Apr 26, 2016 4:32 pm
Contact:

Re: Crafting speed math

Post by Xeanoa »

You'll need 42 stone funaces of iron and 63 of copper, 12 blue assemblers for copper wire to feed 8 assemblers doing curcuits.

Frightning
Filter Inserter
Filter Inserter
Posts: 807
Joined: Fri Apr 29, 2016 5:27 pm
Contact:

Re: Crafting speed math

Post by Frightning »

A good shortcut that I use to remember and math with the crafting speeds of assembly machines is:

Assembly machine 1: 2/4(=1/2)
Assembly machine 2: 3/4
Assembly machine 3: 5/4

Those numbers let you easily compare ratios between unlike assembly machine types (e.g. 3 assem 1s make as much as 2 assem 2s, before modules enter the picture, at least), they're also handy for helping you compute items/s, just do it for the recipe, then multiply by the relevant factor to get the actual value for given assembly machines.

Yoyobuae
Filter Inserter
Filter Inserter
Posts: 499
Joined: Fri Nov 04, 2016 11:04 pm
Contact:

Re: Crafting speed math

Post by Yoyobuae »

Something that bugs me about this kind of math is that the game implies there's a time associated with each recipe. But that's not true, the time a recipe takes is only known once the crafting speed of a machine is applied.

As a result units become all out of whack. For example, what's the unit/dimension of craft speed? None. That makes no sense.

My solution is to consider craft cost as it's own dimension with it's own unit: the craft. So, for example, smelting copper/iron ore costs 3.5 crafts.

And now it's easier to specify the craft speed of things: Stone furnace = 1 craft/second, Assembly machine 1 = 0.5 craft/second.

How much time one stone furnace takes to smelt an iron ore into iron plate:
3.5 craft / 1 craft/second = 3.5 seconds

How many furnaces to fill a yellow belt:
13.3 items/second * 3.5 seconds = 46.5 items

And everything matches perfectly. :D

Sorry, that was a bit of rant. The results are the same in the end. xD

Nich
Fast Inserter
Fast Inserter
Posts: 171
Joined: Wed Jan 18, 2017 2:33 am
Contact:

Re: Crafting speed math

Post by Nich »

I am an aerospace engineer so I have dealt with plenty of dimensionless coefficients but that idea of the "craft" is exactly what I was looking for to help rationalize it in my head. Thanks a Ton

torne
Filter Inserter
Filter Inserter
Posts: 341
Joined: Sun Jan 01, 2017 11:54 am
Contact:

Re: Crafting speed math

Post by torne »

The time of each recipe is the time it takes to craft by hand - the player's hand crafting speed is 1.0.

SirFloIII
Burner Inserter
Burner Inserter
Posts: 12
Joined: Wed Mar 16, 2016 9:09 pm
Contact:

Re: Crafting speed math

Post by SirFloIII »

In my calculations i use the quantities "nominal crafting time" and "real crafting time". the conversion between the two is just the crafting speed.

Frightning
Filter Inserter
Filter Inserter
Posts: 807
Joined: Fri Apr 29, 2016 5:27 pm
Contact:

Re: Crafting speed math

Post by Frightning »

Yoyobuae wrote:Something that bugs me about this kind of math is that the game implies there's a time associated with each recipe. But that's not true, the time a recipe takes is only known once the crafting speed of a machine is applied.

As a result units become all out of whack. For example, what's the unit/dimension of craft speed? None. That makes no sense.

My solution is to consider craft cost as it's own dimension with it's own unit: the craft. So, for example, smelting copper/iron ore costs 3.5 crafts.

And now it's easier to specify the craft speed of things: Stone furnace = 1 craft/second, Assembly machine 1 = 0.5 craft/second.

How much time one stone furnace takes to smelt an iron ore into iron plate:
3.5 craft / 1 craft/second = 3.5 seconds

How many furnaces to fill a yellow belt:
13.3 items/second * 3.5 seconds = 46.5 items

And everything matches perfectly. :D

Sorry, that was a bit of rant. The results are the same in the end. xD
As Nich pointed out, the crafting speed is a dimensionless quantity (meaning no units), you could think of it as seconds/seconds, which of course simplifies to 1 (no unit).

BattleshipBrotemkin
Manual Inserter
Manual Inserter
Posts: 3
Joined: Fri Jan 27, 2017 2:52 am
Contact:

Re: Crafting speed math

Post by BattleshipBrotemkin »

I wouldn't even recommend memorizing assembler machine times or anything since it all goes silly when you throw in beacons or card-up your machines. It's easy math (base craft speed/machine listed speed factor gives you seconds per cycle) Certainly memorize or have a reference guide for belt/inserter speeds, though.

I work off effective assembler operations/minute for planning. It's trivial to convert it to other handy metrics without getting into tick-level calculations. All the information you need to determine throughput is available on the assembler info pane or in the item base recipe values.

Then you can apply some real-life tricks (pull manufacturing principles like takt time) to really become the guy who makes spreadsheets for their Factorio game.

Daid
Fast Inserter
Fast Inserter
Posts: 163
Joined: Sun Jul 03, 2016 7:42 am
Contact:

Re: Crafting speed math

Post by Daid »

The actual code calls this requirement "energy". Which can be confusing as it has nothing to do with power requirements.

MaMo
Burner Inserter
Burner Inserter
Posts: 9
Joined: Mon Jan 30, 2017 11:57 am
Contact:

Re: Crafting speed math

Post by MaMo »

I have created excel spreadsheet, gathered all parametres and all data on production awailable from game. I know there is google spreadsheet accessible that should cover for that but it's not giving even half data and possibilities. My spreadsheet works like this:

1) You input amount of end-resource you want to get on "materials" list, all material requirements on input are calculated here but you don't need to give a s*it, let's move to second list.
2) List with necessary amount of production units (assembly, furnace, chem.plant) for each input material necessary to produce required amount of end product in 1 time unit (this refers to time stated on prod.units ingame, I think it's 1 second?). Then you can play with productivity/speed modules you will use for separate prod.units which immediatelly gives you changed numbers, with set amount of reserve you want on lower tier material just to be sure that everything runs all the time and never stops until you say so :)

3) This precious knowloedge motivates you to create huge monsters. How to exactly supply them? I did not want to count belt throughput, I'm not a fan of them. I have 2 solutions - 1 with trains/bots. Amazing to watch but kills FPS, other pure trainz. For that, I use very complex train logistic system with robot sorting and separated local robot networks, big amount of bots and trains give you any throughput you want and as long as you make sure they fly short distances, game still runs at solid speed.

4) RESULT = no situation like you described when you need to "add this and add that" + you know exact frequency at which you get desired end-output, as long as you keep basic resources coming

5) final remark - this usually does not concern "all-factory" concept for creating factory that gives you materials to create more factories. Such system should be quite slow and you can afford to give it 10 times lower resource /intermediate product supply.

User avatar
DerivePi
Filter Inserter
Filter Inserter
Posts: 505
Joined: Thu May 29, 2014 4:51 pm
Contact:

Re: Crafting speed math

Post by DerivePi »

Frightning wrote:As Nich pointed out, the crafting speed is a dimensionless quantity (meaning no units), you could think of it as seconds/seconds, which of course simplifies to 1 (no unit).
Why not just consider it a modification factor? You have your base units/sec x (unreserved greek letter(s) of your choice - higher points for weird squigglies).

For plastic, you have:
plastic = 2 unit/sec x Kappa = 2.5 units/sec; Kappa = 1.25 for Chemical Plants
coal = -1 unit/sec x Kappa = -1.25 units/sec
Petro = -3 units/sec x Kappa = -3.75 units/sec

If we throw a level 1 productivity module on there (-15% speed and +4% production):
plastic = 2 unit/sec x Kappa x Phi-p x Phi-s = 2.21 units/sec; Phi-p = 1.04, Phi-s = 0.85
coal = -1 unit/sec x Kappa x Phi-s = -1.0625 units/sec
Petro = -3 units/sec x Kappa x Phi-s = -3.1875 units/sec

This format lends itself well to sizing the proper amount of inserters for assembler inputs and outputs as well as sizing the belts for throughput. Lately, I've been more inclined to consider production for each item as a full group of assemblers/furnaces in my "Max Design" thread. viewtopic.php?f=202&t=12588
The thinking is that if I reserve the space in the early game for these end game layouts, I can grow the factory into my end game production as needed knowing numbers like 60 steel furnaces to a blue belt or 1 1/2 belts of copper and 1 belt of iron into 16 circuit assembler 3s will give a full blue belt of circuits.

Yoyobuae
Filter Inserter
Filter Inserter
Posts: 499
Joined: Fri Nov 04, 2016 11:04 pm
Contact:

Re: Crafting speed math

Post by Yoyobuae »

torne wrote:The time of each recipe is the time it takes to craft by hand - the player's hand crafting speed is 1.0.
SirFloIII wrote:In my calculations i use the quantities "nominal crafting time" and "real crafting time". the conversion between the two is just the crafting speed.
Frightning wrote:As Nich pointed out, the crafting speed is a dimensionless quantity (meaning no units), you could think of it as seconds/seconds, which of course simplifies to 1 (no unit).
Dimensionless and mislabeled quantities are just awful. They just lead to all sort of contradictions. A time which isn't a time. A speed which isn't rate over time. ;)

Anyway, the main reason behind my little rant is that I'm working (on and off) on using Frink for factorio (Frinktorio :D). Snippet from my unit definition file:

Code: Select all

meter :=  m
tile := meter
slot := 1/32 meter

time =!= s
second := s
minute := 60 s
hour := 60 minute
cycle := 1/60 s

yellow_belt := 1 slot/cycle
red_belt := 2 slot/cycle
blue_belt := 3 slot/cycle

item =!= item
slots_per_item := 9 slot/item

s/item ||| time_per_item
time_per_item :-> "second/item"

item/s ||| item_per_second
item_per_second :-> "item/second"

smelt =!= smelt
smelt/item ||| smelt_cost
smelt_cost :-> "smelt/item"
smelt/s ||| smelt_speed

craft =!= craft
craft/item ||| craft_cost
craft_cost :-> "craft/item"
craft/s ||| craft_speed
craft_speed :-> "craft/second"

hardness =!= hardness
item/hardness ||| mine_speed

pollution =!= pollution
pollution/s ||| pollution_per_second
pollution_per_second :-> "pollution/second"
pollution/item ||| pollution_per_item
pollution_per_item :-> "pollution/item"

energy =!= joule
J :=                   joule
J/item ||| joule_per_item
joule_per_item :-> "kilojoule/item"
watt :=                J/s
W :=                   watt
watt ||| power
power :-> "W"
Frink automatically works out the units and warns about trying to add two quantities of different dimensions, which in turns makes writing code handling those quantities easier (ie. it prevents bugs). If the units are messed up, then the calculation is probably wrong. ;)

Allows things such as:

Code: Select all

ElectricMiner.mine[IronOre]
    0.525 item/second
StoneFurnace.smelt[IronPlate]
    2/7 (approx. 0.28571428571428571) item/second
AssemblyMachine1.craft[IronGearWheel]
    1. item/second
AssemblyMachine2.craft[SciencePack1]
    0.15 item/second
myFactory.getEnergyPerItem[SciencePack1]
    2559.2857142857142857 kilojoule/item
myFactory.getPollutionPerItem[SciencePack1]
    87.928571428571428571 pollution/item
myFactory.getEnergyPerItem[SolarPanel]
    46458.928571428571429 kilojoule/item
myFactory.getPollutionPerItem[SolarPanel]
    1831.8928571428571429 pollution/item
Still very much a work in progress, though.

aober93
Filter Inserter
Filter Inserter
Posts: 453
Joined: Tue Aug 30, 2016 9:07 pm
Contact:

Re: Crafting speed math

Post by aober93 »

I wouldnt be able to do correct math if i hadnt made an openoffice calc thing. Theres just too many factors. But even this isnt exactly the best thing, because often all i have to do is find a balance between space,speed,power consumption,size, cost, ratios anyway.

Then knowing the exact speed of a machine is becoming less necessary. Like for example just roughly knowing whats becoming twice as fast with the first beacon on certain other prerequisites is good enough, since you are upgrading the machine anyway later. Nothing in this game is final. Its always gonna be improved. The knowledge of whats gonna update or bottleneck is coming from playing the game.

At least this is my point of view. I dont care if i overload a belt by 10% if in the next 30 minutes of playing im speeding up the belt by 100%, or if the machine becomes obsolete. And i dont care if i have too few of a machine to fill a belt, if i just dont need that much. Or too much of a machine, because a machine shuts down itself if its not needed.

Nothing will change that there will always be a bottleneck with this game.

Nich
Fast Inserter
Fast Inserter
Posts: 171
Joined: Wed Jan 18, 2017 2:33 am
Contact:

Re: Crafting speed math

Post by Nich »

aober93,

I was a lot like you until about hour 70. That was when I made my first green circuit "factory" to attempt to support blue circuit production. After spending 45 minutes just watching the factory run at fill tilt and redesigning it 5 times I thought to my self there has to be a better way.

aober93
Filter Inserter
Filter Inserter
Posts: 453
Joined: Tue Aug 30, 2016 9:07 pm
Contact:

Re: Crafting speed math

Post by aober93 »

Nich wrote:aober93,

I was a lot like you until about hour 70. That was when I made my first green circuit "factory" to attempt to support blue circuit production. After spending 45 minutes just watching the factory run at fill tilt and redesigning it 5 times I thought to my self there has to be a better way.

IN about hour 70 you are in the end game (unless marathon, unless noob). Thats where things hit the cap, and squeezing the ratios start makes sense unless you launched a rocket and call it the quits. Since you talked about yellow belts and assemblers 1 i didnt expect you talk 70+ Hours!

I think the easiest way is to have assemblers and beacons intertwined and repeat this over and over again, while having the in/output be managed by robots. You will not care about ratios and layouts and belt saturation anymore.
Not exactly a fulfilling experience ,the designs are boring but it gets the job done and its the most productive and efficient. But its reserved for high end due beacons ,robots and energy consumption.

Nich
Fast Inserter
Fast Inserter
Posts: 171
Joined: Wed Jan 18, 2017 2:33 am
Contact:

Re: Crafting speed math

Post by Nich »

I have a couple personal hangups that are making big factories a real challenge for me.

1. Yellow belts are just so cheap compared to red and blue. I have found a couple uses for red belt to help with through put at bottle necks or to help with compression but other then that I have not been able to mentally move past yellows. I would rather lay 3 yellows then 1 blue

2. Pollution really bugs me. My current factory uses 50 MW, 80% or which is lasers and it is all Solar powered. I basically produce no pollution.

3. I have torn apart my smelting area 5 times attempting to find a better smelting layout but I just keep coming back to the split rows for coal powered

4. I used to think logistics robots were "cheaty" easy but I think I have transcended this and now see them as a quality of life end product transportation system.

5. I am attempting to integrate trains into my factory but I have been having a hard time justifying the extra cost. After about 4 attempts I think I have finally come up with an infinitely expandable furnace solution. Next is to do the same with green circuits.

Post Reply

Return to “General discussion”