l09_6up - : Matrix operations : CSci 1113 C/C+ for...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
: CSci 1113 C/C++ for Scientists and Engineers Section 010 - evening class Arrays Prof. Eric Van Wyk and Ted Kaminski Spring 2010 c ± Van Wyk and Kaminski CSci 1113: C/C++ for Scientists and Engineers, evening class Spring 2010 Page 1 / 20 Matrix operations : Matrix multiplication I Let’s write a matrix multiplication function I Until we introduce pointers, we’ll be working with partially filled arrays. c ± Van Wyk and Kaminski CSci 1113: C/C++ for Scientists and Engineers, evening class Spring 2010 Page 2 / 20 Matrix operations : Exercise 9.1 What should the function declaration for matrix multiply look like? c ± Van Wyk and Kaminski CSci 1113: C/C++ for Scientists and Engineers, evening class Spring 2010 Page 2 / 20 Matrix operations : Examples I RadioCost.cpp I GraphReachability.cpp c ± Van Wyk and Kaminski CSci 1113: C/C++ for Scientists and Engineers, evening class Spring 2010 Page 3 / 20 Grouping data: struct : Syntax struct name { variable declarations } ; c ± Van Wyk and Kaminski CSci 1113: C/C++ for Scientists and Engineers, evening class Spring 2010 Page 4 / 20 Grouping data: struct : Date example: declaration struct Date { int year; int month; int day; } ; I Using a class like a struct is a bad idea. I Classes are about operations! c ± Van Wyk and Kaminski CSci 1113: C/C++ for Scientists and Engineers, evening class Spring 2010 Page 5 / 20
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Grouping data: struct : Date example: use Date now;
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 4

l09_6up - : Matrix operations : CSci 1113 C/C+ for...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online