Skip to content

Instantly share code, notes, and snippets.

View bluescarni's full-sized avatar

Francesco Biscani bluescarni

  • European Space Agency
  • Germany
View GitHub Profile
#include <cmath>
#include <iostream>
#include <functional>
#include <utility>
#include <vector>
double my_cos(double x, double y)
{
return std::cos(x);
}
#include <algorithm>
#include <chrono>
#include <cmath>
#include <functional>
#include <iostream>
#include <iterator>
#include <random>
static std::mt19937 rng;
#include <iostream>
#include <tuple>
template <typename T, typename ... Args>
std::tuple<Args...,T> push_back(const std::tuple<Args...> &t, const T &x)
{
return std::tuple_cat(t,std::make_tuple(x));
}
struct my_add
In file included from /home/yardbird/temp/csympy/symengine/basic.h:25:
/home/yardbird/temp/csympy/symengine/symengine_rcp.h:205:21: error: no matching constructor for initialization of 'const SymEngine::Polynomial'
return rcp( new T( std::forward<Args>(args)... ) );
^ ~~~~~~~~~~~~~~~~~~~~~~~~
/home/yardbird/temp/csympy/symengine/polys.h:28:16: note: in instantiation of function template specialization 'SymEngine::make_rcp<const SymEngine::Polynomial, const
std::vector<SymEngine::RCP<const SymEngine::Symbol>, std::allocator<SymEngine::RCP<const SymEngine::Symbol> > > &, piranha::hash_set<SymEngine::m_pair, SymEngine::pair_hash,
SymEngine::pair_eq> &>' requested here
return make_rcp<const Polynomial>(vars, polys_set);
^
/home/yardbird/temp/csympy/symengine/polys.h:23:5: note: candidate constructor not viable: no known conversion from 'piranha::hash_set<SymEngine::m_pair, SymEngine::pair_hash,
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#include <stdexcept>
#include <string>
#include "piranha/piranha.hpp"
class dual_object
{
using p_type = piranha::polynomial<double,piranha::k_monomial>;
public:
explicit dual_object(const std::string &str, int limit):m_p(str),m_limit(limit) {}
[3000052519351678883,] -3000052519351678883,3000052519351678883,6000105038703357766
[1035674591,1314379097,] -2722538069758902342,2722538069758902342,5445076139517804684
[637718,658770,567487,] -953629001179892287,953629001179892287,1907258002359784574
[19319,19851,21635,19661,] -1305157073341076330,1305157073341076330,2610314146682152660
[2493,2504,2753,2430,2609,] -1744971743003927339,1744971743003927339,3489943486007854678
[743,659,749,629,650,683,] -3291538524541513545,3291538524541513545,6583077049083027090
[165,173,165,155,165,153,157,] -189231215387229067,189231215387229067,378462430774458134
[78,81,83,83,78,74,78,73,] -192660690034080376,192660690034080376,385321380068160752
[39,39,39,39,36,39,36,39,37,] -48577989392677837,48577989392677837,97155978785355674
[39,36,39,39,39,39,39,39,39,37,] -4153085367119210737,4153085367119210737,8306170734238421474
#include <boost/timer/timer.hpp>
#include <cmath>
#include <string>
#include "piranha.hpp"
using namespace piranha;
//typedef k_monomial k_type;
typedef monomial<signed char> k_type;
typedef polynomial<double, k_type > dual;
template <bool Flag, typename T>
struct enable_if
{
using type = T;
};
template <typename T>
struct enable_if<false,T>
{};