0

I have the following 3D plot in quiver. My question is that I have 3 lists x,y,z, and the derivatives u,v, and w lists. My question is how can I make only one quadrant visible? which means if x and y are positive, and z is negative only draw the points starting with these values. Given that all numbers in my system are from -1 to 1.

b=75
T=50
#steps = 20
steps = 4
valuelist = [0]


for i in range(1,steps+1):
  valuelist = [-i/steps] + valuelist
  valuelist.append(i/steps)

print(valuelist)
r= len(valuelist)
x, y, z = np.meshgrid(np.linspace(-1,1,r),
                      np.linspace(-1,1,r),
                      np.linspace(-1,1,r))
u = np.zeros((r,r,r))
v = np.zeros((r,r,r))
w = np.zeros((r,r,r))
for i in range(r):
  for j in range(r):
    for k in range(r):
        initial_values= [valuelist[i],valuelist[j],valuelist[k]]
        u[i,j,k] = derivative-one-step(initial_values,b)[0]
        v[i,j,k] = derivative-one-step(initial_values,b)[1] 
        w[i,j,k] = derivative-one-step(initial_values,b)[2] 
Hani
  • 3
  • 2
  • Please post a [minimal, reproducible example](https://stackoverflow.com/help/minimal-reproducible-example): please share with us what `x`, `y`, `z`, `u`, `v` and `w` are. – medium-dimensional Jan 16 '23 at 10:56
  • x,y,and z are the coordinates of a 3D point in 3D plot. They take values from -1 to 1. On the other hand, u,v, and w are the derivatives of these points. – Hani Jan 16 '23 at 11:34

0 Answers0