Rename accelMotivity to growthRate

This commit is contained in:
Jacob Palecki 2021-04-06 18:04:28 -07:00
parent 5b519e7f86
commit 758de1d236
7 changed files with 8 additions and 7 deletions

View file

@ -13,7 +13,7 @@ namespace rawaccel {
double constant;
sigmoid(const accel_args& args) :
accel(exp(args.accel_motivity)),
accel(exp(args.growth_rate)),
motivity(2 * log(args.motivity)),
midpoint(log(args.midpoint)),
constant(-motivity / 2) {}

View file

@ -52,7 +52,7 @@ namespace rawaccel {
double cap = 1.5;
double accel_classic = 0.005;
double accel_natural = 0.1;
double accel_motivity = 1;
double growth_rate = 1;
double motivity = 1.5;
double power = 2;
double scale = 1;

View file

@ -82,7 +82,7 @@ namespace rawaccel {
error("cap"" must be positive");
}
if (args.accel_motivity <= 0 ||
if (args.growth_rate <= 0 ||
args.accel_natural <= 0 ||
args.accel_classic <= 0) {
error("acceleration"" must be positive");

View file

@ -16,6 +16,7 @@ namespace grapher.Layouts
public const string Weight = "Weight";
public const string Smooth = "Smooth";
public const string Gain = "Gain";
public const string GrowthRate = "Growth Rate";
public LayoutBase()
{

View file

@ -17,7 +17,7 @@ namespace grapher.Layouts
LogarithmicCharts = true;
GainSwitchOptionLayout = new OptionLayout(true, Gain);
AccelLayout = new OptionLayout(true, Acceleration);
AccelLayout = new OptionLayout(true, GrowthRate);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(false, string.Empty);
WeightLayout = new OptionLayout(false, string.Empty);

View file

@ -250,7 +250,7 @@ namespace grapher
}
else if (args.mode == AccelMode.motivity)
{
args.accelMotivity = Acceleration.Field.Data;
args.growthRate = Acceleration.Field.Data;
}
else
{
@ -345,7 +345,7 @@ namespace grapher
{
if (args.mode == AccelMode.motivity)
{
return args.accelMotivity;
return args.growthRate;
}
else if (args.mode == AccelMode.natural)
{

View file

@ -70,7 +70,7 @@ public value struct AccelArgs
double cap;
double accelClassic;
double accelNatural;
double accelMotivity;
double growthRate;
double motivity;
double power;
double scale;