First time here? Check out the FAQ!
answered 7 years ago
I would suggest something like this
k=2 Q=QuadraticForm(ZZ,2,[1,-1,1]);Q m=Q.short_vector_list_up_to_length(k^2+1) m[k^2]
which is A2 for some k which gives the result in the basis e1=(1,−1,0),e2=(0,1,−1).