Lines Matching refs:k
20 k = k_at_slope(coefs.db_threshold, coefs.db_knee, coefs.linear_threshold, coefs.slope); variable
21 coefs.K = k;
22 coefs.knee_alpha = coefs.linear_threshold + 1 / k;
23 coefs.knee_beta = -exp(k * coefs.linear_threshold) / k;
26 y0 = knee_curve(coefs.linear_threshold, coefs.knee_threshold, k);
70 function k = k_at_slope(db_threshold, db_knee, linear_threshold, desired_slope);
72 % Approximate k given initial values
76 k = 5; variable
79 % A high value for k will more quickly asymptotically approach a slope of 0
80 slope = slope_at(linear_threshold, x, k);
82 max_k = k; % k is too high
84 min_k = k; % k is too low
88 k = sqrt(min_k * max_k); variable
94 function slope = slope_at(linear_threshold, x, k);
102 y_db = mag2db(knee_curve(linear_threshold, x, k));
103 y2_db = mag2db(knee_curve(linear_threshold, x2, k));
111 function y = knee_curve(linear_threshold, x, k);
116 y = linear_threshold + (1 - exp(-k * (x - linear_threshold))) / k;