Skip to main content

Developing Classes for Linear Algebra Calculations

  • Chapter
  • First Online:
  • 216k Accesses

Part of the book series: Undergraduate Topics in Computer Science ((UTICS))

Abstract

Linear algebra calculations—i.e. operations on vectors and matrices—are at the heart of many scientific computing application codes. In this chapter we will apply the ideas introduced earlier in this book to begin to develop a collection of classes that allow us to perform these calculations. We will describe the design of a class of vectors in the body of this chapter. Appropriate constructors and destructors will ensure that memory is managed correctly, and operator overloading will allow operations between vectors and matrices (such as addition, subtraction and multiplication) to be coded in a natural manner. The exercises at the end of the chapter will focus on developing this class further, developing a companion class of matrices, and developing a linear system class that allows us to solve matrix equations.

This is a preview of subscription content, log in via an institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Joe Pitt-Francis .

Rights and permissions

Reprints and permissions

Copyright information

© 2017 Springer International Publishing AG, part of Springer Nature

About this chapter

Check for updates. Verify currency and authenticity via CrossMark

Cite this chapter

Pitt-Francis, J., Whiteley, J. (2017). Developing Classes for Linear Algebra Calculations. In: Guide to Scientific Computing in C++. Undergraduate Topics in Computer Science. Springer, Cham. https://doi.org/10.1007/978-3-319-73132-2_10

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-73132-2_10

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-73131-5

  • Online ISBN: 978-3-319-73132-2

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics