inputfile = "Pa0" (Sx, Sy, radius, maxtime, writemovietime) = cpl.get_input_data(inputfile) #plot at the value starttime starttime = 45000 # SX = (Sx[1] - Sx[0]) SY = (Sy[1] - Sy[0]) size = 30 #hard coded by what "looks good" #--------------------------- #set up a 1x1 plot in a subroutine #--------------------------- fig, ax1 = cpl.format_plot(Sx=Sx, Sy=Sy) #--------------------------- #plot the pinning array #--------------------------- cpl.plot_pins(ax1, size=size) out_file = "particle_energies.png" #--------------------------- #get and parse data #--------------------------- datafile_prefix = "velocity_data/XV_data_t=" pin_file = "pin_array.dat" try:
get_ascii_data = 1 #--------------------------- #system specific variables #--------------------------- disk_size = 100 Sx = [0, 60.0] Sy = [0, 60.0] plot_time = 4500000 #time to plot print(plot_time) #--------------------------- #set up a 1x1 plot in a subroutine #--------------------------- fig, ax1 = cpl.format_plot() #------------------------------------------------------------------------ #get data for initial frame, #------------------------------------------------------------------------ datafile_prefix = "velocity_data/XV_data_t=" plot_file = datafile_prefix + "%08d" % (plot_time) print(plot_file) if get_ascii_data == 0: plot_file = plot_file + ".npy" if (verbose): print("Reading in file: %s" % (plot_file)) particle_data = di.get_data(plot_file, 7, sep=" ")