A class used to represent a 3D scalar field.
shape
: list
A list of 3 integers representing the shape of the 3D field.
value
: ndarray
The values of the field, reshaped into a 3D array by default.
path
: str
The file path where the field data is stored.
Nx, Ny, Nz
: int
The dimensions of the field along the x, y, and z axes, respectively.
file_name
: str
The name of the file where the field data is stored.
file_id
: str
The ID of the file where the field data is stored.
filter_size
: int
The size of the filter used for processing the field data.
is_light_mode()
Checks if the field data is stored in memory or in a file.
reshape_3d()
Reshapes the field data into a 3D array.
reshape_column()
Reshapes the field data into a column vector.
reshape_line()
Reshapes the field data into a row vector.
cut(n_cut=1, mode='equal')
Cuts the field data along the edges.
filter_gauss(delta, n_cut=0, mute=False)
Filters the field data using a Gaussian filter.
plot_x_midplane(mesh, title='', colormap='viridis', vmin=None, vmax=None)
Plots the field data on the x midplane.
plot_y_midplane(mesh, title='', colormap='viridis', vmin=None, vmax=None)
Plots the field data on the y midplane.
plot_z_midplane(mesh, title='', colormap='viridis', vmin=None, vmax=None)
Plots the field data on the z midplane.
The field data can be either in memory or in a file. If it's in a file, the file path, name, and ID are required. The reshape methods are used to change the shape of the field data for different purposes. The cut method is used to remove the edges of the field data. The filter_gauss method is used to smooth the field data. The plot methods are used to visualize the field data on different planes.