Question: C++ Review 8 code in c++ Phasoris a vector that has an arrow head at one end which signifies partly the maximum value of the
C++ Review 8
code in c++
Phasoris a vector that has an arrow head at one end which signifies partly the maximum value of the vector quantity and partly the end of the vector that rotates.Phasors are represented by a magnitude (peak amplitude) and phase (angle):
where,
- A is a floating point number which is often called it's magnitude
- is a floating point number which is often called it's phase.
Write the definition of classPhasor, (DO NOT COMPUTE ANY FUNCTION DEFINITIONS INLINE).Phasorshould have two attributes (one to store the magnitude and one to store phase) and the following member functions:
- Class Constructorthat takes two parameters
- Compute X- function that returns the x coordinate of the Phasor number
- Compute Y- function that returns the y coordinate of the Phasor number
- Display- function that displays the (A, ) coordinate of the Phasor number
- Is Opposite- function that compares another Phasor number to this Phasor number to see if they point in opposite
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
