Quadripoint.hpp 745 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. #ifndef __QUADRIPOINT_HPP
  2. #define __QUADRIPOINT_HPP
  3. //#include "bgn.hpp"
  4. #include "mydouble.h"
  5. extern "C" {
  6. #include "fpe.h"
  7. }
  8. extern "C" {
  9. #include "fp2e.h"
  10. }
  11. extern "C" {
  12. #include "fp6e.h"
  13. }
  14. extern "C" {
  15. #include "fp12e.h"
  16. }
  17. #include "zout.hpp"
  18. class Quadripoint
  19. {
  20. public:
  21. //Quadripoint() = default;
  22. Quadripoint();
  23. Quadripoint(fp12e_t p1,fp12e_t p2, fp12e_t p3,fp12e_t p4);
  24. void set(fp12e_t, int numpoint);
  25. void print(int numpoint) const;
  26. fp12e_t& operator[](int n); //la valeur de retour doit être une référence.
  27. bool operator==(Quadripoint b);
  28. Quadripoint operator*(Quadripoint b);
  29. Quadripoint square();
  30. Quadripoint pow_vartime(const scalar_t exp);
  31. void print() const;
  32. private:
  33. fp12e_t point[4]; };
  34. #endif