Calculus of Variations (in Blender) // Optimization Simulations

  Рет қаралды 12,912

CGMatter

CGMatter

Күн бұрын

Head to squarespace.co... to save 10% off your first purchase of a website or domain using code CGMATTER
🐒 ➟ www.patreon.co...
🌐 ➟ www.cgmatter.com

Пікірлер: 76
@andrewphoto4750
@andrewphoto4750 3 ай бұрын
Bro a shapeshifter every time he post
@gnome3d750
@gnome3d750 3 ай бұрын
😂
@sasodoma
@sasodoma 3 ай бұрын
One thing to note about this iterative optimization is that it doesn't necessarily find the most optimal result, just the one that is better than all of the nearby ones. So for example with the two mountains, you would probably never get the line to cross a mountain and find the best path around, because when it tries to go over a mountain, the middle is still comparatively better.
@OGPatriot03
@OGPatriot03 3 ай бұрын
That just depends on your math, for example you could multiply any z axis distance by some arbitrary value to weight inclines more heavily. If the noise distortion is sufficient then one of the random paths would probably eventually skirt around to either side and that would become the new shortest path.
@globglob3d
@globglob3d 3 ай бұрын
​@@OGPatriot03 but if the noise is too strong and big you'll get poor accuracy toward the end. Ideally the noise scaling and strength should decrease overtime in order to get good exploration at the start and small distortion in the end.
@user-sl6gn1ss8p
@user-sl6gn1ss8p 3 ай бұрын
one approach to help with that which wouldn't be too hard to fit into this would be to always accept changes which reduce the length, but also possibly accept changes which increase it, but with a chance which goes down the larger the increase, instead of simply adding more noise. This means the path still strongly favors becoming shorter, but still retains some chance to wander about. You could also keep track of what the shortest path found was, besides the current path.
@namor_votilav
@namor_votilav 3 ай бұрын
Exactly, why not just blur position while «pinning» endpoints with spline parameter?
@user-sl6gn1ss8p
@user-sl6gn1ss8p 3 ай бұрын
@@namor_votilav that won't work for most metrics, will it? Like, if you're using euclidian, which is the usual, it should work, but for anything else I think it would fail
@jonathan6296
@jonathan6296 3 ай бұрын
I feel like an idiot watching this.
@drokolesko12
@drokolesko12 3 ай бұрын
But in every task you somehow find a smart solution!
@NotGarrettT
@NotGarrettT 3 ай бұрын
I feel like an idiot watching all of his videos
@Casey-nz7xl
@Casey-nz7xl 3 ай бұрын
Just in case you are not aware, you can uncheck "Normalize" on the "Noise Texture" to change the range from (0, 1) -> (-1, 1) which would have the same effect as the "Subtract" vector node. (But with a factor of 2)🙂
@gwentarinokripperinolkjdsf683
@gwentarinokripperinolkjdsf683 3 ай бұрын
thanks for saving me using map range everywhere
@omidpakbin
@omidpakbin 3 ай бұрын
I don't think I will ever going to use this technique, but I still sat through the whole thing, because this is one of my top favorite channels. Dude wastes no time. So on point. Love it.
@shadamethyst1258
@shadamethyst1258 3 ай бұрын
It's a technique used in other areas of computer science, and there are many variations to try to find better extremas
@uriinbar6046
@uriinbar6046 3 ай бұрын
to invert the endpoint selection, i think using a boolean 'not' node is simpler and more elegant than subtracting from 1
@13thxenos
@13thxenos 3 ай бұрын
Damn this is amazing. I had a flashback to my machine learning class where we optimize a function. This could be an amazing learning aid, if a teacher can actually use blender as well as you. And you can actually use better optimizing functions instead of random. Though even in this simple form I had a hard time following.
@fredrik3685
@fredrik3685 3 ай бұрын
In order to reach optimal target faster you can add "temperature" to the simulation. At start the added noise can be high but as the simulation continues it can cool down i.e. the added noise can become smaller and smaller.
@hakankosebas2085
@hakankosebas2085 3 ай бұрын
Could you tell in detail how would implementation be exactly?
@XXXMakabaka1880
@XXXMakabaka1880 2 ай бұрын
@@hakankosebas2085 You could actually find some course on ML, it might talks about it
@juliusfucik4011
@juliusfucik4011 3 ай бұрын
Definately going to use this. This has so many uses in modeling and visualization. 👍
@steamer2k319
@steamer2k319 3 ай бұрын
Pro-tip: decrease the scale of the exploratory offset you use in each iteration. Extreme pro-tip: try to identify linear or convex aspects of the particular problem and then exploit that. In the case of the bubbles, try to minimize tension. Instead of moving each vertex in a random direction, weight each vertice's movement towards neighbors which are near longer-than-average edges.
@AKA-f7p
@AKA-f7p 3 ай бұрын
Nice way to teach Lagrangian mechanics. Can you please do hemeltonian mechanics. Not for me for science.
@Ali-s-s-s
@Ali-s-s-s 3 ай бұрын
I don't know what this channel is about anymore man but I'm always watching nonetheless, this is magnificent.
@harryblends
@harryblends 3 ай бұрын
"It's always the useless things that end up being the most useful" - my mum
@MysteryPancake
@MysteryPancake 3 ай бұрын
can't wait for episode 2 neural network in blender
@samk9632
@samk9632 2 ай бұрын
People have already done this in shader nodes
@MysteryPancake
@MysteryPancake 2 ай бұрын
@@samk9632 lol i'm not surprised
@_spartan11796
@_spartan11796 3 ай бұрын
Great stuff as always!
@gower1973
@gower1973 3 ай бұрын
That last example reminds me of that thing you can do on graph paper, where you draw a line from x1 to y10, then x2 to y9 and so on and it ends up tracing out a curve.
@user-sl6gn1ss8p
@user-sl6gn1ss8p 3 ай бұрын
what do you mean by x1, y10, etc?
@rubenoconnor198
@rubenoconnor198 3 ай бұрын
@@user-sl6gn1ss8p As in draw a line between the points 1,0 to 0,10 then again between 2,0 and 0,9 and again from 3,0 to 0,8 etc.. If you then imagined drawing an infinite amount of these lines (in this case the step =1) but if we used a step that was infinitely small we would get a smooth curve. And also im pretty sure the name of this curve will be a quadratic Bézier curve since what you are doing is essentially evaluating nested lerp functions. It is pretty much a geometric interpretation of De Casteljau's algorithm on paper - very cool imo and hope this helps :)
@user-sl6gn1ss8p
@user-sl6gn1ss8p 3 ай бұрын
@@rubenoconnor198 I think I'm misundertanding something, the way I got it this would make a curve mirrored in the y axis. Which is still kinda cool tho
@potaatobaked7013
@potaatobaked7013 3 ай бұрын
yo calculus!
@infectioussneeze9099
@infectioussneeze9099 2 ай бұрын
ai......
@echauz1
@echauz1 3 ай бұрын
Very nice, but there's no calculus of variations here; that was non-guided random search
@skop6321
@skop6321 3 ай бұрын
math is math it is calc of var at its core sure, its basically a minimization function but it gives results consistent with calc of var
@hakankosebas2085
@hakankosebas2085 3 ай бұрын
Yeah thought same thing, do you know any better algorithm to that else? Any tutorial source?
@sikliztailbunch
@sikliztailbunch 3 ай бұрын
Maxon! Take notes. Why is Blender better in so many features. I just figured you cannot measure surface area in C4D. Lame! Thanks for this great video!
@MooImABunny
@MooImABunny 3 ай бұрын
I really love the thought process here, you learned a very important math/physics tool, and you thought "I wonder if I can do this in Blender?" can't wait to see what you can do with the spectral theorem or like Cauchy's integral formula, or the prime number theorem XD
@maxungar516
@maxungar516 3 ай бұрын
just watched physics for the birds / the double bubble theorem. you may be interested in ideating on that general topic
@repositorytutorial3d50
@repositorytutorial3d50 3 ай бұрын
what about shrinking the edges? wouldn't it make it smoother? I feel that adding a noise will really never converge into the smooth shape that you are looking for.
@panz1skate
@panz1skate 3 ай бұрын
Great tutorial, as always! It seems that the algorithm converges to the local optimum and not to the global optimum. on a flat surface they're the same, but we cannot be sure for other geometry.
@gwentarinokripperinolkjdsf683
@gwentarinokripperinolkjdsf683 3 ай бұрын
This is useful, but you can get similar results by applying a smoothing operation instead of random noise, then you don't even need to test that the surface area is going down. much less general though i suppose
@Jebarrda00
@Jebarrda00 3 ай бұрын
also fyi u may want to experiment with decreaseing noise amplitude with frame number to get cleaner convergence to a straight line
@Jebarrda00
@Jebarrda00 3 ай бұрын
ok this is cool. lots of cool stuff. iterative optimization is very cool and swaggy
@DesignTWO
@DesignTWO 3 ай бұрын
boomer here. Love your videos, but I have to listen to them at half speed cause I'm old af.
@muniz9046
@muniz9046 3 ай бұрын
it would be pretty interesting to see that setup used to wrap around a second object in a more interesting way than the ways we do IRL, i bet it can get a ship in a bottle kinda vibe
@004307ec
@004307ec 3 ай бұрын
Basically a evolution algorithm in blender, nice❤
@PCgmesforever
@PCgmesforever 3 ай бұрын
Question. 3:27 is there a benefit of subtracting the end point Boolean from one opposed to using "not" node ?
@PnkBabyZebra
@PnkBabyZebra 3 ай бұрын
when you stroll by and theres a hyperbolic paraboloid in the thumbnail
@suhailabdulla3075
@suhailabdulla3075 2 ай бұрын
how to create pyro solver in blender's geometry nodes?
@bimalpandey9736
@bimalpandey9736 3 ай бұрын
Look what 16 microseconds of node editor does to a man.
@FORTHEGAME-c1n
@FORTHEGAME-c1n 2 ай бұрын
Why am i feeling Nostalgic?
@deedyago
@deedyago 3 ай бұрын
When does this channel shift to a math one?👀
@lennon163
@lennon163 3 ай бұрын
AI will replace us? :(
@rafliadharivaldy883
@rafliadharivaldy883 3 ай бұрын
bro just like a mad scientist
@drokolesko12
@drokolesko12 3 ай бұрын
My personal genius
@fals_volks3127
@fals_volks3127 3 ай бұрын
Oww just 10mnt Vid 🤔
@GaryParris
@GaryParris 2 ай бұрын
excellent use of math
@sanketsbrush
@sanketsbrush 3 ай бұрын
nice👍👍
@89ZY
@89ZY 3 ай бұрын
Great
@skop6321
@skop6321 3 ай бұрын
man explained calc of var in like a minute and my physics professor never could get anyone in class to understand lol This is very cool, I've always liked calc of var. it creates some very cool shapes
@grantmcgregor1571
@grantmcgregor1571 3 ай бұрын
I really apricated this, I tried doing lattices in blender and was stuck with geometry nodes without using Booleans. This helped.
@pranjalrathor
@pranjalrathor 3 ай бұрын
i love u
@mod3528
@mod3528 3 ай бұрын
Why just do not use Blur Attribute node instead...\
@hakankosebas2085
@hakankosebas2085 3 ай бұрын
Sorry to be greedy but it doesn't make a smooth perfect surface, needs too many iteration, is there a better algorithm?
@steamer2k319
@steamer2k319 3 ай бұрын
Yes. Convex optimization + gradient descent.
@hakankosebas2085
@hakankosebas2085 Ай бұрын
@@steamer2k319 how is that, could share node setup of it with me?
@steamer2k319
@steamer2k319 Ай бұрын
@@hakankosebas2085 Unfortunately, no node group. kzbin.info/www/bejne/d36Zc4xql9mdY68
@dwellersart7538
@dwellersart7538 3 ай бұрын
🙌
@edwardedward6130
@edwardedward6130 3 ай бұрын
This is great! You're the best! Thanks!
@StarkRaveness
@StarkRaveness 3 ай бұрын
nice work
Blender Shader Nodes (beginner ➤ advanced)
1:27:47
CGMatter
Рет қаралды 29 М.
Calculus of Variations ft. Flammable Maths
21:10
vcubingx
Рет қаралды 141 М.
Как мы играем в игры 😂
00:20
МЯТНАЯ ФАНТА
Рет қаралды 3,2 МЛН
The Joker wanted to stand at the front, but unexpectedly was beaten up by Officer Rabbit
00:12
How Strong is Tin Foil? 💪
00:26
Preston
Рет қаралды 135 МЛН
Particle Simulations and 3D Snow // Blender Tutorial
15:54
CGMatter
Рет қаралды 6 М.
Why Do Video Game Studios Avoid Blender?
6:49
The Cantina
Рет қаралды 600 М.
The Secret Behind Photorealistic And Stylized Graphics
35:00
Acerola
Рет қаралды 197 М.
Connect two objects using the Data Transfer modifier, it's cool!
10:10
Fracturing in Blender
7:37
CGMatter
Рет қаралды 10 М.
Calculus in a nutshell
3:01
math-obsessed alien
Рет қаралды 1,4 МЛН
Parallax Occlusion Mapping in Blender // Tutorial
11:09
Default Cube
Рет қаралды 48 М.
How Ian Hubert Hacked VFX (and you can too!)
22:26
InLightVFX
Рет қаралды 235 М.
Mastering Sub-D and Low Poly 3D Modeling
9:48
On Mars 3D
Рет қаралды 96 М.
Aerodynamic Streamlines Simulator | Blender Tutorial
20:03
CGMatter
Рет қаралды 25 М.