Abstraction At The Core of Computer Science
I spent the latter part of last week in Palo Alto, California working on the CS 2013 project. There are some pretty amazing people involved in this project (CS 2013 steering committee) and I learned a lot in the various discussions we had around computer science curriculum. Since we are talking about what absolutely positively much be part of undergraduate computer science curriculum it is not surprising that core concepts are an important part of the discussions. One statement that was made was that “abstraction is at the core of computer science.” This is quite true of course but it struck me that maybe we don’t talk enough about this early enough in high school computer science courses. It is an important vocabulary word but do we really talk about what it means at a deep level? Sometimes perhaps but always? Not so sure. I’m pretty sure I never spent enough time on it.
What do we mean by abstraction? There are some interesting definitions floating around that can be used for starters.
- ACM Article Abstraction in Computer science
- Bing search for “Abstraction computer science”
- Wikipedia Abstraction – computer science
- Yahoo! Answers abstraction in computer science
Making all of this clear to students can be tricky especially when we introduce abstract classes. So what is the simple version? I see abstraction as using symbols to represent real things. In other words, we model the real world using data (numbers mostly but also images and words) so that we can manipulate them using the computer. We can’t generate real wind or real buildings in a computer to see how buildings react to different speeds of wind but we can model the effects. Push buttons on the screen don’t actually depress but we can model that behavior by using the right abstractions. Abstraction is a tool for acting on imaginary objects that represent real things.
In a sense object oriented programming and graphical user interface programming both simplifies and complicates our discussion of abstraction. On one hand the GUI objects make it easy to model real work objects of specific types. At the same time, for some students, it makes it harder to understand models or abstractions of items that are not visible on the screen. Personally I find that properties, as implemented nicely in C# and Visual Basic, do help to picture the abstraction – the way the software object represents the physical object it models – of various real world objects. Your mileage as they say may vary of course. The fact that objects have properties and methods is what enables us to model real world objects. At the same time making the transition from physical objects to numbers that somehow represent those objects does not come naturally for everyone. It is important however that they do make the transition. This is at the heart of how computer science works.
I’m trying to work out in my mind how to involved abstraction both earlier and more consistently into a first programming course. My gut tells me that in the long run that would make understanding more of the concepts easier. Do any of you out there have particularly good discussion points, resources or lessons learned about teaching abstraction to share? Any textbook that does an especially good job of it? Or perhaps an operational definition that you find works for you and students?
Abstraction is a core concept in computer science. On the other hand it is a bit abstract for some students. (Sort of pun intended.)
Comments
Anonymous
August 09, 2011
Unfortunately, I think there are two concepts behind your use of the term "abstraction" 1. abstraction is a way of ignoring certain aspects of the real world making it possible for us to make generalizations and reason about them 2. abstraction in computer programming is a way of representing the state of the machine in such a way that we can manipulate the flow of data through the machine. I would agree that they are both important but in very different ways and you will end up compromising both if you don't clearly distinguish them. I believe that much of the difficulty students have in dealing with computer science is precisely the lack of such a distinction. I put together and taught a K9-12 curriculum that was largely based on this assumption - it went across very well.Anonymous
August 09, 2011
Patrick, you are right I think. There is a lot more to the idea of abstraction than fits in a short blog post. I probably do need to do a lot more thinking about how to present the various aspects of abstraction. I would love to know more about the curriculum that you put together. Is it available somewhere?Anonymous
August 09, 2011
The comment has been removedAnonymous
August 10, 2011
Acutally, its more of a riddle then a pun.Anonymous
August 10, 2011
The comment has been removedAnonymous
August 10, 2011
The comment has been removed