Skip to content

Instantly share code, notes, and snippets.

ic[x_, y_] := 1 E^(-350 ((x - 1/5)^2 + ( y - 1/3)^2))
solnDir =
NDSolve[
{D[u[x, y, t], {t, 2}] == D[u[x, y, t], {x, 2}] + D[u[x, y, t], {y, 2}],
u[x, y, 0] == ic[x, y],
(D[u[x, y, t], t] /. t -> 0) == 0,
u[0, y, t] == ic[0, y],
u[1, y, t] == ic[1, y],
u[x, 0, t] == ic[x, 0],
@patriciogonzalezvivo
patriciogonzalezvivo / GLSL-Noise.md
Last active June 8, 2024 06:11
GLSL Noise Algorithms

Please consider using http://lygia.xyz instead of copy/pasting this functions. It expand suport for voronoi, voronoise, fbm, noise, worley, noise, derivatives and much more, through simple file dependencies. Take a look to https://github.com/patriciogonzalezvivo/lygia/tree/main/generative

Generic 1,2,3 Noise

float rand(float n){return fract(sin(n) * 43758.5453123);}

float noise(float p){
	float fl = floor(p);
  float fc = fract(p);