Looking for a formula...

DSP, Plug-in and Host development discussion.
RELATED
PRODUCTS
User avatar
spaceman
KVRAF
8958 posts since 9 Jan, 2004 from leroyaumeuni

Post Fri Aug 20, 2004 6:11 am

Rozzer wrote:
Big Tick wrote:
Rozzer wrote: To change bpm X to bpm Y, I'd have to pitch-shift by Z semitones.
If I have X & Y, how can I calculate Z ?
Should be something like:
Z = 12 * ln(Y/X)/ln(2)

So if you double the bpm, you're pitch-shifting by 12 semitones. ln is neperian log, btw.
'Tick
Thanks BigTick - I think that's what I'm looking for :)

useless bunch he said :roll:

:lol:
My other host is Bruce Forsyth

VicDiesel
KVRAF
2828 posts since 2 Mar, 2003 from The only civilized county in Texas

Post Fri Aug 20, 2004 6:17 am

Rozzer wrote:To change bpm X to bpm Y, I'd have to pitch-shift by Z semitones.

If I have X & Y, how can I calculate Z ?
Every semi-tone up multiplies the frequency by the 12th-root of 2, call this "r". With the frequency the speed (in any measure) also goes up by a factor of r. Shifting n semitones then shifts by r^n.

So you're looking for the n that makes r^n = (Y/X). The answer to that is the log-base-r of Y/X. Your calculator doesn't have log-base-r, but the natural log ln, so that becomes n = log-r (Y/X) = ln (Y/X) / ln r.

I think.

EDIT this is the same as what Big Tick posted: ln r = (ln 2)/12, which makes it his formula.

V.

Rozzer
KVRian
Topic Starter
1120 posts since 4 Jun, 2003 from Skanky Manc

Post Fri Aug 20, 2004 6:38 am

Brilliant - so if I wanted to reshuffle the formula so that I can know BPM Y after shifting BPM X by Z semitones, what would the formula be?

(god its been a long time since I did formulas)

cheers,
R :) zzer

CypherOne
KVRAF
7936 posts since 18 Feb, 2003 from out there somewhere

Post Fri Aug 20, 2004 6:39 am

are you sure you're in the right job?...




:hihi:

Rozzer
KVRian
Topic Starter
1120 posts since 4 Jun, 2003 from Skanky Manc

Post Fri Aug 20, 2004 6:40 am

CypherOne wrote:are you sure you're in the right job?...




:hihi:
shut it you :P

User avatar
spaceman
KVRAF
8958 posts since 9 Jan, 2004 from leroyaumeuni

Post Fri Aug 20, 2004 6:40 am

CypherOne wrote:are you sure you're in the right job?...

:hihi:

step by step.. year by year..

he'll get there


:hihi:
My other host is Bruce Forsyth

Big Tick
KVRAF
3387 posts since 29 May, 2001 from New York, NY

Post Fri Aug 20, 2004 6:42 am

Y = X * exp(Z * ln(2)/12)

CypherOne
KVRAF
7936 posts since 18 Feb, 2003 from out there somewhere

Post Fri Aug 20, 2004 6:42 am

Rozzer wrote:
CypherOne wrote:are you sure you're in the right job?...




:hihi:
shut it you :P
just kidding, Metal Mickey is fantastic (I never use it but hey...). Sorry kidding again, would I be right in thinking that MM features in Time Lapse?

Rozzer
KVRian
Topic Starter
1120 posts since 4 Jun, 2003 from Skanky Manc

Post Fri Aug 20, 2004 6:43 am

Big Tick wrote:Y = X * exp(Z * ln(2)/12)
Ta muchly :)

Rozzer
KVRian
Topic Starter
1120 posts since 4 Jun, 2003 from Skanky Manc

Post Fri Aug 20, 2004 6:45 am

CypherOne wrote:
Rozzer wrote:
CypherOne wrote:are you sure you're in the right job?...




:hihi:
shut it you :P
just kidding, Metal Mickey is fantastic (I never use it but hey...). Sorry kidding again, would I be right in thinking that MM features in Time Lapse?
I think Timelapse was pre-MM actually, but it does end up in most of my tunes :)

(i was only kidding too ;))

scuzzphut
KVRAF
3723 posts since 17 Apr, 2002 from Scotland

Post Fri Aug 20, 2004 6:54 am

Kriminal wrote:1 semitone = 10BPM
I much prefer this method. :scared:

Rozzer
KVRian
Topic Starter
1120 posts since 4 Jun, 2003 from Skanky Manc

Post Fri Aug 20, 2004 6:56 am

scuzzphut wrote:
Kriminal wrote:1 semitone = 10BPM
I much prefer this method. :scared:
:lol:

Thanks again BigTick - those are working great :)

Paul_FX
KVRian
742 posts since 22 Jun, 2004

Post Fri Aug 20, 2004 8:18 am

step by step.. year by year..

he'll get there
May be a long journey! :hihi:

Paul
__________________________
Paul Chana
Senior Software Engineer
FXpansion Audio UK Ltd

Return to “DSP and Plug-in Development”