I would like to calculate the twists of secp256k1 up to isomorphism (find one representative for the quadratic twist, and so on). Therefore I tried the function
E.quadratic_twist(d) and E.sextic_twist(d)
with E = EllipticCurve(GF(115792089237316195423570985008687907853269984665640564039457584007908834671663), [0,0,0,0,7]).
The problem is that I don't understand what the variable $d$ does in this function.
I tried different $d$ and found a quadratic twist with $d=3$ $E' : y^2 = x^3 + 12096 = x^3 + 7 \cdot (12)^3$ and tested that $12$ is square-free in $\mathbb{F}_q$, and two sextic twists with $d=3,7$: $E^{d_6}_1: y^2 = x^3 + 7\cdot 139968$ and $E^{d_6}_2: y^2 = x^3 + 7\cdot 326592$ with $139968$ and $326592$ square- and cube-free in $\mathbb{F}_q$.
But my method is rather brute-force, since I don't really understand the function, and I am also not sure how many different sextic twists sexp256k1 has (up to isomorphism). I think it is two, but I am not sure.
My next question is, if there is a way to calculate the cubic twist with a similar function?