![image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F6fe95e9c-f3ab-4da6-b90f-e4d52ff73936%2FUntitled.png?id=10096202-4da1-49a6-a7aa-2e29fa5ab71b&table=block)
I started off by creating grids of cylinders which had the same height. To do this, I used a code box to create a list of x and y values which I then plugged into coordinates. I set all Z values to zero to mark the base point of the cylinders.
I measured the distance between each base point created above to a pebble point (the coordinates of said pebble points are set by sliding bars). I used a distance to function to do this.
To compute the cylinder heights, I multiplied the absolute distance between the pebble point and each base point by a small number (7) to define the number of waves I would like to see. I used a code box to compute the cylinder heights, which is a function of the sine of the distance between the pebble point and each base point, as well as the wave amplification factor and the base offset. For starters, I made the base offset and the amplification factor integer sliders. After playing around with various numbers of waves, amplification factors, and base offsets, I created a simple graph, shown to the right below.
Then, to compute the decay factor, I created an exponential function, ie y=1.005^x, where x is the distance between the pebble point and each individual point, This created an exaggerated effect of decay at the end corners, but also made it difficult to decipher a base offset - so the entire graph became quite tall. This made the ripples less pronounced, but the decay is very clear.
To create the cylinders, I used the FamilyInstance.ByPoint function to set the location of the cylinders, and the Element.SetParameterbyName function to set the height of the cylinders according to the sine function!
Final model geometry, with decay factor:
Result before adding the decay factor:
![image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F5933ebd2-e042-41d3-ae9e-a194cc92c383%2FUntitled.png?id=ce86d72c-88f2-4919-bfd3-90871a2a7fe8&table=block)
![image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F4b7ea294-67df-47b3-a26d-4502f26c455d%2FUntitled.png?id=c5fa31cd-a5bd-4c76-ad72-596ab193aeef&table=block)
Some images of trial and error, while playing around with # waves, amplitude factor, base factor using the decay factor:
![image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fbd92ae24-7b20-46d4-bb6e-083f38d01328%2FUntitled.png?id=1d9f8131-b22c-4002-90c8-8162221616f2&table=block)
![image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F026c9e6a-9411-49d8-9a0e-1e43a43b54e7%2FUntitled.png?id=48704725-f3ee-462a-8bc3-1dba7cdc8ed6&table=block)
Some Dynamo Screenshots:
![image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Faf18d244-ddb4-4e81-892a-113c54e6272c%2FUntitled.png?id=fbad7181-1c99-490c-b101-c60b5ba1a09d&table=block)
![image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fa172fddc-b15f-4caf-ae30-271120831161%2FUntitled.png?id=e46de578-a291-4126-ab4c-ffabb4a17c5b&table=block)
![image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fd52e9279-1fe4-423c-9083-01107ee1cf4b%2FUntitled.png?id=8b192d13-d3e8-4307-9207-e66a92072715&table=block)
![image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fc3c5de08-48fb-4699-a492-11d108293199%2FUntitled.png?id=95c9865b-c3d8-48f0-a047-86ec83f9fdce&table=block)