Guest User

Untitled

a guest
May 4th, 2015
470
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.57 KB | None | 0 0
  1. #ifndef FACTOR_H
  2. #define FACTOR_H
  3. #include <iostream>
  4. #include <cmath>
  5. #include <fstream>
  6. #define PI 3.14
  7.  
  8. using namespace std;
  9.  
  10.  
  11. struct SQ{
  12. string name;
  13. string a;
  14. string b;
  15. string c;
  16. };
  17.  
  18. class Factor
  19. {
  20. public:
  21. double n = 0;
  22. long long int pot = 0;
  23. bool inf = false;
  24. string name = "";
  25.  
  26. Factor();
  27. virtual ~Factor();
  28. protected:
  29. private:
  30. };
  31.  
  32.  
  33. extern int digits = 0;
  34. extern bool degrees = true;
  35.  
  36. extern ofstream* o;
  37. extern Factor nullFactor;
  38.  
  39.  
  40. template<typename T>
  41. void Send(T a){
  42. *o << a;
  43. cout << a;
  44. }
  45.  
  46. template<typename T>
  47. void Send(T a, bool b){
  48. *o << a << "\n";
  49. cout << a << "\n";
  50. }
  51.  
  52.  
  53. void Send(Factor a, bool b);
  54. void Send(Factor a);
  55. void Send(Factor* a, int n, char c, bool d);
  56. void Send(Factor* a, int n, char c);
  57. Factor fixFactor(Factor a);
  58. bool operator==(Factor a, Factor b);
  59. bool operator<(Factor a, Factor b);
  60. bool operator>(Factor a, Factor b);
  61. bool operator>=(Factor a, Factor b);
  62. bool operator<=(Factor a, Factor b);
  63. bool operator!=(Factor a, Factor b);
  64. Factor operator+(Factor a, Factor b);
  65. Factor operator-(Factor a, Factor b);
  66. Factor operator-(Factor a);
  67. Factor operator*(Factor a, Factor b);
  68. Factor operator/(Factor a, Factor b);
  69. Factor F(double b);
  70. Factor sqrt(Factor a);
  71. Factor cbrt(Factor a);
  72. Factor corruptFactor(Factor a);
  73. Factor tan(Factor a);
  74. Factor atan(Factor a);
  75. Factor sin(Factor a);
  76. Factor asin(Factor a);
  77. Factor cos(Factor a);
  78. Factor acos(Factor a);
  79.  
  80.  
  81. #endif // FACTOR_H
Advertisement
Add Comment
Please, Sign In to add comment