stuff-from-scratch/plugins/math/ComplexNumber.h
2023-01-26 11:27:35 +00:00

21 lines
No EOL
317 B
C++

#pragma once
class ComplexNumber
{
public:
ComplexNumber(double real = 0.0, double imaginary = 0.0);
double getReal() const;
double getImaginary() const;
double getMagnitude() const;
void setReal(double value);
void setImaginary(double value);
private:
double mReal{ 0.0 };
double mImaginary{ 0.0 };
};