Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I always thought the liquid sloshing would be one of the hardest to simulate (considering how chaotic fluid mechanics is). Interestingly, I think this caused the 2nd Falcon launch to fail (the LOX sloshing).



It is difficult, but there are modeling approaches that work, such as VoF (https://en.wikipedia.org/wiki/Volume_of_fluid_method). Basically, in addition to velocity, pressure, temperature, etc., you store an additional scalar in each cell of your computational mesh representing the liquid's volume fraction. Then, you solve an additional equation to transport that scalar.


Solving the Navier-Stokes equations numerically in 3D is very time-consuming, even on HPC clusters, not to mention the additional modeling required for multiphase flows. Your answer implies that the solutions are obtained almost instantaneously, which is not the case.


I think the reason these kind of simulations are fast enough is because they are very coarse and approximate. Don't think of asking how exactly the foam swirls around the individual longerons, more like a very rough estimation of which side of the tank the liquid is slumped to. Remember it doesn't have to be "exact" just close enough to be useful.

By their very nature model predictive controllers operate in a world where not everything is perfectly modelled. Engineers do their best and whatever is left is the "error" the controller is trying to deal with.


Or you compute variations ahead of time and do a situation based lookup, hoing through loops if a situation ressembles another one.


Maybe they don't need to model the fluid dynamics, they just need to detect the mass movement / acceleration forces caused by it, and use those sensor inputs to inform a picture that's fed into their correction thursting.

Sort of like how you can balance a few pitchers of beer on a tray in your hand by remaining aware of the weight, even when people remove one! hahaha :)


Still if there indeed is "free" mass moving about, you need to make sure your control inputs don't make it slosh harder, so you compensate for that, so it sloshes even harder, etc - basically avoiding oscilation. :)


Yeah..ah, control theory. Heh :)


Oh no, apologies if that was the impression I gave!! I actually perform CFD simulations in HPC clusters, and in fact I'm an admin of the small cluster at my research institute =)

These are indeed heavy computations. What I meant is that VoF is one additional equation to be solved besides the N-S equations (either filtered as in LES or Reynolds-averaged as in RANS), the energy equation, your turbulence model equations, and so on. Certainly, not instantaneous at all, but simply an additional "simple" model that we can hook into our current way of doing CFD.

So, my point was, sloshing is a problem that we know how to simulate, although certainly you need HPC resources. Though, looking at those 100k NVIDIA H100 Elon has, I guess they have them! :P


I'm curious, how long time wise do these type of "heavy computations" take on clusters of HPCs?


It really depends on the problem to be solved (domain size, complexity of physical phenomena such as turbulence model, heat transfer, acoustics, multiphase flows, combustion, etc., number of time steps required...). In our case we perform for instance simulations of turbomachinery acoustics that can take 3-4 weeks running in a few hundreds of CPU cores, combustion acoustics simulations that can take a week or two running in 1k-2k cores...


what if you had 100k H100s


In reality few codes are capable of effectively parallelizing to so many computing processes. But, how cool would it be?


They don't need to solve the Navier-Stokes equations, they don't care how the fluid is actually behaving, they just need to approximate how the mass is moving within a margin of error that the control system can handle.


Maybe the tank is just not a large hollow structure but contains fins/compartments/whatever to restrict the sloshing motion and it's not that big a contribution to the overall motion.

If it's no stronger than a sudden wind gust, it's just something the controller has to be able to take care of without a heads-up.


These are indeed part of the solution and are known as baffles. They have risks of their own, e.g.: https://wccftech.com/baffling-baffles-musk-explains-why-spac...


In the first spacex rocket Musk thought that it was a good idea to not install baffles. He learned from experience that they are indeed needed.


I remember a very similar anecdote about Von Braun & the early Juno/Jupiter rockets - with someone pointing out issues with sloshing on a press conference & Von Braun brushing it off as insignificant.

Then the next launch crashed due to slosh induced oscillation - and the one rocket after that had anti-slosh baffles. ;-)


That’s how tanks in race cars are made. Another solution is fill the tank with some kind of sponge-like material.


Sometimes… the baffles break off, and then become surfboard projectiles inside the tank.

More fluid dynamics


That would be far too heavy in this case. :)


That is how they build the tank in Formula One Racing (and probably many other race cars, I guess)


They probably pre solved a bunch of scenarios and interpolate between them known solutions


That usually doesn't work for chaotic systems.


If the computation is too difficult, another approach is build a test stand and try methods until it works.

Which is why we use wind tunnels, for example.


Wouldn't it burn most of the fuel to mitigate the effect?


At least for the retro-propulsive landing burn, I think the modeling problem is probably aided by the high G-forces that must keep the fuel very close to the bottom of the tank. Even before re-light the booster is falling near terminal velocity (I think?), so the fuel is likely sitting at the bottom.

I think it's a huge problem when re-lighting the engines in orbit, though.


Also IIRC the massive main tanks in Super Heavy should be basically empty at landing & the landings propelants come from a set of small header tabks that are near the central axis of the vehicle & arr completely full. This should reduce or even fully remove sloshing issues at landing time.


Iirc cold gas thrusters are used before ignition to provide some acceleration to force the fuel to the bottom of the tank.


The technical term for that is 'ullage'.

See also: https://en.wikipedia.org/wiki/Ullage_motor


I think some Kerbel Space Program players have attempted to approximate the liquid sloshing as an inverted single or double pendulum problem inside the rocket that the control algorithm has to take into consideration in addition to the primary control of the rocket.


Has it been considered to spin the fuel via some centrifuge mechanism as a way to remove sloshing from the equation, or is that more complex/expensive/error-prone than just predicting it via simulation?


I'm thinking we will eventually end up with "active fuel management" techniques like this for in space vehicles.

Bug tanks make sense there & they might not be always full. So I can imagine all kind of interesting ways you can work with the fuel in zero go to avoid not only slosh but also the need for ullage thrusters. Eq. some programmable nozzles using in-tank gas to nudge liquid fuel blobs to move in the right direction. Or even some nets or bags that herd in the fuel in the middle of the tank + prevent it from directly touching the side, reducing boil-off or refrigeration requirements. :)


Maybe they just use pressure sensors to tell where the fluid is within the tank.

Even a real-time simulation should have some measurements to self correct to some degree. Otherwise it'll diverge.


There wouldn’t be a whole lot of fuel left by the time it’s back to land so likely an irrelevant factor.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: