Zeichensatz UTF-8+Z1013()+CTRL()-ohne Umlaute(äöüß) 8 WINDOW:CLS:GOTO 7005 9 INPUT "";X$:PAUSE 2:X=VAL(X$):RETURN 10 INPUT "";Y$:PAUSE 2:RETURN 35 IF N=1 THEN 100 40 FOR K=N TO 2 STEP-1 50 Z=1:FOR I=2 TO K:IF ABS(A(P(Z),P(Z)))<ABS(A(P(I),P(I)))THEN Z=I 55 NEXT 60 P=P(Z):P(Z)=P(K):P(K)=P 65 IF ABS(A(P,P))<P1 THEN PRINT "PIVOT";P,A(P,P) 75 FOR J=1 TO K-1:Z=P(J):IF A(Z,P)=0 THEN 90 80 X=A(Z,P)/A(P,P):B(Z)=B(Z)-X*B(P) 85 FOR I=1 TO K-1:A(Z,P(I))=A(Z,P(I))-X*A(P,P(I)):NEXT 90 NEXT:NEXT 100 FOR J=1 TO N:Z=P(J):IF J=1 THEN 110 105 FOR I=1 TO J-1:B(Z)=B(Z)-B(P(I))*A(Z,P(I)):NEXT 110 IF A(Z,Z)=0 THEN PRINT "KNOTEN";Z;"ISOLIERT !!":GOTO 7300 115 B(Z)=B(Z)/A(Z,Z):NEXT:RETURN 460 A(L,L)=A(L,L)+G1:A(L,M)=A(L,M)-G1:A(M,L)=A(M,L)-G1:A(M,M)=A(M,M)+G1 465 RETURN 500 GOSUB 460:B(L)=B(L)+G1*(U(L)-U(M)):B(M)=B(M)-G1*(U(L)-U(M)):RETURN 525 A(L,J)=A(L,J)-X:A(L,K)=A(L,K)+X:A(M,J)=A(M,J)+X:A(M,K)=A(M,K)-X 530 RETURN 1500 IF T=0 THEN X=0 1505 RETURN 1520 IF T>0 THEN X=0 1525 RETURN 1540 X=X*T:RETURN 1560 X=X*SIN(2*PI*T/T0):RETURN 1580 V=X*SIN(2*PI*T/T0):IF V<=0 THEN X=0 1585 RETURN 1600 V=X*SIN(2*PI*T/T0):IF(T=0)AND(V=0)THEN X=0 1605 IF V<0 THEN X=-X 1610 RETURN 1620 IF(T=0)OR(T>T0)THEN X=0 1625 RETURN 2505 FOR I=1 TO A:B(I)=0:FOR J=1 TO A:A(I,J)=0:NEXT:NEXT 2555 IF Z(1)=0 THEN 2605 2560 FOR I=1 TO Z(1):G1=R(I,1):L=R(I,2):M=R(I,3):GOSUB 460:NEXT 2605 IF Z(2)=0 THEN 2705 2610 FOR I=1 TO Z(2):G1=1/E(I,3):L=E(I,4):M=E(I,5):GOSUB 460 2615 B(L)=B(L)+E(I,6):B(M)=B(M)-E(I,6):NEXT 2705 IF Z(3)=0 THEN 2805 2710 FOR I=1 TO Z(3):X=I(I,7):L=I(I,5):M=I(I,6) 2715 IF I(I,1)<>10 THEN B(L)=B(L)+X:B(M)=B(M)-X:GOTO 2725 2720 J=I(I,3):K=I(I,4):X=I(I,2):GOSUB 525 2725 NEXT 2805 IF(Z(4)=0)OR(T=0)THEN 4995 2810 FOR I=1 TO Z(4):L=C(I,2):M=C(I,3):G1=C(I,1)/H:GOSUB 500:NEXT 4995 RETURN 5005 FOR I=1 TO A:P(I)=I:NEXT 5100 PRINT:PRINT "* BEZUGSKNOTEN: ";:GOSUB 9:B=X 5105 P=P(B):P(B)=P(A):P(A)=P 5250 T2=-1:PRINT "* SCHRITT(nS) : ";:GOSUB 9:H=X:IF H=0 THEN 5595 5275 PRINT "* ENDZEIT(nS): ";:GOSUB 9:T2=X 5300 PRINT "* ANZEIGEKNOTEN: ";:GOSUB 9:A1=X:PRINT TAB(20);CHR$(11);:GOSUB 9:A2=X 5595 T=0 5605 IF Z(2)=0 THEN 5655 5610 FOR I=1 TO Z(2):X=E(I,2)/E(I,3) 5615 ON E(I,1)GOSUB 1500,1520,1540,1560,1580,1600,1620:E(I,6)=X:NEXT 5655 IF Z(3)=0 THEN 5775 5660 FOR I=1 TO Z(3):IF I(I,1)=10 THEN 5670 5665 X=I(I,2):ON I(I,1)GOSUB 1500,1520,1540,1560,1580,1600,1620:I(I,7)=X 5670 NEXT 5775 GOSUB 2505 5905 GOSUB 35:B(B)=0 5910 FOR I=1 TO A:U(I)=B(I):NEXT 6005 IF T=0 THEN PRINT "KNOTENSPANNUNG(VOLT):" 6010 IF H=0 THEN 6030 6015 IF T=0 THEN PRINT "T(nS) U(";A1;")";TAB(18);"U(";A2;")" 6020 PRINT T;TAB(5);B(A1);TAB(19);B(A2):IF T>=T2 THEN 7300 6025 T=T+H:GOTO 5605 6030 FOR I=1 TO A:IF I<>B THEN PRINT "U(";I;")=";B(I) 6035 NEXT:GOTO 7300 7005 WINDOW 0,31,0,31:CLS:PRINT " *** DYNA-L *** " 7015 M$="REIC":DIM Z(LEN(M$)):PRINT:PRINT " MODELLBIBLIOTHEK = ";M$:PRINT 7025 PRINT "* KNOTENZAHL:";:GOSUB 9:A=X 7030 PRINT "* BE-TYPEN:";:GOSUB 10:B$=Y$ 7035 PRINT "* T0 (nS):";:GOSUB 9:T0=X 7170 FOR I=1 TO LEN(B$):FOR J=1 TO LEN(M$) 7175 IF MID$(B$,I,1)=MID$(M$,J,1)THEN GOSUB 7355 7180 NEXT:NEXT 7220 DIM A(A,A):DIM B(A):DIM P(A):DIM U(A):N=A-1:P1=1E-12 7300 PRINT:PRINT "* FORTSETZUNG ? (K/E/H)";:GOSUB 10:IF Y$="E"THEN RUN 7305 IF Y$="K"THEN 9005 7340 GOTO 5005 7355 PRINT:PRINT "* ANZAHL ";MID$(B$,I,1);":";:GOSUB 9:Z(J)=X 7360 ON J GOSUB 7405,7555,7705,7855:FOR K=1 TO Z(J):ON J GOSUB 7420,7570,7720,7870 7365 NEXT:RETURN 7405 DIM R(Z(1),3) 7410 PRINT " Nr";TAB(7);"Wert(Kohm)";TAB(27);"K K":RETURN 7420 PRINT "R";K;TAB(6);:GOSUB 9:R(K,1)=X:PRINT TAB(26);CHR$(11);:R(K,1)=1/R(K,1) 7425 GOSUB 9:R(K,2)=X:PRINT TAB(29);CHR$(11);:GOSUB 9:R(K,3)=X:RETURN 7530 PRINT "R";I;TAB(7);1/R(I,1);TAB(26);R(I,2);TAB(28);R(I,3):RETURN 7555 DIM E(Z(2),6) 7560 PRINT " Nr TYP Wert(VOLT) Ri(Kohm) K+K-":RETURN 7570 PRINT "E";K;TAB(3);:GOSUB 9:E(K,1)=X:PRINT TAB(7);CHR$(11);:GOSUB 9:E(K,2)=X 7580 PRINT TAB(18);CHR$(11);:GOSUB 9:E(K,3)=X:PRINT TAB(27);CHR$(11); 7585 GOSUB 9:E(K,4)=X:PRINT TAB(29);CHR$(11);:GOSUB 9:E(K,5)=X:RETURN 7680 PRINT "E";I;TAB(3);E(I,1);TAB(7);E(I,2);TAB(18);E(I,3);TAB(27);E(I,4); 7685 PRINT TAB(28);E(I,5):RETURN 7705 DIM I(Z(3),7) 7710 PRINT " Nr TYP Wert(mA/V) S+ S- K+ K-":RETURN 7720 PRINT "I";K;:PRINT TAB(2);:GOSUB 9:I(K,1)=X:PRINT TAB(7);CHR$(11); 7725 GOSUB 9:I(K,2)=X:IF I(K,1)<>10 THEN GOTO 7740 7730 PRINT TAB(20);CHR$(11);:GOSUB 9:I(K,3)=X 7735 PRINT TAB(23);CHR$(11);:GOSUB 9:I(K,4)=X 7740 PRINT TAB(26);CHR$(11);:GOSUB 9:I(K,5)=X:PRINT TAB(29);CHR$(11); 7745 GOSUB 9:I(K,6)=X:RETURN 7830 PRINT "I";I;TAB(3);I(I,1);TAB(7);I(I,2);TAB(20);I(I,3);TAB(22);""; 7835 PRINT I(I,4);TAB(26);I(I,5);TAB(28);"";I(I,6):RETURN 7855 DIM C(Z(4),3) 7860 PRINT " Nr";TAB(7);"Wert(pF)";TAB(27);"K K":RETURN 7870 PRINT "C";K;TAB(6);:GOSUB 9:C(K,1)=X:PRINT TAB(26);CHR$(11);:GOSUB 9:C(K,2)=X 7880 PRINT TAB(29);CHR$(11);:GOSUB 9:C(K,3)=X:RETURN 7980 PRINT "C";I;TAB(6);C(I,1);TAB(26);C(I,2);TAB(29);C(I,3):RETURN 9005 X$="":PRINT:PRINT "* TYP ? (";B$;")"; 9010 GOSUB 10:X$=Y$:FOR J=1 TO LEN(M$):IF X$=MID$(M$,J,1)THEN 9025 9015 NEXT:IF X$=""THEN 5005 9020 GOTO 9005 9025 PRINT:ON J GOSUB 7410,7560,7710,7860:FOR I=1 TO Z(J) 9030 ON J GOSUB 7530,7680,7830,7980:NEXT 9035 PRINT "* INDEX ?";:GOSUB 9:K=X:IF K=0 THEN 9005 9040 ON J GOSUB 7420,7570,7720,7870:GOTO 9035 9705 WINDOW 0,31,0,31:CLS 9710 PRINT "ANZAHL UNBEKANNTE: ";:GOSUB 9:N=X; 9715 DIM A(N,N):DIM B(N):DIM P(N):P1=1E-12 9720 FOR I=1 TO N:P(I)=I:FOR J=1 TO N:PRINT "A(";I;J;")";:GOSUB 9:A(I,J)=X:PRINT " " 9725 NEXT:PRINT "B(";I;")";:GOSUB 9:B(I)=X:NEXT 9730 GOSUB 35:PRINT "LOESUNG: ":FOR I=1 TO N:PRINT "X(";I;")=";B(I);:NEXT:STOP