SCREEN 12
Uc = 0
LOCATE 1, 45: PRINT "время t(мс)"
LOCATE 2, 45: PRINT "белаялиния I(А)"
LOCATE 3, 45: PRINT "синяялиния Uc(В)"
LOCATE 4, 45: PRINT "фиолетовая линия X(мм)"
LOCATE 5, 45: PRINT "красная линия V(мм/с)"
LOCATE 6, 45: PRINT "зеленаялиния a(m/S)"
LOCATE 7, 45: PRINT "коричневая линия Ua(В)"
0 LET i1 = I
LET Uc1 = Uc
LET x1 = X
LET V1 = V
LET xc = 0
1 LET k1i = E / La - (R / La) * i1 - Uc / La - (Bo * Pi * D * w) * V / La
LET i1 = I + h * .5 * k1i
LET k2i = E / La - (R / La) * i1 - Uc / La - (Bo * Pi * D * w) * V / La
LET i1 = I + k2i * h * .5
LET k3i = E / La - (R / La) * i1 - Uc / La - (Bo * Pi * D * w) * V / La
LET i1 = I + k3i * h
LET k4i = E / La - (R / La) * i1 - Uc / La - (Bo * Pi * D * w) * V / La
LET di = h * (2 * k2i + k1i + 2 * k3i + k4i) / 6
2 LET k1Uc = I / C
LET Uc1 = Uc + h * .5 * k1Uc
LET k2Uc = I / C
LET Uc1 = Uc + h * .5 * k2Uc
LET k3Uc = I / C
LET Uc1 = Uc + h * k3Uc
LET k4Uc = I / C
LET dUc = h * (2 * k2Uc + k1Uc + 2 * k3Uc + k4Uc) / 6
3 LET k1x = V
LET x1 = X + k1x * h * .5
LET k2x = V
LET x1 = X + k2x * h * .5
LET k3x = V
LET x1 = X + k3x * h
LET k4x = V
LET dx = (k1x + 2 * k2x + 2 * k3x + k4x) * h / 6
4 LET k1V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V1 - (ksi / m1) * X
LET V1 = V + k1V * h * .5
LET k2V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V1 - (ksi / m1) * X
LET V1 = V + k2V * h * .5
LET k3V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V1 - (ksi / m1) * X
LET V1 = V + k3V * h
LET k4V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V1 - (ksi / m1) * X
LET dv = h * (2 * k2V + k1V + 2 * k3V + k4V) / 6
LET I = I + di
LET Uc = Uc + dUc
LET X = X + dx
LET V = V + dv
LET integral2 = integral2 + ABS(I) * h
LET integral = integral + h * (ABS(I)) ^ 2
LET a = (Bo * Pi * D * w * I - nu * V - ksi * X) / m1
LET Ua = La * di / h + Bo * Pi * D * w * V + I * Ra
LET tall = tall + h
IF q = 1 THEN
LOCATE 1, 1: PRINT "t="; tall * 1000, " "
LOCATE 2, 1: PRINT "I="; I, " "
LOCATE 3, 1: PRINT "Uc="; Uc, " "
LOCATE 4, 1: PRINT "X="; X * 1000, " "
LOCATE 5, 1: PRINT "V="; V * 1000, " "
LOCATE 6, 1: PRINT "a="; a, " "
LOCATE 7, 1: PRINT "Ua="; Ua, " "
END IF
PSET (t * 20000 * .01 / t2, 250 - I * .5)
PSET (t * 20000 * .01 / t2, 250 - Uc * .1), 3
PSET (t * 20000 * .01 / t2, 250)
PSET (t * 20000 * .01 / t2, 250 - V * 100), 4
PSET (t * 20000 * .01 / t2, 250 - X * 100000), 5
PSET (t * 20000 * .01 / t2, 250 - a / 3), 2
PSET (t * 20000 * .01 / t2, 250 - Ua * .1), 6
LET t = t + h
IF t > t1 THEN
IF (((I - ikontr) / I) < .001) AND (param = 0) THEN
LOCATE 14, 45
PRINT "Тпп(мс)="; tall * 1000; : INPUT zxc
LET param = 1
END IF
LET ikontr = I
GOTO 5
END IF
GOTO 0
5 i2 = I
V2 = V
x2 = X
7 LET k1i = E / La - (R / La) * i2 - (Bo * Pi * D * w * V / La)
LET i2 = I + h * .5 * k1i
LET k2i = E / La - (R / La) * i2 - (Bo * Pi * D * w * V / La)
LET i2 = I + k2i * h * .5
LET k3i = E / La - (R / La) * i2 - (Bo * Pi * D * w * V / La)
LET i2 = I + k3i * h
LET k4i = E / La - (R / La) * i2 - (Bo * Pi * D * w * V / La)
LET di = h * (2 * k2i + k1i + 2 * k3i + k4i) / 6
8 LET k1x = V
LET x2 = X + k1x * h * .5
LET k2x = V
LET x2 = X + k2x * h * .5
LET k3x = V
LET x2 = X + k3x * h
LET k4x = V
LET dx = (k1x + 2 * k2x + 2 * k3x + k4x) * h / 6
9 LET k1V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V2 - (ksi / m1) * X
LET V2 = V + k1V * h * .5
LET k2V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V2 - (ksi / m1) * X
LET V2 = V + k2V * h * .5
LET k3V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V2 - (ksi / m1) * X
LET V2 = V + k3V * h
LET k4V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V2 - (ksi / m1) * X
LET dv = h * (2 * k2V + k1V + 2 * k3V + k4V) / 6
10 LET I = I + di
LET X = X + dx
LET V = V + dv
LET integral2 = integral2 + ABS(I) * h
LET integral = integral + h * (ABS(I)) ^ 2
LET a = (Bo * Pi * D * w * I - nu * V - ksi * X) / m1
LET Ua = La * di / h + Bo * Pi * D * w * V + I * Ra
LET tall = tall + h
11 IF q = 1 THEN
LOCATE 1, 1: PRINT "t="; tall * 1000, " "
LOCATE 2, 1: PRINT "I="; I, " "
LOCATE 3, 1: PRINT "Uc="; Uc, " "
LOCATE 4, 1: PRINT "X="; X * 1000, " "
LOCATE 5, 1: PRINT "V="; V * 1000, " "
LOCATE 6, 1: PRINT "a="; a, " "
LOCATE 7, 1: PRINT "Ua="; Ua, " "
END IF
PSET (t * 20000 * .01 / t2, 250 - I * .5)
PSET (t * 20000 * .01 / t2, 250 - Uc * .1), 3
PSET (t * 20000 * .01 / t2, 250)
PSET (t * 20000 * .01 / t2, 250 - V * 100), 4
PSET (t * 20000 * .01 / t2, 250 - X * 100000), 5
PSET (t * 20000 * .01 / t2, 250 - a / 3), 2
PSET (t * 20000 * .01 / t2, 250 - Ua * .1), 6
LET t = t + h
IF t > t1 + t2 THEN GOTO 12
GOTO 5
12 LET Uc = -Uc:
LET tkontr = t:
121 LET Uc3 = Uc
LET i3 = I
LET x3 = X
LET V3 = V
13
LET k1i = E / La - (R / La) * i3 - (Uc / La) - (Bo * Pi * D * w / La) * V
LET i3 = I + h * .5 * k1i
LET k2i = E / La - (R / La) * i3 - (Uc / La) - (Bo * Pi * D * w / La) * V
LET i3 = I + k2i * h * .5
LET k3i = E / La - (R / La) * i3 - (Uc / La) - (Bo * Pi * D * w / La) * V
LET i3 = I + k3i * h
LET k4i = E / La - (R / La) * i3 - (Uc / La) - (Bo * Pi * D * w / La) * V
LET di = h * (2 * k2i + k1i + 2 * k3i + k4i) / 6
14 LET k1Uc = I / C
LET Uc3 = Uc + h * .5 * k1Uc
LET k2Uc = I / C
LET Uc3 = Uc + h * .5 * k2Uc
LET k3Uc = I / C
LET Uc3 = Uc + h * k3Uc
LET k4Uc = I / C
LET dUc = h * (2 * k2Uc + k1Uc + 2 * k3Uc + k4Uc) / 6
15 LET k1x = V
LET x3 = X + k1x * h * .5
LET k2x = V
LET x3 = X + k2x * h * .5
LET k3x = V
LET x3 = X + k3x * h * .5
LET k4x = V
LET dx = (k1x + 2 * k2x + 2 * k3x + k4x) * h / 6
16 LET k1V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V3 - (ksi / m1) * X
LET V3 = V + k1V * h * .5
LET k2V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V3 - (ksi / m1) * X
LET V3 = V + k2V * h * .5
LET k3V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V3 - (ksi / m1) * X
LET V3 = V + k3V * h
LET k4V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V3 - (ksi / m1) * X
LET dv = h * (2 * k2V + k1V + 2 * k3V + k4V) / 6
17 LET I = I + di
LET Uc = Uc + dUc
LET X = X + dx
LET V = V + dv
LET integral2 = integral2 + ABS(I) * h
LET integral = integral + h * (ABS(I)) ^ 2
LET a = (Bo * Pi * D * w * I - nu * V - ksi * X) / m1
LET Ua = La * di / h + Bo * Pi * D * w * V + I * Ra
LET tall = tall + h
IF Uc > 0 AND xc = 0 THEN
LOCATE 8, 45
LET tvost = (t - tkontr) * 10 ^ 6
PRINT "tvost(¬Є‘)="; (t - tkontr) * 10 ^ 6
LET xc = 1
END IF
IF q = 1 THEN
LOCATE 1, 1: PRINT "t="; tall * 1000, " "
LOCATE 2, 1: PRINT "I="; I, " "
LOCATE 3, 1: PRINT "Uc="; Uc, " "
LOCATE 4, 1: PRINT "X="; X * 1000, " "
LOCATE 5, 1: PRINT "V="; V * 1000, " "
LOCATE 6, 1: PRINT "a="; a, " "
LOCATE 7, 1: PRINT "Ua="; Ua, " "
END IF
PSET (t * 20000 * .01 / t2, 250 - I * .5)
PSET (t * 20000 * .01 / t2, 250 + Uc * .1), 3
PSET (t * 20000 * .01 / t2, 250)
PSET (t * 20000 * .01 / t2, 250 - V * 100), 4
PSET (t * 20000 * .01 / t2, 250 - X * 100000), 5
PSET (t * 20000 * .01 / t2, 250 - a / 3), 2
PSET (t * 20000 * .01 / t2, 250 - Ua * .1), 6
LET t = t + h
IF I < 0 THEN LET ti = t: GOTO 19
18 GOTO 121
19 LET x31 = X
LET V31 = V
191LET k1V = (nu / m1) * V31 - (ksi / m1) * X
LET V31 = V + k1V * h * .5
LET k2V = (nu / m1) * V31 - (ksi / m1) * X
LET V31 = V + k2V * h * .5
LET k3V = (nu / m1) * V31 - (ksi / m1) * X
LET V31 = V + k3V * h
LET k4V = (nu / m1) * V31 - (ksi / m1) * X
LET dv = h * (2 * k2V + k1V + 2 * k3V + k4V) / 6
192LET k1x = V
LET x31 = X + k1x * h * .5
LET k2x = V
LET x31 = X + k2x * h * .5
LET k3x = V
LET x31 = X + k3x * h
LET k4x = V
LET dx = (k1x + 2 * k2x + 2 * k3x + k4x) * h / 6
193LET X = X + dx
LET V = V + dv
LET a = (Bo * Pi * D * w * I - nu * V - ksi * X) / m1
LET Ua = Bo * Pi * D * w * V + I * Ra
LET tall = tall + h
IF q = 1 THEN
LOCATE 1, 1: PRINT "t="; tall * 1000, " "
LOCATE 2, 1: PRINT "I="; I, " "
LOCATE 3, 1: PRINT "Uc="; Uc, " "
LOCATE 4, 1: PRINT "X="; X * 1000, " "
LOCATE 5, 1: PRINT "V="; V * 1000, " "
LOCATE 6, 1: PRINT "a="; a, " "
LOCATE 7, 1: PRINT "Ua="; Ua, " "
END IF
PSET (t * 20000 * .01 / t2, 250 - I * .5)
PSET (t * 20000 * .01 / t2, 250 + Uc * .1), 3
PSET (t * 20000 * .01 / t2, 250)
PSET (t * 20000 * .01 / t2, 250 - V * 100), 4
PSET (t * 20000 * .01 / t2, 250 - X * 100000), 5
PSET (t * 20000 * .01 / t2, 250 - a / 3), 2
PSET (t * 20000 * .01 / t2, 250 - Ua * .1), 6
LET t = t + h
IF t > (ti + t56) THEN GOTO 20
GOTO 19
20 LET i4 = I
LET Uc4 = Uc
LET x4 = X
LET V4 = V
21 LET k1i = -E / La - (R / La) * i4 - Uc / La - (Bo * Pi * D * w) * V / La
LET i4 = I + h * .5 * k1i
LET k2i = -E / La - (R / La) * i4 - Uc / La - (Bo * Pi * D * w) * V / La
LET i4 = I + k2i * h * .5
LET k3i = -E / La - (R / La) * i4 - Uc / La - (Bo * Pi * D * w) * V / La
LET i4 = I + k3i * h
LET k4i = -E / La - (R / La) * i4 - Uc / La - (Bo * Pi * D * w) * V / La
LET di = h * (2 * k2i + k1i + 2 * k3i + k4i) / 6
22 LET k1Uc = I / C
LET Uc4 = Uc + h * .5 * k1Uc
LET k2Uc = I / C
LET Uc4 = Uc + h * .5 * k2Uc
LET k3Uc = I / C
LET Uc4 = Uc + h * k3Uc
LET k4Uc = I / C
LET dUc = h * (2 * k2Uc + k1Uc + 2 * k3Uc + k4Uc) / 6
23 LET k1x = V
LET x4 = X + k1x * h * .5
LET k2x = V
LET x4 = X + k2x * h * .5
LET k3x = V
LET x4 = X + k3x * h
LET k4x = V
LET dx = (k1x + 2 * k2x + 2 * k3x + k4x) * h / 6
24 LET k1V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V1 - (ksi / m1) * X
LET V4 = V + k1V * h * .5
LET k2V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V1 - (ksi / m1) * X
LET V4 = V + k2V * h * .5
LET k3V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V1 - (ksi / m1) * X
LET V4 = V + k3V * h
LET k4V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V1 - (ksi / m1) * X
LET dv = h * (2 * k2V + k1V + 2 * k3V + k4V) / 6
25 LET I = I + di
LET Uc = Uc + dUc
LET X = X + dx
LET V = V + dv
LET integral2 = integral2 + ABS(I) * h
LET integral = integral + h * (ABS(I)) ^ 2
LET a = (Bo * Pi * D * w * I - nu * V - ksi * X) / m1
LET Ua = La * di / h + Bo * Pi * D * w * V + I * Ra
LET tall = tall + h
26 IF q = 1 THEN
LOCATE 1, 1: PRINT "t="; tall * 1000, " "
LOCATE 2, 1: PRINT "I="; I, " "
LOCATE 3, 1: PRINT "Uб="; Uc, " "
LOCATE 4, 1: PRINT "X="; X * 1000, " "
LOCATE 5, 1: PRINT "V="; V * 1000, " "
LOCATE 6, 1: PRINT "a="; a, " "
LOCATE 7, 1: PRINT "Ua="; Ua, " "
END IF
PSET (t * 20000 * .01 / t2, 250 - I * .5)
PSET (t * 20000 * .01 / t2, 250 + Uc * .1), 3
PSET (t * 20000 * .01 / t2, 250)
PSET (t * 20000 * .01 / t2, 250 - V * 100), 4
PSET (t * 20000 * .01 / t2, 250 - X * 100000), 5
PSET (t * 20000 * .01 / t2, 250 - a / 3), 2
PSET (t * 20000 * .01 / t2, 250 - Ua * .1), 6
LET t = t + h
IF t > ti + t1 + t56 THEN GOTO 27
GOTO 20
27i5 = I
V5 = V
x5 = X
28LET k1i = -E / La - (R / La) * i5 - (Bo * Pi * D * w * V / La)
LET i5 = I + h * .5 * k1i
LET k2i = -E / La - (R / La) * i5 - (Bo * Pi * D * w * V / La)
LET i5 = I + k2i * h * .5
LET k3i = -E / La - (R / La) * i5 - (Bo * Pi * D * w * V / La)
LET i5 = I + k3i * h
LET k4i = -E / La - (R / La) * i5 - (Bo * Pi * D * w * V / La)
LET di = h * (2 * k2i + k1i + 2 * k3i + k4i) / 6
29 LET k1x = V
LET x5 = X + k1x * h * .5
LET k2x = V
LET x5 = X + k2x * h * .5
LET k3x = V
LET x5 = X + k3x * h
LET k4x = V
LET dx = (k1x + 2 * k2x + 2 * k3x + k4x) * h / 6
30 LET k1V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V5 - (ksi / m1) * X
LET V5 = V + k1V * h * .5
LET k2V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V5 - (ksi / m1) * X
LET V5 = V + k2V * h * .5
LET k3V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V5 - (ksi / m1) * X
LET V5 = V + k3V * h
LET k4V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V5 - (ksi / m1) * X
LET dv = h * (2 * k2V + k1V + 2 * k3V + k4V) / 6
31 LET I = I + di
LET X = X + dx
LET V = V + dv
LET integral2 = integral2 + ABS(I) * h
LET integral = integral + h * (ABS(I)) ^ 2
LET a = (Bo * Pi * D * w * I - nu * V - ksi * X) / m1
LET Ua = La * di / h + Bo * Pi * D * w * V + I * Ra
LET tall = tall + h
32 IF q = 1 THEN
LOCATE 1, 1: PRINT "t="; tall * 1000, " "
LOCATE 2, 1: PRINT "I="; I, " "
LOCATE 3, 1: PRINT "Uc="; Uc, " "
LOCATE 4, 1: PRINT "X="; X * 1000, " "
LOCATE 5, 1: PRINT "V="; V * 1000, " "
LOCATE 6, 1: PRINT "a="; a, " "
LOCATE 7, 1: PRINT "Ua="; Ua, " "
END IF
PSET (t * 20000 * .01 / t2, 250 - I * .5)
PSET (t * 20000 * .01 / t2, 250 + Uc * .1), 3
PSET (t * 20000 * .01 / t2, 250)
PSET (t * 20000 * .01 / t2, 250 - V * 100), 4
PSET (t * 20000 * .01 / t2, 250 - X * 100000), 5
PSET (t * 20000 * .01 / t2, 250 - a / 3), 2
PSET (t * 20000 * .01 / t2, 250 - Ua * .1), 6
LET t = t + h
IF t > (ti + t1 + t2 + t56) THEN GOTO 33
GOTO 27
33 LET Uc = -Uc
331 LET Uc6 = Uc
LET i6 = I
LET x6 = X
LET V6 = V
34 LET k1i = E / La - (R / La) * i6 - (Uc / La) - (Bo * Pi * D * w / La) * V
LET i6 = I + h * .5 * k1i
LET k2i = E / La - (R / La) * i6 - (Uc / La) - (Bo * Pi * D * w / La) * V
LET i6 = I + k2i * h * .5
LET k3i = E / La - (R / La) * i6 - (Uc / La) - (Bo * Pi * D * w / La) * V
LET i6 = I + k3i * h
LET k4i = E / La - (R / La) * i6 - (Uc / La) - (Bo * Pi * D * w / La) * V
LET di = h * (2 * k2i + k1i + 2 * k3i + k4i) / 6
35 LET k1Uc = I / C
LET Uc6 = Uc + h * .5 * k1Uc
LET k2Uc = I / C
LET Uc6 = Uc + h * .5 * k2Uc
LET k3Uc = I / C
LET Uc6 = Uc + h * k3Uc
LET k4Uc = I / C
LET dUc = h * (2 * k2Uc + k1Uc + 2 * k3Uc + k4Uc) / 6
36 LET k1x = V
LET x6 = X + k1x * h * .5
LET k2x = V
LET x6 = X + k2x * h * .5
LET k3x = V
LET x6 = X + k3x * h
LET k4x = V
LET dx = (k1x + 2 * k2x + 2 * k3x + k4x) * h / 6
37 LET k1V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V6 - (ksi / m1) * X
LET V6 = V + k1V * h * .5
LET k2V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V6 - (ksi / m1) * X
LET V6 = V + k2V * h * .5
LET k3V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V6 - (ksi / m1) * X
LET V6 = V + k3V * h
LET k4V = (Bo * Pi * D * w * I) / m1 - (nu / m1) * V6 - (ksi / m1) * X
LET dv = h * (2 * k2V + k1V + 2 * k3V + k4V) / 6
38 LET I = I + di
LET Uc = Uc + dUc
LET X = X + dx
LET V = V + dv
LET integral2 = integral2 + ABS(I) * h
LET integral = integral + h * (ABS(I)) ^ 2
LET a = (Bo * Pi * D * w * I - nu * V - ksi * X) / m1
LET Ua = La * di / h + Bo * Pi * D * w * V + I * Ra