Godtone (talk | contribs)
m →My Python 3 code: condition i removed assumed that if you want p fixed then assume full p-odd-limit must be achieved
Godtone (talk | contribs)
Line 780: Line 780:
pl = prime_lim(2*edo-1)
pl = prime_lim(2*edo-1)
return firstnp( make_val(pl,ed(edo),warts,tendency), 2*edo-1 )
return firstnp( make_val(pl,ed(edo),warts,tendency), 2*edo-1 )
# NOTE: this* condition is a small optimisation and restriction that says if you want prime p fixed then assume full p-odd-limit must be achieved.
def base_ringer(edo, tendency = 0, fixed_subgroup = [2], initial_warts = None):
def base_ringer(edo, tendency = 0, fixed_subgroup = [2], initial_warts = None):
if 2 not in fixed_subgroup:
if 2 not in fixed_subgroup:
Line 793: Line 794:
wartable = [p for p in deduce_subgroup(f) if p not in fixed_subgroup+warts]
wartable = [p for p in deduce_subgroup(f) if p not in fixed_subgroup+warts]
for new_warts in powerset(wartable):
for new_warts in powerset(wartable):
if( firstnp_edowarts(edo,warts+list(new_warts),tendency,pl)[0] > max(fixed_subgroup)+1 # SEE NOTE BELOW
if( firstnp_edowarts(edo,warts+list(new_warts),tendency,pl)[0] > max(fixed_subgroup)+1 # *SEE NOTE ABOVE
and warts+list(new_warts) not in best_warts ):
and warts+list(new_warts) not in best_warts ):
best_warts.append(warts+list(new_warts))
best_warts.append(warts+list(new_warts))
Line 807: Line 808:
i += 1
i += 1
return result
return result
# NOTE: this condition is a small optimisation and restriction that says if you want prime p fixed then assume full p-odd-limit must be achieved.
# if the val given splits a 2-step superparticular interval into two 1-step superparticular intervals without modification
# if the val given splits a 2-step superparticular interval into two 1-step superparticular intervals without modification
# then it will show that, otherwise it will just show what the superparticular interval is mapped to by the val.
# then it will show that, otherwise it will just show what the superparticular interval is mapped to by the val.