contour plot bessel

156 days ago by jason3

r,z,gro,kro = var('r,z,gro,kro') gro = 2.405 kro = 3 def f(r,z): term1 = (1+(bessel_J(0, gro)/bessel_J(2,gro)))*(r/1)*(bessel_J(1, gro*r)/bessel_J(1,gro))*cos(kro*z); term2 = -(bessel_J(0,gro)/bessel_J(2, gro))*(r**2/1**2); return term1 + term2 cp = contour_plot(f , (r, 0.1, 1.55), (z,-.5,.5), axes_labels=['$r$','$z$'], contours = [0.0, 0.2, 0.4, 0.6, 0.8], labels = True, label_inline= True, label_colors = 'black', label_inline_spacing = 0.01, fill=False, aspect_ratio=1, legend_label='Polodial') cp.set_axes_range(xmin=0,xmax=2.6,ymin=-1.1, ymax=1.1) show(cp) 
       
canvas.set_axes_range? 
       

File: /sagenb/sage_install/sage-4.7.2/local/lib/python2.6/site-packages/sage/plot/plot.py

Type: <type ‘instancemethod’>

Definition: canvas.set_axes_range(xmin=None, xmax=None, ymin=None, ymax=None)

Docstring:

Set the ranges of the x and y axes.

INPUT:

  • xmin, xmax, ymin, ymax - floats

EXAMPLES:

sage: L = line([(1,2), (3,-4), (2, 5), (1,2)])
sage: L.set_axes_range(-1, 20, 0, 2)
sage: d = L.get_axes_range()
sage: d['xmin'], d['xmax'], d['ymin'], d['ymax']
(-1.0, 20.0, 0.0, 2.0)

File: /sagenb/sage_install/sage-4.7.2/local/lib/python2.6/site-packages/sage/plot/plot.py

Type: <type ‘instancemethod’>

Definition: canvas.set_axes_range(xmin=None, xmax=None, ymin=None, ymax=None)

Docstring:

Set the ranges of the x and y axes.

INPUT:

  • xmin, xmax, ymin, ymax - floats

EXAMPLES:

sage: L = line([(1,2), (3,-4), (2, 5), (1,2)])
sage: L.set_axes_range(-1, 20, 0, 2)
sage: d = L.get_axes_range()
sage: d['xmin'], d['xmax'], d['ymin'], d['ymax']
(-1.0, 20.0, 0.0, 2.0)