soprano.collection.generate.linspace

Contents

soprano.collection.generate.linspace#

Generator producing structures interpolated between two extremes

Functions

linspaceGen(struct_0, struct_1[, steps, ...])

Generator function to create multiple structures with positions interpolated linearly between two extremes.

soprano.collection.generate.linspace.linspaceGen(struct_0, struct_1, steps=10, periodic=False)[source]#

Generator function to create multiple structures with positions interpolated linearly between two extremes.

Args:
struct_0 (ase.Atoms): the starting structure
struct_1 (ase.Atoms): the final structure. The atoms should be in the
same order as the ones in struct_0
steps (Optional[int]): number of interpolated steps to produce
(extremes included). Default is 10
periodic (Optional[bool]): if True the interpolation will take into
account periodic boundaries and interpolate
between positions in struct_0 and the
closest periodic copy of positions in
struct_1. By default set to False
Returns:
linspaceGenerator (generator): an iterator object that yields
structures created by linear
interpolation.