APLIKASI MODUL PEMBELAJARAN POHON EKSPRESI MENGGUNAKAN VISUAL BASIC
The image cannot be display ed. Your computer may not hav e enough memory to open the image, or the image may hav e been corrupted. Restart y our computer, and then open the file again. If the red x still appears, y ou may hav e to delete the image and then insert it again.
TUGAS AKHIR/SKRIPSI OLEH: Husen Haikal 41508120016
PROGRAM STUDI TEKNIK INFORMATIKA FAKULTAS ILMU KOMPUTER UNIVERSITAS MERCU BUANA JAKARTA 2011/2012
i
ii
iii
KATA PENGANTAR
Puja dan puji syukur penulis panjatkan kehadirat Allah SWT atas rahmat dan hidayah-NYA sehingga penulis dapat menyelesaikan tugas akhir dengan maksimal. Tidak lupa pula shalawat serta salam penulis curahkan kepada Nabi Besar Muhammad SAW. Semoga kita semua mendapatkan syafaatnya baik didunia dan diakhirat. Tugas akhir ini yang berjudul “Aplikasi Modul Pembelajaran Pohon Ekspresi Menggunakan Visual Basic ini diajukan sebagai salah satu syarat untuk memperoleh gelar Sarjana Sastra satu (S1) pada Program Studi Teknik Informatika Uneversitas Mercu Buana. Dengan segala keterbatasan, Penulis menyadari bahwa laporan tugas akhir ini tidak akan terwujud tanpa bantuan, bimbingan, dan dukungan dai berbagai pihak. Untuk itu, dengan segala kerendahan hati, penulis mengucapkan terima kasih kepada: 1. Ida Nurhaida, ST, MT, selaku Pembimbing Tugas Akhir, terima kasih atas bibmbinganya. 2. Anis Cherid, SE.MTL, Selaku Ketua Program Studi Teknik Informatika Universitas Mercu Buana. 3. Tri Daryanto, S.Kom, Selaku Koordinator Tugas Akhir Universitas Mercu Buana. 4. Kedua orang tua (Faisal dan Karnia) dan Kedua Mertua (Hanafi dan Juju Juningsih) 5. Istri saya Yuanita Melinda, yang selalu mendukung untuk selsesainya Tugas Akhir ini. 6. Teman-teman satu kantor di BNI Kantor Besar Sudirman (Galih Caksana, Hanang Subagio, Kusada, Ian Lesmana) dan teman-teman satu Kampus Universitas Mercu Buana khusnya jurusan Teknik Informatika. Penulis memohon maaf atas segala kekurangan dan kekhilapan selama mengerjakan Tugas Akhir ini. Semoga Laporan Tugas Akhir ini dapat bermanfaat bagi pihak-pihak yang membutuhkan.
iv
Jakarta, September 2012
Penulis
v
ABSTRACT
Learning module application of expression tree is a learning module that shapes expression tree. The expression tree is a binary tree where leaf containing arithmetic expression and root containing operator in the expression. The arithmetic expression it self consists of three forms, namely prefix, suffix (postfix) and infix. This learning module is formulated to assist Information Engineering students in their learning process as in this application, there are the visualitation of expression tree formulation and traversal process. The learning application is generated by using Visual Basic Programming version 6.0.
keywords : Learning Module, Expression Tree
vi
ABSTRAK Aplikasi modul pembelajaran pohon ekspresi adalah modul pembelajaran pembentukan pohon ekspresi. Pohon ekspresi adalah sebuah pohon biner dimana daun berisi operand yang terdapat dalam ekspresi aritmatika dan akar berisi operator yang terdapat dalam ekspresi aritmatika tersebut. Ekspresi aritmatika ini terdiri dari 3 bentuk, yaitu bentuk Prefix, Suffix (Postfix) dan Infix. Modul pembelajaran ini dibuat untuk memudahkan mahasiswa jurusan Teknik Informatika proses pembelajarannya karena pada aplikasi ini terdapat visualisasi pembentukan pohon ekspresi dan proses traversal. Aplikasi pembelajaran ini dibuat dengan menggunakan bahasa pemrograman Visual Basic versi 6.0.
Kata kunci :Modul Pembelajaran , Pohon Ekspresi.
vii
DARTAR ISI LEMBAR PERNYATAAN .....................................................................................ii LEMBAR PENGESAHAN .....................................................................................iii KATA PENGANTAR ..............................................................................................iv ABSTRCT .................................................................................................................vi ABSTRAK ................................................................................................................vii DAFTAR ISI .............................................................................................................viii DAFTAR GAMBAR ................................................................................................xi DAFTAR TABEL ....................................................................................................xiv BAB I PENDAHULUAN .........................................................................................1 1.1
Latar Belakang ......................................................................................1
1.2
Perumusan Masalah ..............................................................................2
1.3
Tujuan dan Manfaat Penulisan .............................................................2
1.4
Pembatasan Masalah .............................................................................2
1.5
Metode Penelitian .................................................................................3
1.6
Sistematika Penulisan Tugas Akhir ......................................................6
BAB II LANDASAN TEORI ..................................................................................7 2.1
Ekspresi Aritmatika ............................................................................7 2.1.1 Notasi / Penulisan Ekspresi Aritmatika ....................................8 2.1.1.1 Infix ..............................................................................8 2.1.1.2 Prefix ............................................................................9 2.1.1.3 Postfix (Suffix) .............................................................9 2.1.2 Pohon Ekspresi (Ekspression Tree) ..........................................10 2.1.3 Tree ...........................................................................................11 2.1.3.1 Binary Tree .....................................................................15 2.1.3.2 Proses Traversal Pada Binary Tree ................................18
2.2 Unified Modeling Langguange (UML) ................................................22 2.2.1 Use Case Diagram .......................................................................23 2.2.1.1 Simbol Use Case Diagram .............................................23
viii
2.2.2 Activity Diagram .........................................................................24 2.2.2.1 Simbol Activity Diagram ...............................................24 2.3 Pembelajaran Berbantuan Komputer (Computer Aided Intruction ......) ..............................................................................................................27 2.3.1 Definisi Pembelajaran Berbantuan Komputer .............................27 2.3.2 Model Pembelajaran Berbantuan Komputer................................28 2.3.3 Keuntungan dan Keterbatasan CAI .............................................29 2.4 Konsep Dasar Strategi Pembelajaran ....................................................30 2.4.1 Definisi Konsep Pembelajaran.....................................................30 2.4.2 Karakteristik CTL ........................................................................31 2.4.3 Asas-asas CTL .............................................................................31
BAB III ANALISA DAN PERANCANGAN .......................................................34 3.1 Analisa Sistem ....................................................................................34 3.1.1 Definisi Analisa Sistem .............................................................34 3.2 Perancangan........................................................................................35 3.2.1 Perancangan Struktur Navigasi .................................................35 3.2.2 Perancangan Use Case Diagram ................................................35 3.2.3 Perancangan Activity Diagram..................................................44 3.2.3.1 Activity Diagram Use Case LihatTeori .......................44 3.2.3.2 Activity Diagram Use Case Input Ekspresi Aritmatika ...................................................................................................45 3.2.3.3 Activity Diagram Use Case Lihat Pohon Ekspresi ......46 3.2.3.4 Activity Diagram Use Case Lihat Simulasi Traversal .47 3.2.3.5 Activity Diagram Use Case Evaluasi Hasil Operasi .... ...................................................................................................48 3.2.3.6 Activity Diagram Use Case Kuis .................................49 3.2.3.7 Activity Diagram Use Case Membuat Kuis .................50 3.2.3.8 Activity Diagram Use Case Mengerjakan Kuis ...........51 3.2.4 Perancangan Sequence Diagram ...............................................52 3.2.5 Perancangan Class Diagram ......................................................58
ix
3.2.6 Perancangan Antar Muka ..........................................................58
BAB IV IMPLEMENTASI DAN PENGUJIAN ..................................................62 4.1 Implementasi Aplikasi .........................................................................62 4.1.1 Spesifikasi Kebutuhan Sistem ...................................................62 4.2 Proses ...................................................................................................63 4.2.1 Form Login ................................................................................63 4.2.2 Form Menu Utama ....................................................................64 4.2.3 Form Menu Pohon Ekspresi ......................................................65 4.2.4 Form Input Ekspresi Aritmatika ................................................65 4.2.5 Form Menu Kuis........................................................................66 4.2.6 Form Menu Input Kuis ..............................................................67 4.3 Pengujian .............................................................................................68 4.3.1 Pengujian Black Box Testing ....................................................70 4.3.2 Analisis Black Box Testing .......................................................71
BAB V KESIMPILAN DAN SARAN ...................................................................72 5.1 Kesimpulan ............................................................................................72 5.2 Saran ......................................................................................................72
DAFTAR PUSTAKA ..............................................................................................73 DAFTAR RIWAYAT HIDUP ................................................................................74 LAMPIRAN SOURCE CODE................................................................................l1
x
DARTAR GAMBAR
Gambar 1.1 Metode Penelitian Waterfall ..................................................................4 Gambar 2.1 Diagram Bentuk Infix.............................................................................8 Gambar 2.2 Diagram Bentuk Prefix...........................................................................9 Gambar 2.3 Diagram Bentuk Suffix ..........................................................................10 Gambar 2.4 Pohon Ekspresi Untuk Ekspresi Aritmatika ...........................................11 Gambar 2.5 Contoh pembentukan Tree .....................................................................13 Gambar 2.6 Contoh tree dengan 15 node ...................................................................13 Gambar 2.7 Contoh binary tree ..................................................................................16 Gambar 2.8 Complete binary tree level 4 ..................................................................17 Gambar 2.9 Contoh skewed binary tree (a) Skewed left (b) Skewed right ...............17 Gambar 2.10 Contoh binary tree ................................................................................18 Gambar 2.11 Proses Preorder Traversal dari binary Tree ..........................................19 Gambar 2.12 Proses Inorder Traversal dari binary tree .............................................20 Gambar 2.13 Proses Postorder Traversal dari binary tree..........................................21 Gambar 2.14 Usecase .................................................................................................23 Gambar 2.15 Actor .....................................................................................................23 Gambar 2.16 Association ...........................................................................................24 Gambar 2.17 System boundary ..................................................................................24 Gambar 2.18 Solid Circle...........................................................................................25 Gambar 2.19 Rounded Rectangle ..............................................................................25 Gambar 2.20 Continuous Line ...................................................................................26 Gambar 2.21 Document .............................................................................................26 Gambar 2.22 Dotted Line WithArrow .......................................................................26 Gambar 2.23 Table .....................................................................................................27 Gambar 2.24 Dotted Line...........................................................................................27 Gambar 2.25 Bull’s-eye .............................................................................................27 Gambar 3.1 Peta Navigasi ..........................................................................................35 Gambar 3.2 Use Case Diagram Aplikasi Pohon Ekspresi.........................................36
xi
Gambar 3.3 Activity Diagram Lihat Teori .................................................................44 Gambar 3.4 Activity Diagram Input Ekspresi Aritmatika ..........................................45 Gambar 3.5 Activity Diagram Lihat Pohon Ekspresi .................................................46 Gambar 3.6 Activity Diagram Lihat Simulasi Traversal............................................47 Gambar 3.7 Activity Diagram Evaluasi Hasil Operasi ..............................................48 Gambar 3.8 Activity Diagram Kuis............................................................................49 Gambar 3.9Activity Diagram Membuat Kuis ............................................................50 Gambar 3.10 Activity Diagram Mengerjakan Kuis....................................................51 Gambar 3.11 Sequence Diagram Login .....................................................................52 Gambar 3.12 Sequence Diagram Pohon ekspresi ......................................................54 Gambar 3.13 Sequence Diagram kuis-Admin ....................................................................... 56 Gambar 3.14 Sequence Diagram kuis-User .......................................................................... 57 Gambar 3.15 Class Diagram Kuis ..............................................................................58 Gambar 3.16 Tampilan Login ....................................................................................59 Gambar 3.17 Tampilan Menu Utama.........................................................................59 Gambar 3.18 Tampilan Rancangan Pohon Ekspresi ..................................................60 Gambar 3.19 Tampilan Kuis ......................................................................................60 Gambar 3.20 Tampilan Input Soal .............................................................................61 Gambar 3.21 Tampilan Lihat Soal .............................................................................61 Gambar 4.1 Form Login.............................................................................................63 Gambar 4.2 Form Menu Utama .................................................................................64 Gambar 4.3 Form Pohon Ekspresi .............................................................................65 Gambar 4.4 Form Input Ekspresi Aritmatika.............................................................66 Gambar 4.5 Form Kuis...............................................................................................67 Gambar 4.6 Form Input Kuis .....................................................................................68
xii
DARTAR TABEL
Tabel 3.1 Modul Login ..............................................................................................37 Tabel 3.2 Lihat Teori..................................................................................................37 Tabel 3.3 Input Pohon Ekspresi .................................................................................38 Tabel 3.4 Lihat Pohon Ekspresi .................................................................................39 Tabel 3.5 Lihat Simulasi Traversal ............................................................................40 Tabel 3.6 Evaluasi Hasil Operasi ...............................................................................41 Tabel 3.7 Melihat Soal ...............................................................................................42 Tabel 3.8 Membuat Soal ............................................................................................43 Tabel 3.9 Mengerjakan Soal ......................................................................................43 Tabel 3.10 Melihat Nilai ............................................................................................44 Tabel 3.11 Activity Diagram Lihat Teori ...................................................................45 Tabel 3.12 Activity Diagram Input Ekspresi Aritmatika ...........................................46 Tabel 3.13 Activity Diagram Lihat Pohon Ekspresi...................................................47 Tabel 3.14 Activity Diagram Lihat Simulasi Traversal .............................................48 Tabel 3.15 Activity Diagram Evaluasi Hasil Akhir ...................................................49 Tabel 3.16 Activity Diagram Kuis User dan Admin ..................................................50 Tabel 3.17 Activity Diagram Membuat Kuis .............................................................51 Tabel 3.18 Activity Diagram Mengerjakan Kuis .......................................................52 Tabel 3.19 Deskripsi Sequence Diagram Login ........................................................53 Tabel 3.20 Deskripsi Sequence Diagram Pohon Ekspresi .........................................55 Tabel 3.21 Deskripsi Sequence Diagram Kuis-Admin ..............................................57 Tabel 3.22 Deskripsi Sequence Diagram Kuis-User .................................................58 Tabel 4.1 Fungsi Tampilan Pada Form Login ...........................................................63 Tabel 4.2 Fungsi Tampilan Pada Form Menu Utama ................................................64 Tabel 4.3 Fungsi Tampilan Pada Form Menu Pohon Ekspresi ..................................65 Tabel 4.4 Fungsi Tampilan Pada Form Menu Input Ekspresi Aritmatika .................66 Tabel 4.5 Fungsi Tampilan Pada Form Menu Kuis ...................................................67 Tabel 4.6 Fungsi Tampilan Pada Form Menu Input Kuis ..........................................68
xiii
Tabel 4.7 Tabel Skenario Pengujian ..........................................................................69 Tabel 4.8 Tabel Hasil Pengujian Black Box Testing ..................................................70
xiv