Found bug in "Fluid_wave_simulator"
OriLifschitz opened this issue · comments
Hello
Impressive work, thank you for publishing code @SimronThapa
I believe I might have found a bug in the fluid_simulator:
While the WaveLimit, as defined in the paper "Simulating Ocean Water" by Jerry Tessendorf is:
![image](https://private-user-images.githubusercontent.com/63545001/299696833-7b1dfd36-b613-42ad-9b6c-358d477e46af.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjIwMTE0MjIsIm5iZiI6MTcyMjAxMTEyMiwicGF0aCI6Ii82MzU0NTAwMS8yOTk2OTY4MzMtN2IxZGZkMzYtYjYxMy00MmFkLTliNmMtMzU4ZDQ3N2U0NmFmLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MjYlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzI2VDE2MjUyMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWMwZmRiMjhkMzZlOGY5ODZkNzJlYWMxYjIyOWJlNDg5MmU2YmU1ZTRkMmMwNzJkYmMwNTBjYTNiNTFlZDJmZDUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.h6PqpUzn-pNbpYdHVXnzoMZQMCUspFR2LNpaefeaK3Q)
This explains why visually pleasing results with the bug require using 200[m/s] wind speed.
So the correct code would be:
WaveLimit = L/100
Use L instead of Lx or Lz (Lx=Lz=PatchSize in the simulator code)
Best regards,
Ori.