hey assistent
- User
hey assistent
- Assistant
Hello! How can I assist you today?
- User
I have this function def stop_approach_phase(start_time, gradient): t80_dmax = start_time + T80 dmax_80 = 0.8 * DMAX num_points_first = FREQ x_values_first = np.linspace(start_time, t80_dmax, num_points_first) normalized_x = (x_values_first - start_time) / T80 y_values_first = DMAX - (DMAX - dmax_80) * (normalized_x**2.5)
t_g1s = (G1s - y_values_first[-1]) / gradient + x_values_first[-1] num_points_second = FREQ x_values_second = np.linspace(x_values_first[-1], t_g1s, num_points_second) y_values_second = y_values_first[-1] + gradient * ( x_values_second - x_values_first[-1] ) x_values = np.concatenate((x_values_first, x_values_second)) y_values = np.concatenate((y_values_first, y_values_second)) g1s_x = x_values_second[-1] g1s_y = y_values_second[-1] x_values = np.concatenate((x_values_first, [])) y_values = np.concatenate((y_values_first, [])) num_points_third = FREQ if g1s_y < dmax_80: x_values_third = np.linspace(g1s_x, g1s_x + 1, num_points_third) y_values_third = np.linspace(g1s_y, 0, num_points_third) else: x_values_third = np.linspace(g1s_x, g1s_x + 1, num_points_third) k = gradient * 2 A = g1s_y B = -g1s_y * np.exp(-k) / (1 - np.exp(-k)) y_values_third = A * np.exp(-k * np.linspace(0, 1, num_points_third)) + B x_values = np.concatenate((x_values, x_values_third)) y_values = np.concatenate((y_values, y_values_third)) return x_values, y_values, g1s_x, g1s_y, t80_dmax, dmax_80 it works but it kinda dosen't in that I have basicaly 2 points g1s and t80. when g1s < t80 witch is dmax_80 I have liniar. I don't want to have linear I wnat to have like bellow, but if I put like bellow the graphics look weird, - Assistant
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.