User:2^67-1/Sandbox: Difference between revisions

Godtone (talk | contribs)
m expressing it as 5 & 212 shows its notability as 212 = 53*4 and as it's supported by many EDOs 212+5k including the highly notable 217 = 31*7
2^67-1 (talk | contribs)
mNo edit summary
 
(32 intermediate revisions by 2 users not shown)
Line 1: Line 1:
=Testing=
A program to find increasingly better EDns in a given subgroup with a given equave ('increasingly better' is given by decreasing relative error)


The '''blackwood-dicot-semaphore''' equivalence continuum is a continuum of 7-limit rank-3 temperaments describing the set of all 7-limit rank-3 temperaments supported by [[10edo]]. Any rank-2 temperament supported by [[10edo]] can thus be represented by a line between two points in this continuum.
<syntaxhighlight lang="python">
import math


All temperaments in the continuum satisfy (25/24)<sup>''p''</sup>(49/48)<sup>''q''</sup> ~ 256/243, equating a stack of [[25/24|dicot commas (25/24)]] and [[49/48|semaphore commas (49/48)]] with the [[256/243|blackwood comma (256/243)]].
def fracmult(a,b):
    g = math.gcd(a[0]*b[0],a[1]*b[1])
    return [a[0]*b[0]//g,a[1]*b[1]//g]


The blackwood comma is the characteristic [[3-limit]] comma tempered out in 10edo.
def reciprocal(a):
    return [a[1],a[0]]


[[User:Godtone]] notes the following JIP's, each one corresponding to a 1D continua contained therein, for which increasingly efficient approximations generally represents increasingly efficient [[7-limit]] temperaments:
def equavereduce(a,b):
* log<sub>2</sub>(256/243) / log<sub>2</sub>(25/24 * 49/48) = 0.8482245109 ; this is the JIP of p=1, q=1 (equiv. to p=-1, q=-1)
    while b[0]*a[1] > a[0]*b[1]:
* log<sub>2</sub>(256/243) / log<sub>2</sub>(25/24) = 1.2766647429 ; this is the JIP of p=1, q=0 (equiv. to p=-1, q=0)
        b = fracmult(b,reciprocal(a))
* log<sub>2</sub>(256/243) / log<sub>2</sub>(50/49) = 2.5796543166 ; this is the JIP of p=1, q=-1 (equiv. to p=-1, q=1)
    while b[0] < b[1]:
* log<sub>2</sub>(256/243) / log<sub>2</sub>(2401/2400) = 125.1... ; this is the JIP of p=-1, q=2 (equiv. to p=1, q=-2)
        b = fracmult(b,a)
* log<sub>2</sub>(256/243) / log<sub>2</sub>(49/48) = 2.5275365063 ; this is the JIP of p=0, q=1 (equiv. to p=0, q=-1)
    return b
* log<sub>2</sub>(256/243) / log<sub>2</sub>(25/24 * 50/49) = 0.8540148427 ; this is the JIP of p=2, q=-1 (equiv. to p=-2, q=1)


Importantly, each JIP corresponds to a ''rational'', so that, for example, (''p'', ''q'') = (1, -2) is equivalent to (''p'', ''q'') = (2, -4) and to (''p'', ''q'') = (-1, 2) '''but not to (1, 2)'''. Note that all these JIPs lie on the JIL (just intonation line).
def tonalitydiamond(a,b,c):
    return [equavereduce(a,b),equavereduce(a,reciprocal(b)),equavereduce(a,c),equavereduce(a,reciprocal(c)),equavereduce(a,fracmult(b,reciprocal(c))),equavereduce(a,fracmult(c,reciprocal(b)))]


Also note that continua separated by 2401/2400 are meaningfully different, but due to the efficiency of 2401/2400, one may want to examine the continuum of all 7-limit temperaments supported by [[10edo]] for which [[2401/2400]] is tempered.
def cents(a):
    return 1200*math.log2(a[0]/a[1])


{| class="wikitable center-1 center-2"
def centslist(a):
|+ Selected temperaments with integer ''p'' and ''q''
    c = []
    for i in a:
        c.append(cents(i))
    return c


|-
def ednerror(a,e,equave):
! rowspan="2" | ''p''
    step = cents(equave)/e
! rowspan="2" | ''q''
    approx = round(a/step,0)*step
! rowspan="2" | Temperament
    error = math.fabs(a-approx)
! colspan="2" | Comma
    return error
! rowspan="2" | <sub>Added by<br/>someone else?</sub>
 
|-
def ednerrorlist(a,e,equave):
! Ratio
    error = []
! Monzo
    for i in a:
|-
        error.append(ednerror(cents(i),e,equave))
| 0 || 0 || [[Blackwood]] || [[256/243]] || {{monzo| 8 -5 0 0 }} || n
    return error
|-
 
| 0 || 1 || [[Archytas]] (squared) || [[64/63|4096/3969]] || {{monzo| 12 -4 0 -2 }} || n
def euc(a):
|-
    total = 0
| 0 || 2 || [[Buzzard]] || [[65536/64827]] || {{monzo| 16 -3 0 -4 }} || n
    for i in a:
|-
        total = total + i**2
| 0 || 2.5 = 5/2 || [[Slendric schisma|Slendrismic]] || [[Slendric schisma|68719476736/68641485507]] || {{monzo| 36 -5 0 -10 }} || Y
    return total**(1/2)
|-
 
| 0 || 2.66.. = 8/3 || 5 & 212 || 72680419155717387/72057594037927936 || {{monzo| -56 7 0 16 }} || n
def avg(a):
|-
    total = 0
| 0 || 3 || [[Slendric]] (squared) || [[1029/1024|1058841/1048576]] || {{monzo| -20 2 0 6 }} || n
    for i in a:
|-
        total = total + i
| 0 || ∞ || [[Semaphore]] || [[49/48]] || {{monzo| -4 -1 0 2 }} || n
    return total/len(a)
|-
   
| 1 || 0 || [[Srutal]] || [[2048/2025]] || {{monzo| 11 -4 -2 0 }} || n
 
|-
best = 10**10
| 1 || 1 || [[Mirwomo temperaments|Mirwomo]] || [[33075/32768]] || {{monzo| 15 -3 -2 -2 }} || n
 
|-
for i in range(1, 100000):
| 1 || ∞ || [[Jubilic]] || [[50/49]] || {{monzo| 1 0 2 -2 }} || n
    if avg(ednerrorlist(tonalitydiamond([3,2],[5,2],[7,4]),i,[3,2]))*i < best:
|-
        best = avg(ednerrorlist(tonalitydiamond([3,2],[5,2],[7,4]),i,[3,2]))*i
| 1.25 = 5/4 || 0 || [[Quintosec]] || 140737488355328/140126044921875 || {{monzo| 47 -15 -10 0 }} || n
        print(i)
|-
</syntaxhighlight>
| 1.33.. = 4/3 || 0 || [[Marvel temperaments#Submajor|Submajor]] || 69198046875/68719476736 || {{monzo| -36 11 8 }} || Y
|-
| 1.5 = 3/2 || 0 || 2.3.5 [[Miracle]] || [[34171875/33554432]] || {{monzo| -25 7 6 }} || Y
|-
| 2 || 0 || [[Negri]] || [[16875/16384]] || {{monzo| -14 3 4 0 }} || n
|-
| ∞ || 0 || [[Dicot]] || [[25/24]] || {{monzo| -3 -1 2 0 }} || n
|-
| ∞ || 1 || [[Jubilic]] || [[50/49]] || {{monzo| 1 0 2 -2 }} || n
|-
| ∞ || 2 || [[Breedsmic]] || [[2401/2400]] || {{monzo| -5 -1 -2 4 }} || n
|}