From bd65193bf0eab40f1294d566991edc286b99f746 Mon Sep 17 00:00:00 2001 From: ermolaev_p Date: Fri, 15 Nov 2024 16:38:34 +0300 Subject: [PATCH] =?UTF-8?q?fix(SF-483):=20=D0=98=D1=81=D0=BF=D1=80=D0=B0?= =?UTF-8?q?=D0=B2=D0=BB=D0=B5=D0=BD=D0=B0=20=D0=BE=D1=88=D0=B8=D0=B1=D0=BA?= =?UTF-8?q?=D0=B0=20=D1=81=20=D1=80=D0=B0=D1=81=D1=87=D0=B5=D1=82=D0=BE?= =?UTF-8?q?=D0=BC=20=D1=82=D1=80=D0=B0=D0=B5=D0=BA=D1=82=D0=BE=D1=80=D0=B8?= =?UTF-8?q?=D0=B8=20=D0=B7=D0=B0=D0=BA=D1=80=D1=8B=D1=82=D0=B8=D1=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/OptAlgorithm/OptAlgorithm.py | 3 ++- src/OptAlgorithm/OptTimeCalculator.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/OptAlgorithm/OptAlgorithm.py b/src/OptAlgorithm/OptAlgorithm.py index c86e411..e0e8108 100644 --- a/src/OptAlgorithm/OptAlgorithm.py +++ b/src/OptAlgorithm/OptAlgorithm.py @@ -116,7 +116,8 @@ class OptAlgorithm(AutoConfigClass): dF0 = self.a_max_1 * self.Ts["tclose_1_acc"] * self.k_hardness_1 dFmax = min(self.v_max_1 * self.k_hardness_1, sqrt(self.k_hardness_1/(self.mass_1))* self.Ftogrow) - self.Fmeet = 1/ self.freq * sqrt(self.freq**2 * self.Ftogrow**2 - dFmax**2) + eps = 1e1 + self.Fmeet = 1/ self.freq * sqrt(self.freq**2 * self.Ftogrow**2 - dFmax**2 + eps) tspeed = self.Ts["tspeed"] Fspeed = - self.eff_control * cos(self.freq * tspeed) + self.eff_control + 1/self.freq * dF0 * sin(self.freq * tspeed) if t < self.Ts["tspeed"]: diff --git a/src/OptAlgorithm/OptTimeCalculator.py b/src/OptAlgorithm/OptTimeCalculator.py index 5b103aa..d5b93af 100644 --- a/src/OptAlgorithm/OptTimeCalculator.py +++ b/src/OptAlgorithm/OptTimeCalculator.py @@ -173,7 +173,7 @@ class OptTimeCalculator(AutoConfigClass): t5max = (Tfull - v0/a)/2 - t1 v1 = v0 + a * t1 S1 = v0*t1 + a*t1*t1/2 + v1*t31 - a*t31*t31/2 - S2max = abs(Sfull) + abs(S1) + S2max = Sfull + S1 t5 = min(t5max, (vmax)/a, sqrt(S2max / a)) t3 = abs(v0)/a + t1 + t5 t32 = t5