download_cgns_multi

download_cgns_multi#

download_cgns_multi(load: bool = True) MultiBlock | str[source]#

Download a multielement airfoil with a cell centered solution.

Originally downloaded from CFD General Notation System Example Files

Parameters:
loadbool, default: True

Load the dataset after downloading it when True. Set this to False and only the filename will be returned.

Returns:
outputpyvista.MultiBlock | str

Structured, 4 blocks, 2D (2 planes in third dimension) multielement airfoil, with cell centered solution. If load is False, then the path of the example CGNS file is returned.

Examples#

Download Python source code | Download Jupyter notebook

Plot the airfoil dataset. Merge the multi-block and then plot the airfoil’s "ViscosityEddy". Convert the cell data to point data as in this dataset, the solution is stored within the cells.

>>> from pyvista import examples
>>> import pyvista as pv
>>> dataset = examples.download_cgns_multi()
>>> ugrid = dataset.combine()
>>> ugrid = ugrid = ugrid.cell_data_to_point_data()
>>> ugrid.plot(
...     cmap='bwr',
...     scalars='ViscosityEddy',
...     zoom=4,
...     cpos='xz',
...     show_scalar_bar=False,
... )
../../../_images/pyvista-examples-downloads-download_cgns_multi-e3074f74d82b1f05_00_00.png

See also

Cgns Multi Dataset

See this dataset in the Dataset Gallery for more info.

Cgns Structured Dataset