pyvista.ParametricRandomHills#

ParametricRandomHills(
numberofhills=None,
hillxvariance=None,
hillyvariance=None,
hillamplitude=None,
randomseed=None,
xvariancescalefactor=None,
yvariancescalefactor=None,
amplitudescalefactor=None,
number_of_hills=None,
hill_x_variance=None,
hill_y_variance=None,
hill_amplitude=None,
random_seed=None,
x_variance_scale_factor=None,
y_variance_scale_factor=None,
amplitude_scale_factor=None,
**kwargs,
)[source]#

Generate a surface covered with randomly placed hills.

ParametricRandomHills generates a surface covered with randomly placed hills. Hills will vary in shape and height since the presence of nearby hills will contribute to the shape and height of a given hill. An option is provided for placing hills on a regular grid on the surface. In this case the hills will all have the same shape and height.

Parameters:
numberofhillsint, default: 30

The number of hills.

Changed in version 0.43.0: The numberofhills parameter has been renamed to number_of_hills.

hillxvariancefloat, default: 2.5

The hill variance in the x-direction.

Changed in version 0.43.0: The hillxvariance parameter has been renamed to hill_x_variance.

hillyvariancefloat, default: 2.5

The hill variance in the y-direction.

Changed in version 0.43.0: The hillyvariance parameter has been renamed to hill_y_variance.

hillamplitudefloat, default: 2

The hill amplitude (height).

Changed in version 0.43.0: The hillamplitude parameter has been renamed to hill_amplitude.

randomseedint, default: 1

The Seed for the random number generator, a value of 1 will initialize the random number generator, a negative value will initialize it with the system time.

Changed in version 0.43.0: The randomseed parameter has been renamed to random_seed.

xvariancescalefactorfloat, default: 13

The scaling factor for the variance in the x-direction.

Changed in version 0.43.0: The xvariancescalefactor parameter has been renamed to x_variance_scale_factor.

yvariancescalefactorfloat, default: 13

The scaling factor for the variance in the y-direction.

Changed in version 0.43.0: The yvariancescalefactor parameter has been renamed to y_variance_scale_factor.

amplitudescalefactorfloat, default: 13

The scaling factor for the amplitude.

Changed in version 0.43.0: The amplitudescalefactor parameter has been renamed to amplitude_scale_factor.

number_of_hillsint, default: 30

The number of hills.

hill_x_variancefloat, default: 2.5

The hill variance in the x-direction.

hill_y_variancefloat, default: 2.5

The hill variance in the y-direction.

hill_amplitudefloat, default: 2

The hill amplitude (height).

random_seedint, default: 1

The Seed for the random number generator, a value of 1 will initialize the random number generator, a negative value will initialize it with the system time.

x_variance_scale_factorfloat, default: 13

The scaling factor for the variance in the x-direction.

y_variance_scale_factorfloat, default: 13

The scaling factor for the variance in the y-direction.

amplitude_scale_factorfloat, default: 13

The scaling factor for the amplitude.

**kwargsdict, optional

See surface_from_para() for additional keyword arguments.

Returns:
pyvista.PolyData

ParametricRandomHills surface.

Examples

Create a ParametricRandomHills mesh.

>>> import pyvista as pv
>>> mesh = pv.ParametricRandomHills()
>>> mesh.plot(color='w', smooth_shading=True)
../../../_images/pyvista-ParametricRandomHills-1_00_00.png