#include "lst.h"
#include "matrix.h"
#include "mul.h"
-#include "ncmul.h"
-#include "numeric.h"
#include "power.h"
#include "relational.h"
#include "pseries.h"
for (unsigned c=0; c<symbols.nops(); c++) {
ex co = eq.coeff(ex_to_symbol(symbols.op(c)),1);
linpart -= co*symbols.op(c);
- sys.set(r,c,co);
+ sys(r,c) = co;
}
linpart = linpart.expand();
- rhs.set(r,0,-linpart);
+ rhs(r,0) = -linpart;
}
// test if system is linear and fill vars matrix
for (unsigned i=0; i<symbols.nops(); i++) {
- vars.set(i,0,symbols.op(i));
+ vars(i,0) = symbols.op(i);
if (sys.has(symbols.op(i)))
throw(std::logic_error("lsolve: system is not linear"));
if (rhs.has(symbols.op(i)))
return sollist;
}
-/** non-commutative power. */
-ex ncpow(const ex & basis, unsigned exponent)
-{
- if (exponent == 0)
- return _ex1();
-
- exvector v;
- v.reserve(exponent);
- for (unsigned i=0; i<exponent; ++i)
- v.push_back(basis);
-
- return ncmul(v, true);
-}
-
/** Force inclusion of functions from initcns_gamma and inifcns_zeta
* for static lib (so ginsh will see them). */
unsigned force_include_tgamma = function_index_tgamma;