1
Name:
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282: DATA STRUCTURES AND NUMERICAL METHODS
Test 2 November 4, 2014
1. [10 points] In the following, class entry represents a calendar entry. Each entry has a name, date,
start time an

Using Apples Xcode as your editor/compiler
You must first install Xcode using the Mac App Store. If you are not running the
latest version of OS X you may have to update OS X first.
After installation, Xcode will appear in your Application folder. You may

CHAPTER 1
Laplace Transform Methods
Laplace transform is a method frequently employed by engineers. By applying the Laplace transform, one can change an ordinary differential equation into an algebraic equation, as algebraic equation is generally easier t

Numerical Methods
/
/* File: floataddition.cpp
Illustrates round off when numbers are added */
1
Numerical Methods
/
/*
#include <iostream>
#include <iomanip>
#include <cmath>
File: accumulatedroundoff.cpp
This program illustrates the accumulaton of round

The Standard Temple Library
1
The Standard Template Library
The Standard Template Library (STL) provides general purpose, templatized classes and functions
that implement many popular and commonly used algorithms and data structures. For example it
includ

1
Assignment 9
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282
ASSIGNMENT # 9, due Monday Nov 17, 2014 before midnight
1. In the program figures.cpp we have a base class location and various derived classes:
circle, triangle, rectangle

employeedestructor.cpp
/*
File: employeedestructor.cpp
Illustrates the destructor */
#include <iostream>
#include <string>
using namespace std;
class employee cfw_
private:
string name; / last name
int id;
/ employee id number
float salary; / employee sal

fvector.cpp
/*
1
File: fvector.cpp
This program shows how to properly implement a class which represents
an array of floats */
#include <iostream>
#include <fstream>
using namespace std;
class fvector cfw_
private:
int size_;
float* p;
/ size of the array

File: Sept11Programs.md
Date: Sat Sep 13 15:13:31 2014
# September 11, 2014, Programs discussed in class
*Example*
/ File addints.cpp
/ read 2 integers and display the sum
#include <iostream>
using namespace std;
int main(void)
cfw_
int a, b, c;
cout < "E

1
Assignment 8
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282
ASSIGNMENT # 8, Due Monday November 3, 2014, before midnight
1. In this question we model a database of employees of a company. Assume that there are only
three types of em

1
Assignment 10
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282
ASSIGNMENT # 10, due Monday December 1, 2014 before midnight
The header le matrix.h declares a matrix class and various matrix functions.
The source le matrix.cpp implemen

1
Assignment 6
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282
ASSIGNMENT # 6, Due Monday October 20, 2014, before midnight
1. We sometimes see a stack implemented with a sentinel node which does not hold actual data
but is used to loc

1
Assignment 7
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282
ASSIGNMENT # 7, Due Monday October 27, 2014, before midnight
1. The following program simulates a single server queuing system. This simulation uses the STL
classes queue a

1
Assignment 4
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282: DATA STRUCTURES AND NUMERICAL METHODS
ASSIGNMENT # 4, due Monday October 6, 2014 before midnight
1. In the following program an employee of a company is represented by an

1
Assignment # 1
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282: DATA STRUCTURES AND NUMERICAL METHODS
ASSIGNMENT # 1, Due date: Monday, September 15, 2014 before midnight
For marking purposes, copy and paste your source code, output

1
Assignment 5
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM2282
ASSIGNMENT # 5, Due Tuesday October 14, 2014 before midnight
1. Use the class stack discussed in the lectures to make a stack class template. Write the
methods of the templ

Assignment 2
1
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282: DATA STRUCTURES AND NUMERICAL METHODS
ASSIGNMENT # 2, due Monday September 22, 2014 before midnight
1. Complete the implementation of the class time24 as declared in the p

1
Assignment 3
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM3282: DATA STRUCTURES AND NUMERICAL METHODS
ASSIGNMENT # 3, due Monday September 29, 2014 before midnight
1. The C+ standard library includes the complex header le for using com