Class BiomolGradientLayer
-
- All Implemented Interfaces:
-
it.unibo.alchemist.model.Layer
,java.io.Serializable
public final class BiomolGradientLayer<P extends Position2D<P>> implements Layer<T, P>
A Layer representing a linear distribution in space of a molecule.
-
-
Field Summary
Fields Modifier and Type Field Description public final double
steep
-
Constructor Summary
Constructors Constructor Description BiomolGradientLayer(double directionX, double directionY, double unitVariation, double offset)
Initialize a gradient layer which grows in concentration proportionally in space. BiomolGradientLayer(P direction, double unitVariation, double offset)
Initialize a gradient layer which grows in concentration proportionally in space.
-
Method Summary
-
-
Constructor Detail
-
BiomolGradientLayer
BiomolGradientLayer(double directionX, double directionY, double unitVariation, double offset)
Initialize a gradient layer which grows in concentration proportionally in space.- Parameters:
directionX
- x coordinate of the vector representing the direction in which the gradient growsdirectionY
- y coordinate of the vector representing the direction in which the gradient growsunitVariation
- unit variation of the gradientoffset
- minimum value of concentration reached by this spatial distribution
-
BiomolGradientLayer
BiomolGradientLayer(P direction, double unitVariation, double offset)
Initialize a gradient layer which grows in concentration proportionally in space.- Parameters:
direction
- the Position2D representing the direction in which the gradient grows (here the positions is considered as a vector)unitVariation
- unit variation of the gradientoffset
- minimum value of concentration reached by this spatial distribution
-
-
Method Detail
-
getSteep
double getSteep()
- Returns:
the steepness of the gradient
-
getParameters
Array<double> getParameters()
- Returns:
the parameters describing this spatial distribution, that's actually a plain. So the java.lang.reflect.Array a returned by this method contains the parameters of that plain (concentration = a[0] * x + a[1] * y + a[2])
-
-
-
-