Densest lag-machine

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
Post Reply
golfmiketango
Filter Inserter
Filter Inserter
Posts: 549
Joined: Fri Jan 29, 2016 2:48 am
Contact:

Densest lag-machine

Post by golfmiketango »

I want a machine that will give me the most lag in the least tiles. Something I can turn on and off. Any ideas?

I tried building a pump that continuously pushes water through a closed loop of 21,000+ pipes but it was not nearly as computationally expensive as I expected. I am still running at 600UPS+ while running this contraption (200UPS only while looking at the blueprint):
LagMachine.png
LagMachine.png (663.99 KiB) Viewed 4590 times

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3699
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: Densest lag-machine

Post by DaveMcW »

Arithmetic combinators performing Each * N on a large set of signals. Increase N each tick to prevent caching. Wire the outputs together for bonus addition operations. Use the result to turn on a lamp to make sure everything is fully calculated.

golfmiketango
Filter Inserter
Filter Inserter
Posts: 549
Joined: Fri Jan 29, 2016 2:48 am
Contact:

Re: Densest lag-machine

Post by golfmiketango »

DaveMcW wrote:Arithmetic combinators performing Each * N on a large set of signals. Increase N each tick to prevent caching.
Sounds like a start. I've been trying to think of slow-growing chaotic integer sequences that stay small starting from a wide array of different initial starting values so I could get combinators computing per-signal sequence iterations for a long time before they wind up in pathological/overflow sink-holes. The hofstader-conway $10000 sequence looks promising. Maybe a prng is better. Regardless, I admit I suspect something less fun to build and more brute-force-based (like your idea above) is probably more lag-density-maximizing than such ideas.
Last edited by golfmiketango on Tue Feb 20, 2018 9:13 pm, edited 2 times in total.

golfmiketango
Filter Inserter
Filter Inserter
Posts: 549
Joined: Fri Jan 29, 2016 2:48 am
Contact:

Re: Densest lag-machine

Post by golfmiketango »

DaveMcW wrote:Use the result to turn on a lamp to make sure everything is fully calculated.
Even a combinator with nothing hooked up to the outputs at tick t, could always get hooked up to something at tick t+1, so I'd be shocked (but also impressed) if the engine is seeking "no-effect" combinators to ignore.

BlakeMW
Filter Inserter
Filter Inserter
Posts: 950
Joined: Thu Jan 21, 2016 9:29 am
Contact:

Re: Densest lag-machine

Post by BlakeMW »

Hmmmm, I've never tried it, but you could try having batteries of power switches that get flipped on and off so as to continually create/merge and destroy thousands of electrical networks which ought to be somewhat expensive.

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3699
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: Densest lag-machine

Post by DaveMcW »

Nope, they already optimized that. https://www.factorio.com/blog/post/fff-115

Though it would be interesting to see if you could break it. :)

quyxkh
Smart Inserter
Smart Inserter
Posts: 1027
Joined: Sun May 08, 2016 9:01 am
Contact:

Re: Densest lag-machine

Post by quyxkh »

Wire up a parallel lagged-fibonacci rng with one of the monster state sizes and start feeding signals into that, that should do it. Probably best to generate the blueprint as text to save your sanity, fetch the zlib source and buld the zpipe example, then blueprint strings are `xclip -selection clibpoard -o | ( head -c1; base64 -d | zpipe -d | jq . ) >pretty.blueprint, to see whats up, then `(head -c1; zpipe | base64) < pretty.blueprint | xclip -selection clipboard to put your generated blueprint back in the clipboard.

Aeternus
Filter Inserter
Filter Inserter
Posts: 835
Joined: Wed Mar 29, 2017 2:10 am
Contact:

Re: Densest lag-machine

Post by Aeternus »

Main power plant hooked to your base via a tick oscillator controlled power switch. Turning your entire factory on and off 60 times per second should do the trick...
You can build an oscillator with an "Everything = 0" -> A = 1 looped back to it's own input.

golfmiketango
Filter Inserter
Filter Inserter
Posts: 549
Joined: Fri Jan 29, 2016 2:48 am
Contact:

Re: Densest lag-machine

Post by golfmiketango »

quyxkh wrote:head -c1; base64 -d | zpipe -d | jq
Cool, thanks, been trying to figure that out... After scratching my head for a couple of minutes I always end up using some web-form. What's zpipe though? Maybe this thing?edit: oh, you answered that, and yeah, it is :)

edit: Also I assume you meant "head -c -1"? -c1 would be just the first character.One could use "tail -c +2|" in place of "head -c1;"to avoid the subshell and random character on your screen but head -c1 is not a mistake.

edit: OK yes, that all works just like you said! nice.... still don't understand what format the stuff is in between base64 and zpipe though. I did find an a precompiled tool on my box that does it: qpdf ships with a little command-line utility called "zlib-flate" which does this as zlib-flate -uncompress.
Last edited by golfmiketango on Wed Feb 21, 2018 1:27 am, edited 4 times in total.

golfmiketango
Filter Inserter
Filter Inserter
Posts: 549
Joined: Fri Jan 29, 2016 2:48 am
Contact:

Re: Densest lag-machine

Post by golfmiketango »

BlakeMW wrote:Hmmmm, I've never tried it, but you could try having batteries of power switches that get flipped on and off so as to continually create/merge and destroy thousands of electrical networks which ought to be somewhat expensive.
Don't know if this will work or not but it's a freaking hilarious idea!

quyxkh
Smart Inserter
Smart Inserter
Posts: 1027
Joined: Sun May 08, 2016 9:01 am
Contact:

Re: Densest lag-machine

Post by quyxkh »

Here's a little (7,10) starter kit, as you add signals to the constant combinator it'll kick off the rng cascade for that one.
blueprint
... yup, I gut just that up to fish, so 10 combinators on 100-ish signals each and the circuit network's taking ~290µs. Gang-start a fat lot of those you should be in a world of hurt real quick.

golfmiketango
Filter Inserter
Filter Inserter
Posts: 549
Joined: Fri Jan 29, 2016 2:48 am
Contact:

Re: Densest lag-machine

Post by golfmiketango »

quyxkh wrote:Here's a little (7,10) starter kit, as you add signals to the constant combinator it'll kick off the rng cascade for that one.
blueprint
... yup, I gut just that up to fish, so 10 combinators on 100-ish signals each and the circuit network's taking ~290µs. Gang-start a fat lot of those you should be in a world of hurt real quick.
With enough constant combinators hooked up this thing is super crazy to watch. Such a PITA to build though ughhhh... Makes me want to just stop and make an all-the-things combinator mod.

Went as far as I could stand and 100 stamps got me to 10 UPS :) Run-and-stamp of the first few was a particularly amusing experience :)

quyxkh
Smart Inserter
Smart Inserter
Posts: 1027
Joined: Sun May 08, 2016 9:01 am
Contact:

Re: Densest lag-machine

Post by quyxkh »

You don't have to keep the constants, you can clear out slots, it's rising-edge one-shot and the rng juist runs independently from there.
blueprint
Here's a tilable version of the rng block, I'm down below 10fps on not so very many of it and I'm not half done about two thirds done loading the signals in
Attachments
Screenshot from 2018-02-20 18-07-15.jpg
Screenshot from 2018-02-20 18-07-15.jpg (106.05 KiB) Viewed 4523 times

User avatar
impetus maximus
Smart Inserter
Smart Inserter
Posts: 1299
Joined: Sat Aug 20, 2016 10:07 pm
Contact:

Re: Densest lag-machine

Post by impetus maximus »

what is its purpose?

quyxkh
Smart Inserter
Smart Inserter
Posts: 1027
Joined: Sun May 08, 2016 9:01 am
Contact:

Re: Densest lag-machine

Post by quyxkh »

Lag your map as fast and hard as possible. "Lagged fibonacci generator" came to mind immediately for some reason :-)
GolfMikeTango wrote:still don't understand what format the stuff is in between base64 and zpipe though
It's shell pipeline syntax, the guys who built Unix's had a really lovely eye for detail. Open file descriptors are shared among forks, so when you pipe stdin into a subshell, the whole subshell can cooperate to decode the file however it likes. The `head -c1` runs first in the subshell and copies the first character, leaving the rest for the following commands working on that file, base64 -d | zpipe -d de-asciifies and then decompresses the string, and | jq . is a handy json utility.

golfmiketango
Filter Inserter
Filter Inserter
Posts: 549
Joined: Fri Jan 29, 2016 2:48 am
Contact:

Re: Densest lag-machine

Post by golfmiketango »

impetus maximus wrote:what is its purpose?
No purpose, really. Just horsing around. If the factorio UI/console had better isolation from the "entity-update" part of the game-engine it could actually be useful. But in real life, you're waay better off slowing down the game with console commands.

The "vision" was: I want the game to run at 1 UPS for a bit so I flip a switch somewhere in the world and voila, 1 UPS, all achievement stuff intact. But by the time I started getting interested in this I'd already figured out that was hopeless.

I suppose, the maximization problem has utility to the devs, sort of like a bug-bounty program: If someone can find a nice tidy build that totally makes the game unplayable, that might be something they could investigate. But the combinator builds are almost like cheating, so probably not at all helpful to anyone except as a source of amusement.

User avatar
impetus maximus
Smart Inserter
Smart Inserter
Posts: 1299
Joined: Sat Aug 20, 2016 10:07 pm
Contact:

Re: Densest lag-machine

Post by impetus maximus »

ok, but i feel it would be something that would be too easily misused.
seeing how far you can bend or break something can be fun. just not when it someone on your server doing it.

golfmiketango
Filter Inserter
Filter Inserter
Posts: 549
Joined: Fri Jan 29, 2016 2:48 am
Contact:

Re: Densest lag-machine

Post by golfmiketango »

impetus maximus wrote:ok, but i feel it would be something that would be too easily misused.
seeing how far you can bend or break something can be fun. just not when it someone on your server doing it.
Never thought of that but now that you mention it, that sounds quite plausible. So, sorry if we just unleashed an army of factorio-combinator-script-kiddies in this thread but I think the cat is already out of the bag :|

Post Reply

Return to “Gameplay Help”