Contact
CoCalc Logo Icon
StoreFeaturesDocsShareSupport News AboutSign UpSign In
| Download

All published worksheets from http://sagenb.org

Views: 168726
Image: ubuntu2004
# Graph for 15.1 #2 # ----------------- # our function and its plot # (now with more correct function!) f(x,y) = y^2 - 2*x^2 theplot = plot3d(f,(x,-1,3),(y,0,2),aspect_ratio=[1,1.5,1/5]) # The volumes of the 6 boxes defined here are the summands of the # Riemann sum approximating the volume under f(x,y) on [-1,3]x[0,2]. from sage.plot.plot3d.shapes import Box for m in range(4): for n in range(2): fval = f(m-1,n+1)/2 theplot += Box([0.5,0.5,abs(fval)],color='orange',opacity=0.5).translate((-0.5+m,0.5+n,fval)) theplot.show(figsize=6)