GaPFlow.viz.plotting#
Create line and contour plots of the simulation results.
The methods within this module are either called from the command-line interface
or directly from a GaPFlow.Problem instance. The former reads the output
from stored NetCDF files.
Functions
|
Plot a single frame of the solution from a file. |
|
Plot the time evolution of the centerline solution. |
|
Plot the height profile |
|
Plot the time evolution of scalar quantities, e.g. kinetic energy, mass, GP variance etc. |
- GaPFlow.viz.plotting.plot_frame(file_list, dim=1, frame=-1, show=True)#
Plot a single frame of the solution from a file.
- Parameters:
file_list (list) – List of NetCDF files (names)
dim (int, optional) – Dimension (the default is 1, for 2D problems this plots the solution along the y-centerline)
frame (int, optional) – Frame number (the default is -1, which is the last frame)
show (bool, optional) – Flag for plt.show() (the default is True)
- GaPFlow.viz.plotting.plot_frames(filename, every=1)#
Plot the time evolution of the centerline solution.
- Parameters:
filename (str) – NetCDF file name
every (int, optional) – Plot the solution every this many times (the default is 1)
- GaPFlow.viz.plotting.plot_height(file_list, dim=1, show_defo=False, show_pressure=False)#
Plot the height profile
- Parameters:
file_list (list) – List of NetCDF files
dim (int, optional) – Dimension (the default is 1, for 2D problems this plots the solution along the y-centerline)
show_defo (bool) – Show the displacement in a separate subfigure and the initial (default is False) gap height for reference
show_pressure (bool) – Show the pressure profile in a separate subfigure (default is False)
- GaPFlow.viz.plotting.plot_history(file_list, gp_files, show=True)#
Plot the time evolution of scalar quantities, e.g. kinetic energy, mass, GP variance etc.
- Parameters:
file_list (list) – List of CSV files
gp_files (dict) – Dicitonary with list of CSV files for each GP model (zz, xz, yz)
show (bool, optional) – Flag for plt.show() (the default is True)