Skip to content

Commit

Permalink
Fix ploidacot
Browse files Browse the repository at this point in the history
  • Loading branch information
inthar-raven committed Oct 15, 2024
1 parent 7812753 commit 0e61de5
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/guide.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,8 @@ pub struct Ploidacot {
/// The number of parts the voicing of 3/2 is split into
/// If the 3/2 is comprised of several ploids, this is 0 ("acot").
pub cot: usize,
/// Determines the voicing of 3/2 used
/// 0 indicates 3/2 is used; each increment elevates the voicing by a 2/1.
/// Determines the voicing of 3/2 used.
/// 0 indicates 3/2 is used; each increment elevates the voicing by a (2^(1/ploid)).
pub shear: usize,
}

Expand Down Expand Up @@ -144,15 +144,15 @@ impl Ploidacot {
} else {
// Check if aggregate generator can be interpreted as a fifth
for i in 0..gs.len() {
if patent_fifth_mapping + i * n == multigen_class {
if patent_fifth_mapping + i * n / ploid == multigen_class {
let cot = gs.len();
let shear = i;
return Some(Self { ploid, cot, shear });
}
}
let patent_fourth_mapping = 2 * n - patent_3_mapping;
for i in 0..gs.len() {
if patent_fourth_mapping + i * n == multigen_class {
if patent_fourth_mapping + i * n / ploid == multigen_class {
let cot = gs.len();
let shear = (cot - 1 - i) % cot;
return Some(Self { ploid, cot, shear });
Expand Down

0 comments on commit 0e61de5

Please sign in to comment.