Noise Cancellation question-creating an inverted sound wave

Effects, Recipes, Interfacing with other software, etc.
Forum rules
If you require help using Audacity, please post on the forum board relevant to your operating system:
Windows
Mac OS X
GNU/Linux and Unix-like
Post Reply
Jayson79
Posts: 4
Joined: Sun May 27, 2012 1:52 pm
Operating System: Please select

Noise Cancellation question-creating an inverted sound wave

Post by Jayson79 » Sun May 27, 2012 2:03 pm

My neighbor has a HVAC unit that produces a regular low-frequency bumping sound in my bedroom. I would like to try creating the inverse of this sound wave and project it back towards the HVAC unit using outdoor speakers and an mp3 player. I imagine using windows sound recorder (or Audacity I suppose) to record the sound in my bedroom when their HVAC is on, then use use Audacity to invert the sound pattern and record to mp3. But I've never used Audacity or any audio editing software before, it's an entirely new world for me. Can someone please instruct me how to create the inverse sound file? Or does anyone have experience with something like this and can me if I have any flaws in my way of thinking, or something I could do?

PGA
Posts: 695
Joined: Thu Jan 19, 2012 9:16 pm
Operating System: Please select

Re: Noise Cancellation question-creating an inverted sound w

Post by PGA » Sun May 27, 2012 2:24 pm

If you are trying to cancel out the sound by creating the exact inverse, I think you will need to be able to play it back EXACTLY in time and, I suspect, EXACTLY at the same amplitude, otherwise the two sounds will not be a perfect match for each other and will slowly drift out of synch. Whilst creating the inverse signal is feasible. I think your approach is fundamentally flawed.

kozikowski
Forum Staff
Posts: 68942
Joined: Thu Aug 02, 2007 5:57 pm
Operating System: macOS 10.13 High Sierra

Re: Noise Cancellation question-creating an inverted sound w

Post by kozikowski » Mon May 28, 2012 1:11 am

It's a nice concept. If you do manage to get the cancellation to work (see PGA) it's only going to work in one place in the room -- the place where you put the microphone. The room contributes to sound change as you move around, so the cancellation sound is only going to be valid for one location. Anything that changes in the room will change the cancellation characteristic. So don't roll over, and always read the same size book.

That in addition to the sync drift problems.

There is room for speculation about putting a powerful sound system at the pump -- cancel the sound before it leaves the pump area. I can see one practical problem with that. The only way you know what the pump sounds like in real time is to put a microphone there and the only way to cancel the sound is to feed that sound back to the area of the pump. Any system change at all and it will go into feedback.....eeeeEEEEEE

Good thought experiment, though.

Sound Cancelling headphones work because they have a captive workspace (your ear) and a microphone not in the workspace.

Koz

Jayson79
Posts: 4
Joined: Sun May 27, 2012 1:52 pm
Operating System: Please select

Re: Noise Cancellation question-creating an inverted sound w

Post by Jayson79 » Mon May 28, 2012 1:56 am

your responses bum me out. but makes sense I guess. I wasn't planning to sample the outside sound and try to quickly send a cancelling wave back to the HVAC unit. I planned to just play in a loop an inverse sound pattern based on a recording taken from inside the house, mp3 player and speakers located outside the house pointed back at the HVAC unit. I wouldn't mind trying it for the heck of it though. How can I create in Audacity the inverse wave of a recorded sound?

steve
Site Admin
Posts: 80752
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Noise Cancellation question-creating an inverted sound w

Post by steve » Mon May 28, 2012 2:36 am

See "Destructive interference" here: http://en.wikipedia.org/wiki/Interferen ... #Mechanism

To cancel out a sound completely you need an identical sound that has a "180 degree phase shift", or in other words "inverted".
Audacity can invert a waveform with the "Invert" effect (Effect menu).

The problem that you will have is that (a) the recorded sound will not be identical to the live sound (there will be small but significant differences) and (b) even if you did have an identical copy of the sound you have no way to synchronise the recorded sound with the loud sound so that they are exactly 180 degrees out of phase with each other.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

Post Reply