Creating a simple animation from a buggy simulation. 00:00 Hello world 00:50 Instabilities 01:40 Simulation parameters 02:20 Objects color 02:45 Results github.com/johnBuffer/NovaBug
@@d9gepro2 To be honest, it kind of is. This isn't THAT far off from being a reasonable approximation of a star. The main difference is that the overshoot is the source of the extra energy here instead of fusion, but both happen because of particles getting shoved together too hard.
looka like the sun, but just too tiny too exist. maybe with a billion paricles and some kind of particle fusing, one could try and error its way up to near a real sun. Also about the star Canis Majoris ,its form may be something very similar to 6:42 .
This is probably one of the most beautiful and impressive simulations I've ever seen. I'm pretty sure humanity has discovered the secret of the universe by now, but counted as a memory leak on their program and just fixed it away.
You're kind of talking about a counter argument to dark matter there. We can't explain the exponential acceleration of the universe's expansion under the standard model alone, nor does it match up with the amount of matter we see in the observable universe, which can primarily only mean one of two things: 1) There is a hidden force, possibly a form of exotic matter/energy, which is driving expansion ever faster 2) We done fucked up and magic numbered ourselves into a corner because there is something fundamentally wrong with the standard model. We've seriously misunderstood something at the bottom, and it's causing predictions to collapse at the top.
@@Rudxain We could be forgiven for that since physicists also often use them interchangeably unless specifically discussing both as separate phenomena. There's a lot of argument that they're ultimately the same thing exerting parallel forces. We don't really know one way or another yet.
@@ledumpsterfire6474 But, AFAIK, dark matter only has "normal gravity" while dark energy is kinda "anti gravity". But we don't know enough about neither, so maybe they're connected and we don't know it yet
lovely, absolutely stunning Technical question: How does one even stabilize the energy at such high pressures? This is a really valid stress test for any physics engine
off the top of my head (and I'm no specialist : p), you can fiddle with the step sizes (either just reduce them all around, or use a method which calculates the necessary size or a predictor), use higher order methods (which take into account the rate of change of acceleration, and it's rate of change, etc), or try to force constraints (like re-normalizing energy or enforcing minimal distances and etc). The first two options can get really slow really fast. The last will introduce other unphysical behaviour. So yeah, as far as I know there's no way to really avoid this given finite time and an arbitrarily large amount of objects : p
"Sub stepping" (ie dividing each simulation step into N substeps with a dt N times slower) is a first possibility which in the end multiply the cost of the frame simulation by N but it's easy to add and quite robust (it also allows for faster moving object without tunneling effect). Another approach which can be combined with the previous one is multiplying solver iterations (we solve the contacts multiple times in each simulation step) which is a bit less costly than real substeps because spatial partitionning doesn't have to be done at each iteration. But as @yout ube said there are no miracle solutions I guess
@@PezzzasWork I understand about that solution, just increase iterations and you're gtg. But at some point it has to stop, even the universe has a plank time. Is there any way to deal with this issue that doesn't involve adding indefinite calculations for precisions? Maybe not using absolute values for speed and such but use relative values instead? Just guessing.
@@EbonyWolf. yes there is an exact method that's quite efficient. You can calculate the exact time of the next collision (because you know all object future paths, and can do some maths on it). Advance all objects to this moment, perform the collision and repeat. This way you aren't limited to the predefined regular step interval. Another, hybrid way is to use step based iteration, like normal. But once a collision (overlap) is detected; calculate back in time the exact moment of collision, and perform the calculation as if it happened already at that point in time. This is what Rocket League does.
This is like when artists got so good at making art look realistic that they had to start making it ugly and abtract in order to show off how good they were. Pezzza is transcended beyond simulating real life, now he makes art out of "buggy" code.
This would make a really interesting screensaver, at least, so long as the number of objects didn't actually increase the power usage whenever it turned on.
To echo what others have said this looks like a stellar simulation. The energy released at the core of a star is constantly pushing outward trying to tear the star apart, but the mass of the star and resulting space time distortion that it creates (i.e. gravity) is simultaneously trying the crush the core into a smaller more compact state. Eventually the two forces reach a balance called "hydrostatic equilibrium" where the outward force is equal to the inward pressure. Amazing that this was created via bug.
every once in a while i just binge your videos and recently these beta test videos where you discuss the variables and how they effect the objects really give me inspiration to add more to my game. This video and your newest one about smoke have given me two wonderful ideas. Thanks for all the amazing work you put into your videos.
This guy make a virtual firework, or the star death simulation, using a bug. Just incredible! Don't be afraid to make mistakes, kids. Learn how to turn them into greater things.
I once had a small, broken lennard-jones simulation that kind of looked like a dbz fight, but this is at another level : ) I'll check the repo when it comes out, but what method did you use for the movement?
Omg this is so amasing!!! I would be also amasing to see collide two heap particles each other with no speed or pressure visualization but rather with acceleration visualization. Acceleration visualization I mean by sum of all the acceleration vectors what effecting a particle. Keep in mind that the acceleration vector length can change very rapidly, so if you visualize it, it can create some crazy flickering, so it would be also amasing to see if you implement it in a way that the particles color changes not just by their current acceleration vector lengt, but how much time the particle experiencing a given acceleration. Like if they being" heating up" when experiencing a great amount of acceleration and that "charge" being dissipating slowly by time. Please try to create something like this it would be amasing to see it.
This reminds me of my experiments with Algodoo.. I wish I could program simply so I could make my own simulators; not only to break limitations of Algodoo and visualize better, but to increase performance, as algodoo simulates many things that I often intentionally reduce to 0 (thus disabling them; but its still simulating the calculations; they're just multiplied by 0 in the end), and getting rid of those unnecessary calculations would be nice.
Most commercial game engines like Unity have visual scripting tools for people who struggle with programming, I recommend you check those out if you're interested.
try processing, it's pretty quick, easy and lightweight, you should be able to do some neat simulations withnit (not as good for more general stuff though keep in mind)
I've managed to get similar results in the past, though on a much smaller scale, and I think there's something really beautiful about systems that oscillate between chaos and order. It kinda reminds me of life and death. A clump of particles explodes and gives way for others to form and so on forever.
accurate representation of a star, the core is where the fusion takes place and that keeps the star from collapsing, meanwhile, the gravity keeps the star held together
Inspiring! Would be interesting to see with additive shading - usually works best with very low RGB values per particle, and just a smidgen of desaturation, so not purely primary colors. Though often requires quite small particles, a good deal of overlap, and very high count (millions), for smooth effects.
This is fascinating to me (I just found this channel and am binging through it now). This simulation uses a linear force law (which arguably makes "physical" sense in a 2d simulation), but I wanted to try an inverse square law. If you do that (changing a single line in the code), you get much less spectacular results, the particles settle nicely in a clump, but you do still get occasional eruptions from the core, these go into random directions much like solar flares, and they create shock waves, sometimes resulting in secondary eruptions.
Very interesting how it forms hexagons after bursting out, you can see it many times around 4:43 through 5:08 If I had to guess why, it is because the spheres are crystallizing into a hexagonal lattice, and drawing a line through opposite vertices of the hexagon corresponds to the close-packed (highest density of atoms in a straight line) crystallographic direction before the explosion. In the close-packed direction of a crystal, the atoms are closer together, so compressive stress is higher in those directions. The explosion would happen along the close-packed directions before any other direction, and that leads to those atoms being farther out in hexagonal close-packed directions because they got a head start. Alternatively, you can think of it as the pressure equalizing in that direction through an increase in volume. As evidence of crystallization in your video, you can see a hexagonal lattice in the small-scale simulations (0:12 through 1:01). You can even see vacancies and dislocations (crystallographic defects) at 1:12. A really good video to illustrate those defects is by Alpha Phoenix, here: ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-sn1Y6zIS91g.html Or you can watch this video from the 50s by a nobel prize winner, which is the original experiment Alpha Phoenix replicated: ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-UEB39-jlmdw.html I've got a background in materials science, had to put in my two cents because the bubble experiment is ubiquitous in the field and this video gave me strong deja vu! You made a great demo
dude, you should totally use newton's gravity laws and make them attracted to eachother instead of the center. it would make a similar but much better effect. plus it would basically be the big bang when it explodes. amazing video!
Much better bugged art than that one weird cluster of frozen floating cars that accidentally became an abstract sculpture in Cyperpunk 2077! All glitches could be art themselves... so long they don't entirely corrupt the whole software!
If you give each particle an attraction force to every other particle within a certain radius, you get a pretty accurate visualisation of stellar nucleation, lifetime and finally supernova instead. The explosion of particles after the system is "overleaded" is the result of a principle that works actually in pretty much the same exact way in reality (there's obviously differences, but on a macro level it's basically what happens).