Computer Science

Abstraction Computer Science

Abstraction in Computer Science refers to the process of simplifying complex systems by focusing on the essential features while ignoring the details. It is a fundamental concept that allows programmers to create efficient and scalable software by breaking down complex problems into smaller, more manageable components. Abstraction is used in many areas of computer science, including programming languages, algorithms, and data structures.

Written by Perlego with AI-assistance

9 Key excerpts on "Abstraction Computer Science"

  • Book cover image for: Philosophy and Computer Science
    • Timothy Colburn(Author)
    • 2015(Publication Date)
    • Routledge
      (Publisher)
    enlargement of content. For computer scientists, this allows programs and machines to be reasoned about, analyzed, and ultimately efficiently implemented in physical systems. For computer users, this allows useful objects, such as documents, shopping malls, and chat rooms, to exist virtually in a purely electronic space.

    Abstraction in Computer Science

    Understanding abstraction in computer science requires understanding some of the history of software engineering and hardware development, for it tells a story of an increasing distance between programmers and the machine-oriented entities which provide the foundation of their work. This increasing distance corresponds to a concomitant increase in the reliance on abstract views of the entities with which the discipline is fundamentally concerned. These entities include machine instructions, machine-oriented processes, and machine-oriented data types. I will now try to explain the role of abstraction with regard to these kinds of entities.
    Language Abstraction
    At the grossest physical level, a computer process is a series of changes in the state of a machine, where each state is described by the presence or absence of electrical charges in memory and processor elements. But as we have seen, programmers need not be directly concerned with machine states so described, because they can make use of software development tools which allow them to think in other terms. For example, with the move from assembly to high-level language, computer scientists can abandon talk about particular machine-oriented entities like instructions, registers and word integers in favor of more abstract statements and variables. High-level language programs allow machine processes to be described without reference to any particular machine. Thus, specific language content has not been eliminated, as in mathematical or deductive systems, but replaced by abstract descriptions with more expressive power.
  • Book cover image for: The Cambridge Handbook of Computing Education Research
    This is a core skill underpinning the way that the subject of computing has developed. It is also a core skill of computer scientists because without it, building the immensely large and complex systems that we now rely on is intractable. It is only by building in layers with clean interfaces between them that complex systems can be built, so that the complexity of each new layer is simple once the complexity of the lower layers has been hidden by the interface. A course has even been given where students build all of the layers of abstraction one at a time, starting with logic gates, and ending up with a working program running on an operating system (Schocken & Nisan, 2004). Such an endeavor is made possible by breaking it into 12 levels of abstraction. Computer scientists make use of a wide variety of forms of abstractions both in programming and in system design more generally. These include control abstraction, which is the core of developing programs based on procedures and functions, and data abstraction, which is the core idea behind building complex data types from simpler ones. Being able to think at multiple levels of abstraction and move between levels is a key ability. This is needed as one develops solutions, moving back and forth, for example, between the level of the problem, design levels, and pro- gramming levels. Linked to this is being able to view systems through different abstractions: the bus map intended for passengers may not, for example, include locations and times where drivers swap as their shifts start and end, whereas the abstract version for drivers would have very different information. Abstraction is not just important for building systems, but also for the devel- opment of theory. For example, O-notation focuses on critical operations rather than all operations or processor cycles. Hiding that detail allows us to reason effectively about the efficiency of algorithms.
  • Book cover image for: The Blackwell Guide to the Philosophy of Computing and Information
    Understanding abstraction in computer sci-ence requires understanding some of the history of software engineering and hardware develop-ment, for it tells a story of an increasing distance between programmers and the machine-oriented entities that provide the foundation of their work. This increasing distance corresponds to a con-comitant increase in the reliance on abstract views of the entities with which the discipline is fundamentally concerned. These entities include machine instructions, machine-oriented processes, and machine-oriented data types. The remainder of this chapter will explain the role of abstrac-tion with regard to these kinds of entities. Language abstraction . At the grossest physical level, a computer process is a series of changes in the state of a machine, where each state is described by the presence or absence of elec-trical charges in memory and processor elements. But programmers need not be directly concerned with machine states so described, because they can make use of software development tools that allow them to think in other terms. For example, with the move from assembly to high-level language, computer scientists can abandon Timothy Colburn 324 ReadMatrix(A,n,m) ReadMatrix(B,m,p) MultiplyMatrices(A,B,C,n,m,p) for i ← 1 to n do for j ← 1 to m do read(A[i,j]) for j ← 1 to m do for k ← 1 to p do read(B[j,k]) for i ← 1 to n do for k ← 1 to p do begin C[i,k] ← 0 for j ← 1 to m do C[i,k] ← C[i,k] + A[i,j] * B[j,k] end Figure 24.2 : Multiplying matrices with procedural abstraction talk about particular machine-oriented entities like instructions, registers, and word integers in favor of more abstract statements and variables. High-level language programs allow machine processes to be described without reference to any particular machine. Thus, specific language content has not been eliminated, as in mathemat-ical or deductive systems, but replaced by abstract descriptions with more expressive power.
  • Book cover image for: Programming with C++
    • Kyla McMullen, Elizabeth Matthews, June Jamrich Parsons, , Kyla McMullen, Kyla McMullen, Elizabeth Matthews, June Jamrich Parsons(Authors)
    • 2021(Publication Date)
    PROGRAMMING WITH C++ 12 Levels of Abstraction (1.4.7) After you get the hang of abstraction, you’ll see examples of this computational thinking concept everywhere. Applying the correct level of abstraction to your programs may take a little practice. A level of abstraction relates to the amount of detail that is hidden. Abstracting out too much detail can make a program too generalized. Neglecting abstraction can produce programs that are too specific to work with a wide variety of data. See Figure 1-11. Figure 1-11 Levels of abstraction Just right Too specific Too abstract With experience, you’ll be able to identify useful abstractions and gauge the correct level of abstraction to use. SUMMARY • Computational thinking techniques help programmers define problems, find solutions, delineate tasks, and devise algorithms. • An algorithm is a series of steps for solving a problem or carrying out a task. Programming algorithms are the blueprints for computer programs. • Standard algorithms exist for many computing tasks. When an algorithm does not exist, you can step through a process manually and record the steps, or apply computational thinking techniques, such as decomposition, pattern identification, and abstraction. • Decomposition divides a complex problem or task into manageable units. • Pattern identification reveals sequences and repetitive tasks that can lead to algorithm efficiencies. • Abstraction is a key computer science concept that suppresses details, substitutes a generalization for something specific, and allows an algorithm to work for multiple inputs. Figure 1-10 A login abstraction Black box User ID password Allow or deny access Look up stored user ID and password. Compare stored user ID and password to entered user ID and password. If they match, allow access. Copyright 2022 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
  • Book cover image for: Putting Information First
    eBook - ePub

    Putting Information First

    Luciano Floridi and the Philosophy of Information

    interaction patterns . Certainly, the objective of computer science is at times similar to that of mathematics—for example, when proving theorems about formal languages and the automata that process them. However, the central activity of computer science is the production of software, and this activity is primarily characterized not by the creation and exploitation of inference structures but by the modeling of interaction patterns. The kind of interaction involved depends upon the level of abstraction used to describe programs. At a basic level, software prescribes the interacting of a certain part of computer memory, namely, the program itself, and another part of memory, called the program data, through explicit instructions carried out by a processor. At a different level, software embodies algorithms that prescribe interactions among subroutines, which are cooperating pieces of programs. At a still different level, every software system is an interaction of computational processes. Today’s extremely complex software is possible only through abstraction levels that obscure machine-oriented concepts. Still, these levels are used to describe interaction patterns, whether they be between software objects or between a user and a system.
    What is a “level of abstraction” in computer science? The history of software development tells a story of an increasing distance between programmers and the machine-oriented entities that provide the foundation of their work, such as machine instructions, machine-oriented processes, and machine-oriented data types. Language abstraction accounts for this distance by allowing programmers to describe computational processes through linguistic constructs that hide details about the machine entities by allowing underlying software to handle those details. At the most basic physical level, a computer process is a series of changes in the state of a machine, where each state is described by the presence or absence of electrical charges in memory and processor elements. But programmers need not be directly concerned with machine states so described, because they can make use of languages that allow them to think in other terms. An assembly language programmer can ignore electrical charges and logic gates in favor of language involving registers, memory locations , and subroutines . A C language programmer can in turn ignore assembly language constructs in favor of language involving variables, pointers, arrays, structures , and functions . A Java language programmer can ignore some C language constructs by employing language involving objects and methods . The concepts introduced by each of these languages are not just old concepts with new names. They significantly enlarge the vocabulary of the programmer with new functionality while simultaneously freeing the programmer from having to attend to tedious details. For example, in the move from C to Java, programmers have new access to active
  • Book cover image for: Concepts in Programming Languages
    We could implement priority queues inefficiently to begin with, by using an algorithm that is easy to code, and then optimize the implementation later if this turns out to be needed. As written, it seems difficult to sort an array in place by this algorithm. However, it is possible to come close to the conventional heapsort algorithm. 242 Data Abstraction and Modularity 9.2 LANGUAGE SUPPORT FOR ABSTRACTION Programmers and software designers often speak about “finding the right abstrac-tion” for a problem. This means that they are looking for general concepts, such as data structures or processing metaphors, that will make a complex, detailed problem seem more orderly or systematic. One way that a programming language can help programmers find the right abstraction is by providing a variety of ways to organize data and computation. Another way that a programming language can help with finding the right abstraction is to make it possible to build program components that capture meaningful patterns in computation. 9.2.1 Abstraction In programming languages, an abstraction mechanism is one that emphasizes the general properties of some segment of code and hides details. Abstraction mecha-nisms generally involve separating a program into parts that contain certain details and parts where these details are hidden. Common terms associated with abstraction are client: the part of a program that uses program component implementation: the part of a program that defines a program component. The interaction between the client of an abstraction and the implementation of the abstraction is usually restricted to a specific interface. Procedural Abstraction One of the oldest abstraction mechanisms in programming languages is the proce-dure or function. The client of a function is a program making a function call. The implementation of a function is the function body, which consists of the instructions that will be executed each time the function is called.
  • Book cover image for: Introduction to Programming Languages
    121 C H A P T E R 4 Abstractions in Programs and Information Exchange BACKGROUND CONCEPTS Abstract syntax (Section 3.2.6); Abstract concepts in computations (Section 2.4); Grammars (Section 3.1); Control flow (Section 1.4.2); Data structure concepts (Section 2.3); Discrete structures (Section 2.2); Graphs (Section 2.3.6); Programming background; Trees (Section 2.3.5); Syntax diagrams (Section 3.3). A program is about the manipulation of structured data to achieve an intended computa-tional state that satisfies the final intended condition. Programming can be done at multi-ple levels: machine-level programming, assembly-level programming, low-level procedural programming, high-level procedural programming, declarative programming, and so on. The amount of abstraction and the level of explicit control separate high-level program-ming languages from low-level programming languages. One of the goals of abstractions is to make the software reusable with minimal change, so that software evolution has minimal overhead as the needs evolve or technology changes. There are two types of abstractions as described earlier: data abstractions and control abstractions. Data abstractions are used to model real-world entities using a required subset of their attributes, and control abstractions are used to structure the sequence of instructions for better comprehension and maintenance. A data entity can be characterized by a set of attributes and can be abstracted by a relevant subset of those attributes needed to solve a prob-lem at hand. Data entities are generally expressed in the declaration part of a program, and the control part is expressed in the body of the program. As described earlier, the declaration part of the program modifies the program environment, and the control part of the pro-gram that involves assignment statement modifies the program store.
  • Book cover image for: Managing Complexity of Information Systems
    eBook - ePub
    • Pirmin P. Lemberger, Mederic Morel(Authors)
    • 2013(Publication Date)
    • Wiley-ISTE
      (Publisher)
    An interesting by-product of the above discussion on K-complexity and Bennett's depth is that these concepts can help us clarify what is the level of abstraction of the model for a system. This is particularly important, as most complex systems, such as ISs, need several descriptions at different scales. As we will argue later, scale is precisely one of the attributes of an abstraction level of a model.
    Having a clear idea of what an abstraction level is will be of particular importance when we discuss abstraction in software engineering in section 2.3.2 and IS modeling best practices in section 4.3.1 . Abstraction levels in IT are customarily denoted by well-known terms that correspond, more or less, to layers of IT architecture such as the business process architecture, the software architecture, the application architecture, the hardware architecture, and so on.
    To define the level of abstraction of a model of a system, we use an analogy. The system under consideration is represented by a binary string s : think of it as its description at a given scale as we explained earlier. A model of this system, at a given scale, can be considered a compressed version of its explicit description. We thus assimilate a model with a program p that generates the string s through some computing mechanism such as a Turing machine. The Turing machine should be considered here as a metaphor for the design process that leads from the model of a system to the system itself. To set the ideas in an IT context, consider the system as a business application, and its model is a set of UML diagrams.
    Figure 2.4.
    The model for a piece of software can consist of a set of UML diagrams. These diagrams can be thought of as a compressed version of the software to be produced: they are to be read and interpreted by a designer to produce the desired piece of software. This closely parallels the concepts of Bennett's logical depth where a compressed description of an object is a program run by a Turing machine, which produces the explicit description of an object. An abstraction level of the description of a system is characterized, besides the scale, by its level of compression
  • Book cover image for: The Cognitive Psychology of Knowledge
    • G. Strube, K.F. Wender(Authors)
    • 1993(Publication Date)
    • North Holland
      (Publisher)
    Michalski and Kodratoff (1990) have recently pointed out that abstraction has to be distinguished from generalization. While generalization transforms a description along a set superset dimension, abstraction transforms a description along a level of detail dimension. While generalization often uses the same representationlanguage, abstractionusually involves a changein the representation space (e.g. from the system level to the situational level) to transform the representation languageinto a simpler language than the original (Michalski I& Kodratoff, 1990). The central idea of abstraction, therefore, may be stated as to achieve a reduction of the level of detail of a description. The acquisition of knowledge from programming events has often be described as generalization (Weber, Bagelsack, & Wender, in press) rather than abstraction. A program is composed of operations which are executed in a specific order and changes the state of the system. Therefore program abstraction has two independent dimensions: On the first dimension a change in the level of detail for the representation of single states is described. On the second dimension a change in the level of detail is declared by reducing the number of the states Chapter 10 Learning Program Abstractions 213 contained in a program. As a consequence, a change of the representation of the state description and a change of the operations which describe the state transitions is required. SufSicient Conditions for the Formation of a Procedure Schema Since the goal is to construct domain-specific program abstractions, we assume that the system model about the programming environment and the situation model about the application domain can be formalized as two STRIPS worlds (e.g., Fikes, Hart, & Nilsson, 1972; Lifschitz, 1987; Knoblock, 1989). A STRIPS world W is a Triple (R, T, Op) over a first-order language L, where R is a set of essential sentences (Lifschitz, 1987) which describe aspects of a state of the world.
Index pages curate the most relevant extracts from our library of academic textbooks. They’ve been created using an in-house natural language model (NLM), each adding context and meaning to key research topics.