Hi, I came across this example from lammps region and variable doc and I would like to assign a constant velocity to a region in my workpiece.
variable dx equal ramp(0,10)
region 2 sphere 10.0 10.0 0.0 5 move v_dx NULL NULL
The ramp(x,y) function uses the current timestep to generate a value linearly interpolated between the specified x,y values over the course of a run, according to this formula:
value = x + (y-x) * (timestep-startstep) / (stopstep-startstep)
If i would like to assign constant velocity of -1 (Angstrom/ps) in x direction, what X value should i use for the second value of ramp?
ramp (0, X)
Thank you.
this is a part of my input.
Unit: metal
Lammps version: 30 Jul 2021
variable Vx equal ramp (0,-100)
region box block 0 10 0 10 0 10 units box move v_Vx NULL NULL
group box dynamic all region box every 1
variable num1 equal count(box)
Read more here: Source link