Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrectly marks non-TU balancer as TU and non-TU as universal #15

Open
EMeindertsma opened this issue Jan 26, 2024 · 5 comments
Open
Labels
bug Something isn't working

Comments

@EMeindertsma
Copy link

First Blueprint:

0eNqlV8GOmzAQ/RXLp1aCCBsSIMdKu1Klqqe2l7ZakeAEq8Yg2ySNovx7DaxSkmUTD7klxvMeb8bzGB/xSjSsVlwavDzinOm14rXhlcRL/OmAnjNtMpk/c13wqtEz9EuGPkXfvqNVJjK5ZgrxDeKyboxGmWJo0wiBKoVYWZuDh1aNQaZQVbMt7BZf8JIblrcxpmBI85wNg4tMbPwOwXJ2O0qe5+J1D+K6h/+gWC2yNWt3lGjPTYEOTIhqj1ZMWChTIc3Yxxn2MF9XUuPlzyPWfCsz0Yo0h5pZdTuuTGNXPCyzsl3od/hP+GTjZM7+4iU5eYDIH4NICor8PIgMQZFfBpHR6beHmTTccNaL7v4cXmRTrpiycs7RRmVS15Uyfpsyi1pXmvdlP2IL5ZMFDWdzDx/a30ESzeaWJ+eKrftdnb4reAqCp7fgoxH48Ay/safSd+GIBhzURUJ0yaFrwY2xD+4qoFfYHq4aYw/ti+2tSlkKCynYxuAR0vmZtLGFVFvbLjJ3LEzYqXo9JD3lGMUCnrsQmrt4cvlDF/gEUppgiH4fOwW9OoFmhgST8Z1SQwi4vCQFi6CAApDkZm90fu7SGuTBpg+clEWPkRAnkvlUawkcrEXxbTGewKvOhzvMW3Vnv+nKOMoaP+Y3bmUDOcKwqYgDeDolb4Fb3t73aRrAExfcStzYh5SC5oCLVnYqDAU5RQorDA0h4AsgONwJSAx1Agpxggv4wAEc/qUnc7CC+DESt1OUTB+L4nQ4Fr1rUzSdOrLEybWExdjEGkwduDv8MUQydZJ4Tcm9GZtOxnfLSPiQv70VMXZywuihcciRZA4nSW6T2NubvR2XFvH/pdzDIrOAdu1pxwVqL99fmdlX6o99tGNK97EJieKUxglN4yBJT6d/mF8apw==

Test results:
Belt-balancer: Yes
Input-balanced (if belt-balancer): No
TU (if belt-balancer): Yes
Universal: Yes

This blueprint is not TU however; if the two outer input belts receive only 15 item/s and the inner receives the full 30 item/s, the output is still limited to a total of 45 item/s. See https://imgur.com/a/DVMmcIK for a visual.
I think this might be because the balancer uses mixed belts: most are red/fast, but some are yellow/normal.

Second blueprint:

0eNqlWk1v4zYQ/SuETi1gB/wQRTLHAlmgQNtTt5e2WMg2E7OVJUGikjUC//fS9mJXcaTujOYSJA45j/PImXkc8zXbVINvu1DH7P412/l+24U2hqbO7rOfjuxD2cey3n0I/T40Q/9XrdaS/f6RbcqqrLe+Y+GRhbodYs/KzrPHoapY0zF/aONxxTZDZHHfNcPTPg1ZV+EQot+d58S9Z+Xun3Lr6zg2sC+rx/XFSkK9jGrSj+46hIX+ivBD59sqzT0POLCXEPfs6KuqeWEbXyVLsWG99z/eZassbJu6z+7/fM368FSX1dnLeGx9cu85dHFIn6yyujycP7iOWD9kpzSv3vnP2b04rRAz/xjNlKiZP49mKtTMX0Yz89PfqywxGmLwV6cvfxw/1cNh47vkztfZj2lj17Er675turg+85ZMt00frpv/miV7a1EocadX2fH8u+D8TiewXej89jrq4uQNhnyL0bdViDH9Y9I6H1v/vm2FX/8YQdyuv5jAyGkcvcPIJzA0giNpcRwV6PVLh+XI4DEsFsPiMczNWZ2w6mhWQSsXHA+isWEm8LEs8/8DmTqnQuKDofgKwp0FebIgqg0aZEFYazSIxoPkaBB8gCuFBsFHuJJoEEtJ51AQh6lHYmTeAWodpyRboAdSULItFETSPHEgEHykS3Q6kTklxUNBNA0ERldBowsGYijFCkqXpRQrKIijeeKmFYO6ifEhae3uKV1q6h1w9e/2IZ3QL6r+cq/JplAXBP1tlp8yi1Hn8k1GB6hzRVsz6LyqBeEt0SAogc6RNBUY48iKpAym3I2PfwEwbjHGxyFgAMZRhVrhVp5zmmgykFOTC5pogoFIyv00kQUCUQty3htt9h7m+zkvz2muGciVJl9494Yds4KmomCbY2ggMJosTXQaUKsFE/JvpA1gLzSnqSeQB1rQdCAMRNKETTGtBbSiibI5szlttTBKNG3toFSriyXKT8GyYDPEmTSozVKNBokKS9NoMOIWKHGOTYPFgvgWWE8KfHwLi/YEI8qFw8mqQtE8gNGU01p4OQhE00A0CKSgdTxhnhgaCMwTu/QmkAOMO1qnE0ST4TQQEE1GLL12AGgyknYjgNGkaCAwmojaHOaJpjWEYSAFzRMYXYbmCQzELr3KQI6uo90yQHthif1zEE1WLL1lAGiyknYBgNGkaCAwmnIMTeN6ATFO1Ot6+q5hC5qazWfMGlqPEbapRCUO21S3tNcIMO44TebPbKoTS7uMCrBmSWsESgjrjliRYSDEiixn2Nc0swq09oLaX1QL+ouO2DibY4zYKpOQhocjlmPQtgjOaYVGwp7HCFpnDohC7JoBURT120E5/+3gfI9IcGKXTYGe/3BN9U4t6YAJXtAK8EykCk4s7GrOLrGWz9p1NNkkYC/JOG31QBRB4/6Mcn7fGqI/JBvf3i2vsqpMJtJnD8++Zr82nWcPz6Fi57fKv/n40nT/pkHPvuuvq7MiN04aK53h1p1O/wG71Gqk

gets results:
Belt-balancer: Yes
Input-balanced (if belt-balancer): No
TU (if belt-balancer): No
Universal: Yes

whereas it has a throughput oscillating between 45 and 60 item/s if the inputs that are next to each other receive 15 item/s each, and the other input receives 30 item/s, so is definitely not universal/UTU. Does the universal proof assume the balancer is TU?

@alegnani
Copy link
Owner

Thank you very much for the report. There is definitely some digging to be done for the first blueprint.
For the Universal proof I only considered if it still functions as a belt balancer. It does not assume the balancer to be TU but it also does not prove that the balancer is TU.
I think the problem lies with the terminology: does a universal balancer have to be throughput unlimited in all the cases? Or does it make sense to split the definition into universal and UTU?

@alegnani alegnani added the bug Something isn't working label Jan 27, 2024
@EMeindertsma
Copy link
Author

EMeindertsma commented Jan 30, 2024

You could have different definitions for universal and UTU, but I think it would be best to discuss this with the rest of the Factorio community. If you do choose something different it should be clear in the program. Edit: I do see this distinction being made on the wiki though, but this Reddit post pocarski calls his UTU balancer universal.

If the universal proof assumes that the setup is a belt balancer, then I think you should state this in the UI, as you did with the other proofs.

@EMeindertsma
Copy link
Author

EMeindertsma commented Feb 3, 2024

Also, since were talking about terminology, does the TU proof require that the setup is a balancer? Or can it also check if non-balancing networks are TU? Such networks have been repeatedly explored in the past (flow router, TU imbalancer, compressor, throughput unlimiter) and are somtimes useful, though if you don't care about the number of splitters, they are trivially easy to design.
In that case you could change the text to "Is it throughput unlimited?" From the limited testing I have done it does seem to work this way.

@alegnani
Copy link
Owner

alegnani commented Feb 3, 2024

I think the best thing would be to use the terminology of the wiki as that should be the most consistent one.

  • Universal: the balancer works, as a balancer, if any combination of inputs/outputs are blocked. (does not imply throughput unlimited)
  • Throughput unlimited (TU): "Balancers that are throughput limited may not be able to provide maximum output if one or more outputs are blocked"
  • UTU: a universal balancer that is always throughput unlimited in every configuration it is being used in

If the universal proof assumes that the setup is a belt balancer, then I think you should state this in the UI, as you did with the other proofs.

This is not assumed as it checks that that for all possible inputs and outputs being blocked it is a balancer. This also includes the case in which nothing is blocked.

Also, since were talking about terminology, does the TU proof require that the setup is a balancer? Or can it also check if non-balancing networks are TU? Such networks have been repeatedly explored in the past (flow router, TU imbalancer, compressor, throughput unlimiter) and are somtimes useful, though if you don't care about the number of splitters, they are trivially easy to design. In that case you could change the text to "Is it throughput unlimited?" From the limited testing I have done it does seem to work this way.

Cool! I didn't think about these. I think the proof should work nonetheless. Do you mind providing some blueprint that could be added as tests? That would be great!

@EMeindertsma
Copy link
Author

I suggest:

  • UTU: the balancer is universal and TU.

the terminology of the wiki as that should be the most consistent one.

True, but emphasis on 'should'. At least 2 of the 4 links in the further-reading section lead to outdated documents (mostly that they state that UTU balancers are impossible), so I think it doesn't fully reflect current usage.

Flow routers:
https://www.reddit.com/r/factorio/comments/72bki0/throughput_unlimiters/
https://www.reddit.com/r/factorio/comments/7skwms/for_priority_splitmerge_splitter_square_is_more/ -simplest designs
https://factoriobin.com/post/q0IGjUI3 from https://forums.factorio.com/viewtopic.php?t=100671

They should all be throughput unlimited, but I haven't tested them. The first two links don't have blueprints sadly, and the third is all with express belts, so probably slow to check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants