0

The scaling for axes X,Y and Z that I specify in the procedure scale3 is overridden. I don't understand why? Could someone point out what is wrong with my code?

The width of a box is n1/2-1(~128 points) and it is more than the height(98 points).

n1=257
n2=257
n3=98

file='test.ps'

set_plot,'Z'
erase,255

scale3,XRange=[0,n1-1],YRange=[0,n2-1],ZRange=[0,n3-1],az=-30,ax=30


PLOTS,[0,n1-1],[0,0],[0,0],/T3D,color=0,thick=2
PLOTS,[0,0],[0,n2-1],[0,0],/T3D,color=0,thick=2
PLOTS,[0,n1-1],[n2-1,n2-1],[0,0],/T3D,color=0,thick=2
PLOTS,[n1-1,n1-1],[0,n2-1],[0,0],/T3D,color=0,thick=2
PLOTS,[0,n1-1],[n2-1,n2-1],[n3-1,n3-1],/T3D,color=0,thick=2
PLOTS,[n1-1,n1-1],[0,n2-1],[n3-1,n3-1],/T3D,color=0,thick=2
PLOTS,[0,n1-1],[0,0],[n3-1,n3-1],/T3D,color=0,thick=2
PLOTS,[0,0],[0,n2-1],[n3-1,n3-1],/T3D,color=0,thick=2
PLOTS,[0,0],[0,0],[0,n3-1],/T3D,color=0,thick=2
PLOTS,[n1/2-1,n1/2-1],[0,0],[0,n3-1],/T3D,color=0,thick=2
PLOTS,[n1-1,n1-1],[0,0],[0,n3-1],/T3D,color=0,thick=2
PLOTS,[n1-1,n1-1],[n2-1,n2-1],[0,n3-1],/T3D,color=0,thick=2
PLOTS,[0,0],[n2-1,n2-1],[0,n3-1],/T3D,color=0,thick=2
PLOTS,[n1/2-1,n1/2-1],[0,n2-1],[n3-1,n3-1],/T3D,color=0,thick=2
PLOTS,[0,n1-1],[n2/2-1,n2/2-1],[n3-1,n3-1],/T3D,color=0,thick=2
PLOTS,[n1-1,n1-1],[n2/2-1,n2/2-1],[0,n3-1],/T3D,color=0,thick=2
PLOTS,[n1/2-1,n1/2-1],[0,n2-1],[0,0],/T3D,color=0,thick=2
PLOTS,[0,0],[n2/2-1,n2/2-1],[0,n3-1],/T3D,color=0,thick=2
PLOTS,[n1/2-1,n1/2-1],[n2-1,n2-1],[0,n3-1],/T3D,color=0,thick=2
PLOTS,[0,n1-1],[n2/2-1,n2/2-1],[0,0],/T3D,color=0,thick=2

g=TVRD()

set_plot,'PS'
device,filename=file,xsize=8,ysize=6,/encapsulated
tv,g
device,/close

end

2x2 geometry

enter image description here

1 Answers1

0

Do you mean mean the display is anisotropic? Just add:

device, set_resolution=[500, 500]

after you change to the Z-buffer device. This is what I get:

enter image description here

mgalloy
  • 2,356
  • 1
  • 12
  • 10
  • Thanks Michael. The set_resolution keyword did help. I was looking for something that is similar to my 2nd image in my post. – Simon Ranjith Jul 25 '19 at 16:40