Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/GAP/pkg/anupq/src/   (Algebra von RWTH Aachen Version 4.15.1©)  Datei vom 28.7.2025 mit Größe 1 kB image not shown  

Quelle  print_auts.c   Sprache: C

 
/****************************************************************************
**
*A  print_auts.c                ANUPQ source                   Eamonn O'Brien
**
*Y  Copyright 1995-2001,  Lehrstuhl D fuer Mathematik,  RWTH Aachen,  Germany
*Y  Copyright 1995-2001,  School of Mathematical Sciences, ANU,     Australia
**
*/


#include "pq_defs.h"
#include "pcp_vars.h"
#include "pga_vars.h"
#include "pq_functions.h"
#include "constants.h"

/* list the actions of the nmr_auts automorphisms on the
   nmr_gens generators of the group */


void Aprint_auts(int nmr_auts, int nmr_gens, int ***auts, struct pcp_vars *pcp)
{
   register int i, j, k;
   FILE *output_file;
   char *file_name;
   int image;

   file_name = allocate_char_vector(MAXWORD + 1, 0, FALSE);

   sprintf(file_name, "auts%d^%d", pcp->p, pcp->lastg);
   /* open the file in update mode */
   output_file = OpenFile(file_name, "a+");

   fprintf(output_file, "[");

   for (i = 1; i <= nmr_auts; ++i) {
      for (j = 1; j <= nmr_gens; ++j) {
         image = 0;
         for (k = 1; k <= pcp->lastg; ++k)
            if (auts[i][j][k] != 0)
               image = 10 * image + k;

         fprintf(output_file, "%d", image);
         if (i == nmr_auts && j == nmr_gens)
            /*x = 1*/;
         else
            fprintf(output_file, ",");
         /*
                     if (auts[i][j][k] != 0)
                        fprintf (output_file, "%d ", k);
                        fprintf (output_file, "%d ", auts[i][j][k]);
         */

      }
   }
   fprintf(output_file, "],\n");

   CloseFile(output_file);

   free(file_name);
}

void print_auts(int nmr_auts, int nmr_gens, int ***auts, struct pcp_vars *pcp)
{
   register int i, j, k;

   for (i = 1; i <= nmr_auts; ++i) {
      printf("Automorphism %d:\n", i);
      for (j = 1; j <= nmr_gens; ++j) {
         printf("Generator %2d --> ", j);
         for (k = 1; k <= pcp->lastg; ++k)
            printf("%d ", auts[i][j][k]);
         printf("\n");
      }
   }
}

Messung V0.5
C=70 H=93 G=82

¤ Dauer der Verarbeitung: 0.11 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.