Abstraction & Reality in Computational Thinking (OCR AS Computer Science): Revision Note

Exam code: H046

Robert Hampton

Written by: Robert Hampton

Reviewed by: James Woodhouse

Updated on

The difference between abstraction and reality

What is the difference between abstraction and reality?

  • The real world is very complex and has many, many variables that factor into problems

  • An aerial view of a city with all of its roads, junctions and streets forms the basis of reality when travelling from point A to point B. Roads weave and turn and may have different governing laws depending on location, such as maximum speed limits or no left turnings

abstraction-and-reality-in-computational-thinking-1

A street view of a city showing roads, junctions and streets
Source: Google Maps

  • When travelling by vehicle, the greenspace and buildings of a city are usually unnecessary detail. When creating a useful map of a city, these elements can be removed, leaving only roads and junctions

abstraction-and-reality-in-computational-thinking-2

An abstracted street view, with all buildings and greenspace removed
Source: Google Maps

  • Quick and efficient travel has always been a considerable problem, usually done by humans using maps. Computers however can process routes much quicker but require a suitable map to calculate these routes

  • To provide a usable map to a computer, the map must be abstracted. After removing unnecessary detail, such as greenspace and buildings, a simplified representation of a map can be created

  • All junctions can be represented by graph nodes and each road is represented as an edge or arc between each junction. Elements such as no left turnings can be represented by directed edges or arcs. The distance between each junction can be represented by an appropriate weight on each arc or edge

  • The final product is a graph to which graph theory and algorithms such as Dijkstra’s shortest path or A* search can be applied to

abstraction-in-computational-thinking

A further abstracted street view, showing a collection of labelled and connected junction nodes

  • Apps such as Google Maps or Uber use abstracted maps such as this to calculate the shortest routes from a starting point to a destination. Other factors such as traffic, roadworks and weather conditions can also be factored in, enabling more accurate calculations

  • The final abstracted map above has removed all elements that do not impact or affect the finding of the shortest distance between two points

You've read 0 of your 5 free revision notes this week

Unlock more, it's free!

Join the 100,000+ Students that ❤️ Save My Exams

the (exam) results speak for themselves:

Robert Hampton

Author: Robert Hampton

Expertise: Computer Science Content Creator

Rob has over 16 years' experience teaching Computer Science and ICT at KS3 & GCSE levels. Rob has demonstrated strong leadership as Head of Department since 2012 and previously supported teacher development as a Specialist Leader of Education, empowering departments to excel in Computer Science. Beyond his tech expertise, Robert embraces the virtual world as an avid gamer, conquering digital battlefields when he's not coding.

James Woodhouse

Reviewer: James Woodhouse

Expertise: Computer Science & English Subject Lead

James graduated from the University of Sunderland with a degree in ICT and Computing education. He has over 14 years of experience both teaching and leading in Computer Science, specialising in teaching GCSE and A-level. James has held various leadership roles, including Head of Computer Science and coordinator positions for Key Stage 3 and Key Stage 4. James has a keen interest in networking security and technologies aimed at preventing security breaches.