Qrack
9.0
General classical-emulating-quantum development framework
|
#include "config.h"
#include <cmath>
#include <complex>
#include <cstdint>
#include <functional>
#include <limits>
#include <math.h>
#include <memory>
#include "half.hpp"
Go to the source code of this file.
Namespaces | |
Qrack | |
Macros | |
#define | _USE_MATH_DEFINES |
#define | IS_NORM_0(c) (norm(c) <= FP_NORM_EPSILON) |
#define | IS_SAME(c1, c2) (IS_NORM_0((c1) - (c2))) |
#define | IS_OPPOSITE(c1, c2) (IS_NORM_0((c1) + (c2))) |
#define | bitLenInt uint8_t |
#define | bitCapIntOcl uint8_t |
#define | bitsInCap 32 |
#define | bitCapInt uint32_t |
#define | bitsInByte 8U |
#define | qrack_rand_gen std::mt19937_64 |
#define | qrack_rand_gen_ptr std::shared_ptr<qrack_rand_gen> |
#define | QRACK_ALIGN_SIZE 64U |
#define | QRACK_CONST const |
Typedefs | |
typedef std::complex< half_float::half > | Qrack::complex |
typedef half_float::half | Qrack::real1 |
typedef float | Qrack::real1_f |
typedef float | Qrack::real1_s |
typedef std::shared_ptr< complex > | Qrack::BitOp |
typedef std::function< void(const bitCapIntOcl &, const unsigned &cpu)> | Qrack::ParallelFunc |
typedef std::function< bitCapIntOcl(const bitCapIntOcl &)> | Qrack::IncrementFunc |
typedef std::function< bitCapInt(const bitCapInt &)> | Qrack::BdtFunc |
typedef std::function< void(const bitCapInt &, const unsigned &cpu)> | Qrack::ParallelFuncBdt |
typedef std::shared_ptr< StateVector > | Qrack::StateVectorPtr |
typedef std::shared_ptr< StateVectorArray > | Qrack::StateVectorArrayPtr |
typedef std::shared_ptr< StateVectorSparse > | Qrack::StateVectorSparsePtr |
typedef std::shared_ptr< QEngine > | Qrack::QEnginePtr |
Variables | |
constexpr uint8_t | Qrack::ONE_BCI = 1U |
const real1 | Qrack::ZERO_R1 = (real1)0.0f |
constexpr real1_f | Qrack::ZERO_R1_F = 0.0f |
const real1 | Qrack::ONE_R1 = (real1)1.0f |
constexpr real1_f | Qrack::ONE_R1_F = 1.0f |
const real1 | Qrack::REAL1_DEFAULT_ARG = (real1)-999.0f |
const real1 | Qrack::REAL1_EPSILON = (real1)0.00000762939f |
const real1 | Qrack::PI_R1 = (real1)M_PI |
const real1 | Qrack::SQRT2_R1 = (real1)M_SQRT2 |
const real1 | Qrack::SQRT1_2_R1 = (real1)M_SQRT1_2 |
QRACK_CONST complex | Qrack::ONE_CMPLX = complex(ONE_R1, ZERO_R1) |
QRACK_CONST complex | Qrack::ZERO_CMPLX = complex(ZERO_R1, ZERO_R1) |
QRACK_CONST complex | Qrack::I_CMPLX = complex(ZERO_R1, ONE_R1) |
QRACK_CONST complex | Qrack::CMPLX_DEFAULT_ARG = complex(REAL1_DEFAULT_ARG, REAL1_DEFAULT_ARG) |
QRACK_CONST real1 | Qrack::FP_NORM_EPSILON = std::numeric_limits<real1>::epsilon() |
QRACK_CONST real1_f | Qrack::TRYDECOMPOSE_EPSILON = (real1_f)(8 * FP_NORM_EPSILON) |
constexpr real1_f | Qrack::FP_NORM_EPSILON_F = std::numeric_limits<real1_f>::epsilon() |
#define _USE_MATH_DEFINES |
#define bitCapInt uint32_t |
#define bitCapIntOcl uint8_t |
#define bitLenInt uint8_t |
#define bitsInByte 8U |
#define bitsInCap 32 |
#define IS_NORM_0 | ( | c | ) | (norm(c) <= FP_NORM_EPSILON) |
#define IS_OPPOSITE | ( | c1, | |
c2 | |||
) | (IS_NORM_0((c1) + (c2))) |
#define IS_SAME | ( | c1, | |
c2 | |||
) | (IS_NORM_0((c1) - (c2))) |
#define QRACK_ALIGN_SIZE 64U |
#define QRACK_CONST const |
#define qrack_rand_gen std::mt19937_64 |
#define qrack_rand_gen_ptr std::shared_ptr<qrack_rand_gen> |