Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 'bobot kriteriA
- c1 = 40
- c2 = 20
- c3 = 40
- 'cari nilai max dan min hitung 2
- p1 = max_harga2(HARGA1.Text, HARGA2.Text)
- p2 = max_kap2(KAP1.Text, KAP2.Text)
- p3 = min_kon2(KON1.Text, KON2.Text)
- 'normalisasi matrik
- c11 = Round((HARGA1.Text / p1), 4)
- a11 = c11 * c1
- '================================
- c21 = Round((KAP1.Text / p2), 4)
- a12 = c21 * c2
- '================================
- c31 = Round((p3 / KON1.Text), 4)
- a13 = c31 * c3
- '================================
- b21 = Round((HARGA2.Text / p1), 4)
- a14 = b21 * c1
- '=================================
- b22 = Round((KAP2.Text / p2), 4)
- a15 = b22 * c2
- '=================================
- b32 = Round((p3 / KON2.Text), 4)
- a16 = b32 * c3
- 'total
- total1 = a11 + a12 + a13
- total2 = a14 + a15 + a16
- '=================================
- If total1 >= total2 Then
- hasil.Text = total1
- layak.Text = "layak"
- If total2 <= total1 Then
- hasil1.Text = total2
- tdklayak.Text = "tidak layak"
- End If
- End If
Advertisement
Add Comment
Please, Sign In to add comment