*/
/*
- * GiNaC Copyright (C) 1999-2003 Johannes Gutenberg University Mainz, Germany
+ * GiNaC Copyright (C) 1999-2004 Johannes Gutenberg University Mainz, Germany
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
namespace {
+// regulates the pole (used by 1/x-transformation)
+symbol H_polesign("IMSIGN");
+
+
// forward declaration
ex convert_from_RV(const lst& parameterlst, const ex& arg);
// if all parameters are either zero or one return the transformed function
if (find(parameter.begin(), parameter.end(), 0) == parameter.end()) {
map_trafo_H_mult unify;
- return unify((pow(H(lst(1),1/arg).hold() + H(lst(0),1/arg).hold() - I*Pi, parameter.nops()) /
+ return unify((pow(H(lst(1),1/arg).hold() + H(lst(0),1/arg).hold() + H_polesign, parameter.nops()) /
factorial(parameter.nops())).expand());
} else if (find(parameter.begin(), parameter.end(), 1) == parameter.end()) {
return pow(-1, parameter.nops()) * H(parameter, 1/arg).hold();
ex res = trafo(H(convert_to_RV(ex_to<lst>(x1)), xtemp));
map_trafo_H_convert converter;
res = converter(res);
+ if (cln::imagpart(x) <= 0) {
+ res = res.subs(H_polesign == -I*Pi);
+ } else {
+ res = res.subs(H_polesign == I*Pi);
+ }
return res.subs(xtemp==x2).evalf();
}