Orbiter 2022
Combinatorial Objects
projective_space_activity.cpp
Go to the documentation of this file.
1/*
2 * projective_space_activity.cpp
3 *
4 * Created on: Jan 5, 2021
5 * Author: betten
6 */
7
8
9
10
11#include "orbiter.h"
12
13using namespace std;
14
15namespace orbiter {
16namespace layer5_applications {
17namespace projective_geometry {
18
19
21{
22 Descr = NULL;
23 PA = NULL;
24}
25
27{
28
29}
30
32{
33 int f_v = (verbose_level >= 1);
34
35 if (f_v) {
36 cout << "projective_space_activity::perform_activity" << endl;
37 }
38
39#if 0
40 if (Descr->f_canonical_form_PG) {
41
42 PA->canonical_form(
43 Descr->Canonical_form_PG_Descr,
44 verbose_level);
45 }
46#endif
47
49
50 PA->P->export_incidence_matrix_to_csv(verbose_level);
51 }
52
53
55
57
59 PA,
63 verbose_level);
64 }
66
67
69
71 PA,
74 verbose_level);
75 }
77
78 //projective_space_global G;
79
80 int *genma;
81 int k, n;
82
84
85#if 0
86 G.canonical_form_of_code(
87 PA,
89 v, m, n,
91 verbose_level);
92#endif
93
96 genma, k, n,
98 verbose_level);
99
100
101 }
102 else if (Descr->f_map) {
103
105
106 G.map(
107 PA,
110 verbose_level);
111
112 }
114
116
118 PA,
121 verbose_level);
122
123 }
124
126
131 verbose_level);
132
133 }
134
136
140 verbose_level);
141
142 }
143
144
145 else if (Descr->f_define_object) {
146 cout << "-define_object " << Descr->define_object_label << endl;
148
150
152
153 GeoObj->init(Descr->Object_Descr, PA->P, verbose_level);
154
156
158
159 Symb->init_geometric_object(Descr->define_object_label, GeoObj, verbose_level);
160 if (f_v) {
161 cout << "before Orbiter->add_symbol_table_entry " << Descr->define_object_label << endl;
162 }
164
165 }
166 else if (Descr->f_define_surface) {
167
168 cout << "f_define_surface label = " << Descr->define_surface_label << endl;
169
172
174
176 PA,
178 Surf_A,
179 SC,
180 verbose_level);
181
183
185
186 Symb->init_cubic_surface(Descr->define_surface_label, SC, verbose_level);
187 if (f_v) {
188 cout << "before Orbiter->add_symbol_table_entry " << Descr->define_surface_label << endl;
189 }
191
192
193 //FREE_OBJECT(SC);
194 //FREE_OBJECT(Surf_A);
195 }
196
198
199 cout << "table_of_quartic_curves" << endl;
200
201 //projective_space_global G;
202
203 //G.table_of_quartic_curves(PA, verbose_level);
204 if (f_v) {
205 cout << "projective_space_activity::perform_activity before PA->table_of_quartic_curves" << endl;
206 }
207 PA->table_of_quartic_curves(verbose_level);
208 if (f_v) {
209 cout << "projective_space_activity::perform_activity after PA->table_of_quartic_curves" << endl;
210 }
211
212 }
213
215
216 cout << "table_of_cubic_surfaces" << endl;
217
218 //projective_space_global G;
219
220 //G.table_of_cubic_surfaces(PA, verbose_level);
221 if (f_v) {
222 cout << "projective_space_activity::perform_activity before PA->table_of_cubic_surfaces" << endl;
223 }
224 PA->table_of_cubic_surfaces(verbose_level);
225 if (f_v) {
226 cout << "projective_space_activity::perform_activity after PA->table_of_cubic_surfaces" << endl;
227 }
228 }
229
230 else if (Descr->f_define_quartic_curve) {
231
232 cout << "f_define_quartic_curve label = " << Descr->f_define_quartic_curve << endl;
233
235
236#if 0
238
239 G.do_create_quartic_curve(
240 PA,
242 QC,
243 verbose_level);
244#endif
245
246 if (f_v) {
247 cout << "projective_space_activity::perform_activity before PA->create_quartic_curve" << endl;
248 }
251 QC,
252 verbose_level);
253 if (f_v) {
254 cout << "projective_space_activity::perform_activity after PA->create_quartic_curve" << endl;
255 }
256
258
260
261 Symb->init_quartic_curve(Descr->define_quartic_curve_label, QC, verbose_level);
262 if (f_v) {
263 cout << "before Orbiter->add_symbol_table_entry "
264 << Descr->define_surface_label << endl;
265 }
267
268
269 //FREE_OBJECT(SC);
270 }
271
272 // surfaces:
273
274
276
279
280
282 PA,
284 SCW,
285 verbose_level);
286
288
290
292 if (f_v) {
293 cout << "before Orbiter->add_symbol_table_entry "
295 }
297
298 }
299
301
303 cout << "please use option -control_six_arcs <description> -end" << endl;
304 exit(1);
305 }
307
309 PA,
312 verbose_level);
313 }
314
317 cout << "please use option -trihedra1_control <description> -end" << endl;
318 exit(1);
319 }
321 cout << "please use option -trihedra2_control <description> -end" << endl;
322 exit(1);
323 }
325 cout << "please use option -control_six_arcs <description> -end" << endl;
326 exit(1);
327 }
329
331 PA,
335 verbose_level);
336 }
337 else if (Descr->f_sweep_4_15_lines) {
338
340
341
343 PA,
346 verbose_level);
347 }
348 else if (Descr->f_sweep_F_beta_9_lines) {
349
351
352
354 PA,
357 verbose_level);
358 }
359 else if (Descr->f_sweep_6_9_lines) {
360
362
363
365 PA,
368 verbose_level);
369 }
370 else if (Descr->f_sweep_4_27) {
371
373
374
375 SH.do_sweep_4_27(
376 PA,
379 verbose_level);
380 }
381
382#if 0
383 else if (Descr->f_create_surface) {
385 cout << "please use option -control_six_arcs <description> -end" << endl;
386 exit(1);
387 }
388
389 surface_domain_high_level SH;
390
391 SH.do_create_surface(
392 PA,
393 Descr->surface_description, Descr->Control_six_arcs,
394 verbose_level);
395 }
396#endif
397 else if (Descr->f_six_arcs_not_on_conic) {
399 cout << "please use option -control_six_arcs <description> -end" << endl;
400 exit(1);
401 }
403
404 SH.do_six_arcs(
405 PA,
409 verbose_level);
410 }
412
414
419 PA->P->F->q,
420 PA->P, verbose_level);
421 }
422
423 else if (Descr->f_spread_classify) {
424
425#if 0
427
428 G.do_spread_classify(PA,
431 verbose_level);
432#endif
435 verbose_level);
436 }
437 else if (Descr->f_classify_semifields) {
438
439#if 0
441
442 G.do_classify_semifields(
443 PA,
446 verbose_level);
447#endif
449
451
452 if (f_v) {
453 cout << "projective_space_activity::perform_activity before S->init" << endl;
454 }
455 S->init(
457 PA,
459 verbose_level);
460 if (f_v) {
461 cout << "projective_space_activity::perform_activity after S->init" << endl;
462 }
463
464 }
465 else if (Descr->f_cheat_sheet) {
466
468
469 if (orbiter_kernel_system::Orbiter->f_draw_options) {
471 }
472 else {
473 cout << "please use -draw_options .. -end" << endl;
474 exit(1);
475 }
476
477#if 0
479
480 G.do_cheat_sheet_PG(
481 PA,
482 O,
483 verbose_level);
484#endif
485 PA->cheat_sheet(O, verbose_level);
486
487 }
489
490 canonical_form_classifier *Classifier;
491
493
498 Classifier,
499 verbose_level);
500 }
501
502
504
506
508 PA,
514 verbose_level);
515
516 }
517 else if (Descr->f_set_stabilizer) {
518
520
527 verbose_level);
528 }
529
530 else if (Descr->f_conic_type) {
531
533
534 G.conic_type(PA,
537 verbose_level);
538 }
539
540 else if (Descr->f_lift_skew_hexagon) {
541
543
546 verbose_level);
547 }
548
550
552
555 verbose_level);
556 }
558 if (f_v) {
559 cout << "projective_space_activity::perform_activity f_arc_with_given_set_as_i_lines_after_dualizing" << endl;
560 }
561
564 Descr->arc_d,
566 Descr->arc_s,
569 verbose_level);
570
571 }
573 if (f_v) {
574 cout << "projective_space_activity::perform_activity f_arc_with_two_given_sets_of_lines_after_dualizing" << endl;
575 }
576
579 Descr->arc_d,
581 Descr->arc_s,
584 Descr->arc_t,
586 verbose_level);
587
588
589 }
591 if (f_v) {
592 cout << "projective_space_activity::perform_activity f_arc_with_three_given_sets_of_lines_after_dualizing" << endl;
593 }
594
597 Descr->arc_d,
599 Descr->arc_s,
602 Descr->arc_t,
604 Descr->arc_u,
606 verbose_level);
607
608 }
610 if (f_v) {
611 cout << "projective_space_activity::perform_activity f_dualize_hyperplanes_to_points" << endl;
612 }
613 long int *the_set_in;
614 int set_size_in;
615 long int *the_set_out;
616 int set_size_out;
617
618 Lint_vec_scan(Descr->dualize_input_set, the_set_in, set_size_in);
619
620 int i;
621 long int a;
622
623 set_size_out = set_size_in;
624 the_set_out = NEW_lint(set_size_in);
625 for (i = 0; i < set_size_in; i++) {
626 a = the_set_in[i];
627 the_set_out[i] = PA->P->Standard_polarity->Hyperplane_to_point[a];
628 }
629
630 cout << "output set:" << endl;
631 Lint_vec_print(cout, the_set_out, set_size_in);
632 cout << endl;
633
634 // only if n = 2:
635 //int *Polarity_point_to_hyperplane; // [N_points]
636 //int *Polarity_hyperplane_to_point; // [N_points]
637
638 FREE_lint(the_set_in);
639 FREE_lint(the_set_out);
640
641 }
643 if (f_v) {
644 cout << "projective_space_activity::perform_activity f_dualize_points_to_hyperplanes" << endl;
645 }
646 long int *the_set_in;
647 int set_size_in;
648 long int *the_set_out;
649 int set_size_out;
650
651 Lint_vec_scan(Descr->dualize_input_set, the_set_in, set_size_in);
652
653 int i;
654 long int a;
655
656 set_size_out = set_size_in;
657 the_set_out = NEW_lint(set_size_in);
658 for (i = 0; i < set_size_in; i++) {
659 a = the_set_in[i];
660 the_set_out[i] = PA->P->Standard_polarity->Point_to_hyperplane[a];
661 }
662
663 cout << "output set:" << endl;
664 Lint_vec_print(cout, the_set_out, set_size_in);
665 cout << endl;
666
667 FREE_lint(the_set_in);
668 FREE_lint(the_set_out);
669
670 }
672 if (f_v) {
673 cout << "projective_space_activity::perform_activity f_dualize_rank_k_subspaces" << endl;
674 }
675 long int *the_set_in;
676 int set_size_in;
677 long int *the_set_out;
678 int set_size_out;
679
680 Lint_vec_scan(Descr->dualize_input_set, the_set_in, set_size_in);
681
682 int i;
683 long int a;
684
685 set_size_out = set_size_in;
686 the_set_out = NEW_lint(set_size_in);
687 for (i = 0; i < set_size_in; i++) {
688 a = the_set_in[i];
689 cout << "i=" << i << " in=" << a << endl;
691 a, the_set_out[i], verbose_level);
692 cout << "i=" << i << " in=" << a << " out=" << the_set_out[i] << endl;
693 }
694
695 cout << "output set:" << endl;
696 Lint_vec_print(cout, the_set_out, set_size_in);
697 cout << endl;
698
699 FREE_lint(the_set_in);
700 FREE_lint(the_set_out);
701
702 }
703 else if (Descr->f_classify_arcs) {
705
707 PA,
709 verbose_level);
710 }
711 else if (Descr->f_classify_cubic_curves) {
713
715 PA,
717 verbose_level);
718 }
720
723 int nb_vars = PA->d;
724
725 G.latex_homogeneous_equation(PA->F, degree, nb_vars,
729 verbose_level);
730
731
732 }
734
735 if (f_v) {
736 cout << "projective_space_activity::perform_activity f_lines_on_point_but_within_a_plane" << endl;
737 }
738
741 long int *line_pencil;
742 int q;
743
744 q = PA->F->q;
745 line_pencil = NEW_lint(q + 1);
746
748 point_rk, plane_rk,
749 line_pencil, verbose_level);
750 // assumes that line_pencil[q + 1] has been allocated
751
752 cout << "line_pencil: ";
753 Lint_vec_print(cout, line_pencil, q + 1);
754 cout << endl;
755
756 if (f_v) {
757 cout << "projective_space_activity::perform_activity f_lines_on_point_but_within_a_plane done" << endl;
758 }
759 }
760 else if (Descr->f_rank_lines_in_PG) {
761
762
765 verbose_level);
766 }
767 else if (Descr->f_unrank_lines_in_PG) {
768
769
772 verbose_level);
773 }
775
776
779 Descr->line1_to, Descr->line2_to, verbose_level);
780 }
782
783
787 verbose_level);
788 }
789
790
791
792 if (f_v) {
793 cout << "projective_space_activity::perform_activity done" << endl;
794 }
795
796}
797
798
799
800
801
802
803}}}
804
void make_gilbert_varshamov_code(int n, int k, int d, int q, geometry::projective_space *P, int verbose_level)
void arc_lifting3(int arc_size, int arc_d, int arc_d_low, int arc_s, std::string arc_input_set, std::string arc_label, int arc_t, std::string t_lines_string, int arc_u, std::string u_lines_string, int verbose_level)
void arc_lifting2(int arc_size, int arc_d, int arc_d_low, int arc_s, std::string arc_input_set, std::string arc_label, int arc_t, std::string t_lines_string, int verbose_level)
void arc_lifting1(int arc_size, int arc_d, int arc_d_low, int arc_s, std::string arc_input_set, std::string arc_label, int verbose_level)
to create a geometric object from a description using class geometric_object_description
Definition: geometry.h:568
void init(geometric_object_description *Descr, projective_space *P, int verbose_level)
various functions related to geometries
Definition: geometry.h:721
void latex_homogeneous_equation(field_theory::finite_field *F, int degree, int nb_vars, std::string &equation_text, std::string &symbol_txt, std::string &symbol_tex, int verbose_level)
void do_move_two_lines_in_hyperplane_stabilizer_text(std::string line1_from_text, std::string line2_from_text, std::string line1_to_text, std::string line2_to_text, int verbose_level)
void polarity_rank_k_subspace(int k, long int rk_in, long int &rk_out, int verbose_level)
void do_move_two_lines_in_hyperplane_stabilizer(long int line1_from, long int line2_from, long int line1_to, long int line2_to, int verbose_level)
void create_lines_on_point_but_inside_a_plane(long int point_rk, long int plane_rk, long int *line_pencil, int verbose_level)
options for drawing an object of type layered_graph
Definition: graphics.h:457
void add_symbol_table_entry(std::string &label, orbiter_symbol_table_entry *Symb, int verbose_level)
void get_matrix_from_label(std::string &label, int *&v, int &m, int &n)
symbol table to store data entries for the orbiter run-time system
void init_classification_of_cubic_surfaces_with_double_sixes(std::string &label, void *p, int verbose_level)
void init_geometric_object(std::string &label, geometry::geometric_object_create *COC, int verbose_level)
void init_quartic_curve(std::string &label, void *p, int verbose_level)
void init_cubic_surface(std::string &label, void *p, int verbose_level)
void do_sweep_4_15_lines(projective_geometry::projective_space_with_action *PA, surface_create_description *Surface_Descr, std::string &sweep_fname, int verbose_level)
void do_sweep_F_beta_9_lines(projective_geometry::projective_space_with_action *PA, surface_create_description *Surface_Descr, std::string &sweep_fname, int verbose_level)
void classify_surfaces_with_double_sixes(projective_geometry::projective_space_with_action *PA, poset_classification::poset_classification_control *Control, cubic_surfaces_and_double_sixes::surface_classify_wedge *&SCW, int verbose_level)
void do_classify_surfaces_through_arcs_and_two_lines(projective_geometry::projective_space_with_action *PA, poset_classification::poset_classification_control *Control_six_arcs, int f_test_nb_Eckardt_points, int nb_E, int verbose_level)
void do_cubic_surface_properties_analyze(projective_geometry::projective_space_with_action *PA, std::string &fname_csv, int defining_q, int verbose_level)
void do_six_arcs(projective_geometry::projective_space_with_action *PA, poset_classification::poset_classification_control *Control_six_arcs, int f_filter_by_nb_Eckardt_points, int nb_Eckardt_points, int verbose_level)
void do_cubic_surface_properties(projective_geometry::projective_space_with_action *PA, std::string &fname_csv, int defining_q, int column_offset, int verbose_level)
void do_sweep_4_27(projective_geometry::projective_space_with_action *PA, surface_create_description *Surface_Descr, std::string &sweep_fname, int verbose_level)
void do_classify_surfaces_through_arcs_and_trihedral_pairs(projective_geometry::projective_space_with_action *PA, poset_classification::poset_classification_control *Control1, poset_classification::poset_classification_control *Control2, poset_classification::poset_classification_control *Control_six_arcs, int f_test_nb_Eckardt_points, int nb_E, int verbose_level)
void do_sweep_6_9_lines(projective_geometry::projective_space_with_action *PA, surface_create_description *Surface_Descr, std::string &sweep_fname, int verbose_level)
to create a cubic surface from a description using class surface_create_description
to create a quartic curve from a description using class quartic_curve_create_description
applications_in_algebraic_geometry::cubic_surfaces_in_general::surface_create_description * sweep_4_15_lines_surface_description
applications_in_algebraic_geometry::cubic_surfaces_in_general::surface_create_description * Surface_Descr
applications_in_algebraic_geometry::quartic_curves::quartic_curve_create_description * Quartic_curve_descr
applications_in_algebraic_geometry::cubic_surfaces_in_general::surface_create_description * sweep_F_beta_9_lines_surface_description
applications_in_algebraic_geometry::cubic_surfaces_in_general::surface_create_description * sweep_6_9_lines_surface_description
combinatorics::classification_of_objects_description * Canonical_form_codes_Descr
poset_classification::poset_classification_control * classify_surfaces_with_double_sixes_control
applications_in_algebraic_geometry::cubic_surfaces_in_general::surface_create_description * sweep_4_27_surface_description
void do_classify_cubic_curves(projective_space_with_action *PA, apps_geometry::arc_generator_description *Arc_generator_description, int verbose_level)
void analyze_del_Pezzo_surface(projective_space_with_action *PA, std::string &label, std::string &evaluate_text, int verbose_level)
void conic_type(projective_space_with_action *PA, int threshold, std::string &set_text, int verbose_level)
void do_lift_skew_hexagon_with_polarity(projective_space_with_action *PA, std::string &polarity_36, int verbose_level)
void map(projective_space_with_action *PA, std::string &label, std::string &evaluate_text, int verbose_level)
void set_stabilizer(projective_space_with_action *PA, int intermediate_subset_size, std::string &fname_mask, int nb, std::string &column_label, std::string &fname_out, int verbose_level)
void do_classify_arcs(projective_space_with_action *PA, apps_geometry::arc_generator_description *Arc_generator_description, int verbose_level)
void do_create_surface(projective_space_with_action *PA, applications_in_algebraic_geometry::cubic_surfaces_in_general::surface_create_description *Surface_Descr, applications_in_algebraic_geometry::cubic_surfaces_in_general::surface_with_action *&Surf_A, applications_in_algebraic_geometry::cubic_surfaces_in_general::surface_create *&SC, int verbose_level)
void do_lift_skew_hexagon(projective_space_with_action *PA, std::string &text, int verbose_level)
void classify_quartic_curves(projective_space_with_action *PA, std::string &fname_mask, int nb, int size, int degree, std::string &fname_classification, int verbose_level)
void classify_quartic_curves_nauty(projective_space_with_action *PA, std::string &fname_mask, int nb, std::string &fname_classification, canonical_form_classifier *&Classifier, int verbose_level)
void do_spread_classify(int k, poset_classification::poset_classification_control *Control, int verbose_level)
void do_cheat_sheet_for_decomposition_by_element_PG(int decomposition_by_element_power, std::string &decomposition_by_element_data, std::string &fname_base, int verbose_level)
void canonical_form_of_code(std::string &label, int *genma, int m, int n, combinatorics::classification_of_objects_description *Canonical_form_codes_Descr, int verbose_level)
void cheat_sheet(graphics::layered_graph_draw_options *O, int verbose_level)
void do_cheat_sheet_for_decomposition_by_subgroup(std::string &label, groups::linear_group_description *subgroup_Descr, int verbose_level)
void create_quartic_curve(applications_in_algebraic_geometry::quartic_curves::quartic_curve_create_description *Quartic_curve_descr, applications_in_algebraic_geometry::quartic_curves::quartic_curve_create *&QC, int verbose_level)
void init(semifield_classify_description *Descr, projective_geometry::projective_space_with_action *PA, poset_classification::poset_classification_control *Control, int verbose_level)
#define Lint_vec_scan(A, B, C)
Definition: foundations.h:717
#define NEW_OBJECT(type)
Definition: foundations.h:638
#define Lint_vec_print(A, B, C)
Definition: foundations.h:686
#define FREE_lint(p)
Definition: foundations.h:642
#define NEW_lint(n)
Definition: foundations.h:628
orbiter_kernel_system::orbiter_session * Orbiter
global Orbiter session
the orbiter library for the classification of combinatorial objects