LAMPIRAN A. Flowchart 1. Contoh Flowchart Penempatan Subjek
Gambar 185. Flowchart Penempatan Subjek AB
361
2. Flowchart Reset Status Cell
Gambar 186. Flowchart Tahap Reset Status Cell
3. Contoh Flowchart Perhitungan Nilai Konflik
Gambar 187. Flowchart Perhitungan Nilai
4. Contoh Flowchart Perhitungan Gap 362
Gambar 188. Flowchart Perhitungan Gap Subjek Menuju Timur (bagian 1)
363
Gambar 189. Flowchart Perhitungan Gap Subjek Menuju Timur (bagian 2)
364
Gambar 190. Flowchart Perhitungan Gap Subjek Menuju Timur (bagian 3)
365
Gambar 191. Flowchart Perhitungan Gap Subjek Menuju Timur (bagian 4)
366
5. Contoh Flowchart Perhitungan MAP
Gambar 192. Flowchart Perhitungan
367
6. Contoh Flowchart Aturan Transisi
Gambar 193. Flowchart Aturan Transisi 111.1
368
7. Contoh Flowchart Aturan Posisi
Gambar 194. Flowchart Aturan Posisi 48.1 dan 48.2
369
B. Program Cell Position Tester 1. Cell Position Tester Program ini dibuat dan digunakan untuk melihat apakah aturan posisi sudah benar. Program ini disusun menggunakan bahasa pemrograman Object Pascal dan dikembanggan menggunakan IDE Lazarus.
Gambar 195.Cell Position Tester
2. Cara Penggunaan Pertama masukkan terlebih dahulu input letak dari cell parent subjek. Misalkan ingin mengetahui letak bagian subjek ke pendekat . Posisi cell parent subjek di cell ( pembahasan diketahui aturan posisi sebagai berikut
370
yang berbelok dari pendekat ), (
) dan (
). Dari
Perhatikan groupbox cell parent input pada program, kotak berada di paling kiri jendela program. Karena cell parent subjek diketahui melalui 3 cell berbeda centang kotak kecil bertuliskan cell parent 1 sampai cell parent 3. Setelah dicentang kotak isian letak cell parent akan aktif. Masukkan letak cell parent pada kotak, kotak kiri untuk dan kotak kanan untuk .
Gambar 196.Contoh Isian di Groupbox Cell Parent Input
Kemudian beralih ke isian input aturan posisi. Lihat terlebih dahulu pilihan di sisi kanan atas jendela program. Beri centang pada kotak kecil condition
371
2 has same argument with condition 1 jika kondisi kedua sama dengan kondisi pertama kecuali tanda pertidaksamaan dan konstan setelah tanda tersebut. pada contoh kasus kondisi aturan posisi kedua sama dengan kondisi aturan posisi pertama yaitu (
) kecuali tanda pertidaksamaan yaitu
dan
kemudian
konstan setelah tanda yaitu 5 dan 6. Sehingga beri tanda centang pada pilihan pertama. Pemberian tanda centang akan membuat kotak-kotak isian input untuk aturan posisi kedua akan nonaktif, hal ini hanya untuk mempercepat pengisisan input saja supaya tidak mengulang-ulang isian yang sama.
Kemudian pada
pilihan yang kedua beri tanda centang jika aturan posisi kedua memiliki kondisi dengan tanda sama dengan ( ). Pada contoh kasus kondisi pada aturan posisi kedua memiliki tanda sama dengan yaitu (
)
sehingga beri yanda
centang pada pilihan kedua. Pemberian tanda centang akan mengaktifkan kotak isian tanda centang pada isian input kondisi 2. Kemudian beri tanda centang pada pilihan ketiga jika aturan posisi memiliki 3 buah aturan posisi dan sekaligus 3 buah kondisi. Karena pada contoh kasus aturan posisi (66) memiliki tiga aturan maka beri tanda centang pada pilihan ketiga. Beri centang pada pilihan keempat jika kondisi ketiga sama dengan kondisi pertama dan kedua kecuali tanda pertidaksamaan dan konstan setelah tanda tersebut. Karena pada contoh kasus kondisi ketiga pada aturan ketiga bagian kiri tanda sama dengan kondisi satu dan dua maka beri tanda centang pada pilihan keempat.
Gambar 197. Contoh Isian di Pilihan Kondisi
Kemudian isikan aturan posisi sekaligus kondisinya pada program dan pilihan subjek pada groupbox subject type di jendela program kanan bawah, berikut contoh isian aturan posisi (66) pada program.
372
Gambar 198. Isian Pada Program Untuk Aturan Posisi (66)
Kemudian klik tombol check!. Jendela baru akan muncul menampilkan output letak bagian subjek berdasarkan aturan posisi subjek dan letak cell parent dari subjek.
Gambar 199. Contoh Output Program
Setelah jendela output muncul, samakan dengan tabel di bagian pembahasan. Pada contoh kasus, output yang diberikan oleh program sama dengan tabel 40.
373
3. Sintax Program a. Unit1.pas unit Unit1; {$mode objfpc}{$H+} interface uses Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, StdCtrls, ExtCtrls, inifiles; type { TForm1 } TForm1 = class(TForm) Button1: TButton;Button2: TButton;Button3: TButton; CheckCondition2samesign: TCheckBox;Image1: TImage; same2: TCheckBox;Subjek1: TCheckBox; CheckCOndition3: TCheckBox; CheckSameArgument1: TCheckBox; CheckSameArgument2: TCheckBox; condition3box: TGroupBox; condition2box: TGroupBox;ConsM2: TEdit;ConsM3: TEdit; ConsN1: TEdit;ConsN2: TEdit;ConsN3: TEdit; GroupBox1: TGroupBox;IMA2: TCheckBox;IMA3: TCheckBox; INA1: TCheckBox;IMB2: TCheckBox;IMB3: TCheckBox; INA2: TCheckBox;INA3: TCheckBox;INB1: TCheckBox; INB2: TCheckBox;INB3: TCheckBox;JMA2: TCheckBox; JMA3: TCheckBox;JNA1: TCheckBox;JMB2: TCheckBox; JMB3: TCheckBox;JNA2: TCheckBox;JNA3: TCheckBox; JNB1: TCheckBox;JNB2: TCheckBox;JNB3: TCheckBox; MinMA2: TCheckBox;MinMA3: TCheckBox; MinNA1: TCheckBox;MinMB2: TCheckBox; MinMB3: TCheckBox;MinNA2: TCheckBox; MinNA3: TCheckBox;MinNB1: TCheckBox; MinMC2: TCheckBox;MinMC3: TCheckBox; MinNB2: TCheckBox;MinNB3: TCheckBox; MinNC1: TCheckBox;MinNC2: TCheckBox; MinNC3: TCheckBox;MMA2: TCheckBox; MMA3: TCheckBox;MNA1: TCheckBox; MMB2: TCheckBox;MMB3: TCheckBox; MNA2: TCheckBox;MNA3: TCheckBox; MNB1: TCheckBox;MNB2: TCheckBox; MNB3: TCheckBox;mpositionrule3: TGroupBox; NNA2: TCheckBox;NNA3: TCheckBox; NNB2: TCheckBox;NNB3: TCheckBox; npositionrule1: TGroupBox;NMA2: TCheckBox; NMA3: TCheckBox;NNA1: TCheckBox; NMB2: TCheckBox;NMB3: TCheckBox; NNB1: TCheckBox;npositionrule2: TGroupBox; npositionrule3: TGroupBox;PlusMA2: TCheckBox; PlusMA3: TCheckBox;PlusNA1: TCheckBox; PlusMB2: TCheckBox;PlusMB3: TCheckBox; PlusNA2: TCheckBox;PlusNA3: TCheckBox; PlusNB1: TCheckBox;PlusMC2: TCheckBox; mpositionrule1: TGroupBox;ConsConA3: TEdit; ConsM1: TEdit;ConsConB2: TEdit; ConsConA2: TEdit;ConsConB1: TEdit; ConsConB3: TEdit;ConsConC2: TEdit;IA2: TCheckBox; IA3: TCheckBox;IMA1: TCheckBox;IB2: TCheckBox; IB3: TCheckBox;IMB1: TCheckBox;JA2: TCheckBox; JA3: TCheckBox;JMA1: TCheckBox;JB2: TCheckBox; JB3: TCheckBox;JMB1: TCheckBox;
less3: TCheckBox;lessB2: TCheckBox; lessA2: TCheckBox;lessSame3: TCheckBox; lessSameB2: TCheckBox;lessSameA2: TCheckBox; MA2: TCheckBox;MA3: TCheckBox; MMA1: TCheckBox;MB2: TCheckBox;MB3: TCheckBox; MMB1: TCheckBox;MinA3: TCheckBox; MinMA1: TCheckBox;MinB2: TCheckBox; MinB3: TCheckBox;MinMB1: TCheckBox; MinC2: TCheckBox;MinC3: TCheckBox; MinMC1: TCheckBox;MinD2: TCheckBox; MinA2: TCheckBox;MinD1: TCheckBox; MinD3: TCheckBox;MinE2: TCheckBox; More3: TCheckBox;MoreB2: TCheckBox; MoreA2: TCheckBox;MoreSame1: TCheckBox; More1: TCheckBox;lessSame1: TCheckBox; MinA1: TCheckBox;JA1: TCheckBox; MoreSame3: TCheckBox;MoreSameB2: TCheckBox; MoreSameA2: TCheckBox;NA1: TCheckBox; MinB1: TCheckBox;JB1: TCheckBox; NA2: TCheckBox;NA3: TCheckBox;NMA1: TCheckBox; NB1: TCheckBox;MinC1: TCheckBox;ConsConA1: TEdit; less1: TCheckBox;NB2: TCheckBox;NB3: TCheckBox; NMB1: TCheckBox;PlusA1: TCheckBox; checkcellparent1: TCheckBox; checkcellparent2: TCheckBox; checkcellparent3: TCheckBox; checkcellparent4: TCheckBox; checkcellparent5: TCheckBox; checkcellparent6: TCheckBox; checkcellparent7: TCheckBox; checkcellparent8: TCheckBox; checkcellparent9: TCheckBox;inputi1: TEdit; inputi2: TEdit; inputi3: TEdit;inputi4: TEdit;inputi5: TEdit;inputi6: TEdit; inputi7: TEdit;inputi8: TEdit;inputi9: TEdit;inputj1: TEdit; condition1box: TGroupBox;GroupCellParent: TGroupBox; inputj2: TEdit;inputj3: TEdit;inputj4: TEdit;inputj5: TEdit; inputj6: TEdit;inputj7: TEdit;inputj8: TEdit;inputj9: TEdit; IA1: TCheckBox;MA1: TCheckBox;PlusA3: TCheckBox; PlusMA1: TCheckBox;PlusB2: TCheckBox; PlusB1: TCheckBox;IB1: TCheckBox; MB1: TCheckBox;PlusB3: TCheckBox; PlusMB1: TCheckBox;PlusC2: TCheckBox; PlusC1: TCheckBox;PlusA2: TCheckBox; PlusC3: TCheckBox;PlusMC1: TCheckBox; PlusD1: TCheckBox;PlusD2: TCheckBox; PlusD3: TCheckBox;PlusE2: TCheckBox; mpositionrule2: TGroupBox;PlusMC3: TCheckBox; PlusNB2: TCheckBox;PlusNB3: TCheckBox; PlusNC1: TCheckBox;PlusNC2: TCheckBox; PlusNC3: TCheckBox;Subjek2: TCheckBox; Subjek3: TCheckBox;Subjek4: TCheckBox; Subjek5: TCheckBox;Subjek6: TCheckBox; procedure Button1Click(Sender: TObject); procedure checkcellparent1Change(Sender: TObject); procedure checkcellparent2Change(Sender: TObject); procedure checkcellparent3Change(Sender: TObject); procedure checkcellparent4Change(Sender: TObject); procedure checkcellparent5Change(Sender: TObject); procedure checkcellparent6Change(Sender: TObject); procedure checkcellparent7Change(Sender: TObject); procedure checkcellparent8Change(Sender: TObject); procedure checkcellparent9Change(Sender: TObject);
361
procedure CheckCondition2samesignChange(Sender: TObject); procedure CheckCOndition3Change(Sender: TObject); procedure CheckSameArgument1Change(Sender: TObject); procedure CheckSameArgument2Change(Sender: TObject); procedure FormCreate(Sender: TObject); procedure inputparent1; procedure inputparent2; procedure inputparent3; procedure inputparent4; procedure inputparent5; procedure inputparent6; procedure inputparent7; procedure inputparent8; procedure inputparent9; procedure kondisipertama; procedure kondisikedua; procedure kondisiketiga; procedure posisim1; procedure posisin1; procedure posisim2; procedure posisin2; procedure posisim3; procedure posisin3; private { private declarations } public { public declarations } end; var Form1: TForm1; i,j:array [1..9] of integer; posm,posn:array [1..9,1..10,1..3] of integer; y,x,a1,a2,a3,m,n:integer; kondisi1,kondisi2,kondisi3:boolean; savefile:TIniFile; implementation uses unit2; {$R *.lfm} { TForm1 } procedure TForm1.checkcellparent1Change(Sender: TObject); begin if checkcellparent1.Checked=true then begin inputi1.Enabled:=true; inputj1.Enabled:=true; end; if checkcellparent1.Checked=false then begin inputi1.Enabled:=false; inputj1.Enabled:=false; end;end; procedure TForm1.checkcellparent2Change(Sender: TObject); begin if checkcellparent2.Checked=true then begin inputi2.Enabled:=true; inputj2.Enabled:=true; checkcellparent1.Checked:=true; end; if checkcellparent2.Checked=false then begin inputi2.Enabled:=false; inputj2.Enabled:=false; checkcellparent1.Checked:=false; end;end; procedure TForm1.checkcellparent3Change(Sender: TObject); begin if checkcellparent3.Checked=true then begin inputi3.Enabled:=true; inputj3.Enabled:=true; checkcellparent1.Checked:=true; checkcellparent2.Checked:=true; end;
if checkcellparent3.Checked=false then begin inputi3.Enabled:=false; inputj3.Enabled:=false; checkcellparent1.Checked:=false; checkcellparent2.Checked:=false; end;end; procedure TForm1.checkcellparent4Change(Sender: TObject); begin if checkcellparent4.Checked=true then begin inputi4.Enabled:=true; inputj4.Enabled:=true; checkcellparent1.Checked:=true; checkcellparent2.Checked:=true; checkcellparent3.Checked:=true; end; if checkcellparent4.Checked=false then begin inputi4.Enabled:=false; inputj4.Enabled:=false; checkcellparent1.Checked:=false; checkcellparent2.Checked:=false; checkcellparent3.Checked:=false; end; end; procedure TForm1.checkcellparent5Change(Sender: TObject); begin if checkcellparent5.Checked=true then begin inputi5.Enabled:=true; inputj5.Enabled:=true; checkcellparent1.Checked:=true; checkcellparent2.Checked:=true; checkcellparent3.Checked:=true; checkcellparent4.Checked:=true; end; if checkcellparent5.Checked=false then begin inputi5.Enabled:=false; inputj5.Enabled:=false; checkcellparent1.Checked:=false; checkcellparent2.Checked:=false; checkcellparent3.Checked:=false; checkcellparent4.Checked:=false; end; end; procedure TForm1.checkcellparent6Change(Sender: TObject); begin if checkcellparent6.Checked=true then begin inputi6.Enabled:=true; inputj6.Enabled:=true; checkcellparent1.Checked:=true; checkcellparent2.Checked:=true; checkcellparent3.Checked:=true; checkcellparent4.Checked:=true; checkcellparent5.Checked:=true; end; if checkcellparent6.Checked=false then begin inputi6.Enabled:=false; inputj6.Enabled:=false; checkcellparent1.Checked:=false; checkcellparent2.Checked:=false; checkcellparent3.Checked:=false; checkcellparent4.Checked:=false; checkcellparent5.Checked:=false; end; end; procedure TForm1.checkcellparent7Change(Sender: TObject); begin if checkcellparent7.Checked=true then begin inputi7.Enabled:=true; inputj7.Enabled:=true; checkcellparent1.Checked:=true; checkcellparent2.Checked:=true; checkcellparent3.Checked:=true;
checkcellparent4.Checked:=true; checkcellparent5.Checked:=true; checkcellparent6.Checked:=true; end; if checkcellparent7.Checked=false then begin inputi7.Enabled:=false; inputj7.Enabled:=false; checkcellparent1.Checked:=false; checkcellparent2.Checked:=false; checkcellparent3.Checked:=false; checkcellparent4.Checked:=false; checkcellparent5.Checked:=false; checkcellparent6.Checked:=false; end; end; procedure TForm1.checkcellparent8Change(Sender: TObject); begin if checkcellparent8.Checked=true then begin inputi8.Enabled:=true; inputj8.Enabled:=true; checkcellparent1.Checked:=true; checkcellparent2.Checked:=true; checkcellparent3.Checked:=true; checkcellparent4.Checked:=true; checkcellparent5.Checked:=true; checkcellparent6.Checked:=true; checkcellparent7.Checked:=true; end; if checkcellparent8.Checked=false then begin inputi8.Enabled:=false; inputj8.Enabled:=false; checkcellparent1.Checked:=false; checkcellparent2.Checked:=false; checkcellparent3.Checked:=false; checkcellparent4.Checked:=false; checkcellparent5.Checked:=false; checkcellparent6.Checked:=false; checkcellparent7.Checked:=false; end; end; procedure TForm1.checkcellparent9Change(Sender: TObject); begin if checkcellparent9.Checked=true then begin inputi9.Enabled:=true; inputj9.Enabled:=true; checkcellparent1.Checked:=true; checkcellparent2.Checked:=true; checkcellparent3.Checked:=true; checkcellparent4.Checked:=true; checkcellparent5.Checked:=true; checkcellparent6.Checked:=true; checkcellparent7.Checked:=true; checkcellparent8.Checked:=true; end; if checkcellparent9.Checked=false then begin inputi9.Enabled:=false; inputj9.Enabled:=false; checkcellparent1.Checked:=false; checkcellparent2.Checked:=false; checkcellparent3.Checked:=false; checkcellparent4.Checked:=false; checkcellparent5.Checked:=false; checkcellparent6.Checked:=false; checkcellparent7.Checked:=false; checkcellparent8.Checked:=false; end; end;
procedure TForm1.CheckCondition2samesignChange( Sender: TObject); begin if (checkcondition2samesign.Checked=true) and (checkcondition3.Checked=false) then begin same2.Enabled:=true; end;
362
if (checkcondition2samesign.Checked=false) and (checkcondition3.Checked=false) then begin same2.Enabled:=false; end; if (checkcondition2samesign.Checked=true) and (checkcondition3.Checked=true) then begin same2.Enabled:=true; plusa2.Enabled:=false; mina2.Enabled:=false; conscona2.Enabled:=false; moresamea2.Enabled:=false; morea2.Enabled:=false; lesssamea2.Enabled:=false; lessa2.Enabled:=false; end; if (checkcondition2samesign.Checked=false) and (checkcondition3.Checked=true) then begin same2.Enabled:=false; plusa2.Enabled:=true; mina2.Enabled:=true; conscona2.Enabled:=true; moresamea2.Enabled:=true; morea2.Enabled:=true; lesssamea2.Enabled:=true; lessa2.Enabled:=true; end; end; procedure TForm1.CheckCOndition3Change(Sender: TObject); begin if (checkcondition3.Checked=true) and (checkcondition2samesign.Checked=false) then begin plusa2.Enabled:=true; mina2.Enabled:=true; conscona2.Enabled:=true; moresamea2.Enabled:=true; morea2.Enabled:=true; lesssamea2.Enabled:=true; lessa2.Enabled:=true; same2.Enabled:=false; condition3box.Enabled:=true; mpositionrule3.Enabled:=true; npositionrule3.Enabled:=true; checksameargument2.Enabled:=true; end; if (checkcondition3.Checked=false) and (checkcondition2samesign.Checked=true) then begin plusa2.Enabled:=false; mina2.Enabled:=false; conscona2.Enabled:=false; moresamea2.Enabled:=false; morea2.Enabled:=false; lesssamea2.Enabled:=false; lessa2.Enabled:=false; same2.Enabled:=true; condition3box.Enabled:=false; mpositionrule3.Enabled:=false; npositionrule3.Enabled:=false; checksameargument2.Enabled:=false; end; if (checkcondition3.Checked=true) and (checkcondition2samesign.Checked=true) then begin plusa2.Enabled:=false; mina2.Enabled:=false; conscona2.Enabled:=false; moresamea2.Enabled:=false; morea2.Enabled:=false; lesssamea2.Enabled:=false; lessa2.Enabled:=false; same2.Enabled:=true; condition3box.Enabled:=true; mpositionrule3.Enabled:=true; npositionrule3.Enabled:=true; checksameargument2.Enabled:=true; end;
if (checkcondition3.Checked=false) and (checkcondition2samesign.Checked=false) then begin plusa2.Enabled:=false; mina2.Enabled:=false; conscona2.Enabled:=false; moresamea2.Enabled:=false; morea2.Enabled:=false; lesssamea2.Enabled:=false; lessa2.Enabled:=false; same2.Enabled:=false; condition3box.Enabled:=false; mpositionrule3.Enabled:=false; npositionrule3.Enabled:=false; checksameargument2.Enabled:=false; end; end; procedure TForm1.CheckSameArgument1Change(Sen der: TObject); begin if checksameargument1.Checked=true then begin plusb2.Enabled:=false; minb2.Enabled:=false; ia2.Enabled:=false; ja2.Enabled:=false; ma2.Enabled:=false; na2.Enabled:=false; plusc2.Enabled:=false; minc2.Enabled:=false; ib2.Enabled:=false; jb2.Enabled:=false; mb2.Enabled:=false; nb2.Enabled:=false; plusd2.Enabled:=false; mind2.Enabled:=false; consconb2.Enabled:=false; end; if checksameargument1.Checked=false then begin plusb2.Enabled:=true; minb2.Enabled:=true; ia2.Enabled:=true; ja2.Enabled:=true; ma2.Enabled:=true; na2.Enabled:=true; plusc2.Enabled:=true; minc2.Enabled:=true; ib2.Enabled:=true; jb2.Enabled:=true; mb2.Enabled:=true; nb2.Enabled:=true; plusd2.Enabled:=true; mind2.Enabled:=true; consconb2.Enabled:=true; end; end; procedure TForm1.CheckSameArgument2Change(Sen der: TObject); begin if checksameargument2.Checked=true then begin plusa3.Enabled:=false; mina3.Enabled:=false; ia3.Enabled:=false; ja3.Enabled:=false; ma3.Enabled:=false; na3.Enabled:=false; plusb3.Enabled:=false; minb3.Enabled:=false; ib3.Enabled:=false; jb3.Enabled:=false; mb3.Enabled:=false; nb3.Enabled:=false; plusc3.Enabled:=false; minc3.Enabled:=false; conscona3.Enabled:=false; end; if checksameargument2.Checked=false then begin plusa3.Enabled:=true; mina3.Enabled:=true;
ia3.Enabled:=true; ja3.Enabled:=true; ma3.Enabled:=true; na3.Enabled:=true; plusb3.Enabled:=true; minb3.Enabled:=true; ib3.Enabled:=true; jb3.Enabled:=true; mb3.Enabled:=true; nb3.Enabled:=true; plusc3.Enabled:=true; minc3.Enabled:=true; conscona3.Enabled:=true; end; end; procedure TForm1.FormCreate(Sender: TObject); begin form1.Image1.Picture.LoadFromFile(applica tion.Location+'Aset/background_1.jpg'); form1.Icon.LoadFromFile(application.Locati on+'Aset/icon.ico'); end; procedure TForm1.inputparent1; begin i[1]:=strtoint(inputi1.Text); j[1]:=strtoint(inputj1.Text); end; procedure TForm1.inputparent2; begin i[2]:=strtoint(inputi2.Text); j[2]:=strtoint(inputj2.Text); end; procedure TForm1.inputparent3; begin i[3]:=strtoint(inputi3.Text); j[3]:=strtoint(inputj3.Text); end; procedure TForm1.inputparent4; begin i[4]:=strtoint(inputi4.Text); j[4]:=strtoint(inputj4.Text); end; procedure TForm1.inputparent5; begin i[5]:=strtoint(inputi5.Text); j[5]:=strtoint(inputj5.Text); end; procedure TForm1.inputparent6; begin i[6]:=strtoint(inputi6.Text); j[6]:=strtoint(inputj6.Text); end; procedure TForm1.inputparent7; begin i[7]:=strtoint(inputi7.Text); j[7]:=strtoint(inputj7.Text); end; procedure TForm1.inputparent8; begin i[8]:=strtoint(inputi8.Text); j[8]:=strtoint(inputj8.Text); end; procedure TForm1.inputparent9; begin i[9]:=strtoint(inputi9.Text); j[9]:=strtoint(inputj9.Text); end; procedure TForm1.kondisipertama; var a,b,c,d:integer; begin begin if ia1.Checked=true then a:=i[x]; if ja1.Checked=true then a:=j[x]; if ma1.Checked=true then a:=m; if na1.Checked=true then a:=n; end; begin if plusa1.Checked=true then a:=a;
363
if mina1.Checked=true then a:=-a; end; begin if ib1.Checked=true then b:=i[x]; if jb1.Checked=true then b:=j[x]; if mb1.Checked=true then b:=m; if nb1.Checked=true then b:=n; end; begin if plusb1.Checked=true then b:=b; if minb1.Checked=true then b:=-b; end; begin c:=strtoint(conscona1.Text); if plusc1.Checked=true then c:=c; if minc1.Checked=true then c:=-c; end; begin a1:=a+b+c; end; begin d:=strtoint(consconb1.Text); if plusd1.Checked=true then d:=d; if mind1.Checked=true then d:=-d; end; //= nilai kondisi 1 ==================================[ begin if moresame1.Checked=true then begin if a1>=d then kondisi1:=true else kondisi1:=false; end; if more1.Checked=true then begin if a1>d then kondisi1:=true else kondisi1:=false; end; if lesssame1.Checked=true then begin if a1<=d then kondisi1:=true else kondisi1:=false; end; if less1.Checked=true then begin if a1
//================================== ============= //= jika argument sama ==================== if checksameargument1.Checked=true then begin begin if ia1.Checked=true then a:=i[x]; if ja1.Checked=true then a:=j[x]; if ma1.Checked=true then a:=m; if na1.Checked=true then a:=n; end; begin if plusa1.Checked=true then a:=a; if mina1.Checked=true then a:=-a; end; begin if ib1.Checked=true then b:=i[x]; if jb1.Checked=true then b:=j[x]; if mb1.Checked=true then b:=m; if nb1.Checked=true then b:=n; end; begin if plusb1.Checked=true then b:=b; if minb1.Checked=true then b:=-b; end; begin c:=strtoint(conscona1.Text); if plusc1.Checked=true then c:=c; if minc1.Checked=true then c:=-c; end; begin a2:=a+b+c; end; end; //================================== ============= begin d:=strtoint(consconc2.Text); if pluse2.Checked=true then d:=d; if mine2.Checked=true then d:=-d; end; if (checkcondition3.Checked=true) and (checkcondition2samesign.Checked=false) then begin d1:=strtoint(conscona2.Text); if plusa2.Checked=true then d1:=d1; if mina2.Checked=true then d1:=-d1; end; //= nilai kondisi 2 jika hanya 2 kondisi ============== if checkcondition3.Checked=false then begin if moresameb2.Checked=true then begin if a2>=d then kondisi2:=true else kondisi2:=false; end; if moreb2.Checked=true then begin if a2>d then kondisi2:=true else kondisi2:=false; end; if lesssameb2.Checked=true then begin if a2<=d then kondisi2:=true else kondisi2:=false; end; if lessb2.Checked=true then begin if a2
begin if moresamea2.Checked=true then begin if moresameb2.Checked=true then begin if (d1>=a2) and (a2>=d) then kondisi2:=true else kondisi2:=false; end; if moreb2.Checked=true then begin if (d1>=a2) and (a2>d) then kondisi2:=true else kondisi2:=false; end; if lesssameb2.Checked=true then begin if (d1>=a2) and (a2<=d) then kondisi2:=true else kondisi2:=false; end; if lessb2.Checked=true then begin if (d1>=a2) and (a2
a2) and (a2>=d) then kondisi2:=true else kondisi2:=false; end; if moreb2.Checked=true then begin if (d1>a2) and (a2>d) then kondisi2:=true else kondisi2:=false; end; if lesssameb2.Checked=true then begin if (d1>a2) and (a2<=d) then kondisi2:=true else kondisi2:=false; end; if lessb2.Checked=true then begin if (d1>a2) and (a2=d) then kondisi2:=true else kondisi2:=false; end; if moreb2.Checked=true then begin if (d1<=a2) and (a2>d) then kondisi2:=true else kondisi2:=false; end; if lesssameb2.Checked=true then begin if (d1<=a2) and (a2<=d) then kondisi2:=true else kondisi2:=false; end; if lessb2.Checked=true then begin if (d1<=a2) and (a2=d) then kondisi2:=true
364
else kondisi2:=false; end; if moreb2.Checked=true then begin if (d1d) then kondisi2:=true else kondisi2:=false; end; if lesssameb2.Checked=true then begin if (d1
end; end; //================================== ============= begin d:=strtoint(consconb3.Text); if plusd3.Checked=true then d:=d; if mind3.Checked=true then d:=-d; end; //=== cari nilai kondisi 3 =================== begin if moresame3.Checked=true then begin if a3>=d then kondisi3:=true else kondisi3:=false; end; if more3.Checked=true then begin if a3>d then kondisi3:=true else kondisi3:=false; end; if lesssame3.Checked=true then begin if a3<=d then kondisi3:=true else kondisi3:=false; end; if less3.Checked=true then begin if a3
procedure TForm1.posisim2; var a,b,c:integer; begin begin if ima2.Checked=true then a:=i[x]; if jma2.Checked=true then a:=j[x]; if mma2.Checked=true then a:=m; if nma2.Checked=true then a:=n; if imb2.Checked=true then b:=i[x]; if jmb2.Checked=true then b:=j[x]; if mmb2.Checked=true then b:=m; if nmb2.Checked=true then b:=n; c:=strtoint(consm2.Text); end; begin if plusma2.Checked=true then a:=a; if minma2.Checked=true then a:=-a; if plusmb2.Checked=true then b:=b; if minmb2.Checked=true then b:=-b; if plusmc2.Checked=true then c:=c; if minmc2.Checked=true then c:=-c; end; begin posm[x,m,n]:=a+b+c; end; end; procedure TForm1.posisin2; var a,b,c:integer; begin begin if ina2.Checked=true then a:=i[x]; if jna2.Checked=true then a:=j[x]; if mna2.Checked=true then a:=m; if nna2.Checked=true then a:=n; if inb2.Checked=true then b:=i[x]; if jnb2.Checked=true then b:=j[x]; if mnb2.Checked=true then b:=m; if nnb2.Checked=true then b:=n; c:=strtoint(consn2.Text); end; begin if plusna2.Checked=true then a:=a; if minna2.Checked=true then a:=-a; if plusnb2.Checked=true then b:=b; if minnb2.Checked=true then b:=-b; if plusnc2.Checked=true then c:=c; if minnc2.Checked=true then c:=-c; end; begin posn[x,m,n]:=a+b+c; end; end; procedure TForm1.posisim3; var a,b,c:integer; begin begin if ima3.Checked=true then a:=i[x]; if jma3.Checked=true then a:=j[x]; if mma3.Checked=true then a:=m; if nma3.Checked=true then a:=n; if imb3.Checked=true then b:=i[x]; if jmb3.Checked=true then b:=j[x]; if mmb3.Checked=true then b:=m; if nmb3.Checked=true then b:=n; c:=strtoint(consm3.Text); end; begin if plusma3.Checked=true then a:=a; if minma3.Checked=true then a:=-a; if plusmb3.Checked=true then b:=b; if minmb3.Checked=true then b:=-b; if plusmc3.Checked=true then c:=c; if minmc3.Checked=true then c:=-c; end; begin posm[x,m,n]:=a+b+c; end; end; procedure TForm1.posisin3; var a,b,c:integer; begin begin if ina3.Checked=true then a:=i[x]; if jna3.Checked=true then a:=j[x]; if mna3.Checked=true then a:=m; if nna3.Checked=true then a:=n; if inb3.Checked=true then b:=i[x]; if jnb3.Checked=true then b:=j[x];
365
if mnb3.Checked=true then b:=m; if nnb3.Checked=true then b:=n; c:=strtoint(consn3.Text); end; begin if plusna3.Checked=true then a:=a; if minna3.Checked=true then a:=-a; if plusnb3.Checked=true then b:=b; if minnb3.Checked=true then b:=-b; if plusnc3.Checked=true then c:=c; if minnc3.Checked=true then c:=-c; end; begin posn[x,m,n]:=a+b+c; end; end; procedure TForm1.Button1Click(Sender: TObject); var a,b,c,d:integer; begin //== setting nilai vaiabel awal =============================== begin for a:=1 to 9 do begin i[a]:=0; j[a]:=0; end; for b:=1 to 9 do begin for c:=1 to 10 do begin for d:=1 to 3 do begin posm[b,c,d]:=0; posn[b,c,d]:=0; end; end; end; y:=0;x:=0; a1:=0;a2:=0;a3:=0; m:=0;n:=0; kondisi1:=false;kondisi2:=false;kondisi3:=fal se; end; //= baca input cell parent ====== begin if checkcellparent1.Checked=true then begin form1.inputparent1;y:=1; end; if checkcellparent2.Checked=true then begin form1.inputparent2;y:=2; end; if checkcellparent3.Checked=true then begin form1.inputparent3;y:=3; end; if checkcellparent4.Checked=true then begin form1.inputparent4;y:=4; end; if checkcellparent5.Checked=true then begin form1.inputparent5;y:=5; end; if checkcellparent6.Checked=true then begin form1.inputparent6;y:=6; end; if checkcellparent7.Checked=true then begin form1.inputparent7;y:=7; end; if checkcellparent8.Checked=true then begin form1.inputparent8;y:=8; end; if checkcellparent9.Checked=true then begin form1.inputparent9;y:=9; end; end; //= cari posisi ================================ begin for x:=1 to y do begin
for m:=1 to 10 do begin for n:=1 to 3 do begin form1.kondisipertama; form1.kondisikedua; if checkcondition3.Checked=true then begin form1.kondisiketiga; end; begin if kondisi1=true then begin form1.posisim1; form1.posisin1; end; if kondisi2=true then begin form1.posisim2; form1.posisin2; end; if kondisi3=true then begin form1.posisim3; form1.posisin3; end;end;end;end;end;end; begin form2.Show; end;end; end.
b. Unit2.pas unit Unit2; {$mode objfpc}{$H+} interface uses Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ComCtrls,Grids, ExtCtrls, StdCtrls; type { TForm2 } TForm2 = class(TForm) PageControl1: TPageControl; StringGrid2: TStringGrid;StringGrid1: TStringGrid; StringGrid3: TStringGrid;StringGrid4: TStringGrid; StringGrid5: TStringGrid;StringGrid6: TStringGrid; TabSheet1: TTabSheet;TabSheet2: TTabSheet; TabSheet3: TTabSheet;TabSheet4: TTabSheet; TabSheet5: TTabSheet;TabSheet6: TTabSheet; procedure FormClose(Sender: TObject; var CloseAction: TCloseAction); procedure posisisubjek1;procedure posisisubjek2; procedure posisisubjek3; procedure posisisubjek4; procedure posisisubjek5;procedure posisisubjek6; procedure FormShow(Sender: TObject); private { private declarations } public { public declarations } end; var Form2: TForm2; implementation uses unit1; {$R *.lfm} { TForm2 } procedure TForm2.posisisubjek1; begin tabsheet1.TabVisible:=true; StringGrid1.Cells[0,1]:='(1,1)'; StringGrid1.Cells[0,2]:='(2,1)'; StringGrid1.Cells[0,3]:='(1,2)'; StringGrid1.Cells[0,4]:='(2,2)'; if form1.checkcellparent1.Checked=true then begin
StringGrid1.Cells[1,1]:='('+inttostr(posm[1,1, 1])+','+ inttostr(posn[1,1,1])+')'; StringGrid1.Cells[1,2]:='('+IntToStr(posm[1,2 ,1])+','+ Inttostr(posn[1,2,1])+')'; StringGrid1.Cells[1,3]:='('+inttostr(posm[1,1, 2])+','+ inttostr(posn[1,1,2])+')'; StringGrid1.Cells[1,4]:='('+IntToStr(posm[1,2 ,2])+','+ Inttostr(posn[1,2,2])+')'; end; end; procedure TForm2.FormClose(Sender: TObject; var CloseAction: TCloseAction); begin kondisi1:=false;kondisi2:=false;kondisi3:=fal se; end; procedure TForm2.posisisubjek2; begin tabsheet2.TabVisible:=true; StringGrid2.Cells[0,1]:='(1,1)'; StringGrid2.Cells[0,2]:='(2,1)'; StringGrid2.Cells[0,3]:='(3,1)'; StringGrid2.Cells[0,4]:='(1,2)'; StringGrid2.Cells[0,5]:='(2,2)'; StringGrid2.Cells[0,6]:='(3,2)'; begin if form1.checkcellparent1.Checked=true then begin StringGrid2.Cells[1,1]:='('+inttostr(posm[1,1, 1])+','+ inttostr(posn[1,1,1])+')'; StringGrid2.Cells[1,2]:='('+IntToStr(posm[1,2 ,1])+','+ Inttostr(posn[1,2,1])+')'; StringGrid2.Cells[1,3]:='('+IntToStr(posm[1,3 ,1])+','+ IntToStr(posn[1,3,1])+')'; StringGrid2.Cells[1,4]:='('+inttostr(posm[1,1, 2])+','+ inttostr(posn[1,1,2])+')'; StringGrid2.Cells[1,5]:='('+IntToStr(posm[1,2 ,2])+','+ Inttostr(posn[1,2,2])+')'; StringGrid2.Cells[1,6]:='('+IntToStr(posm[1,3 ,2])+','+ IntToStr(posn[1,3,2])+')'; end; if form1.checkcellparent2.Checked=true then begin StringGrid2.Cells[2,1]:='('+inttostr(posm[2,1, 1])+','+ inttostr(posn[2,1,1])+')'; StringGrid2.Cells[2,2]:='('+IntToStr(posm[2,2 ,1])+','+ Inttostr(posn[2,2,1])+')'; StringGrid2.Cells[2,3]:='('+IntToStr(posm[2,3 ,1])+','+ IntToStr(posn[2,3,1])+')'; StringGrid2.Cells[2,4]:='('+inttostr(posm[2,1, 2])+','+ inttostr(posn[2,1,2])+')'; StringGrid2.Cells[2,5]:='('+IntToStr(posm[2,2 ,2])+','+ Inttostr(posn[2,2,2])+')'; StringGrid2.Cells[2,6]:='('+IntToStr(posm[2,3 ,2])+','+ IntToStr(posn[2,3,2])+')'; end;end;end; procedure TForm2.posisisubjek3; begin tabsheet3.TabVisible:=true; StringGrid3.Cells[0,1]:='(1,1)'; StringGrid3.Cells[0,2]:='(2,1)'; StringGrid3.Cells[0,3]:='(3,1)'; StringGrid3.Cells[0,4]:='(4,1)'; StringGrid3.Cells[0,5]:='(5,1)'; StringGrid3.Cells[0,6]:='(1,2)'; StringGrid3.Cells[0,7]:='(2,2)'; StringGrid3.Cells[0,8]:='(3,2)'; StringGrid3.Cells[0,9]:='(4,2)'; StringGrid3.Cells[0,10]:='(5,2)';
366
begin if form1.checkcellparent1.Checked=true then begin StringGrid3.Cells[1,1]:='('+inttostr(posm[1,1, 1])+','+inttostr(posn[1,1,1])+')'; StringGrid3.Cells[1,2]:='('+IntToStr(posm[1,2 ,1])+','+Inttostr(posn[1,2,1])+')'; StringGrid3.Cells[1,3]:='('+IntToStr(posm[1,3 ,1])+','+IntToStr(posn[1,3,1])+')'; StringGrid3.Cells[1,4]:='('+IntToStr(posm[1,4 ,1])+','+Inttostr(posn[1,4,1])+')'; StringGrid3.Cells[1,5]:='('+IntToStr(posm[1,5 ,1])+','+IntToStr(posn[1,5,1])+')'; StringGrid3.Cells[1,6]:='('+IntToStr(posm[1,1 ,2])+','+IntToStr(posn[1,1,2])+')'; StringGrid3.Cells[1,7]:='('+IntToStr(posm[1,2 ,2])+','+IntToStr(posn[1,2,2])+')'; StringGrid3.Cells[1,8]:='('+IntToStr(posm[1,3 ,2])+','+IntToStr(posn[1,3,2])+')'; StringGrid3.Cells[1,9]:='('+IntToStr(posm[1,4 ,2])+','+IntToStr(posn[1,4,2])+')'; StringGrid3.Cells[1,10]:='('+IntToStr(posm[1, 5,2])+','+IntToStr(posn[1,5,2])+')'; end; if form1.checkcellparent2.Checked=true then begin StringGrid3.Cells[2,1]:='('+inttostr(posm[2,1, 1])+','+inttostr(posn[2,1,1])+')'; StringGrid3.Cells[2,2]:='('+IntToStr(posm[2,2 ,1])+','+Inttostr(posn[2,2,1])+')'; StringGrid3.Cells[2,3]:='('+IntToStr(posm[2,3 ,1])+','+IntToStr(posn[2,3,1])+')'; StringGrid3.Cells[2,4]:='('+IntToStr(posm[2,4 ,1])+','+Inttostr(posn[2,4,1])+')'; StringGrid3.Cells[2,5]:='('+IntToStr(posm[2,5 ,1])+','+IntToStr(posn[2,5,1])+')'; StringGrid3.Cells[2,6]:='('+IntToStr(posm[2,1 ,2])+','+IntToStr(posn[2,1,2])+')'; StringGrid3.Cells[2,7]:='('+IntToStr(posm[2,2 ,2])+','+IntToStr(posn[2,2,2])+')'; StringGrid3.Cells[2,8]:='('+IntToStr(posm[2,3 ,2])+','+IntToStr(posn[2,3,2])+')'; StringGrid3.Cells[2,9]:='('+IntToStr(posm[2,4 ,2])+','+IntToStr(posn[2,4,2])+')'; StringGrid3.Cells[2,10]:='('+IntToStr(posm[2, 5,2])+','+IntToStr(posn[2,5,2])+')'; end; if form1.checkcellparent3.Checked=true then begin StringGrid3.Cells[3,1]:='('+inttostr(posm[3,1, 1])+','+inttostr(posn[3,1,1])+')'; StringGrid3.Cells[3,2]:='('+IntToStr(posm[3,2 ,1])+','+Inttostr(posn[3,2,1])+')'; StringGrid3.Cells[3,3]:='('+IntToStr(posm[3,3 ,1])+','+IntToStr(posn[3,3,1])+')'; StringGrid3.Cells[3,4]:='('+IntToStr(posm[3,4 ,1])+','+Inttostr(posn[3,4,1])+')'; StringGrid3.Cells[3,5]:='('+IntToStr(posm[3,5 ,1])+','+IntToStr(posn[3,5,1])+')'; StringGrid3.Cells[3,6]:='('+IntToStr(posm[3,1 ,2])+','+IntToStr(posn[3,1,2])+')'; StringGrid3.Cells[3,7]:='('+IntToStr(posm[3,2 ,2])+','+IntToStr(posn[3,2,2])+')'; StringGrid3.Cells[3,8]:='('+IntToStr(posm[3,3 ,2])+','+IntToStr(posn[3,3,2])+')'; StringGrid3.Cells[3,9]:='('+IntToStr(posm[3,4 ,2])+','+IntToStr(posn[3,4,2])+')'; StringGrid3.Cells[3,10]:='('+IntToStr(posm[3, 5,2])+','+IntToStr(posn[3,5,2])+')'; end; if form1.checkcellparent4.Checked=true then begin StringGrid3.Cells[4,1]:='('+inttostr(posm[4,1, 1])+','+inttostr(posn[4,1,1])+')'; StringGrid3.Cells[4,2]:='('+IntToStr(posm[4,2 ,1])+','+Inttostr(posn[4,2,1])+')'; StringGrid3.Cells[4,3]:='('+IntToStr(posm[4,3 ,1])+','+IntToStr(posn[4,3,1])+')'; StringGrid3.Cells[4,4]:='('+IntToStr(posm[4,4 ,1])+','+Inttostr(posn[4,4,1])+')'; StringGrid3.Cells[4,5]:='('+IntToStr(posm[4,5 ,1])+','+IntToStr(posn[4,5,1])+')'; StringGrid3.Cells[4,6]:='('+IntToStr(posm[4,1 ,2])+','+IntToStr(posn[4,1,2])+')'; StringGrid3.Cells[4,7]:='('+IntToStr(posm[4,2 ,2])+','+IntToStr(posn[4,2,2])+')'; StringGrid3.Cells[4,8]:='('+IntToStr(posm[4,3 ,2])+','+IntToStr(posn[4,3,2])+')';
StringGrid3.Cells[4,9]:='('+IntToStr(posm[4,4 ,2])+','+IntToStr(posn[4,4,2])+')'; StringGrid3.Cells[4,10]:='('+IntToStr(posm[4, 5,2])+','+IntToStr(posn[4,5,2])+')'; end; end; end; procedure TForm2.posisisubjek4; begin tabsheet4.TabVisible:=true; StringGrid4.Cells[0,1]:='(1,1)'; StringGrid4.Cells[0,2]:='(2,1)'; StringGrid4.Cells[0,3]:='(3,1)'; StringGrid4.Cells[0,4]:='(4,1)'; StringGrid4.Cells[0,5]:='(5,1)'; StringGrid4.Cells[0,6]:='(6,1)'; StringGrid4.Cells[0,7]:='(1,2)'; StringGrid4.Cells[0,8]:='(2,2)'; StringGrid4.Cells[0,9]:='(3,2)'; StringGrid4.Cells[0,10]:='(4,2)'; StringGrid4.Cells[0,11]:='(5,2)'; StringGrid4.Cells[0,12]:='(6,2)'; begin if form1.checkcellparent1.Checked=true then begin StringGrid4.Cells[1,1]:='('+inttostr(posm[1,1, 1])+','+inttostr(posn[1,1,1])+')'; StringGrid4.Cells[1,2]:='('+IntToStr(posm[1,2 ,1])+','+Inttostr(posn[1,2,1])+')'; StringGrid4.Cells[1,3]:='('+IntToStr(posm[1,3 ,1])+','+IntToStr(posn[1,3,1])+')'; StringGrid4.Cells[1,4]:='('+IntToStr(posm[1,4 ,1])+','+Inttostr(posn[1,4,1])+')'; StringGrid4.Cells[1,5]:='('+IntToStr(posm[1,5 ,1])+','+IntToStr(posn[1,5,1])+')'; StringGrid4.Cells[1,6]:='('+IntToStr(posm[1,6 ,1])+','+IntToStr(posn[1,6,1])+')'; StringGrid4.Cells[1,7]:='('+IntToStr(posm[1,1 ,2])+','+IntToStr(posn[1,1,2])+')'; StringGrid4.Cells[1,8]:='('+IntToStr(posm[1,2 ,2])+','+IntToStr(posn[1,2,2])+')'; StringGrid4.Cells[1,9]:='('+IntToStr(posm[1,3 ,2])+','+IntToStr(posn[1,3,2])+')'; StringGrid4.Cells[1,10]:='('+IntToStr(posm[1, 4,2])+','+IntToStr(posn[1,4,2])+')'; StringGrid4.Cells[1,11]:='('+IntToStr(posm[1, 5,2])+','+IntToStr(posn[1,5,2])+')'; StringGrid4.Cells[1,12]:='('+IntToStr(posm[1, 6,2])+','+IntToStr(posn[1,6,2])+')'; end; if form1.checkcellparent2.Checked=true then begin StringGrid4.Cells[2,1]:='('+inttostr(posm[2,1, 1])+','+inttostr(posn[2,1,1])+')'; StringGrid4.Cells[2,2]:='('+IntToStr(posm[2,2 ,1])+','+Inttostr(posn[2,2,1])+')'; StringGrid4.Cells[2,3]:='('+IntToStr(posm[2,3 ,1])+','+IntToStr(posn[2,3,1])+')'; StringGrid4.Cells[2,4]:='('+IntToStr(posm[2,4 ,1])+','+Inttostr(posn[2,4,1])+')'; StringGrid4.Cells[2,5]:='('+IntToStr(posm[2,5 ,1])+','+IntToStr(posn[2,5,1])+')'; StringGrid4.Cells[2,6]:='('+IntToStr(posm[2,6 ,1])+','+IntToStr(posn[2,6,1])+')'; StringGrid4.Cells[2,7]:='('+IntToStr(posm[2,1 ,2])+','+IntToStr(posn[2,1,2])+')'; StringGrid4.Cells[2,8]:='('+IntToStr(posm[2,2 ,2])+','+IntToStr(posn[2,2,2])+')'; StringGrid4.Cells[2,9]:='('+IntToStr(posm[2,3 ,2])+','+IntToStr(posn[2,3,2])+')'; StringGrid4.Cells[2,10]:='('+IntToStr(posm[2, 4,2])+','+IntToStr(posn[2,4,2])+')'; StringGrid4.Cells[2,11]:='('+IntToStr(posm[2, 5,2])+','+IntToStr(posn[2,5,2])+')'; StringGrid4.Cells[2,12]:='('+IntToStr(posm[2, 6,2])+','+IntToStr(posn[2,6,2])+')'; end; if form1.checkcellparent3.Checked=true then begin StringGrid4.Cells[3,1]:='('+inttostr(posm[3,1, 1])+','+inttostr(posn[3,1,1])+')'; StringGrid4.Cells[3,2]:='('+IntToStr(posm[3,2 ,1])+','+Inttostr(posn[3,2,1])+')'; StringGrid4.Cells[3,3]:='('+IntToStr(posm[3,3 ,1])+','+IntToStr(posn[3,3,1])+')'; StringGrid4.Cells[3,4]:='('+IntToStr(posm[3,4 ,1])+','+Inttostr(posn[3,4,1])+')';
StringGrid4.Cells[3,5]:='('+IntToStr(posm[3,5 ,1])+','+IntToStr(posn[3,5,1])+')'; StringGrid4.Cells[3,6]:='('+IntToStr(posm[3,6 ,1])+','+IntToStr(posn[3,6,1])+')'; StringGrid4.Cells[3,7]:='('+IntToStr(posm[3,1 ,2])+','+IntToStr(posn[3,1,2])+')'; StringGrid4.Cells[3,8]:='('+IntToStr(posm[3,2 ,2])+','+IntToStr(posn[3,2,2])+')'; StringGrid4.Cells[3,9]:='('+IntToStr(posm[3,3 ,2])+','+IntToStr(posn[3,3,2])+')'; StringGrid4.Cells[3,10]:='('+IntToStr(posm[3, 4,2])+','+IntToStr(posn[3,4,2])+')'; StringGrid4.Cells[3,11]:='('+IntToStr(posm[3, 5,2])+','+IntToStr(posn[3,5,2])+')'; StringGrid4.Cells[3,12]:='('+IntToStr(posm[3, 6,2])+','+IntToStr(posn[3,6,2])+')'; end; if form1.checkcellparent4.Checked=true then begin StringGrid4.Cells[4,1]:='('+inttostr(posm[4,1, 1])+','+inttostr(posn[4,1,1])+')'; StringGrid4.Cells[4,2]:='('+IntToStr(posm[4,2 ,1])+','+Inttostr(posn[4,2,1])+')'; StringGrid4.Cells[4,3]:='('+IntToStr(posm[4,3 ,1])+','+IntToStr(posn[4,3,1])+')'; StringGrid4.Cells[4,4]:='('+IntToStr(posm[4,4 ,1])+','+Inttostr(posn[4,4,1])+')'; StringGrid4.Cells[4,5]:='('+IntToStr(posm[4,5 ,1])+','+IntToStr(posn[4,5,1])+')'; StringGrid4.Cells[4,6]:='('+IntToStr(posm[4,6 ,1])+','+IntToStr(posn[4,6,1])+')'; StringGrid4.Cells[4,7]:='('+IntToStr(posm[4,1 ,2])+','+IntToStr(posn[4,1,2])+')'; StringGrid4.Cells[4,8]:='('+IntToStr(posm[4,2 ,2])+','+IntToStr(posn[4,2,2])+')'; StringGrid4.Cells[4,9]:='('+IntToStr(posm[4,3 ,2])+','+IntToStr(posn[4,3,2])+')'; StringGrid4.Cells[4,10]:='('+IntToStr(posm[4, 4,2])+','+IntToStr(posn[4,4,2])+')'; StringGrid4.Cells[4,11]:='('+IntToStr(posm[4, 5,2])+','+IntToStr(posn[4,5,2])+')'; StringGrid4.Cells[4,12]:='('+IntToStr(posm[4, 6,2])+','+IntToStr(posn[4,6,2])+')'; end; if form1.checkcellparent5.Checked=true then begin StringGrid4.Cells[5,1]:='('+inttostr(posm[5,1, 1])+','+inttostr(posn[5,1,1])+')'; StringGrid4.Cells[5,2]:='('+IntToStr(posm[5,2 ,1])+','+Inttostr(posn[5,2,1])+')'; StringGrid4.Cells[5,3]:='('+IntToStr(posm[5,3 ,1])+','+IntToStr(posn[5,3,1])+')'; StringGrid4.Cells[5,4]:='('+IntToStr(posm[5,4 ,1])+','+Inttostr(posn[5,4,1])+')'; StringGrid4.Cells[5,5]:='('+IntToStr(posm[5,5 ,1])+','+IntToStr(posn[5,5,1])+')'; StringGrid4.Cells[5,6]:='('+IntToStr(posm[5,6 ,1])+','+IntToStr(posn[5,6,1])+')'; StringGrid4.Cells[5,7]:='('+IntToStr(posm[5,1 ,2])+','+IntToStr(posn[5,1,2])+')'; StringGrid4.Cells[5,8]:='('+IntToStr(posm[5,2 ,2])+','+IntToStr(posn[5,2,2])+')'; StringGrid4.Cells[5,9]:='('+IntToStr(posm[5,3 ,2])+','+IntToStr(posn[5,3,2])+')'; StringGrid4.Cells[5,10]:='('+IntToStr(posm[5, 4,2])+','+IntToStr(posn[5,4,2])+')'; StringGrid4.Cells[5,11]:='('+IntToStr(posm[5, 5,2])+','+IntToStr(posn[5,5,2])+')'; StringGrid4.Cells[5,12]:='('+IntToStr(posm[5, 6,2])+','+IntToStr(posn[5,6,2])+')'; end; end; end; procedure TForm2.posisisubjek5; var d1,d2,d3,e1,e2,e3,f1,f2,f3,g1,g2,g3:integer; begin tabsheet5.TabVisible:=true; StringGrid5.Cells[0,1]:='(1,1)'; StringGrid5.Cells[0,2]:='(2,1)'; StringGrid5.Cells[0,3]:='(3,1)'; StringGrid5.Cells[0,4]:='(4,1)'; StringGrid5.Cells[0,5]:='(5,1)'; StringGrid5.Cells[0,6]:='(6,1)'; StringGrid5.Cells[0,7]:='(7,1)'; StringGrid5.Cells[0,8]:='(8,1)'; StringGrid5.Cells[0,9]:='(1,2)'; StringGrid5.Cells[0,10]:='(2,2)';
367
StringGrid5.Cells[0,11]:='(3,2)'; StringGrid5.Cells[0,12]:='(4,2)'; StringGrid5.Cells[0,13]:='(5,2)'; StringGrid5.Cells[0,14]:='(6,2)'; StringGrid5.Cells[0,15]:='(7,2)'; StringGrid5.Cells[0,16]:='(8,2)'; StringGrid5.Cells[0,17]:='(1,3)'; StringGrid5.Cells[0,18]:='(2,3)'; StringGrid5.Cells[0,19]:='(3,3)'; StringGrid5.Cells[0,20]:='(4,3)'; StringGrid5.Cells[0,21]:='(5,3)'; StringGrid5.Cells[0,22]:='(6,3)'; StringGrid5.Cells[0,23]:='(7,3)'; StringGrid5.Cells[0,24]:='(8,3)'; begin if form1.checkcellparent1.Checked=true then begin StringGrid5.Cells[1,1]:='('+inttostr(posm[1,1, 1])+','+inttostr(posn[1,1,1])+')'; StringGrid5.Cells[1,2]:='('+inttostr(posm[1,2, 1])+','+inttostr(posn[1,2,1])+')'; StringGrid5.Cells[1,3]:='('+inttostr(posm[1,3, 1])+','+inttostr(posn[1,3,1])+')'; StringGrid5.Cells[1,4]:='('+inttostr(posm[1,4, 1])+','+inttostr(posn[1,4,1])+')'; StringGrid5.Cells[1,5]:='('+inttostr(posm[1,5, 1])+','+inttostr(posn[1,5,1])+')'; StringGrid5.Cells[1,6]:='('+inttostr(posm[1,6, 1])+','+inttostr(posn[1,6,1])+')'; StringGrid5.Cells[1,7]:='('+inttostr(posm[1,7, 1])+','+inttostr(posn[1,7,1])+')'; StringGrid5.Cells[1,8]:='('+inttostr(posm[1,8, 1])+','+inttostr(posn[1,8,1])+')'; StringGrid5.Cells[1,9]:='('+inttostr(posm[1,1, 2])+','+inttostr(posn[1,1,2])+')'; StringGrid5.Cells[1,10]:='('+inttostr(posm[1, 2,2])+','+inttostr(posn[1,2,2])+')'; StringGrid5.Cells[1,11]:='('+inttostr(posm[1, 3,2])+','+inttostr(posn[1,3,2])+')'; StringGrid5.Cells[1,12]:='('+inttostr(posm[1, 4,2])+','+inttostr(posn[1,4,2])+')'; StringGrid5.Cells[1,13]:='('+inttostr(posm[1, 5,2])+','+inttostr(posn[1,5,2])+')'; StringGrid5.Cells[1,14]:='('+inttostr(posm[1, 6,2])+','+inttostr(posn[1,6,2])+')'; StringGrid5.Cells[1,15]:='('+inttostr(posm[1, 7,2])+','+inttostr(posn[1,7,2])+')'; StringGrid5.Cells[1,16]:='('+inttostr(posm[1, 8,2])+','+inttostr(posn[1,8,2])+')'; StringGrid5.Cells[1,17]:='('+inttostr(posm[1, 1,3])+','+inttostr(posn[1,1,3])+')'; StringGrid5.Cells[1,18]:='('+inttostr(posm[1, 2,3])+','+inttostr(posn[1,2,3])+')'; StringGrid5.Cells[1,19]:='('+inttostr(posm[1, 3,3])+','+inttostr(posn[1,3,3])+')'; StringGrid5.Cells[1,20]:='('+inttostr(posm[1, 4,3])+','+inttostr(posn[1,4,3])+')'; StringGrid5.Cells[1,21]:='('+inttostr(posm[1, 5,3])+','+inttostr(posn[1,5,3])+')'; StringGrid5.Cells[1,22]:='('+inttostr(posm[1, 6,3])+','+inttostr(posn[1,6,3])+')'; StringGrid5.Cells[1,23]:='('+inttostr(posm[1, 7,3])+','+inttostr(posn[1,7,3])+')'; StringGrid5.Cells[1,24]:='('+inttostr(posm[1, 8,3])+','+inttostr(posn[1,8,3])+')'; end; if form1.checkcellparent2.Checked=true then begin StringGrid5.Cells[2,1]:='('+inttostr(posm[2,1, 1])+','+inttostr(posn[2,1,1])+')'; StringGrid5.Cells[2,2]:='('+inttostr(posm[2,2, 1])+','+inttostr(posn[2,2,1])+')'; StringGrid5.Cells[2,3]:='('+inttostr(posm[2,3, 1])+','+inttostr(posn[2,3,1])+')'; StringGrid5.Cells[2,4]:='('+inttostr(posm[2,4, 1])+','+inttostr(posn[2,4,1])+')'; StringGrid5.Cells[2,5]:='('+inttostr(posm[2,5, 1])+','+inttostr(posn[2,5,1])+')'; StringGrid5.Cells[2,6]:='('+inttostr(posm[2,6, 1])+','+inttostr(posn[2,6,1])+')'; StringGrid5.Cells[2,7]:='('+inttostr(posm[2,7, 1])+','+inttostr(posn[2,7,1])+')'; StringGrid5.Cells[2,8]:='('+inttostr(posm[2,8, 1])+','+inttostr(posn[2,8,1])+')'; StringGrid5.Cells[2,9]:='('+inttostr(posm[2,1, 2])+','+inttostr(posn[2,1,2])+')'; StringGrid5.Cells[2,10]:='('+inttostr(posm[2, 2,2])+','+inttostr(posn[2,2,2])+')';
StringGrid5.Cells[2,11]:='('+inttostr(posm[2, 3,2])+','+inttostr(posn[2,3,2])+')'; StringGrid5.Cells[2,12]:='('+inttostr(posm[2, 4,2])+','+inttostr(posn[2,4,2])+')'; StringGrid5.Cells[2,13]:='('+inttostr(posm[2, 5,2])+','+inttostr(posn[2,5,2])+')'; StringGrid5.Cells[2,14]:='('+inttostr(posm[2, 6,2])+','+inttostr(posn[2,6,2])+')'; StringGrid5.Cells[2,15]:='('+inttostr(posm[2, 7,2])+','+inttostr(posn[2,7,2])+')'; StringGrid5.Cells[2,16]:='('+inttostr(posm[2, 8,2])+','+inttostr(posn[2,8,2])+')'; StringGrid5.Cells[2,17]:='('+inttostr(posm[2, 1,3])+','+inttostr(posn[2,1,3])+')'; StringGrid5.Cells[2,18]:='('+inttostr(posm[2, 2,3])+','+inttostr(posn[2,2,3])+')'; StringGrid5.Cells[2,19]:='('+inttostr(posm[2, 3,3])+','+inttostr(posn[2,3,3])+')'; StringGrid5.Cells[2,20]:='('+inttostr(posm[2, 4,3])+','+inttostr(posn[2,4,3])+')'; StringGrid5.Cells[2,21]:='('+inttostr(posm[2, 5,3])+','+inttostr(posn[2,5,3])+')'; StringGrid5.Cells[2,22]:='('+inttostr(posm[2, 6,3])+','+inttostr(posn[2,6,3])+')'; StringGrid5.Cells[2,23]:='('+inttostr(posm[2, 7,3])+','+inttostr(posn[2,7,3])+')'; StringGrid5.Cells[2,24]:='('+inttostr(posm[2, 8,3])+','+inttostr(posn[2,8,3])+')'; end; if form1.checkcellparent3.Checked=true then begin StringGrid5.Cells[3,1]:='('+inttostr(posm[3,1, 1])+','+inttostr(posn[3,1,1])+')'; StringGrid5.Cells[3,2]:='('+inttostr(posm[3,2, 1])+','+inttostr(posn[3,2,1])+')'; StringGrid5.Cells[3,3]:='('+inttostr(posm[3,3, 1])+','+inttostr(posn[3,3,1])+')'; StringGrid5.Cells[3,4]:='('+inttostr(posm[3,4, 1])+','+inttostr(posn[3,4,1])+')'; StringGrid5.Cells[3,5]:='('+inttostr(posm[3,5, 1])+','+inttostr(posn[3,5,1])+')'; StringGrid5.Cells[3,6]:='('+inttostr(posm[3,6, 1])+','+inttostr(posn[3,6,1])+')'; StringGrid5.Cells[3,7]:='('+inttostr(posm[3,7, 1])+','+inttostr(posn[3,7,1])+')'; StringGrid5.Cells[3,8]:='('+inttostr(posm[3,8, 1])+','+inttostr(posn[3,8,1])+')'; StringGrid5.Cells[3,9]:='('+inttostr(posm[3,1, 2])+','+inttostr(posn[3,1,2])+')'; StringGrid5.Cells[3,10]:='('+inttostr(posm[3, 2,2])+','+inttostr(posn[3,2,2])+')'; StringGrid5.Cells[3,11]:='('+inttostr(posm[3, 3,2])+','+inttostr(posn[3,3,2])+')'; StringGrid5.Cells[3,12]:='('+inttostr(posm[3, 4,2])+','+inttostr(posn[3,4,2])+')'; StringGrid5.Cells[3,13]:='('+inttostr(posm[3, 5,2])+','+inttostr(posn[3,5,2])+')'; StringGrid5.Cells[3,14]:='('+inttostr(posm[3, 6,2])+','+inttostr(posn[3,6,2])+')'; StringGrid5.Cells[3,15]:='('+inttostr(posm[3, 7,2])+','+inttostr(posn[3,7,2])+')'; StringGrid5.Cells[3,16]:='('+inttostr(posm[3, 8,2])+','+inttostr(posn[3,8,2])+')'; StringGrid5.Cells[3,17]:='('+inttostr(posm[3, 1,3])+','+inttostr(posn[3,1,3])+')'; StringGrid5.Cells[3,18]:='('+inttostr(posm[3, 2,3])+','+inttostr(posn[3,2,3])+')'; StringGrid5.Cells[3,19]:='('+inttostr(posm[3, 3,3])+','+inttostr(posn[3,3,3])+')'; StringGrid5.Cells[3,20]:='('+inttostr(posm[3, 4,3])+','+inttostr(posn[3,4,3])+')'; StringGrid5.Cells[3,21]:='('+inttostr(posm[3, 5,3])+','+inttostr(posn[3,5,3])+')'; StringGrid5.Cells[3,22]:='('+inttostr(posm[3, 6,3])+','+inttostr(posn[3,6,3])+')'; StringGrid5.Cells[3,23]:='('+inttostr(posm[3, 7,3])+','+inttostr(posn[3,7,3])+')'; StringGrid5.Cells[3,24]:='('+inttostr(posm[3, 8,3])+','+inttostr(posn[3,8,3])+')'; end; if form1.checkcellparent4.Checked=true then begin for d1:=1 to 8 do begin StringGrid5.Cells[4,d1]:='('+inttostr(posm[4, d1,1])+','+inttostr(posn[4,d1,1])+')'; end; for d2:=1 to 8 do
begin StringGrid5.Cells[4,d2+8]:='('+inttostr(posm[ 4,d2,2])+','+inttostr(posn[4,d2,2])+')'; end; for d3:=1 to 8 do begin StringGrid5.Cells[4,d3+16]:='('+inttostr(pos m[4,d3,3])+','+inttostr(posn[4,d3,3])+')'; end; end; if form1.checkcellparent5.Checked=true then begin for e1:=1 to 8 do begin StringGrid5.Cells[5,e1]:='('+inttostr(posm[5, e1,1])+','+inttostr(posn[5,e1,1])+')'; end; for e2:=1 to 8 do begin StringGrid5.Cells[5,e2+8]:='('+inttostr(posm[ 5,e2,2])+','+inttostr(posn[5,e2,2])+')'; end; for e3:=1 to 8 do begin StringGrid5.Cells[5,e3+16]:='('+inttostr(pos m[5,e3,3])+','+inttostr(posn[5,e3,3])+')'; end; end; if form1.checkcellparent6.Checked=true then begin for f1:=1 to 8 do begin StringGrid5.Cells[6,f1]:='('+inttostr(posm[6,f 1,1])+','+inttostr(posn[6,f1,1])+')'; end; for f2:=1 to 8 do begin StringGrid5.Cells[6,f2+8]:='('+inttostr(posm[ 6,f2,2])+','+inttostr(posn[6,f2,2])+')'; end; for f3:=1 to 8 do begin StringGrid5.Cells[6,f3+16]:='('+inttostr(posm [6,f3,3])+','+inttostr(posn[6,f3,3])+')'; end; end; if form1.checkcellparent7.Checked=true then begin for g1:=1 to 8 do begin StringGrid5.Cells[7,g1]:='('+inttostr(posm[7, g1,1])+','+inttostr(posn[7,g1,1])+')'; end; for g2:=1 to 8 do begin StringGrid5.Cells[7,g2+8]:='('+inttostr(posm[ 7,g2,2])+','+inttostr(posn[7,g2,2])+')'; end; for g3:=1 to 8 do begin StringGrid5.Cells[7,g3+16]:='('+inttostr(pos m[7,g3,3])+','+inttostr(posn[7,g3,3])+')'; end; end; end; end; procedure TForm2.posisisubjek6; var b1,b2,b3,c1,c2,c3,d1,d2,d3,f1,f2,f3,g1,g2,g3 :integer; h1,h2,h3,i1,i2,i3,j1,j2,j3,k1,k2,k3:integer; begin tabsheet6.TabVisible:=true; StringGrid6.Cells[0,1]:='(1,1)'; StringGrid6.Cells[0,2]:='(2,1)'; StringGrid6.Cells[0,3]:='(3,1)'; StringGrid6.Cells[0,4]:='(4,1)'; StringGrid6.Cells[0,5]:='(5,1)'; StringGrid6.Cells[0,6]:='(6,1)'; StringGrid6.Cells[0,7]:='(7,1)'; StringGrid6.Cells[0,8]:='(8,1)'; StringGrid6.Cells[0,9]:='(9,1)'; StringGrid6.Cells[0,10]:='(10,1)'; StringGrid6.Cells[0,11]:='(1,2)'; StringGrid6.Cells[0,12]:='(2,2)'; StringGrid6.Cells[0,13]:='(3,2)'; StringGrid6.Cells[0,14]:='(4,2)';
368
StringGrid6.Cells[0,15]:='(5,2)'; StringGrid6.Cells[0,16]:='(6,2)'; StringGrid6.Cells[0,17]:='(7,2)'; StringGrid6.Cells[0,18]:='(8,2)'; StringGrid6.Cells[0,19]:='(9,2)'; StringGrid6.Cells[0,20]:='(10,2)'; StringGrid6.Cells[0,21]:='(1,3)'; StringGrid6.Cells[0,22]:='(2,3)'; StringGrid6.Cells[0,23]:='(3,3)'; StringGrid6.Cells[0,24]:='(4,3)'; StringGrid6.Cells[0,25]:='(5,3)'; StringGrid6.Cells[0,26]:='(6,3)'; StringGrid6.Cells[0,27]:='(7,3)'; StringGrid6.Cells[0,28]:='(8,3)'; StringGrid6.Cells[0,29]:='(9,3)'; StringGrid6.Cells[0,30]:='(10,3)'; begin if form1.checkcellparent1.Checked=true then begin for b1:=1 to 10 do begin StringGrid6.Cells[1,b1]:='('+inttostr(posm[1, b1,1])+','+inttostr(posn[1,b1,1])+')'; end; for b2:=1 to 10 do begin StringGrid6.Cells[1,b2+10]:='('+inttostr(pos m[1,b2,2])+','+inttostr(posn[1,b2,2])+')'; end; for b3:=1 to 10 do begin StringGrid6.Cells[1,b3+20]:='('+inttostr(pos m[1,b3,3])+','+inttostr(posn[1,b3,3])+')'; end; end; if form1.checkcellparent2.Checked=true then begin for c1:=1 to 10 do begin StringGrid6.Cells[2,c1]:='('+inttostr(posm[2, c1,1])+','+inttostr(posn[2,c1,1])+')'; end; for c2:=1 to 10 do begin StringGrid6.Cells[2,c2+10]:='('+inttostr(pos m[2,c2,2])+','+inttostr(posn[2,c2,2])+')'; end; for c3:=1 to 10 do begin StringGrid6.Cells[2,c3+20]:='('+inttostr(pos m[2,c3,3])+','+inttostr(posn[2,c3,3])+')'; end; end; if form1.checkcellparent3.Checked=true then begin for d1:=1 to 10 do begin StringGrid6.Cells[3,d1]:='('+inttostr(posm[3, d1,1])+','+inttostr(posn[3,d1,1])+')'; end; for d2:=1 to 10 do begin StringGrid6.Cells[3,d2+10]:='('+inttostr(pos m[3,d2,2])+','+inttostr(posn[3,d2,2])+')'; end; for d3:=1 to 10 do begin StringGrid6.Cells[3,d3+20]:='('+inttostr(pos m[3,d3,3])+','+inttostr(posn[3,d3,3])+')'; end; end; if form1.checkcellparent4.Checked=true then begin for f1:=1 to 10 do begin StringGrid6.Cells[4,f1]:='('+inttostr(posm[4,f 1,1])+','+inttostr(posn[4,f1,1])+')'; end; for f2:=1 to 10 do begin StringGrid6.Cells[4,f2+10]:='('+inttostr(posm [4,f2,2])+','+inttostr(posn[4,f2,2])+')'; end; for f3:=1 to 10 do begin StringGrid6.Cells[4,f3+20]:='('+inttostr(posm [4,f3,3])+','+inttostr(posn[4,f3,3])+')';
end; end; if form1.checkcellparent5.Checked=true then begin for g1:=1 to 10 do begin StringGrid6.Cells[5,g1]:='('+inttostr(posm[5, g1,1])+','+inttostr(posn[5,g1,1])+')'; end; for g2:=1 to 10 do begin StringGrid6.Cells[5,g2+10]:='('+inttostr(pos m[5,g2,2])+','+inttostr(posn[5,g2,2])+')'; end; for g3:=1 to 10 do begin StringGrid6.Cells[5,g3+20]:='('+inttostr(pos m[5,g3,3])+','+inttostr(posn[5,g3,3])+')'; end; end; if form1.checkcellparent6.Checked=true then begin for h1:=1 to 10 do begin StringGrid6.Cells[6,h1]:='('+inttostr(posm[6, h1,1])+','+inttostr(posn[6,h1,1])+')'; end; for h2:=1 to 10 do begin StringGrid6.Cells[6,h2+10]:='('+inttostr(pos m[6,h2,2])+','+inttostr(posn[6,h2,2])+')'; end; for h3:=1 to 10 do begin StringGrid6.Cells[6,h3+20]:='('+inttostr(pos m[6,h3,3])+','+inttostr(posn[6,h3,3])+')'; end; end; if form1.checkcellparent7.Checked=true then begin for i1:=1 to 10 do begin StringGrid6.Cells[7,i1]:='('+inttostr(posm[7,i 1,1])+','+inttostr(posn[7,i1,1])+')'; end; for i2:=1 to 10 do begin StringGrid6.Cells[7,i2+10]:='('+inttostr(posm [7,i2,2])+','+inttostr(posn[7,i2,2])+')'; end; for i3:=1 to 10 do begin StringGrid6.Cells[7,i3+20]:='('+inttostr(posm [7,i3,3])+','+inttostr(posn[7,i3,3])+')'; end; end; if form1.checkcellparent8.Checked=true then begin for j1:=1 to 10 do begin StringGrid6.Cells[8,j1]:='('+inttostr(posm[8,j 1,1])+','+inttostr(posn[8,j1,1])+')'; end; for j2:=1 to 10 do begin StringGrid6.Cells[8,j2+10]:='('+inttostr(posm [8,j2,2])+','+inttostr(posn[8,j2,2])+')'; end; for j3:=1 to 10 do begin StringGrid6.Cells[8,j3+20]:='('+inttostr(posm [8,j3,3])+','+inttostr(posn[8,j3,3])+')'; end; end; if form1.checkcellparent9.Checked=true then begin for k1:=1 to 10 do begin StringGrid6.Cells[9,k1]:='('+inttostr(posm[9, k1,1])+','+inttostr(posn[9,k1,1])+')'; end; for k2:=1 to 10 do begin StringGrid6.Cells[9,k2+10]:='('+inttostr(pos m[9,k2,2])+','+inttostr(posn[9,k2,2])+')'; end;
for k3:=1 to 10 do begin StringGrid6.Cells[9,k3+20]:='('+inttostr(pos m[9,k3,3])+','+inttostr(posn[9,k3,3])+')'; end; end; end; end; procedure TForm2.FormShow(Sender: TObject); begin StringGrid1.Clean; StringGrid2.Clean; StringGrid3.Clean; StringGrid4.Clean; StringGrid5.Clean; StringGrid6.Clean; tabsheet1.TabVisible:=false; tabsheet2.TabVisible:=false; tabsheet3.TabVisible:=false; tabsheet4.TabVisible:=false; tabsheet5.TabVisible:=false; tabsheet6.TabVisible:=false; if form1.Subjek1.Checked=true then form2.posisisubjek1; if form1.Subjek2.Checked=true then form2.posisisubjek2; if form1.Subjek3.Checked=true then form2.posisisubjek3; if form1.Subjek4.Checked=true then form2.posisisubjek4; if form1.Subjek5.Checked=true then form2.posisisubjek5; if form1.Subjek6.Checked=true then form2.posisisubjek6; end; end.
369