Ask Your Question

Jawaka's profile - activity

2018-12-19 11:18:31 +0200 received badge  Student (source)
2018-12-19 11:15:36 +0200 asked a question Vector field: how to make arrows fine? (plot2d)

I'm using the function arrow and I'm trying to have arrows fine like the one you can find on the wikipedia page of vector field, because the normal arrows in Sage are not enough fine for me. I looked at the manual and at the properties of arrows but I found nothing.

Thank you for any help :)

here is my code:

def champs_vecteur(f,L,n):
P = point((0,0))

for k in [-n..n]:
    for l in [-n..n]:
        i = L*k
        j = L*l
        (u,v) = f(i,j) 
        nor = sqrt(u*u+v*v)/L
        if nor != 0:
            u = u/nor
            v = v/nor
        P += arrow( (i-u/2,j-v/2) , (i+u/2,j+v/2) ,color="black", arrowsize=3,width=1)

I use it like that

h(x,y) = (-x-y,-y+x)