[PD] making scales from frequency values

Andrew Turley aturley at acm.org
Tue Jul 21 05:06:04 CEST 2009

```The ratios are maintained because you're multiplying (I'm not quite
sure what you mean by "even out"). But yes, you could also convert to
MIDI and then use addition, and then convert back to set the
oscillator. Six of one, half-a-dozen of the other.

andy

On Mon, Jul 20, 2009 at 7:06 PM, Mike Moser-Booth<mmoserbooth at gmail.com> wrote:
> How do these objects even out your ratios (or, I guess, what do you mean by
> that)? Finding the difference between two frequencies after converting them
> to a MIDI value allows you to work linearly instead of logarithmically,
> which is just easier--well, for me anyway. For example, after converting
> 912Hz and 1081Hz to MIDI and getting the difference, you come up with
> 2.9431. Now you can just think of them as 2.9431 half-steps apart, and that
> one number will work starting from any pitch. If you stick to the frequency
> realm, you'll have to consider them a ratio of 912:1081, which is fine, but
> a little ugly and not as easy.
>
> As far as filling in the gaps, I don't know if this will help at all or not,
> but it might be something to think about. When you look at how the major
> scale is constructed, it can be seen as taking advantage of the first few
> harmonics in the harmonic series. I'll use the C major scale to (try to)
> illustrate. Going up from C in the harmonic series, you get an octave, a
> fifth (G), another octave, a major third (E), and another fifth [1]. Those
> last three notes are a C major triad (C-E-G). Now, stepping back a bit, the
> first note other than C in the series is G, the fifth, or dominant, in the
> scale. If you go the other way, down a fifth, you get F, the subdominant.
> Now, taking the intervals from the C major chord and applying them to G and
> F, you get G-B-D and F-A-C, respectively. The notes in those chords are what
> is used to fill in the gaps, and now you have all of the notes of a C major
> scale: C-D-E-F-G-A-B.
>
> I mention all of that because you're already working with partials. So
> perhaps working with an interval or ratio between two of your partials and
> applying that to another of your partials to generate new frequencies might
> get you somewhere. Or it might suck, who the fuck knows :-). Either way,
> this sounds like an interesting project, and I'd be interested in seeing
> where you go with all of this.
>
> Best of luck,
> .mmb
>
> [1] http://en.wikipedia.org/wiki/Harmonic_series_(music)
>
> J bz wrote:
>
> Dear Mike and Andrew,
>
> Thank you for your speedy responses, though I think I am not explaining
> myself very well.  I don't want to use mtof or ftom as these objects even
> out my ratios.  What I'm looking to do is create a scale (say 12 notes for
> example) out of these ratio's with the possibility of filling in the
> consonant gaps whilst preserving the original frequencies and ratio's.  The
> 1st number in each group is the strongest partial so: 912Hz, 1081Hz, 1211Hz
> etc.  If I'm saying that these frequencies are 'good' to my ear, is there a
> way of creating equally 'good' sounding notes to fill in the gaps in, say
> for example, a 12 note scale based on these notes scaling from the lowest to
> the highest without doing the whole thing 'by ear'?
>
> Cheers for weighing in,
>
> Jbz
>
> On Mon, Jul 20, 2009 at 11:16 PM, Andrew Faraday <jbturgid at hotmail.com>
> wrote:
>>
>> Hey Jbz
>> I'm not sure if this is what you want, but if you convert a midi note to
>> frequency [mtof] then multiply by integers, you get the natural partials.
>> So if you multiply the outlet of [mtof] by 2 3 4 5 and 6. then you can
>> change the multiplication figure, etc. I think that's the effect you're
>> after.
>> God bless
>> Andrew
>>
>> ________________________________
>> Date: Mon, 20 Jul 2009 22:24:05 +0100
>> To: pd-list at iem.at
>> Subject: [PD] making scales from frequency values
>>
>> Dear all,
>>
>> I have five chimes.  I've worked out the frequencies (using Audacity) of
>> the 5 strongest partials of each chime.  I now want to be able to work out
>> how to change the octaves of the various partials?  My original intention
>> was to find the nearest midinote and just use those but after listening to
>> the results I would much prefer to keep the original ratio's whilst being
>> able to alter the 'inversions'.
>>
>> Here's the list that I have already:
>> BT1
>>     912Hz
>>   2434Hz
>>   4575Hz
>>   7175Hz
>> 11584Hz
>>
>> BT2
>>   1081Hz
>>   2861Hz
>>   5339Hz
>>   8325Hz
>> 15209Hz
>>
>> BT3
>>   1211Hz
>>   3196Hz
>>   5935Hz
>>   9199Hz
>> 15206Hz
>>
>> BT4
>>   1347Hz
>>   3553Hz
>>   6569Hz
>> 10128Hz
>> 18139Hz
>>
>> BT5
>>   1812Hz
>>   4699Hz
>>   8525Hz
>> 13264Hz
>> 15469Hz
>>
>> Is there one piece of mathematrical wizardy that can sort this in Pd?
>>
>> Cheers,
>>
>> Jbz
>>
>> ________________________________
>> Windows Live Messenger: Happy 10-Year Anniversary—get free winks and
>> emoticons. Get Them Now
>
> ________________________________
> _______________________________________________
> Pd-list at iem.at mailing list
> UNSUBSCRIBE and account-management ->
> http://lists.puredata.info/listinfo/pd-list
>
>
> _______________________________________________
> Pd-list at iem.at mailing list
> UNSUBSCRIBE and account-management ->
> http://lists.puredata.info/listinfo/pd-list
>
>

```