# Chladni patterns & interference patterns code understanding

I am referring to these patterns code by carlos ponce in open processing. I can’t seem to understand a bit of what is actually causing pattern. Dissecting it bit by bit but intuitive understanding is tricky.
Also the formula for chladni is different then what is essentially used in the chladni pattern code.
This is the general formula I found from internet :
asin(PInx)sin(PImy) + bsin(PImx)sin(PIny) = 0

But the formula used in the code is different than this. Any insight on how the calculation is carried out would greatly help to understand the code. Thanks:)

1 Like

What is your goal? Is it to create cool looking patterns, or to simulate Chladni effects for some purpose, or…?

Where did you find the equation that you provide above?

An important point is that there are two ways to do this – one is iterative simulation, the other is to solve for the final state using a closed form equation. Which approach do you want? Both are discussed here:

1 Like

@jeremydouglass Thanks for the link. Made concept easier to understand. Well I have no specific goal as such for these patterns. Just wanted to understand the logic of coding the patterns which I happened to find on open processing.
Regarding the formula, I found it on desmos
https://www.desmos.com/calculator/rdpbran7og

2 Likes

The first example was a fork I made to try to understand how to make it.

The second was made base on complex functions as a complex potential to represent wave sources. So you can see interference. This leads to certain Chladni patters. I updated the sketch the formula you shared in desmos.

Update: I made another sketch with the function from desmos website.

Cheers!

2 Likes