cymatic pattern generation

   7205   6   3
User Avatar
Member
39 posts
Joined: Nov. 2014
Offline
Hi everyone

I'm trying to generate cymatic patterns to then become my source for a particle sim.
Main issue is I'm not entirely sure where to start or how to achieve the effect. Has anyone tried to achieve a similar effect? Te only thing stopping me from painting the pattern or getting an image is that I need the pattern to evolve.

Thanks
User Avatar
Member
670 posts
Joined: Sept. 2013
Offline
Scatter points on a grid and connect them to a solver with an attribwrangle that says something like:
vector bbox   = relbbox(0, @P);
vector source = chv('source');
vector grad   = bbox * (1 - bbox) * 4;
float  dist   = distance(grad, source);
float  wave   = sin(dist * 34) * 0.004;
@P += grad * wave;
Edited by Konstantin Magnus - April 1, 2017 22:54:46

Attachments:
cymatic_pattern.png (312.4 KB)
cymatic2.png (135.6 KB)
cymatic.hipnc (81.8 KB)

https://procegen.konstantinmagnus.de/ [procegen.konstantinmagnus.de]
User Avatar
Member
1739 posts
Joined: May 2006
Online
Awesome fun. Driving from symmetrical points gets some cool results too:

Attachments:
cymatics.gif (3.0 MB)
cymaticish.hipnc (63.9 KB)

http://www.tokeru.com/cgwiki [www.tokeru.com]
https://www.patreon.com/mattestela [www.patreon.com]
User Avatar
Member
39 posts
Joined: Nov. 2014
Offline
Wow these are great! really need to push and learn VEX.
It looks like you both took a similar fundamental approach using the same equation.
I was trying to look online for the maths behind this and was wondering if you guys had managed to find it? as you're both using the same approach or was this already something you had known before hand?
User Avatar
Member
164 posts
Joined: Feb. 2014
Offline
Now if I only understood mathematics!
http://simonfarussell.com [simonfarussell.com]
User Avatar
Member
670 posts
Joined: Sept. 2013
Offline
Here is a nice page explaining some contexts between music and mathematics, as well:
http://tuvalu.santafe.edu/projects/musicplusmath/ [tuvalu.santafe.edu]

More equations can be found here:
http://www.phy.davidson.edu/stuhome/derekk/chladni/pages/theory.htm [phy.davidson.edu]

Not knowing these equations I developed a rather visual approach.

  1. Gradients from left to right, top to bottom
  2. Distance between gradients and a source location
  3. Putting sine waves on the distance
  4. Moving particles along the gradients towards/away from the sine waves

Something very similar can be applied to circles, as well.

#include <voplib.h>
vector bcir = vop_topolar(@P) * {0, 1, 1};
vector grad = sin(bcir * 2.5);
vector source = point(1, "P", 0);
float dist = distance(grad, source);
float wave = sin(dist * 24) * 0.05;
if(@ptnum%2 == 0) @P += grad * wave;
if(@ptnum%2 == 1) @P -= grad * wave;
@P.y = 0;

Attachments:
cymatic_style_rect.jpeg (299.2 KB)
cymatic_style_circle.jpeg (265.6 KB)

https://procegen.konstantinmagnus.de/ [procegen.konstantinmagnus.de]
  • Quick Links