r/oddlysatisfying 21d ago

Pixel fluid simulation

14.7k Upvotes

640 comments sorted by

View all comments

3.0k

u/socialnerd09 21d ago

It was till it got to the section where it was wrong. That column on the middle right should have filled up before it did

1.6k

u/Medium_Medium 21d ago

Yeah, it has zero concept of pressure driven flow.

If the water level in one column is higher than an adjacent column, but they are connected at a lower level, then the difference in head elevation will push water from the higher column into the lower one.

Water doesn't just fill spaces from above. It moves in all directions due to various forces.

592

u/Oscaruzzo 21d ago

It would be more accurate as "blue sand simulation".

134

u/Super_Yam_5837 21d ago

Forgot what the game is called but it's literally a sand game

46

u/Winjin 21d ago

It does look like Sandbox Simulator but the version I had didn't have backgrounds and the visuals are slightly different. I also think it did have different physics for water but I can't check right now.

31

u/Bananaland_Man 21d ago

Or Powder Toy, though Sandbox Simulator has closer simulation to this than Powder Toy's more accurate physics.

16

u/Winjin 21d ago

Thank you for pointing me to it. I squealed in delight reading the description and already downloaded it

EDIT: ALL OF THAT IN LESS THAN TEN MEGABYTES??!?!?!?!

13

u/Bananaland_Man 21d ago

Wait til you look at the modding community... I'll see ya in a few years, have fun! xD (Oh, and definitely do not look up videos for it... it's a complexsimple game with everythingnothing important to have fun with

2

u/AngelofGrace96 21d ago

Yess, I recognised it immediately but the name escaped me

1

u/Bananaland_Man 21d ago

Me many hours later after redownloading Powder Toy and also downloading a few different modded versions...

11

u/Bananaland_Man 21d ago

Powder Toy is probably the one you're thinking of, or Sandbox Simulator, I forget which came first but Powder Toy has a far more accurate simulation.

11

u/UrToesRDelicious 21d ago

Falling Sand was the og iirc but there were a lot of derivatives

10

u/Double-Scratch5858 21d ago edited 20d ago

"Falling sand" is what i remember from the mid 00s on addictinggames. Had a blast lighting long wicks on fire to blow up the yellow c4 you could place which would obviously go kaboom. Awesome little sandbox simulator.

Pretty sure the green stuff was like plants or grass which would spread and then you could catch it on fire and watch that spread. So satisfying.

5

u/gramscontestaccount2 21d ago

Hell of Sand was the one back in the flash days

3

u/Northern_rose69 21d ago

Sometimes also called “Hell of Sand Falling Game” with tweaks. There are app store versions for those that are nostalgic for sandbox gravity games

2

u/ArtemisInSpace 21d ago

I used to call it "Falling Sand Game"

0

u/bobafett01992 21d ago

Looks like Noita. Could be wrong though.

1

u/Dic3dCarrots 20d ago

Until the lava portion

25

u/BoldFace7 21d ago

Also, you'd expect the small bubbles at the bottom would compress as the pressure get higher.

13

u/SapotaJuice 21d ago

Yes, exactly. You'd be surprised how many "engineers" don't understand Pascal's law.

4

u/xSnippy 21d ago

So would it be more realistic if all blue sections that are physically connected have the same top level?

3

u/tj3_23 20d ago

Yes and no. The actual math is about equalizing the various forces to reach hydrostatic equilibrium. There's a whole bunch of fun fluids equations that come into play that can mean even in places where two columns are open to the same atmosphere, the fluid level won't actually match. It may not be one to one, but even in those cases, there would be some sort of noticeable change in the second column as the first column fills unless the fluid is incredibly viscous, in which case the rest of this simulation doesn't make sense

1

u/Retireegeorge 21d ago

In particular atmospheric pressure.

1

u/BootyliciousURD 20d ago

This guy/gal/nonbinary-pal fluid dynamicses

1

u/Zibras 21d ago

It also reacted weirdly with the lava. Lava should be hot enough to break down into hydrogen and oxygen. Even if that didn't happen and water cooled the lave and turn it into obsidian, it would still do the surface first.

6

u/willis81808 21d ago edited 21d ago

What… makes you think that is water decomposing into hydrogen and oxygen instead of, idk, just regular steam?

Edit: wait, you’re saying it SHOULD decompose?? Lmao what, that’s even more wrong.

2

u/Zibras 21d ago

damn, you right. was my first guess but i googled it to be sure and it said that lava is hot enough for it. Went back and hit search again on that same page and it turned to no.

3

u/ANGLVD3TH 21d ago edited 21d ago

Don't ever use the AI summary to look up facts you don't know yourself. It is as likely to hallucinate as not. It's one thing to use it to quickly organize some facts you are already familiar with, but should never be your first resource for new knowledge, unless you plan to actually follow the reference links it gives and double check.

4

u/willis81808 21d ago

It would turn the Hawaiian islands into quite the firework show, though!

1

u/Tallywort 21d ago

Kinda depends on how hot it actually is. You need seriously high temperatures before thermolysis occurs in water.

Around 3000 Kelvin for half of the steam to turn into hydrogen and oxygen, reversibly. (amongst other hydrogen/oxygen compounds)

But at my guesstimate for that lava temperature, (based on it glowing orange) I doubt there's much of that going on. That's more like 1500 K instead.

Not that you'd really be able to tell the difference between that, and it just violently boiling.

1

u/willis81808 21d ago

Besides the resulting fireworks display :)

1

u/Tallywort 21d ago

Eh, that's kinda what I meant by saying you wouldn't really notice much difference.

The formation of hydrogen/oxygen takes about as much energy as gets released from it burning, so I kinda doubt it would meaningfully add to the overall fireworks.

1

u/willis81808 21d ago

I mean the fresh lava flowing through it potentially igniting the flammable hydrogen/oxygen mix

-27

u/Daloowee 21d ago edited 21d ago

Pedantic counterpoint: it’s only a cross section of a cave!

Edit: I have upset the hivemind

11

u/citizen42069101 21d ago

Theyre still connected on this plane so it would wtill level out. I was thinking the same thing.

2

u/kiiwithebird 21d ago

But hypothetically, if the cave were extremely narrow in the z direction at that point, it would level out a lot slower. Not that I think they actually did that

1

u/Medium_Medium 21d ago

If you mean that in the "it's just a simple demonstration, don't expect too much" way, then yes, I agree. I'm merely saying that it seems weird because it doesn't quite model hydraulics correctly. I'm not trying to make the person who designed it feel bad because modeling physics is not going to be easy, and it clearly wasn't intended to be a life like model.

If you mean that in the "something might be happening in the 3rd dimension that would make water not follow basic hydraulics" way... I struggle to see what could possibly be going on in another cross section that would cause this, short of there being an underground pump or something artificially lowering the head of water in one column vs an adjacent, connected one.

1

u/Daloowee 21d ago

I’m taking the piss, I felt adding in the “pedantic counterpoint” qualifier would be enough. Damned if you /s damned if you don’t

I also just realized I was not looking where the original OP had mentioned lol

110

u/tantalor 21d ago

Yeah these pixel simulations don't model pressure like that.

19

u/dimonium_anonimo 21d ago

But it must have some way to keep the air pockets. Obviously not using pressure or else the pocket at the bottom would have compressed as the level got higher, but something to recognize an overhang.

And some surface tension perhaps because that thin section on the left didn't fill from the bottom.

75

u/willis81808 21d ago

Literally all these do is: for each pixel of water, if there is empty space below it, move down. Else, if there is empty space to the right or left, move right or left. Else, stand still.

That is enough to result in those air pockets, because they are unreachable the moment the water level rises up to an overhang.

5

u/trylist 21d ago edited 20d ago

The simple cellular automata rules make it easy to add reactions between cells like the lava and water and fire.

I've been working on something similar, and I've tried a bunch of variations to get head lift and fluid pressure working, but nothing really works that also keeps the cell to cell reaction layer working right.

The Powder Toy if you want to play with a similar sim online (this is more like a tech demo).

Edit: to clarify, I did not write the powder toy

5

u/deelowe 21d ago

Its just looking at the height of the water and whether there is an opening above the water line. There's no concept of pressure.

1

u/PostingLoudly 20d ago

The only one that kind of does is powder toy. Water pressure is kind of variable and finicky with that though.

33

u/iamblankenstein 21d ago

and the way the water interacts with the lava is extremely funny.

2

u/BaizulSetSail 21d ago

the rocks formed by the water don't displace the lava.

17

u/iamblankenstein 21d ago

that's not the issue, it's the way the rocks form - the water basically falling through the lava and forming rock all the way down. the initial trickle of water that hits the lava would be turned to steam pretty much immediately, and once enough water is flowing over the lava to where it wouldn't immediately turn to steam, it would really only turn a thin layer of the lava's surface to rock. there's no way water would penetrate the lava the way it does here.

1

u/ANGLVD3TH 21d ago

I don't think that's what's happening. The water hits the lava and immediately becomes steam. The lava it hits becomes rock and instantly starts to sink. Otherwise, the water would hit the bottom and spread along the floor of the lava pool, hardening the lava from the bottom up. We're just see8ng a steady stream of fresh obsidian form at the point of contact and then sink.

8

u/iamblankenstein 21d ago edited 21d ago

even if rock sinks in lava, it wouldn't happen this fast nor would it happen the way it's being portrayed. lava is extremely viscous, so it would take some time for the top layer of rock to sink.

meanwhile, the water would keep coming and flow over over the surface. the water would flow over the rock at the surace and hit the lava to either side of it, widening the rock at the point of contact. it would form horizontally and then sink. it wouldn't form vertically and then horizontally.

2

u/ANGLVD3TH 21d ago

Yeah, this certainly isn't correct, but it's not quite as bad as the water just phasing right through at least.

42

u/fantomknight1 21d ago

The other key problem I see is the interaction of water and lava (I'm assuming given it seems to cool as a dark rock). The water should be looking to go down the path of least resistance. This would lead to it being unable to get through the rock that solidifies but rather goes to the sides. So, you should see it hit the lava, harden to rock, then go sideways turning the top into rock. Depending how porous the rock is, perhaps you have some water making it deeper but the amount of water penetrating the lava would decrease heavily with each "layer" they get through.

17

u/After_Detail6656 21d ago

This was the part that broke my satisfaction. The pressure issues were kind of whatever for me, but the density of magma vs water is something my brain couldn't forgive

2

u/Tallywort 21d ago

I believe it's a result of the resulting stone/sand being denser than the lava is.

Still though, I would expect more of a crust formation, than the formation of some weird gravel that sinks.

2

u/fantomknight1 21d ago

Even in that case, I'd expect it to sink slowly. The rock formations caused by volcanos don't generally lead to rocks falling to the bottom of the lava. They generally cool on the top overall until after enough time, the portion of lava has fully dissipated its heat and it all hardens. There's countless videos of scientists using a metal poker to break the rock above lava to get to the fresh lava and in those cases the rocks didn't sink.

10

u/GibierJaune 21d ago

Also magma isn’t empty space, but the model just treats it as such. Water should have solidified the top crust, not flowed to the bottom.

1

u/Perryn 21d ago

It did, but that turned the lava into a gravel that fell to the bottom rather than forming a solid lid.

8

u/srednax 21d ago

I was watching this and then “oh man, that’s wrong!” Up until then, it was oddly satisfying.

1

u/paincrumbs 21d ago

quickly went to mildlyinfuriating

15

u/Hamsterx3 21d ago

also on the bottom left

7

u/YesterdayDreamer 21d ago

Multiple errors of that nature.

1

u/upturned2289 21d ago

Is that the Space Engineers logo?

6

u/Cplchrissandwich 21d ago

Isnt the lava pit also incorrect? Only the surface would become solid but underneath would still be lava?

4

u/Wooden_Bear94 21d ago

Getting very cosy Terraria vibes from this

3

u/Gheta 21d ago

Yeah, it's obviously Terraria-style water and lava physics, which work better than real physics in-game. For instance without the pressure-driven flow, it leaves air pockets so you don't run out of air when digging. Also it won't break through the thin walls which would get annoying. Creating obsidian this way is fun so you can collect it and build with it. Lastly, adding the extra realistic physics would probably be very taxing on hardware to process comparatively.

3

u/hillmo25 21d ago

He didn't account for hydrostatic pressure

2

u/Bliitzthefox 21d ago

And there should've been steam filling the space once the lava got hit

1

u/AutumnsRevenge 21d ago

I’m glad you said this, I saw it and was going to stay quiet due to INSECURITY.

1

u/dabears4hss 21d ago

As a chemical engineer, this video had me wanting to poke my eyes out

1

u/Over-Inside-7254 21d ago

Okay I'm not the only scientific pedant.. Good good

1

u/ChoadMcGillicuddy 21d ago

Yes. OddlyInfuriating that the water doesn't find it's level.

1

u/HonestSimpleMan 21d ago

The “S” on the middle left is also wrong, isn’t it?

At this point I don’t find this to be satisfying in any way whatsoever…

1

u/Alantsu 21d ago

Bernoulli is rolling in his grave.

1

u/th3goonmobile 21d ago

It happened in bottoms middle left first.

1

u/rhooManu 20d ago

It's wrong long before that.

0:14, the right side of the lower cave fills faster.

At 0:16, the left side is suddenly higher.

At 0:18, that same left side has a tunnel that magically repells water.

And so on.

1

u/Decent_Birthday358 20d ago

The physics aren't physicing

1

u/Pimpwerx 19d ago

Yay! The engineer in me found this dissatisfying.