pencil_ccyang.find ================== .. py:module:: pencil_ccyang.find Functions --------- .. autoapisummary:: pencil_ccyang.find.avgt1d pencil_ccyang.find.par_disp pencil_ccyang.find.eta_z pencil_ccyang.find.midplane pencil_ccyang.find.sigma0 pencil_ccyang.find.slice pencil_ccyang.find.stratz pencil_ccyang.find.time_average Module Contents --------------- .. py:function:: avgt1d(tmin=None, **kwarg) Finds the time average of the 1D averages. :keyword tmin: Minimum time to be included in the average. If None, the whole time series is used. :keyword \*\*kwarg: Keyword arguments to be passed to read.avg1d(). .. py:function:: par_disp(datadir='./data', save_to=None) Finds the displacement of each particle as a function of time. :keyword datadir: Path to the data directory. :keyword save_to: If not None, a string of the filename (without .npz extension) to save the results (t and dxp) to a numpy data file under datadir. Returned Values: t A numpy array of times, starting from zero. dxp, dyp, dzp A tuple of three 2D numpy arrays, where dxp[i,j], dyp[i,j], and dzp[i,j] are the components of the displacement of particle j at t[i]. A component is returned None if the dimension is neither active nor periodic. .. py:function:: eta_z(z, datadir='./data') Finds the vertical profile of the resistivity, if any. Positional Arguments: z Numpy array of vertical coordinates. :keyword datadir: Data directory. Returned values: Magnetic diffusivity at the corresponding z. .. py:function:: midplane(**kwarg) Finds horizontally-averaged mid-plane properties as a function of time. Returned Values: Time and mid-plane properties. :keyword \*\*kwarg: Keyword arguments to be passed to read.avg1d(), except keyword plane. .. py:function:: sigma0(datadir='./data') Returns the background gas column density inside the computational domain. :keyword datadir: Name of the data directory. .. py:function:: slice(axis=2, var=None, z0=0, **kwarg) Finds a slice normal to one of the axis direction in one snapshot. :keyword axis: Axis that is normal to the slice. :keyword z0: Coordinate of the slice on the axis. :keyword var: List of variables; all variables are retrieved if None. :keyword \*\*kwarg: Keyword arguments to be passed to read.var(). Returned Values: Time of and fields on the slice. .. py:function:: stratz(datadir='./data', par=None, trim=False) Finds the vertical background stratification. Returned Values: The z coordinates and the corresponding density stratification. :keyword datadir: Name of the data directory. :keyword par: If not None, parameters given by read.parameters(). :keyword trim: Whether or not to trim ghost cells. .. py:function:: time_average(datadir='./data', diagnostics=None, tmin=0, verbose=True) Finds the time average of each given diagnostic variable. Returned Values: The mean and standard deviation of each diagnostics for t >= tmin. :keyword datadir: Name of the data directory. :keyword diagnostics: (A list of) diagnostic variable(s). If None, all diagnostics but it and t are processed. :keyword tmin: Starting time of the time average. :keyword verbose: Directly print out the averages when True.