Latest Post

Situs Paling Terlengkap

Sebuah informasi program terbaru dan juga aktual bisa kita dapatkan di http://mesran.net/ , semua Tentang Pemrograman  , maupun berita-berita aktual terlengkap bisa kita peroleh dengan mudah di http://mesran.net/  atau juga http://www.mesran.blogspot.com .
Anda ingin mengetahui tentang VB NET bisa juga anda dapatkan di http://mesran.net/vbnet.html, atau juga tentang TURBO PASCAL bisa anda dapatkan di http://mesran.net/pascal.html , atau mungkin anda butuh MOTIVASI maka anda bisa juga dapatkan di http://mesran.net/motivasi.html , TIPS/TRICK lihat disini http://mesran.net/tipstrik.html.

Sesuai dengan analisa saya bahwa setiap orang pernah berkunjung di situs http://mesran.net/ dan http://www.mesran.blogspot.com pasti tidak akan pernah meninggalkan situs ini karena selain berbagi dengan ikhlas juga situs ini mempunyai daya pikatnya tersendiri.Oleh karenanya tunggu apalagi silahkan berkunjung ke situsnya sekarang juga......
Silahkan klik link ini secara lengkap  http://www.mesran.blogspot.com dan http://mesran.net/ .


Terimakasih ...Selamat Menikmati......
 

Latihan Pelajaran Sistem Pendukung Keputusan (Lat 1) Menggunakan Metode WP (Weight Product)



Sebuah PTS di Kota Medan, akan memberikan beasiswa kepada 5 orang mahasiswanya. Adapun syarat pemberian beasiswa tersebut, yaitu harus memenuhi ketentuan berikut ini :

Syarat :
C1: Semester Aktif Perkuliahan (Attribut Keuntungan)
C2: IPK  (Attribut Keuntungan)
C3: Penghasilan Orang Tua  (Attribut Biaya)
C4: Aktif Berorganisasi (Attribut Keuntungan)

Untuk bobot W=[4,4,5,3]

Adapun mahasiswa yang menjadi alternatif dalam pemberian beasiswa yaitu :
No
Nama
C1
C2
C3
C4
1
Joko
VI
3.7
1.850.000
Aktif
2
Widodo
VI
3.5
1.500.000
Aktif
3
Simamora
IV
3.8
1.350.000
Tidak Aktif
4
Susilawati
II
3.9
1.650.000
Tidak Aktif
5
Dian
II
3.6
2.300.000
Aktif
6
Roma
IV
3.3
2.250.000
Aktif
7
Hendro
VIII
3.4
1.950.000
Aktif

Untuk pembobotan yang digunakan bisa mengacu pada bobot di bawah ini :
C1:Semester Aktif Perkuliahan
Semester II --> 1
Semester IV --> 2
Semester VI -->  3
Semester VIII -->  4

C2: IPK
IPK  3.00 - 3.249 --> 1
IPK  3.25 - 3.499 --> 2
IPK  3.50 - 3.749 --> 3
IPK  3.75 - 3.999 --> 4
IPK  4.00 --> 5
 
C3: Penghasilan Orang Tua 
1.000.000 --> 1
1.400.000 --> 2
1.800.000 --> 3
2.200.000 --> 4
2.600.000 --> 5

C4: Aktif Berorganisasi
Aktif --> 2
Tidak Aktif --> 1
     

Penyelesaian :
 Tabel Hasil Bobot Dari Setiap Kriteria
No
Nama
Kriteria
C1
C2
C3
C4
1
Joko
3
3
3
2
2
Widodo
3
3
2
2
3
Simamora
2
4
1
1
4
Susilawati
1
4
2
1
5
Dian
1
3
4
2
6
Roma
2
2
4
2
7
Hendro
4
2
3
2


1. Rumus Untuk Mencari Perbaikan Bobot :



2. Rumus Untuk Mencari Vektor Ternormalisasi :



3. Rumus Untuk Mencari Preferensi dari Setiap Alternatif :







 MATA KULIAH  SITEM PENDUKUNG KEPUTUSAN ....


 

PROGRAM KRIPTOGRAFI PADA VB-2008

Pertama-tama Desain Form Menunya Seperti  berikut  :





















Kemudian Desain Form untuk...

 1.  CAESAR CHIPER :

























Berikut Listing Programnya :

Public Class Caesar_Chiper
    Private Sub Btnenkripsi_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnEnkripsi.Click
        Dim x As String = ""

        Dim xkalimat As String = ""
        For i = 1 To Len(Plainteks.Text)
            x = Mid(Plainteks.Text, i, i)
            x = Chr(Asc(x) + 3)
            xkalimat = xkalimat + x
        Next
        Chiperteks.Text = xkalimat
    End Sub

    Private Sub BtnDeskripsi_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnDeskripsi.Click
        Dim x As String = ""
        Dim xkalimat As String = ""
        For i = 1 To Len(Chiperteks.Text)
            x = Mid(Chiperteks.Text, i, i)
            x = Chr(Asc(x) - 3)
            xkalimat = xkalimat + x
        Next
        Plainteks.Text = xkalimat
    End Sub

    Private Sub BtnHapus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnHapus.Click
        Plainteks.Text = ""
        Chiperteks.Text = ""
    End Sub

    Private Sub BtnKeluar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnKeluar.Click
        Me.Close()
    End Sub
End Class



Nah Berikut Hasilnya :
























2. GRONSFELD CHIPER























Berikut Listing Programnya :

Public Class Gronsfeld_Chiper

    Private Sub Gronsfeld_Chiper_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Plainteks.Text = ""
        Chiperteks.Text = ""
    End Sub

    Private Sub BtnHitung_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnEnkripsi.Click
        Dim ind As Integer
        Dim huruf, kalimat As String
        Dim jumlah(25) As Integer
        kalimat = (Plainteks.Text).ToUpper
        For x = 1 To Microsoft.VisualBasic.Len(kalimat)
            huruf = kalimat.Substring(x - 1, 1)
            If (huruf >= "A") And (huruf <= "Z") Then
                ind = Asc(huruf) - 65
                jumlah(ind) += 1
            End If
        Next
        Chiperteks.Text = ""
        For i As Integer = 0 To 25
            huruf = Chr(i + 65)
            If jumlah(i) > 0 Then
                Chiperteks.Text = Chiperteks.Text & huruf & " = " & jumlah(i) & vbCrLf
            End If
        Next
    End Sub

    Private Sub BtnKeluar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnKeluar.Click
        Me.Close()
    End Sub

    Private Sub Key_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles Kunci.KeyPress
        e.KeyChar = UCase(e.KeyChar)
        Dim tombol As Integer = Asc(e.KeyChar)
        If Not (((tombol >= 65) And (tombol <= 90)) Or (tombol = 8)) Then
            e.Handled = True
        End If
    End Sub

    Private Sub BtnHapus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnHapus.Click
        Plainteks.Text = ""
        Chiperteks.Text = ""
        Kunci.Text = ""
    End Sub
End Class


Nah Berikut Hasilnya :























3. VERNAM CHIPER























Berikut Listing Programnya : 

Public Class Vernam_Chiper

    Private Sub Vernam_Chiper_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Plainteks.Text = ""
        Kunci.Text = ""
        Chiperteks.Text = ""
    End Sub

    Private Sub Btnenkripsi_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnEnkripsi.Click
        Dim j As Integer
        Dim jum As Integer
        Dim sKey As String
        Dim nKata As Integer
        Dim nKunci As Integer
        Dim sKata As String
        Dim sPlain As String = ""
        Dim nEnc As Integer
        j = 0
        sKata = Plainteks.Text
        jum = Len(sKata)
        sKey = Kunci.Text
        For i = 1 To jum
            If j = Len(sKey) Then
                j = 1
            Else
                j = j + 1
            End If
            nKata = Asc(Mid(sKata, i, 1)) - 65

            nKunci = Asc(Mid(sKey, j, 1)) - 65

            nEnc = ((nKata + nKunci) Mod 26)

            sPlain = sPlain & Chr((nEnc) + 65)
        Next i
        Chiperteks.Text = sPlain
    End Sub
    Private Sub Plainteks_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles Plainteks.KeyPress
        e.KeyChar = UCase(e.KeyChar)
        Dim tombol As Integer = Asc(e.KeyChar)
        If Not (((tombol >= 65) And (tombol <= 90)) Or (tombol = 8)) Then
            e.Handled = True
        End If
    End Sub

    Private Sub Kunci_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles Kunci.KeyPress
        e.KeyChar = UCase(e.KeyChar)
        Dim tombol As Integer = Asc(e.KeyChar)
        If Not (((tombol >= 65) And (tombol <= 90)) Or (tombol = 8)) Then
            e.Handled = True
        End If
    End Sub

    Private Sub BtnHapus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnHapus.Click
        Plainteks.Text = ""
        Kunci.Text = ""
        Chiperteks.Text = ""
    End Sub
End Class


Nah Berikut Hasilnya :  























4. VIGENERE CHIPER






















Berikut Listing Programnya :

Public Class Vigenere_Chiper


    Private Sub Vigenere_Chiper_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Plainteks.Text = ""
        Chiperteks.Text = ""
        Kunci.Text = ""
    End Sub

    Private Sub BtnEnkripsi_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnEnkripsi.Click
        Dim J As Integer
        Dim Jum As Integer
        Dim sKey As String
        Dim nKata As Integer
        Dim nKunci As Integer
        Dim sKata As String
        Dim sPlain As String = ""
        Dim nEnc As Integer
        J = 0
        sKata = Plainteks.Text
        Jum = Len(sKata)
        sKey = Kunci.Text
        For i = 1 To Jum
            If J = Len(sKey) Then
                J = 1
            Else
                J = J + 1
            End If
            nKata = Asc(Mid(sKata, i, 1)) + 0
            nKunci = Asc(Mid(sKey, J, 1)) + 0
            nEnc = ((nKata + nKunci) Mod 256)
            sPlain = sPlain & Chr((nEnc))
        Next i
        Chiperteks.Text = sPlain
    End Sub

    Private Sub Plainteks_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles Plainteks.KeyPress
        Dim tombol As Integer = Asc(e.KeyChar)
        If Not (((tombol >= 65) And (tombol <= 90)) Or (tombol = 8)) Then
            e.Handled = True
        End If
    End Sub

    Private Sub Kunci_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles Kunci.KeyPress
        e.KeyChar = UCase(e.KeyChar)
        Dim tombol As Integer = Asc(e.KeyChar)
        If Not (((tombol >= 65) And (tombol <= 90)) Or (tombol = 8)) Then
            e.Handled = True
        End If
    End Sub

    Private Sub BtnHapus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnHapus.Click
        Plainteks.Text = ""
        Chiperteks.Text = ""
        Kunci.Text = ""
    End Sub
End Class

Berikut Hasilnya :
























5. DES CHIPER






















Berikut Listing Programnya :


Imports System.IO
Imports System.Security.Cryptography
Imports System.Text

Public Class DES_Chiper
    Private Sub BtnEnkripsi_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnEnkripsi.Click
        Plainteks.Text = "abcdef"
        Dim enc As Encoder = System.Text.Encoding.Unicode.GetEncoder()
        Dim unicodeText As Byte()
        unicodeText = DirectCast(Array.CreateInstance(GetType(Byte), Plainteks.Text.Length * 2), Byte())
        enc.GetBytes(Plainteks.Text.ToCharArray(), 0, Plainteks.Text.Length, unicodeText, 0, True)
        Dim objmd5 As MD5 = New MD5CryptoServiceProvider ' Untuk enkripsi MD5
        'Dim objmd5 As MD5 = New SHA1CryptoServiceProvider() ' Untuk enkripsi SHA1
        'Dim objmd5 As MD5 = New DESCryptoServiceProvider() ' Untuk enkripsi DES
        'Dim objmd5 As MD5 = New RSACryptoServiceProvider ' Untuk enkripsi RSA
        Dim result As Byte() = objmd5.ComputeHash(unicodeText)
        Dim sb As StringBuilder = New StringBuilder()
        Dim i As Integer
        For i = 0 To result.Length - 1
            sb.Append(result(i).ToString("X2"))
        Next
        Chiperteks.Text = sb.ToString()
        'Anda dapat mengganti "abcdef" dengan kata yang anda butuhkan, dan menggunakan tipe enkripsi yang lain yang anda inginkan dengan mengaktifkan baris berikut :
        'Dim objmd5 As MD5 = New MD5CryptoServiceProvider ' Untuk enkripsi MD5
        'Dim objmd5 As MD5 = New SHA1CryptoServiceProvider() ' Untuk enkripsi SHA1
        'Dim objmd5 As MD5 = New DESCryptoServiceProvider() ' Untuk enkripsi DES
        'Dim objmd5 As MD5 = New RSACryptoServiceProvider ' Untuk enkripsi RSA
    End Sub

    Private Sub BtnHapus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnHapus.Click
        Plainteks.Text = ""
        Chiperteks.Text = ""
    End Sub
End Class



Berikut Hasilnya :
























6. RC4





















Berikut Listing Programnya :

Public Class RC4

    Private Function Rc4(ByVal message As String, ByVal password As String) As String
        Dim s = Enumerable.Range(0, 256).ToArray
        Dim i, j As Integer
        For i = 0 To s.Length - 1
            j = (j + Asc(password(i Mod password.Length)) + s(i)) And 255
            Dim temp = s(i)
            s(i) = s(j)
            s(j) = temp
        Next
        i = 0
        j = 0
        Dim sb As New System.Text.StringBuilder(message.Length)
        For Each c As Char In message
            i = (i + 1) And 255
            j = (j + s(i)) And 255
            Dim temp = s(i)
            s(i) = s(j)
            s(j) = temp
            sb.Append(Chr(s((s(i) + s(j)) And 255) Xor Asc(c)))
        Next
        Return sb.ToString
    End Function

    Private Sub BtnEnkript_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnEnkripsi.Click
        Chiperteks.Text = Rc4(Plainteks.Text, Kunci.Text)
    End Sub

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnHapus.Click
        Plainteks.Text = ""
        Kunci.Text = ""
        Chiperteks.Text = ""
    End Sub
End Class



Berikut Hasilnya :






















Berikut Listing Program agar  dapat dijalankan di Form Menu :

Public Class Form1

    Private Sub CaesarChiperToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CaesarChiperToolStripMenuItem.Click
        Caesar_Chiper.Show()
    End Sub

    Private Sub GronsfeldChiperToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles GronsfeldChiperToolStripMenuItem.Click
        Gronsfeld_Chiper.Show()
    End Sub

    Private Sub RC4ToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RC4ToolStripMenuItem.Click
        RC4.Show()
    End Sub

    Private Sub VernamChiperToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles VernamChiperToolStripMenuItem.Click
        Vernam_Chiper.Show()
    End Sub

    Private Sub VigenereChiperToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles VigenereChiperToolStripMenuItem.Click
        Vigenere_Chiper.Show()
    End Sub

    Private Sub DESChiperToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles DESChiperToolStripMenuItem.Click
        DES_Chiper.Show()
    End Sub
End Class

SELAMAT MENCOBA !!!

PEMROGRAMAN VB-2008
 
 
Support : Creating Website | Johny Template | Mas Template
Copyright © 2011. SIMPLE BLOG - All Rights Reserved
Template Created by Creating Website Published by Mas Template
Proudly powered by Blogger