From bf28c9f0b06f349b3a655ee7c152d9ab77a900b7 Mon Sep 17 00:00:00 2001 From: Christian Bauer Date: Sat, 16 Jun 2001 20:23:26 +0000 Subject: [PATCH] fixed comments --- check/time_lw_H.cpp | 16 +++++++++------- ginac/inifcns.cpp | 4 ++-- ginac/symmetry.cpp | 6 +++--- 3 files changed, 14 insertions(+), 12 deletions(-) diff --git a/check/time_lw_H.cpp b/check/time_lw_H.cpp index 1621a6e1..fe64b3ab 100644 --- a/check/time_lw_H.cpp +++ b/check/time_lw_H.cpp @@ -32,13 +32,15 @@ static unsigned test(unsigned n) hilbert.set(r,c,numeric(1,r+c+1)); ex det = hilbert.determinant(); - // The closed form of the determinant of n x n Hilbert matrices is: - // - // n-1 / n-1 \ - // ----- | ----- | - // | | | pow(factorial(r),2) | | hilbert(r,c) | - // | | | | | | - // r = 0 \ c = 0 / + /* + The closed form of the determinant of n x n Hilbert matrices is: + + n-1 / n-1 \ + ----- | ----- | + | | | pow(factorial(r),2) | | hilbert(r,c) | + | | | | | | + r = 0 \ c = 0 / + */ ex hilbdet = 1; for (unsigned r=0; r #include -#define DO_GINAC_ASSERT -#include "assertion.h" - #include "symmetry.h" #include "lst.h" #include "numeric.h" // for factorial() @@ -289,12 +286,15 @@ int canonicalize(exvector::iterator v, const symmetry &symm) first = symm.children.begin(); switch (symm.type) { case symmetry::symmetric: + // Sort the children in ascending order shaker_sort(first, last, sy_is_less(v), sy_swap(v, something_changed)); break; case symmetry::antisymmetric: + // Sort the children in ascending order, keeping track of the signum sign *= permutation_sign(first, last, sy_is_less(v), sy_swap(v, something_changed)); break; case symmetry::cyclic: + // Permute the smallest child to the front cyclic_permutation(first, last, min_element(first, last, sy_is_less(v)), sy_swap(v, something_changed)); break; default: -- 2.35.3