[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Unusual idea..

On Fri, Aug 08, 2003 at 09:22:47AM +0100, Craig Tinson wrote:
> Guys...
> I've had an idea for a "play project" I can work on at home in my spare
> time.. but before I start on it I need a few ideas..
> Can anyone come up with a theory on how to "convert an mp3 into a
> number"? I know that sounds weird so I'll explain what I mean...
> Imagine converting an mp3 into a wav and loading it into a wav editor..
> you will see a waveform.. there must be a mathematical way of converting
> that waveform into a unique number that will represent that waveform..
> the number would be huge to hold all the information for the waveform...
> When I say "number" I don't mean as in integer, long etc.. I mean as in
> a huge set of individual integers..
> Hope that all makes sense.. anyone any ideas on how this could be done?

It kind of does, because wild ideas like that have occasionally come
into my head; and it kind of doesn't, because such ideas have
generally failed to make any sort of sense when I tried to define them
in a more rigorous manner.

The first thing that comes to mind is the Fourier transform. This
basically takes the string of integers which the .wav file consists of
which describes the waveform in terms of instantaneous amplitude with
respect to time, and gives you an equallly large set of (amplitude,
phase) pairs representing a large set of continuous frequencies. So
you could work out how to tune half a billion organ pipes so that when
you blew them all at the same time for three quarters of an hour it
would sound like 'The Final Cut'.

What do you actually want to do with this magic number? Do you want to
store it in less space than the original? If it's going to store all
the information in the original waveform, it can't be guaranteed to be
any smaller. You will probably also find that existing compression
tools won't do such a good job on it as they would on the raw .wav.

Do you want to uniquely identify a .wav? Have a look at something like
md5sums. This generates a number from the contents of the file which
identifies the file as belonging to one of a finite number of sets each
containing an infinite number of different files, the only one of which
you'll ever manage to find is the one you generated the number from.

Do you want to change the sound of the file in some way? It's probably
easier to leave it as a .wav, and use sox / look at the source code of
sox / read a book on DSP.


Be kind to pigeons
Get my GPG key here: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x21C61F7F

Attachment: pgpfEfwGWjbMc.pgp
Description: PGP signature

Reply to: