New version with better marker algorithm allowing path optimization New data model (x3 perf) Old video • C++ Ants Simulation 1,... Github github.com/johnBuffer/AntSimu... Music freepd.com/music/The%20Lagoon...
Not just behavior, but also life itself also emerges from simple rules: 1) Eat 2) Don't get eaten 3) Reproduce. If you want to get really philosophical, you could argue that what ultimately drives this emergence of complexity is a simple energy gradient; hot sun + cold space = a flow of energy that can be exploited to rearrange molecules, i.e. life.
this is pretty dope. a lot of others have taken inspiration from your work, but the pathing on the ants here is top tier. The ants slowly optimizing the lines seems very organic and authentic too. Please keep extending this silly little project. Add a queen and larvae or opposing ant colonies or something. you slowly perfecting their behavior is very entertaining for me as a viewer.
btw: can you do a maze (with multiple valid paths) and see if they optimize that? You would probably have to set the variable to stray from the path pretty high to make that work but it would be a fun experiment to see.
I saw "Thanks for watching" and was sad that my daily dose of beautiful patterns was over. Then I saw that the "Thanks for watching" was food too, and was happy again :D
It would be cool to see simulations of two separate colonies with separate markers, having them use their own colony's markers and move a way from the foreign ones.
Great content man, I got the first ants video recommended to me and I must say I was very impressed by your work. Keep learning, keep growing. You have a lot of potential.
This makes quite a bit of sense, actually. No use wandering forever in the opposite direction of the food so you may as well go back home and see if there're any existing paths to food
It’s so interesting to see how Nature imitates nature even in a simulation. That test near the end was honestly looking like a plasma ball. It’s so interesting because it’s still based on the idea of take the easiest path with the least resistance which almost everything in existence follows.
I was literally going to ask about path optimization after watching your last video, and here you've gone and done it! Cheers mate, very impressive work.
This is absolutely amazing. The way coding and visual animations were implemented are very impressing!! It's emotional to see other people achieving this kind of skills.
Wow, I've seen a lot of ant simulators but what you've done here is probably the most organic and natural system I've seen. Great works really interesting and beautiful patterns
Suggestion: Enemy colonies/species Description: You have the option to look at the perpective of a ant colony. This will visually make the dots of the other colonies blue. Ants without food may follow the blue trails, while ants with food will avoid it. Two ants of different colonies when close to each other will "fight", which simply chooses a random ant to get removed. If the removed ant had food, there will be a food piece where it died. Added stuff: Dots have colony marker, different ant types, ant home marker, ants will "fight" with random winner ------------------------------------- Suggestion: Regrowth Description: Empty space near food will have a chance of becoming food. There is also a super smaller chance that the empty space will do it without being near food Added stuff: Empty space will become food with a chance of N+(0.125-N/8)*F (N being a small number, F being food nearby, and the chance being in decimal form) ------------------------------------ Suggestion: Reproduction Description: An amount of food at a colony nest will create an ant of that colony. Should work best with the Enemy colonies/species suggestion. Added stuff: The stuff is litterally said in one sentence for this suggestion, why do you need this section?
From my humble point of view, you Jean is an SW artists who matches beauty of C++, state-of-the-art concept and music. Awesome effort and outstanding results. Remarkable YT channel and community. Thanks and have a nice day!
@@HyperMAX9001 >"And hunger for the small creatures. If it goes full, they die." He implemented this in the newer versions but a little differently, If an ant goes too far from either its colony or food for too long it dies
Very cool! One thing that does kind of bug (heh) me is that the ants themselves aren't particularly realistic - most notably, they have infinite stamina - but trying to model that in a way that both performs reasonably well and actually generates interesting results is probably more trouble than it's worth.
Nice... I think i could be optimized somewhat by adding a third marker type of "No more food to be found here", to get rid of the slow decaying food marker. I believe that's how real ants handle it as well. Really nice work ^^
Simple and pretty animations! A question came to mi mind: how many ants do you need in order to get best results using this algorithm? Would it work with a half or a quarter of ants you used in your video? Thanks!
So one thing i noticed that real ants do that your simulation is not doing is surrounding the food source. I hypothesise that they do this to avoid the behaviour that your simulated ants perform when the food source dries up. by surrounding the food source, they can guage how much food is left. if 30 ants can touch the food at once, there is more of it than if only 10 can. This also allows for the ants to take more of the food faster, as more workers can be feeding at a given moment in time. However, I believe the main difference lies with the fact that as the food depletes, less and less workers should be going to the food source. In nature, there are never large piles of ants that burst away from where a source of food source once was, and wander aimlessly around. Great work. I just looked at some other videos showing 2D ant feeding simulations, and so far I believe yours is the most natural. Fixing the surrounding behaviour would definately improve it though.
This is super cool! Has anyone tried adding more pharamones? Tasks? or perhaps an enemy colony? Perhaps a 'death' pharamone that invites others to investigate, and a fighting pharamone. I love ants and my mind is racing! I'll check out the github :D
I have spent at least two or 300 hours just watching ants and how they behave and react to food sources and maybe it's the simplicity of your models that don't take into account any sort of real world geometry but they behave much differently at least the ones I've been observing
World be interested in hearing the differences or seeing a resource that encapsulates them in a digestible but specific package. I'm sure nature gave them every optimization they could.
i think it would be really cool to make them go through a maze and see how they optimise a really complex path like that, you could even have the maze change half way through and see what happens!
Man, great work! Also, it's great that you posted the program but I'm begging you, please please please make a video tutorial of how you coded the simulator...
love 'em or hate 'em, the fact that ants have been doing this type of strategy for centuries makes me amazed... and scared lel, imagine in the past where ants are as big as an average cellphone
Could you make it so that if they often move past some wall they have a chance of removing (eating) the wall block, so over time they can burrow through walls?
can you make a simulation video with like 'difficult terrain' and such and maybe multiple food sources, which also are ranked differently according to their size/benefit as food for the ants?
This is a amazing and beautiful simulation! And inspred by you, I make a simillar Ant Simulation in Unity but I am stucking in some troubles. My ants now can seach for food and build paths between home and foods. But they were not able to optimize the path. Because I am not sure how to "determine the ant's tendency to get out of the way", and I just set a random bool to determine weather should the ant follow the Pheromones or just wander each frame. Predictably it didn't work. May I know how you handle this? And thanks for your time to read this message!
This would be a good program to find the optimal route around a racetrack using the obstacles as grass. Would be cool to see the similarities between this program and F1 drivers around the same track.
Should I ever be asked to come up with an algorithm that brute forces the shortest distance between two obstructed points I'll refer them to this video. Seeing them ants working and slowly optimizing their path is beautiful.
This makes me wonder if you could use a similar technique to implement pathfinding in a 3d environment, though it would only be good for a system that would have the opportunity to use the path over and over again.