Object Oriented Programming Lab 7. Lab Task#1 Create a create POINT to represent a point in Cartesian coordinate system Choose appropriate data members.

Slides:



Advertisements
Similar presentations
Sec 1-3 Concept: Use Midpoint and Distance Formulas
Advertisements

The Point Class public class Point { public double x; public double y; public Point(double x0, double y0) { x = x0; y = y0; } public double distance(Point.
Contents o Introduction o Characteristics of Constructor. o Types of constructor. - Default Constructor - Parameterized Constructor - Copy Constructor.
C1: The Distance Between Two Points & The Mid-Point of a Line
Lecture 15 Today Transformations between coordinate systems 1.Cartesian to cylindrical transformations 2.Cartesian to spherical transformations.
Basic Math Vectors and Scalars Addition/Subtraction of Vectors Unit Vectors Dot Product.
©thevisualclassroom.com (2,4) (12, 8) 2.7 Determining the Midpoint of a Line Segment (7,6) Find the midpoint between the points (2, 4) and (12, 8) 2 12.
THE DISTANCE FORMULA During this lesson, we will use the Distance Formula to measure distances on the coordinate plane.
M5G2 – Students will understand the relationship of the circumference of a circle, its diameter, and pi (pi ≈ 3.14)
In a not gate, if the input is on(1) the output is off (0) and vice versa.
CIRCLES Topic 7.3.
SOLUTION EXAMPLE 4 Standardized Test Practice Use the Distance Formula. You may find it helpful to draw a diagram.
7.7: Areas of Circles and Sectors
4.7 Triangles and Coordinate Proof
The Distance and Midpoint Formulas and Other Applications 10.7.
(x 1, y 1 ) (x 2, y 2 (x 1, y 1 ) (x 2, y 2 ) |x 1 – x 2 | |y 1 – y 2 | d.
1-3 The Distance and Midpoint Formulas
Algebra Commandments Measurement. Solve real-world problems involving formulas for perimeter, area, distance, and rate Objective 4a – DoK 2.
Midpoint and Distance Formulas Goal 1 Find the Midpoint of a Segment Goal 2 Find the Distance Between Two Points on a Coordinate Plane 12.6.
Definitions of the Day (DODs) 9.2 – The Distance Formula and the Midpoint Formula Distance Formula Midpoint of a line segment Midpoint Formula.
Objective: Finding distance and midpoint between two points. Warm up 1.
Warm Up:. What is Geometry?  A branch of mathematics that studies the shape and size of objects.
Plotting, Midpoint, Distance, Slope. Cartesian Plane Coordinates are written in the following order.
Perimeter & Circumference Return to table of contents.
Circles in the Coordinate Plane I can identify and understand equations for circles.
Aim: Review the distance and midpoint Do Now: in the triangle, find the lengths of two legs (-2,4) (3,6) (3,4)
Midpoint and Distance Formulas
Topic 5-1 Midpoint and Distance in the Coordinate plan.
1-6 Midpoint and distance in the coordinate plane
Ellipses Topic Definitions Ellipse: set of all points where the sum of the distances from the foci is constant Major Axis: axis on which the foci.
1.1 and 1.5 Rectangular Coordinates and Circles Every man dies, not every man really lives. -William Wallace.
Warm up Write the standard form of the equation: Then find the radius and the coordinates of the center. Graph the equation.
1.1 and 1.5 Rectangular Coordinates and Circles Every man dies, not every man really lives. -William Wallace.
4.1 Apply the Distance and Midpoint Formulas The Distance Formula: d = Find the distance between the points: (4, -1), (-1, 6)
1.8 Midpoint & Distance Formula in the Coordinate Plane Objective: Develop and apply the formula for midpoint. Use the Distance Formula and the Pythagorean.
Making graphs and using equations of ellipses. An ellipse is the set of all points P in a plane such that the sum of the distance from P to 2 fixed points.
Equation of Circle Midpoint and Endpoint Distance Slope
DILATIONS Content Standards G.CO.2 Represent transformations in the plane using, e.g., transparencies and geometry software; describe transformations as.
Circle Equations. Definitions Circle: The set of all points that are the same distance from the center Radius: a segment whose endpoints are the center.
Midpoint and Distance in the Coordinate Plane SEI.3.AC.4: Use, with and without appropriate technology, coordinate geometry to represent and solve problems.
Warm Up.
1.3 Distance and Midpoints
CIRCLES Topic 7.3.
Algebra Commandments Measurement.
Bellwork: Find the length of the segments
Midpoint and Distance Formulas
Distance and Midpoint Formulas
1. Find the distance between HINT FOR MULTIPLE CHOICE!
Introduction to Graphing
Perpendiculars and Distance
CIRCLES Topic 10.2.
Cartesian Coordinate System
MATH 1330 Section 8.2b.
HINT FOR MULTIPLE CHOICE!
P.5 The Cartesian Plane Our goals are to learn
Distance Distance – The length of a segment, found by using the coordinates of the endpoints. If the segment is part of a number line (either horizontal.
Circles 4.1 (Chapter 10). Circles 4.1 (Chapter 10)
HINT FOR MULTIPLE CHOICE!
Function Rules and Tables.
21 3 Variables Selection Functions Repetition Challenge 21
NAME 436.
Review Unit 6 Test 1.
Find the center and radius of a circle with equation:
Parts, Circumference, Area
Warmup Find the distance between the point (x, y) and the point (h, k).
CIRCLES Topic 7.3.
C++ data types.
CIRCLES Topic 7.3.
Rectangular Coordinates and Circles
CIRCLES Topic 7.3.
Presentation transcript:

Object Oriented Programming Lab 7

Lab Task#1 Create a create POINT to represent a point in Cartesian coordinate system Choose appropriate data members Provide member functions: – Default constructor – Input – Output – Distance( returns the distance between two POINT objects, the function takes one object as an input) – isZero(determines if a point is the center) – Midlepoint(returns the middle point, takes one object as an input and returns the answer in a POINT object) – isEqualTo (compare two POINTs) – isGreaterThan (compares two POINT in terms of the distance from the center )

Lab Task Make a class LINE include appropriate data members. – A line segment includes the endpoints, i.e. the points that it joins. Class should also provide a function to find the length of the Line Two lines can be compared to determine which line is shorter and vice versa. Provide function to compare two Lines Provide appropriate constructors for initialization and destructor Make appropriate members constant