2011 | OriginalPaper | Chapter
Object-Oriented Programming
Author : Hans Petter Langtangen
Published in: A Primer on Scientific Programming with Python
Publisher: Springer Berlin Heidelberg
Activate our intelligent search to find suitable subject content or patents.
Select sections of text to find matching patents with Artificial Intelligence. powered by
Select sections of text to find additional relevant content using AI-assisted search. powered by
This chapter introduces the basic ideas of object-oriented programming. Different people put different meanings into the term objectoriented programming: Some use the term for programming with objects in general, while others use the term for programming with class hierarchies. The author applies the second meaning, which is the most widely accepted one in computer science. The first meaning is better named
object-based
programming. Since everything in Python is an object, we do object-based programming all the time, yet one usually reserves this term for the case when classes different from Python’s basic types (
int, float, str, list, tuple, dict
) are involved.
A necessary background for the present chapter is Chapter 7. For Chapters 9.2 and 9.3 one must know basic methods for numerical differentiation and integration, for example from Appendix B. During an initial readings of the chapter, it can be beneficial to skip the more advanced material in Chapters 9.2.3–9.2.6.
All the programs associated with this chapter are found in the
src/oo
folder.