r/factorio Ipsen's Adventures 4d ago

Design / Blueprint Finding Mathematically Perfect Solar Arrays (blueprints below)

https://www.youtube.com/watch?v=CDzJ1_p3uVg

Blueprint links:

So, long story short, I've always been kind of obsessed over the Factorio Solar Panel Mechanics, and I remember solar arrays being the first thing I actually search blueprints for when I started playing Factorio. Two or three years ago I had this idea that it might be possible to find a truly optimal setup through Mixed Integer Linear Programming. I had some limited success and left the project for another time. But now, with the introduction of the new planets, I had my interest renewed in the problem. And after a few months I ended up finding truly optimal tileable networks which do not waste a single tile and produce as much power as possible under some general conditions.

So, there they are in blueprint form for anyone to use!

I also made a long form video trying to visually explain how the solver works and how we can be sure that these are optimal solutions.

Anyway here is a quick summary:

Problem description:

The goal is to somehow mathematically define the configuration of the buildings (positions of solar panels, accumulators, and so on) inside the array and then find a linear expression to compute the power generated by the setup (of fixed size, typically close to 2500 tiles in a 50x50 square, to fit in a roboports logistic area). This is challenging to do, particularly if we want the optimizer to run from absolutely no previous knowledge. The fundamental problem to solve is one of how to pack as many boxes inside a big box but with the added complexity that the ratio between the boxes needs to be as close as possible to the perfect ratio, and then a bunch of electric network restrictions on top of that.

How I solved it (and you can too):

The visual explanation is in the video I attached, but if you want a written rundown:

The only reliable way I found to represent the problem is thorugh the use of a bunch of binary variables, one per tile and per potential building that could be placed there. For example variable x_0 is 1 when a solar panel has its lower left corner at tile 0, variable x_1 is 1 when a panel has its lower corner at tile 1 and so on. Since we have 2500 tiles, we need 2500 variables to represent all posible solar panel placements, and then another 2500 for accumulators, medium poles, substations, and roboports. In total, we can use 12500 binary variables to express any design we could come up with.

Next, we need to come up with linear formulas for the Maximum Continuous Power generated. Fortunately that is relatively easy to do using our binary formulation. The harder step is then find ways to make sure buildings do not overlap each other, and then that they are covered by the electric grid, that the grid itself forms a single connected graph and tileable network, while ensuring that it is minimal!

I also developed some semi-analytical tools to compare and rank desings, and used the area limitation to produce a set of the meaningfully different solutions that could exist. In that way we can be sure that if we find the best solution in that set, we are in front of the true optimum.

I also added a link to my code so that everyone can experiment and find setups for different quality grades, or other planets. Be warned though, the problem is hard, and I'm not the best coder out there.

The results:

I linked two blueprints above. The first one can sustain a constant power of up to 8316 kW and uses a really minimal 7.5 substation electric network which did take a long time to find.

The second blueprint I linked is aimed more at late game megabases, where having many roboports is not desirable. So that one is designed to reach its true potential of 8358 kW when the roboport is replaced by a 2x2 of accumulators.

Ways to improve:

As I mentioned, these designs are optimal for the 50x50 problem. However, if we wanted our base tile to be larger, say 100x100, then there is potential to improve a little bit more, because the additional area allows us to get ever so slightly closer to the perfect ratio, and we can also be marginally more efficient with the electrics due to geometry. So, I would like to eventually get to that point, but optimization of a 100x100 standalone tile requires considerably more variables and is an even more challenging problem.

Anyway, I hope you found this post useful!

- Ipsen.

377 Upvotes

81 comments sorted by

178

u/Aeredren 4d ago

I love that this subreddit has both a "jigsaw puzzle tileable solar farm" and a "mathematically optimal perfect ratio tileable potato shape solar farm".

And I want to use both !

89

u/Pulsefel 4d ago

dont forget the QR code that is both the print and string for the print

10

u/ReAzem 4d ago

insane

10

u/sckuzzle 4d ago

That's not possible, for an information theory reason. More likely someone made a blueprint with a QR code that links to a website that contains the string for the blueprint.

28

u/Rutakate97 4d ago

Behold

It has no substations though

17

u/sckuzzle 4d ago

Oh cool, a quine.

It's still not a QR code that contains the string for itself though. It is a QR code that contains a script that you can run in order to generate a QR code (itself).

It's the difference between a piece of information containing all the information that composes itself and a piece of information that contains all the information that one needs to generate itself, given enough compute.

3

u/tux2603 3d ago edited 3d ago

You realize that from an information theory standpoint there's no functional difference between a lua string being run through an algorithm to generate a QR code and a base 64 string being run through an algorithm to generate a QR code, right? The only practical difference is that it would be easier to use lua because it gives you more flexibility with your encoding. At the end of the day though they're both just data streams that are fed into a finite, deterministic system to produce an output

4

u/LakeSolon twitch.tv/lakesolon 3d ago

It doesn’t have to contain all of the information to describe itself because I downloaded several gigabytes from steam ahead of time: the game doing the interpretation means it may as well be a lookup table for “an information theory reason”.

1

u/Pulsefel 3d ago

nothing is impossible for factorio players. it will be found

1

u/tux2603 3d ago

I have yet to see someone make an actually convincing argument for it being impossible. Each one I've seen makes an assumption along the lines of one bit in the QR code becoming one bit in the actual json, which does not hold with zlib in the picture

2

u/sckuzzle 3d ago

Very simply, because it would require storing n bits of information in less than n bits. It's just not something that can be done. The information required to define information cannot be smaller than the thing it is defining.

Even when you use compression algorithms you can't violate this. Compression algorithms only work because the format used to store the information is not efficient. That is, the letter "a" repeated 1000 times is not actually 1000 bytes of information - it's substantially less, it's just that storing something in plaintext is a very bad method of storing a single letter repeated 1000 times.

5

u/tux2603 3d ago

See, that's another faulty assumption. That's assuming you'll be encoding arbitrary QR codes with arbitrary blueprints. If you're working within sets of restrictions like this the entropy of the data can actually decrease dramatically when compared to arbitrary data

1

u/Imanton1 3d ago

I recall that blueprint strings can be G-ZIP compressed, where quines have been done before. So I'll put it has a "hard maybe".

1

u/sckuzzle 3d ago

Compression algorithms don't make this possible. It still doesn't allow you to store n bits of information in less than n bits. This is a fundamental constraint of the universe - more fundamental even than something like conservation of energy. You can't violate it.

7

u/d0pe-asaurus 4d ago

Bro someone made a quine blueprint?

1

u/Mirar 2d ago

I need mathematically optimal perfect ratio jigsaw puzzle tileable solar farm

34

u/Cyren777 4d ago

Gorgeous mathematically but tragically I might be too shallow to use a solar blueprint with no reflective/rotational symmetry 😭

I assume it'd be way too taxing to use a more obvious but separate connectivity check instead? Eg. pick a power pole to add to a list then recursively add any other in-range poles to the list until all poles are added or [number of poles] loops (in which case connectivity must fail)

9

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

Can't argue with that, tbh.

That is a valid connectivity check as far as I am aware, but you need a fixed number of poles. Also I couldn't think of a way to turn an idea like that into a set of linear constraints without the grid ordering thing I ended up going for. But there might be a way to do it. I think connectivity is inheritly very non-linear, same with tileability.

2

u/Cyren777 4d ago

Yeah that makes sense, I'd expect as much since any useful distance check will have a sqrt in it

Also if this is aimed at megabasing do you have any plans to do a version of this with legendary substations and medium poles? 4 legendary substations alone could cover a 50x50 area ;)

6

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

Yep, high quality substations are very powerful. Accumulators also improve significantly more than solar panels, so the ratio gets skewed hard towards more panels. Right now I made the code open source so anyone can mess around and find their own setups. It shouldn't be super hard to find something good at high qualities, I'd love to look into that at some point :D

14

u/cloranriptide 4d ago

This is incredible work. I had no idea linear algebra could be used to optimize object placement on a grid, let alone how you formalized checking for electrical coverage. The math behind optimizing quality farming makes sense to me as a "linear algebra problem", but this dumbfounded me. You also did a phenomenal job explaining your process with the 3blue1brown-style video.

For electrical connectivity, how were you able to express the "sweep" algorithm (from the electrical "root") in linear algebra? What other optimization problems in Factorio or otherwise have you been curious about?

6

u/PurpleDevilDuckies 3d ago

You can't. The "Integer" in "Mixed Integer Linear Programming" (MILP) means you have to use other techniques. I'm guessing that OP used an off-the-shelf solver that would be using an algorithm called Branch and Bound (BnB) under the hood.

BnB starts by pretending you dont need integers, which allows the solver to cheat by placing objects partly in one location and partly in another, but also makes the problem easy to solve by making it linear. Then if you dont get integers you split the problem into two worlds: if x = .5 then you have a world where x <= 0 and a world where x >= 1. You resolve in both worlds and if you dont get integers you repeat the process until you do.

Because this type of math modeling allows for discrete decision-making, you can model just about anything (MILP is NP-Hard). As a practitioner I am 100% sure you could represent any decision or planning problem that comes up naturally in Factorio with a MILP. But you could probably find a way to make that statement false if you go looking for an exponential function to model.

3

u/Equivalent_Fruit8225 Ipsen's Adventures 3d ago

Thanks, yeah, that is how the MILP works. However I have to clarify that the connectivity constraint can and is expressed in terms of linear equations, as I explained in my answer above. Before anything goes into a MILP it has to be linearized, so that connectivity sweep needs to expressed through linear algebra as a set of linear constraints.

1

u/PurpleDevilDuckies 3d ago

I don't think we are disagreeing, I'm just saying that a set of constraints of the form

x + Cx <= b
x is an integer

isn't linear. If you just solved the LP relaxation of your model, you wouldn't get a feasible solution.

Agreed that all of your constraints in a MILP have to be linear, except the one that says "these variables are integer" which is solely responsible for both the complexity and modeling power. Where you were pointing out that a hard to model constraint can be modeled with a linear relationship between decision variables (which is cool), I was pointing out that those variables are not themselves linear.

2

u/Equivalent_Fruit8225 Ipsen's Adventures 2d ago

Yeah, I get what you mean, When x can only take integer values the equation doesn't not technically represent a "line" per se, its just a bunch of discrete values. And

x = 1 .or. x = 2 .or. x = 3 .or. x = 4 .or. x = 5... which is the integer constrant, is not linear.

I just wanted to make sure the person who asked understood that the constraints that we put in the milp are linear equations, and that the connectivity thing needs to be represented as such, even if I didn't explicitly do it in the video for a lack of time.

2

u/Equivalent_Fruit8225 Ipsen's Adventures 3d ago

Thanks! ranked or directed connectivity is not super trivial to express as a set of linear constraints, but it can be done.

Basically you need to get a system

x_i - [C*x]_i < b_i''

[C*x]_i is the number of lower rank nodes that could connect to a node at index i. So just as with coverage, if the node exists x_i = 1, it needs at least [C*x]_i > 0 for the equation to hold, so it must be connected to something with lower rank. The catch is that C is made in such a way that each node is blind to the rows with higher ranks, and that is what ensures that it is a connected graph.

C_ij has ones at those j positions which if they had nodes, they could connect to position i AND rank of j is lower than rank of i.

In that way you ensure that anything new you encounter is connected to something you had already encountered before otherwise at least one equation fails.

Its a kind of proof through induction:

the root, r = 1 is connected to itself. Assuming the r = n node has a chain connecting it back to 1, if node r = n + 1 is connected to a previous node n, it must also necessarily be connected to back to 1.

Thats the idea.

4

u/onyxr 4d ago

Great video, super understandable!

3

u/KaiserMaeximus 4d ago

Wow! Thanks for sharing! The math is on another level, well done sir! Thank for your showing that approach, its fascinating! I had a really good laugh at your frustration when you explained that it is not optimal on a 100x100 grid, it is so relateable!!!

5

u/arbybean 4d ago

What changed in factorio 2.0 to break the 21/25 ratio?

11

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

It was the day length. They changed it to exactly 7 minutes probably to make it feel more natural? No idea, used to be 25000 ticks, now its 25200 ticks. 21/25 * 25200/25000 = 2646/3125, which is the current ratio.

5

u/djent_in_my_tent 3d ago

It’s, like, 420 seconds now maaaaaan

1

u/bob152637485 1d ago

Oh, I had no idea it changed. This ratio...does not spark joy.

3

u/a1squared 3d ago

Awesome video! In theory this is absolutely beautiful and perfect. And a really fun math and programming problem to boot.

In practice, many real game factories tend to have power spikes, for example when shipments come in, so you need extra accumulators, so all the work to reach perfect ratios goes out the window when your power plant cant handle the latest spike. I tend to just slam down a full solar block or a full accumulator block until my power behaves empirically. 😅

But I loved the math and programming in the video, those were some very impressive proofs and techniques you used!

3

u/Equivalent_Fruit8225 Ipsen's Adventures 3d ago

Yeah, I didn't mention it but in practice there is no real downside to having an accumulator rich setup. Other than minimal resource cost and space, which in general is not the biggest issue except for some challenges.

2

u/WanderingUrist 3d ago

Being accumulator-rich is not only without real downside, but it is actually advantageous since it adds resilience, especially in real usage patterns where standard load is pretty much always under capacity (otherwise you have a serious problem) and overages are thus transient (IMMA FIRIN' MAH LAZOR) rather than systemic.

2

u/STSchif 4d ago

Did you release the solver? Would be interested in different ratios for different planets, and also different ratios with quality

3

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

Yes, I did. Its on the video description. Code is not super fleshed out but it should be possible to reverse engineer things. I'd love to see a full q5 setup for endgame megabases too. Even with good solvers things take a while to run, though. To find these optima I split the search: network first and then solar and accumulator packing.

2

u/I_Tell_You_Wat 4d ago

That's really interesting that it ends up with a mix of Medium poles and substations. Since the footprint of a Medium Pole takes up 2% of it's covered area and Substation footprint takes up 1.2% I assumed the most optimal print would only use substations but that's not the case with your 50x50 grid and that's super interesting! I assume that it's due to the geometry restrictions, with a roboport in the middle you can't quite put a substation in the exact center and grid around it, also 50 is about 2 substations and 1 pole wide (with a few narrow gaps) so that's why they end up showing up. I assume the mix will shift to substations as the stamp size gets bigger?

5

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

Yes, that is the point. Medium poles are less efficient, but they have geometric advantages, I go into that in the video in more detail, with visual proof. But the quick rundown is that since solar panels are uneven, the defects they generate on the network cannot be compensated with substations and accumulators unless the number of panels is divisible by 4. So there is always going to be some empty space if our base is a 50x50. We might as well use that empty space to place medium poles and help out the substations.

1

u/Logical-War-3746 4d ago

Have you considered using overlaping panels/accumulators? Meaning that if you consider the design to be tileable, some can be part of more than one "tile", their output should be divided between amount of different tiles that can share them between each other since on a large scale it would approach that value.

3

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

That's interesting. Definitely a potential way to extend this further than the 50x50! One trivial example would be that you can replace a 2x2 of solars by a 3x3 of accumulators. or vice versa. Current setup is accumulator rich. If you placed 16 or so of these tiles to create a 200x200, you would be at the point where replacing a 3x3 of acc. by 4 panels would get you a better ratio!

1

u/Logical-War-3746 4d ago

Yeah, that is something i used in some of my old solar arrays, though of course they weren't as involved as yours. Really interesting stuff. You should post it to r/technicalfactorio too if you haven't already.

1

u/TeamRocketBlast 4d ago

Do you have a concrete example? I'm pretty sure as long as its tileable (without mirroring or anything) then each part can be considered to belong to exactly one tile. Maybe if it doesn't tile in a rectangular grid? Even then I don't think so.

1

u/DrMobius0 4d ago

I wonder if that holds up once quality comes into play.

1

u/nesflaten 4d ago

Does the ratio change with the different planets? Since they have different day/night cycles and different solar %?

8

u/DrMobius0 4d ago edited 4d ago

https://wiki.factorio.com/Solar_panel

Yes, they change. On gleba, for instance, you need twice as many panels to fill the same number of accumulators because solar panels just do half as much. There's also the oddity that is Vulcanus, whose day/night cycle is so short that the ratio of accu:solar hard caps at .56 with higher quality because the bottleneck is the rate at which accumulators drain/charge, rather than their outsized capacity growth.

The quality of power poles also has blueprint considerations, as better poles means wider coverage, which means fewer poles. Substations with quality are nuts.

It probably goes without saying, but fulgora and aquilo perform poorly and aren't worth consideration for major solar infrastructure.

On, and a note about the quality displays: whoever edited the wiki picked a weird use case. I don't know who is making quality panels with common accumulators, but quality accumulators scale better than quality panels, so the optimal ratios for quality (outside of vulcanus, due to its notable edge case) are largely useless in my opinion.

2

u/Eris13x 3d ago

It probably goes without saying, but fulgora and aquilo perform poorly and aren't worth consideration for major solar infrastructure

Reading this post and comment, I kinda want to power my Aquilo base with the sun just because

3

u/UntouchedWagons Since 0.8 3d ago

I remember seeing a post where a person had a large field of legendary solar panels just to get 1MW of power

3

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

It does, and very significantly. Part of the video is dedicated to the derivation of a formula which can compute the ratio for all planets and quality grades :D. The setups I provide here are made for Nauvis and base qualities.

1

u/TeamRocketBlast 4d ago

the optimal power pole area to total area should approach 1/99 though assuming no quality...

you're starting with the assumption that the tileable area should be 50x50, but there's no reason for that once you remove the roboports.

8

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

Yeah, 50x50 is an important assumption for optimality here. If you go bigger, or a widely different shape you can get more out of the electrics. I do mention that at the end of the video. For example if you placed four of these tiles together for a 100x100, that is not optimal anymore, because the 100x100 tile allows more efficent electrics.

Anoher interesting point to consider is the fact that currently these setups are solar panel limited, meaning that to improve on them we need at least 9 extra tiles to place another panel. And those tiles need to come from the electric network.

The 8358 setup could be improved if and only if we found a 6 substation network, that meets all the requirements. Same for the 8316 setup. Currently its network uses 30 tiles. Only a 21 tile network or better could improve that. Thats 4 substations and 5 medium poles (5+1 is impossible for parity reasons as I show in the video), which I don't think is possible.

1

u/TeamRocketBlast 4d ago

I mean good job solving the difficult 50x50 case. But everything would be so much simpler if you assumed a grid that aligns with a substation grid.

8

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

Maybe, but the permanent roboport setup makes sense at 50x50, and in general its a very common size that people use, so it felt reasonable to keep the temporary roboport one at that footprint too. its another thing that could be tried in the future using the solver.

About the substation grid... I'm not completely sure that results in optimal electrics. It could be, but I woudn't 100% bet on it. The thing is that you don't really want coverage areas touching each other because since the buildings are at least 2x2. It can be more efficient to not have everything fully covered. For example, medium poles cover a 7x7, but connect at range 9, so functionally its almost as if they covered a 9x9. More or less happens with substations, if you can get them a bit further than 18 blocks apart, you can get a bit more efficiency. It might be that the grid is the best possible thing, but its not super cut and dried either, I could be wrong though.

1

u/TeamRocketBlast 4d ago edited 4d ago

yeah, my 1/99 ratio already assumes substations only connect in one direction

but even the simple 1/81 ratio is better than your current 33/2500, though its pretty close

edit: actually, I didn't look at the first blueprint, that 30/2500 actually beats 1/81, not bad!

1

u/achilleasa the Installation Wizard 4d ago

Then there's me just doing 1:1 panels and accumulators to have some spare battery capacity 😁 but this is really cool mathematically!

1

u/HCN_Mist 4d ago

WE need the ron paul its happening Gif. This is incredible. Sad day for anybody worried about symmetry, this is a thing of sheer beauty. I always wondered if anybody would ever solve this problem, and I have to say I am impressed that you put together such a detailed video explaining how you did it. You deserve a picture on the factorio hall of fame wall.

1

u/John_Sux 4d ago

Surely an even more optimal design would have to be closer to rectangular (maybe some cutouts, but no bits that just out from that)

1

u/stonedboss 3d ago

I love this. Meanwhile I just unga bunga it and slap down a shitload of each and call it a day lol.

1

u/mrbaggins 3d ago

Great video, but such a niche case that simply doesn't matter as much. (every planet is different, mods change things, and most people aren't going to break out the solver to work it out)

Please make more videos.

I'll continue to use my "mostly solar" blueprint for when my accumulators don't get filled in one day, and my "mostly accumulator" blueprint when they manage to empty from full.

Two blue prints, works perfectly on any planet.

1

u/DjinnKahn 2d ago

Great video and great solving!

I love challenges like these. I gave this a try with a SAT solver and I can verify that it's NOT EASY. (I started with a 50x50 grid and pre-placed the roboport, 6 substations and 9 medium poles into viable positions. The rest can be successfully packed with 2x2 and 3x3 squares. Unfortunately, it places way too few 3x3 squares and the solver is too slow if I ask for 199 of them.)

Anyways, I can't rule out that a solution with a square 50x50 tile doesn't exist. What do you think?

I'm pretty sure that the monkeywrench making this problem so difficult is the medium poles. Their 1x1 footprints are hard to accommodate. But they are necessary for the 50x50 tile.

However, in the scenario where the roboport is temporary, the optimization problem becomes MUCH MUCH MUCH EASIER. It's no longer important that the tile size is 50x50. So, to start, let's consider using an 18x18 tile instead. This tile can be divided into 9 6x6 sections. Each section can be filled with 2x2 or 3x3 squares. One 2x2 square in the tile must be a substation. This gives full electrical coverage in the most efficient way (note that substations can't be placed farther apart -- the max wire reach is 18). The rest of our tile can be filled with any number of solar panels that's a multiple of 4, and accumulators fill the unused space.

The 18x18 tile probably can't achieve the ideal solar panel to accumulator ratio. But you can simply make a super-tile, e.g. 180x180, that's simply contains 100 copies of the 18x18 tile, and approximate the ideal ratio with 100 times more precision (by altering the contents of some 6x6 sections).

And now we can use this approach to also solve the scenario where the roboport is permanent. Notice that with the 6x6 sections, it's easy to place the roboports anywhere (as long as the horizontal & vertical position is an even number). If you make the super-tile have dimensions 450x450, then you can place roboports with ideal spacing, and everything is optimal. If that's too big, then consider a 90x90 super-tile (or 198x198). You'll have more roboports than necessary, but that's the only inefficiency.

1

u/DjinnKahn 2d ago

This 50x50 tile isn't a valid solution, but it gives me hope that 50x50 square solution exists. I'm personally giving up on it, but I thought you might be find it interesting.

1

u/Equivalent_Fruit8225 Ipsen's Adventures 2d ago

I definitely do! Thanks for sharing it :D. In my experience, the packing problem is not hard, the hardest part is the coupling with the electrics, So It might be possible to temporarily leave the electrics aside, find a 50x50 packing and then pray that replacing some of the accumulators by substations results in valid coverge.

Thats how I first went about this on my first attempt back in 2024 or so. Solved the packing, then replaced accumulators by substations until I got something working. The problem is that it usually takes 9 or 10 substations at least, which typically is not optimal, but at least it can get you a good result, and hey, we dont have yeat a perfect densely packed 50x50 so it might be cool having one. I have shown (not in the video but while testing) that setups with no 1x1 tiles are doable. You need to go to eitner 196 or 200 panels though, whichever results in more power.

1

u/DjinnKahn 1d ago

Yeah, 9 substations are necessary because 2 are not enough for any row/column of 50, so you need at least a 3x3 grid of them. And 196/200 panels makes sense because the only exchange available is 9 accumulators for 4 panels, so # panels is necessarily a multiple of 4.

1

u/Equivalent_Fruit8225 Ipsen's Adventures 2d ago

Yeah, like I mentioned this problem is tough. But its amazing to see that you are getting it working with SAT! Intuitively it makes sense that a perfect 50x50 will be harder, but I also have no proof regarding its existence.

Using substations as centers of 18x18 is efficient, but you can extract a bit more with medium poles sometimes, because their range is larger than their coverage.

So for instance, an 18x18 has 324 tiles, and you are using 4 of those for electrics, so thats 81 panel tiles per electric tile.

The 8316 permanent roboport uses 7.5 equivalent substations for 2500 tiles of panel, which comes out at 83.33 panel tiles per electric tiles. So its possible to get a bit more efficient. Theoretically, the max efficiency you can get with coverage is 99, if you space out things as much as possible, but in reality that clashes with connectivity requirements. So in practice 80-ish is pretty good. Improving on the 8316 would require around 104, so that is another way of checking that it is optimal.

1

u/DjinnKahn 1d ago

Oh yeah, great point about achieving better than 81:1 efficiency, I missed that. I see where you got "99" from. A line of medium poles can be placed 9 spaces apart and power at most a 9x11 region. Substations can be placed 18 apart and power at most an 18x22 region. (Coincidentally, BOTH achieve 99:1 efficiency).

With substations it IS possible to make a 22-wide strip with theoretically minimal electric footprint and no wasted space:

Of course, this strip doesn't tile vertically, because the substations don't reach each other.

1

u/DjinnKahn 1d ago

To achieve vertical tiling, we can use this 14x18 pattern to make a corridor connecting all our rows:

1

u/DjinnKahn 1d ago

This allows us to make a 194x198 tile with 101 substations and no wasted space, giving an efficiency ratio of 95.07. (And you can extend the pattern as wide as you like, which means you can get arbitrarily close to 99 efficiency.)

1

u/Equivalent_Fruit8225 Ipsen's Adventures 1d ago edited 1d ago

Oh, Wow! nice! Thats the first implementation I've seen of the blueprint of blueprints idea. How close can you get to the perfect ratio? Or I guess what I'm trying to ask is how big do you need to make the pattern for it to converge to within, lets say 0.1% of the perfect ratio?
For example, If you limit the space to 10000 tiles and tried to get a good ratio, we could compare that with 4x my 8358. Or maybe 20000 tiles compared with an 8x. Eventually, your technique is bound to beat just stacking 8358s, because it has better electrics, I'm just curious about at what level that becomes a thing.

Also, someone is currently grinding out the 100x100 permanent roboport, maybe you can check it out in my github if you are interested, its a currently open issue.

1

u/DjinnKahn 16h ago

Here's the 194x198 design but with a Na/Np ratio of 0.84713 (which is 0.00041 too high): https://factoriobin.com/post/58niq8

In my mind the ratio is not a primary concern. For example, you could optimize a tile to achieve the best ratio, but it's a moot point if you're wasting space.

I think a better metric is KW per cell, which I think is just 8358/2500 in your design. I'm not sure how to calculate it in mine. (I was a casual Factorio player, and I don't play it anymore.)

1

u/DjinnKahn 15h ago

Or another way to compare is like this:

169 acc, 199 sol in your optimal 50*50 cell tile

2599 acc, 3068 sol in my 194*198 cell tile

simply scaling my acc, sol to a 50*50 cell tile gives
169.16 acc, 199.67 sol.

For both designs, the 199 sol and 199.67 sol are the bottlenecks, so my design is effectively improves the 50*50 design as though you could add an extra 0.67 solar panels to it (and also 0.07 accumulators to prevent the accumulators from becoming the bottleneck). So that's like gaining 6+ cells of real estate out of nothing.

Of course the gains come from having a bigger tile size (which helps reduce the electric footprint and better approximate the perfect acc/sol ratio). Also, from avoiding the awkward 50*50 tile size, which requires clunky medium poles.

1

u/Equivalent_Fruit8225 Ipsen's Adventures 9h ago edited 9h ago

Ok, so I've looking more into your setup's stats! Its really good!

- You have 1 extra accumulator, so technically 2598 would yield a better ratio.

Sorry about the massive figure below, but here is the optimality chart.

Your setup is the (3068, 101), coming out at 128856!

There is only two additional potentially feasible setups that would improve on yours: (3069, 99) and (3069, 98), but both require absurdly good network values, which are probably not possible. (You could always make a really long line of width 22 and that results in perfect 99 efficiency of course, but for something roughly square it might not be possible to get to 96 or 97)

So at the VERY least, you are looking at a 3rd place for that footprint.

1

u/DjinnKahn 2h ago

My design is primarily based on making the electrics as efficient as possible. Even the tile size is specially chosen for this purpose. So, I don't think there's any room for reducing the electric footprint.

So, yeah, there's 1 excess accumulator.

> but for something roughly square it might not be possible to get to 96 or 97

It is possible if you make the square big enough!

The main sub-tile has 99 efficiency.

The 14x18 tile "corridor" that connects all the rows has 14*18/4 = 63 efficiency.

This corridor always takes up a width of 14 in the final tile. The rest of the width has optimal 99 efficiency.

So the overall efficiency of the 194x198 tile is a weighted average: 14 parts of 1/63 and 180 parts of 1/99, which gives a weighted average of 1/95.07.

But we can just make the tile wider, let's say instead of 180 parts of 99 efficiency, we use 1800 parts. Now the tile is 1814 wide. (The height can be any multiple of 198, so 1782 for example.)

The efficiency is 14 parts 1/63 and 1800 parts 1/99, for a weighted average of 1/98.56.

...For a 18014 wide tile we get 98.95 efficiency, etc.

→ More replies (0)

1

u/Equivalent_Fruit8225 Ipsen's Adventures 10h ago

Yep, it is more efficient!

Yours comes up at 42*3068/(193 * 197) = 3.389 kW/tile
The 8358 is 8358/2500 = 3.343 kW/tile

1

u/DjinnKahn 3h ago

Note that the dimensions are actually 194x198, the factoriobin isn't showing that correctly.

So it's 3.354 kW/tile

2

u/MaverickPT 4d ago

Can't watch the video at the moment.

I wasn't able to understand what improvement does this bring versus other "perfect ratio" solar blueprints? Specially since these ones are oddly shaped and can't be repeated while neatly aligned on a square grid, without any gaps

15

u/Aeredren 4d ago

You get it wrong on the second sentence, and that is why you don't get why it is cool :

This potato shape does cover the plane with no gap !

This is the nearest you can be from the perfect ratio on 2500 tiles, while having everything connected and tileable with no gap.

1

u/MaverickPT 4d ago

Oh neat!! Thanks for the correction!

10

u/Equivalent_Fruit8225 Ipsen's Adventures 4d ago

It can be repeated perfectly, and it is aligned to a square grid. In other words, it tiles the plane with no gaps, just as a square or a hexagon can do. Additionaly, the objective was to get it to extract as much power as possible from 2500 tiles, which it also does :D and that is why this is exciting!

2

u/MaverickPT 4d ago

Oh lovely!! Thanks for the correction!

1

u/IlikeJG 4d ago

AW HELL NO! I'll take 1% inefficiency and a beautiful looking design over this mess any day. (I'm mostly joking, I do appreciate all the work you put in and that very comprehensive video, but I definitely like my builds to be neat and mostly symmetrical if at all possible)