Similar presentations

2
September 12 2 Vision = what is where by looking Visualization = the power or process of forming a mental image of vision of something not actually present to the sight You have 10s to find this image

3
3 Dijkstra feared… “…permanent mental damage for most students exposed to program visualization software …”

9
September 12 9 Typical Approach in AV take the description of the algorithm graphically represent data in the code using bars, points, etc. use animation to represent the flow of control show the animated algorithm and hope that the learner will now understand the algorithm

10
September 12 10 Problems with AV Graphical language versus text Low level of abstraction (code stepping) Emphasis on meta-tools Students perform best if they are asked to develop visualizations no attempt to visualize or even suggest essential properties, such as invariants Very few attempts to visualize recursive algorithms

11
September 12 11 Introduction to AE systematic procedure to explain algorithms: an algorithm for explaining algorithms Based on findings from Cognitive Psychology, Constructivism Theory, Software Engineering visual representation is used to help reason about the textual representation Use multiple abstraction levels to focus on selected issues Designed by experts

12
September 12 12 Goals of AE Understanding of both, what the algorithm is doing and how it works Ability to justify the algorithm correctness (why the algorithm works) Ability to code the algorithm in any programming language Understanding of time complexity of the algorithm

13
September 12 13 Requirements for AE The algorithm is presented at several levels of abstraction Each level of abstraction is represented by the abstract data model and pseudocode The design supports active learning The design helps to understand time complexity

15
September 12 15 AE Catalogue Entries Multi-leveled Abstract Algorithm Model Example of an abstract implementation of the Abstract Algorithm Model Tools that can be used to help to predict the algorithm complexity Questions for students

16
September 12 16 MAK Uses multimedia: –Graphics –Animation –Auralization to show abstractions of data Interacts with the student; e.g. by providing post-tests Uses a student model for adaptive behavior

19
September 12 19 Selection Sort: Top level of Abstraction Abstract Data Model Type T also supports the function swap(T el1, T el2) The following operations on Seq are available: a sequence t can be divided into prefix and suffix the prefix can be incremented (which will decrement the suffix ) first(suffix) T smallest(seq t, Comparator comp)

25
September 12 25 Abstract Implementation The Abstract Iterator Implementation Model assumes There is an Iterator type, where iterations are performed over a half-closed interval [a, b) Iterator type supports the following operations: –two iterators can be compared for equality and inequality –there are operations to provide various kinds of traversals; for example forward and backward –an iterator can be dereferenced to access the object it points to

32
September 12 32 Algorithm Complexity Three kinds of tools: to experiment with various data sizes and plot a function that approximates the time spent on execution with this data. a visualization that helps to carry out time analysis of the algorithm questions regarding the time complexity

33
September 12 33 Post Test 1.What is the number of comparisons and swaps performed when selection sort is executed for: 1.sorted sequence 2.sequence sorted in reverse 2.What is the time complexity of the function isSorted(t), which checks if t is a sorted sequence? 3.Hand-execute the algorithm for a sample set of input data of size 4. 4.Hand-execute the next step of the algorithm for the specified state 5.What’s the last step of the algorithm? 6.There are two invariants of this algorithm; which one is essential for the correctness of swap(smallest(), eop), and why. 7.“do it yourself “