Constrained tuning: Difference between revisions

Mike Battaglia (talk | contribs)
Simple Fast Algorithm: Better algorithm for general CTWE that doesn't require
Mike Battaglia (talk | contribs)
Line 201: Line 201:
where  
where  


- <math>x</math> is any random tuning with pure octaves
* <math>x</math> is any random tuning with pure octaves
- <math>B</math> is a matrix whose rows are a basis for the subspace of generator maps with octave coordinate set to 0
* <math>B</math> is a matrix whose rows are a basis for the subspace of generator maps with octave coordinate set to 0
- <math>h</math> being a free variable.
* <math>h</math> being a free variable.


Given that, and assuming <math>M</math> is our mapping matrix, <math>W</math> our weighting matrix, and <math>j</math> our JIP, we can solve for the best possible <math>g</math> in closed form:
Given that, and assuming <math>M</math> is our mapping matrix, <math>W</math> our weighting matrix, and <math>j</math> our JIP, we can solve for the best possible <math>g</math> in closed form:
Line 261: Line 261:
  M = np.array( # mapping matrix for meantone
  M = np.array( # mapping matrix for meantone
     [[1, 0, -4, -13],
     [[1, 0, -4, -13],
      [0, 1,  4,  10]]
      [0, 1,  4,  10]]
  )
  )