%pylab inline import os try: CLAW = os.environ['CLAW'] print "Using Clawpack from ", CLAW except: print "*** Environment variable CLAW must be set to run code" from clawpack.clawutil import nbtools nbtools.make_exe(new=True) # new=True ==> force recompilation of all code nbtools.make_htmls() nbtools.make_data(verbose=False) outdir,plotdir = nbtools.make_output_and_plots(label='1') import clawpack.visclaw.JSAnimation.JSAnimation_frametools as J anim = J.make_anim(plotdir, figno=1, figsize=(6,4)) anim import setrun rundata = setrun.setrun() print "The order is currently set to ",rundata.clawdata.order print "The limiter is currently set to ",rundata.clawdata.limiter rundata.clawdata.order = 1 rundata.write() outdir, plotdir = nbtools.make_output_and_plots(verbose=False) anim = J.make_anim(plotdir, figno=1, figsize=(6,4)) anim rundata.clawdata.order = 2 rundata.clawdata.limiter = ['none'] rundata.write() outdir, plotdir = nbtools.make_output_and_plots(verbose=False) anim = J.make_anim(plotdir, figno=1, figsize=(6,4)) anim print "The number of grid cells is currently set to ", rundata.clawdata.num_cells