result += clifford_check6<varidx>(ex_to<matrix>(diag_matrix({-1, 0, 1, -1})))+clifford_check6<idx>(ex_to<matrix>(diag_matrix({-1, 0, 1, -1})));; cout << '.' << flush;
result += clifford_check6<varidx>(ex_to<matrix>(diag_matrix({-3, 0, 2, -1})))+clifford_check6<idx>(ex_to<matrix>(diag_matrix({-3, 0, 2, -1})));; cout << '.' << flush;
- realsymbol s("s"), t("t"); // symbolic entries in matric
+ realsymbol s("s"), t("t"); // symbolic entries in matrix
result += clifford_check6<varidx>(ex_to<matrix>(diag_matrix({-1, 1, s, t})))+clifford_check6<idx>(ex_to<matrix>(diag_matrix({-1, 1, s, t})));; cout << '.' << flush;
matrix A(4, 4);
++result;
}
- // Prefix/postfix increment/decrement behaviour:
+ // Prefix/postfix increment/decrement behavior:
e1 = 7; e2 = 4;
i1 = 7; i2 = 4;
e1 = (--e2 = 2)++;
/** @file exam_paranoia.cpp
*
* This set of tests checks for some of GiNaC's oopses which showed up during
- * development. Things were evaluated wrongly and so. Such a sick behaviour
+ * development. Things were evaluated wrongly and so. Such a sick behavior
* shouldn't occur any more. But we are paranoic and we want to exclude these
* these oopses for good, so we run those stupid tests... */
* their hash values. If the hash values are unpredictable, then so are
* the canonical orderings. If the canonical orderings are unpredictable,
* all subsequent times are subject to some variation. This variation,
- * however is natural and desireable for two reasons: First, we cannot know
+ * however is natural and desirable for two reasons: First, we cannot know
* how many symbols have been generated before in real world computations.
* Second, the following timings are subject to some semi-random variation
* anyways because short timings need to be repeated until enough time has
}
-/** Class of vertices of type Sigma_flipped, sitting in the upper fermionline of Vacuum; no consequences for Gamma. */
+/** Class of vertices of type Sigma_flipped, sitting in the upper fermion line of Vacuum; no consequences for Gamma. */
class Sigma_flipped : public Sigma {
public:
Sigma_flipped(ijpair ij = ijpair(0,0)) : Sigma(ij) { }
the maximal expansion. For example, for the exponent GiNaC firstly expands
the argument and then the function. For the logarithm and absolute value,
GiNaC uses the opposite order: firstly expands the function and then its
-argument. Of course, a user can fine-tune this behaviour by sequential
+argument. Of course, a user can fine-tune this behavior by sequential
calls of several @code{expand()} methods with desired flags.
@node Multiple polylogarithms, Complex expressions, Built-in functions, Methods and functions
}
/**
- * This method is defined to be in line with behaviour of function::return_type()
+ * This method is defined to be in line with behavior of function::return_type()
*/
ex function::eval_ncmul(const exvector & v) const
{
// end of generated lines
}
}
- // There is no fallback for explicit deriviative.
+ // There is no fallback for explicit derivative.
throw(std::logic_error("function::expl_derivative(): explicit derivation is called, but no such function defined"));
}
/** Maximum number of terms of leading coefficient of symbol in both polynomials */
size_t max_lcnops;
- /** Commparison operator for sorting */
+ /** Comparison operator for sorting */
bool operator<(const sym_desc &x) const
{
if (max_deg == x.max_deg)
namespace GiNaC {
/**
- * Flags to control the behaviour of gcd() and friends
+ * Flags to control the behavior of gcd() and friends
*/
struct gcd_options
{
numeric::numeric(int i)
{
// Not the whole int-range is available if we don't cast to long
- // first. This is due to the behaviour of the cl_I-ctor, which
+ // first. This is due to the behavior of the cl_I-ctor, which
// emphasizes efficiency. However, if the integer is small enough
// we save space and dereferences by using an immediate type.
// (C.f. <cln/object.h>)
numeric::numeric(unsigned int i)
{
// Not the whole uint-range is available if we don't cast to ulong
- // first. This is due to the behaviour of the cl_I-ctor, which
+ // first. This is due to the behavior of the cl_I-ctor, which
// emphasizes efficiency. However, if the integer is small enough
// we save space and dereferences by using an immediate type.
// (C.f. <cln/object.h>)
results.reserve(n/2);
for (unsigned p=next_r; p<=n; p+=2) {
- cln::cl_I c = 1; // seed for binonmial coefficients
+ cln::cl_I c = 1; // seed for binomial coefficients
cln::cl_RA b = cln::cl_RA(p-1)/-2;
// The CLN manual says: "The conversion from `unsigned int' works only
// if the argument is < 2^29" (This is for 32 Bit machines. More
// -(a)
// +a
// +(a)
- // Delegete the work to parse_binop_rhs(), otherwise we end up
+ // Delegate the work to parse_binop_rhs(), otherwise we end up
// duplicating it here.
ex lhs = _ex0; // silly trick
ex e = parse_binop_rhs(0, lhs);
{
auto i = m.begin();
while (i != m.end()) {
- // be careful to not invalide iterator, use post-increment
+ // be careful to not invalidate the iterator, use post-increment
// for that, see e.g.
// http://coding.derkeiler.com/Archive/C_CPP/comp.lang.cpp/2004-02/0502.html
if (i->second.is_zero())
}
} else {
Apr = (A/icont_).expand();
- // A is a polynomail over rationals, so GCD is defined
+ // A is a polynomial over rationals, so GCD is defined
// up to arbitrary rational number.
return n1;
}
/** Maximum number of terms of leading coefficient of symbol in both polynomials */
std::size_t max_lcnops;
- /** Commparison operator for sorting */
+ /** Comparison operator for sorting */
bool operator<(const sym_desc &x) const
{
if (max_deg == x.max_deg)