User:Hkm/Fokker block code: Difference between revisions

Hkm (talk | contribs)
No edit summary
Hkm (talk | contribs)
No edit summary
Line 1: Line 1:
This code can be used to find Fokker blocks.
This code can be used to find Fokker blocks. It requires the [https://github.com/Sin-tel/temper/tree/main/lib_temper lib_temper] library made by [sintel].
<syntaxhighlight lang=python>
<syntaxhighlight lang=python>
import numpy as np
import numpy as np
Line 7: Line 7:
from functools import reduce
from functools import reduce


from temper.lib_temper.temper import cokernel, defactored_hnf
from lib_temper.temper import cokernel, defactored_hnf
from temper.lib_temper.optimize import lstsq
from lib_temper.optimize import lstsq
from temper.lib_temper.subgroup import p_limit
from lib_temper.subgroup import p_limit
from temper.lib_temper.interval import factors
from lib_temper.interval import factors


def prime_factors(n):
def prime_factors(n):