Code Monkey home page Code Monkey logo

physics-hackathon-2021's Introduction

physics-hackathon-2021

Membrane vibration with energy dissipation based on temperature

magic

Introduction

Make some noise!

You take the sound of a hammer banging on a nail, some random person screaming at an auction or perhaps record the residual noise from the birth of the universe and put these sounds together in a cohesive rhythmic way and, if done right, you might have yourself a piece of music!

The point is: we are surrounded by a ton of cool sounds/signals that can be used to make music. So why not simulate some of the systems around us in a mega bruteforce way and H E A R T H E D A R N T H I N G. This is what we're doing here.

In a normal setting, you don't hear the thermal fluctuations affecting your guitar string or your drumhead when you play it, but let's be hardcore. Would the quality of that sound depend on the temperature? These were some of the motivating questions for our project. By combining the classical vibrations of a surface with characteristic surface thermal fluctuations, we have attempted to model a physically valid membrane which can, in principle, be parametrized to play different sounds.

The Physics

We won't go into a big technical discussion of surfaces here. We'll only talk about the intuitive concepts.

Here we have 2 things we want to model:

  1. The classic motion of an oscillating membrane/surface under the laws of Newtonian mechanics.
  2. The thermal fluctuations that occur in systesm such as the interface between two phases of a substance (say at the triple point or something like that).

The classic motion of the surface is well understood using tools such as the wave equation, however, we decided to do the simulation numerically using Hooke's law and stuff of the sort (for every tiny piece of the membrane)! On top of that, we even added some thermal randomness to the system, where our "elastic" membrane reacts at those random factors.

Concretely speaking, the noise, or thermal fluctuations, are generated using a Monte Carlo and Metropolis Algorithm. Which means that, for every step, at random the fluctuations lowering the energy will be applied with probability 100%, while fluctuations augmenting the energy are applied with a probability given by an exponential decay based on the energy difference.

Method

Using odeint solve in the Numpy library, we were able to model the vibrations on the surface as a function of the tension associated with the neighbouring points. At each time step, the energy functional is evaluated and the next state of that system established with the following formula:

The additional fluctuations add some noise to the classical vibrations that would mimic the behaviour of an energy dissipating membrane (as will be heard?)

I'm realizing I do not understand what is going on nearly well enough....

physics-hackathon-2021's People

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.