atlas  0.6
kgb.h
Go to the documentation of this file.
1 
6 /*
7  This is kgb.h
8 
9  Copyright (C) 2004,2005 Fokko du Cloux
10  Copyright (C) 2006-2013 Marc van Leeuwen
11  part of the Atlas of Lie Groups and Representations
12 
13  For license information see the LICENSE file
14 */
15 
16 #ifndef KGB_H /* guard against multiple inclusions */
17 #define KGB_H
18 
19 #include "../Atlas.h"
20 
21 #include "gradings.h" // containment in |KGBEltInfo|
22 #include "hashtable.h" // containment in |KGB_base|
23 #include "innerclass.h" // access to involution table
24 #include "weyl.h" // |weyl::TI_Entry::Pooltype|
25 #include "tits.h" // containment |GlobalTitsGroup|
26 #include "y_values.h" // containment |TorusElement|
27 
28 #include <algorithm>
29 #include <iostream> // for virtual print method
30 
31 namespace atlas {
32 
33 namespace kgb {
34 
35 
36 /******** type definitions **************************************************/
37 
38 
39 /*
40  The following base class follows a somewhat particular design: it is not an
41  abstract base class in the sense that it has no purely virtual methods (in
42  the original design there were no virtual methods, but a few have been
43  added since for printing purposes), yet it is not intended to have any
44  independent instances. The point is that the base class provides all
45  methods needed for basic \emph{use}, in for instance the block
46  construction, but it does not provide sufficient methods for constructing
47  the KGB set. Indeed the basic constructor is made |protected| to emphasise
48  that it is up to derived classes to actually fill the tables in the
49  structure, using concrete representations for the KGB elements (possibly
50  using |TitsElt|) that are mainly relevant during construction. Once
51  constructed there is no need to slice off the base object (although it
52  could be done) and the full derived object can be used for instance to
53  print more information about block elements than available in |KGB_base|.
54  */
55 class KGB_base
56 {
57  protected: // available during construction from derived classes
58  typedef unsigned int inv_index; // internal sequence number of involutions
59 
60  const InnerClass& ic; // hold a reference for convenience
61 
62  // per KGB element information
63  struct EltInfo
64  {
65  gradings::Status status; // status of each simple root for this element
66  DescentSet desc; // which simple reflections are complex descent or real
67  KGBElt dual; // number of Hermitian dual of this element
68 
69  EltInfo() : status(), desc(), dual(UndefKGB) {}
70 
71  }; // |struct EltInfo|
72 
73  struct KGBfields // per KGB element and simple reflection data
74  {
75  KGBElt cross_image; // cross action image
78 
80  : cross_image(UndefKGB)
81  , Cayley_image(UndefKGB)
82  , inverse_Cayley_image(std::make_pair(UndefKGB,UndefKGB)) {}
83  }; // | KGBfields|
84 
85  std::vector<std::vector<KGBfields> > data; // first index: simple reflection
86  std::vector<EltInfo> info; // per element information
87 
88  // tables defining local (generation) ordering of involutions
89  std::vector<InvolutionNbr> inv_nrs; // |inv_index| means index into |inv_nrs|
90  std::vector<inv_index> inv_loc; // parital inverse, indexed |InvolutionNbr|
91 
93  std::vector<KGBElt> first_of_tau; // size: |numInvolutions()+1|
94 
95 
96 
97  protected: // constructor is only meant for use from derived classes
98  explicit KGB_base(const InnerClass& GC, unsigned int ss_rank)
99  : ic(GC)
100  , data(ss_rank)
101  , info()
102  , inv_nrs(), inv_loc()
103  , first_of_tau()
104  {}
105 
106 
107  public:
108  KGB_base (const KGB_base& org) // copy contructor
109  : ic(org.ic) // share
110  , data(org.data)
111  , info(org.info)
112  , inv_nrs(org.inv_nrs), inv_loc(org.inv_loc)
113  , first_of_tau(org.first_of_tau)
114  {}
115 
116  virtual ~KGB_base(){} // maybe overly cautious; no |KGB_base*| is intended
117 // accessors
118 
119  size_t rank() const { return data.size(); } // number of simple reflections
120  size_t size() const { return info.size(); } // number of KGB elements
121  inv_index nr_involutions() const { return inv_nrs.size(); }
122 
123  const InnerClass& innerClass() const { return ic; }
124  const RootDatum& rootDatum() const;
125  const WeylGroup& weylGroup() const;
126  const TwistedWeylGroup& twistedWeylGroup() const;
127 
129  { return data[s][x].cross_image; }
131  { return data[s][x].Cayley_image; }
133  { return data[s][x].inverse_Cayley_image; }
135  { return isDescent(s,x) ? inverseCayley(s,x).first : cayley(s,x); }
136 
137  KGBElt cross(const WeylWord& ww, KGBElt x) const;
138  KGBElt cross(KGBElt x, const WeylWord& ww) const;
139 
140  unsigned int length(KGBElt x) const
141  { return ic.involution_table().length(inv_nr(x));}
142 
143  KGBElt Hermitian_dual(KGBElt x) const { return info[x].dual; }
144 
145  // a method useful mostly for traversing all our involutions
146  const TwistedInvolution& nth_involution(inv_index n) const
147  { return ic.involution_table().involution(inv_nrs[n]); }
148 
149  const TwistedInvolution& involution(KGBElt x) const // after construction only
150  { return nth_involution(involution_index(x)); } // the one associated to |x|
151 
153  { return ic.involution_table().matrix(inv_nr(x)); }
154 
155  InvolutionNbr inv_nr(KGBElt x) const; // external number (within inner class)
156 
157  const DescentSet& descent(KGBElt x) const { return info[x].desc; }
159  { return descent(x).test(s); }
160  const gradings::Status& status(KGBElt x) const { return info[x].status; }
162  { return status(x)[s]; }
163 
165  { return status(x).isComplex(s) and isDescent(s,x); }
166 
168  { return inverseCayley(s,x).second!=UndefKGB; }
169 
170  bool isAscent(weyl::Generator s, KGBElt x) const // not true for imag cpct!
171  { return not isDescent(s,x)
172  and not (status(s,x) == gradings::Status::ImaginaryCompact);
173  }
174 
175  size_t weylLength(KGBElt x) const // needed in sorting, in case |length| ties
176  { return weylGroup().length(involution(x).w()); }
177 
180  return KGBEltPair(first_of_tau[i],first_of_tau[i+1]);
181  }
182 
183  // range of KGB elements with given twisted involution, needed for block
184  KGBEltPair tauPacket(const TwistedInvolution&) const;
185  size_t packet_size(const TwistedInvolution&) const;
186 
187 // virtual methods
188  virtual CartanNbr Cartan_class(KGBElt x) const; // default, uses |G| tables
189  // print derived-class specific per-element information
190  virtual std::ostream& print(std::ostream& strm, KGBElt x) const
191  { return strm; }
192 
193  private: // this internal index of involution is only usable by methods above
194 
195  // find involution index |i| such that |inv_nrs[i]| is involution of |x|
197  // look up index first element if |first_of_tau| greater than |x|; then -1
198  { return std::upper_bound(first_of_tau.begin(),first_of_tau.end(),x)
199  -first_of_tau.begin() -1;
200  } // returns |i| where |first_of_tau(i)<=x| and this fails for |i+1|;
201 
202  protected:
203  void reserve (size_t n); // prepare for generating |n| elements
204  void add_element(); // create entry in |data| and |info|
205 
206 
207 }; // |class KGB_base|
208 
209 
210 
211 
212 // |global_KGB| and subsidiary types
213 
214 
215 
216 // a |GlobalTitsElement| can be hashed as (fingerprint,twisted_inv) pair
218 {
219  TorusElement t_rep; // a representative, ignored in test
221  RatWeight fingerprint; // characterizes the torus element, modulo equivalence
222 
223  // obligatory fields for hashable entry
224  typedef std::vector<KGB_elt_entry> Pooltype;
225  size_t hashCode(size_t modulus) const; // hash function
226  bool operator !=(const KGB_elt_entry& x) const; // ignores repr
227 
228  KGB_elt_entry (const RatWeight& f,
229  const GlobalTitsElement& y);
230  GlobalTitsElement repr() const;
231  RatWeight label () const { return fingerprint; }
232 
233 }; // |struct KGB_elt_entry|
234 
235 class global_KGB : public KGB_base
236 {
237  const GlobalTitsGroup Tg;
238  std::vector<GlobalTitsElement> elt;
239 
240  global_KGB(const global_KGB& org); // forbid copying
241 
242  public:
243  global_KGB(InnerClass& G, bool dual_twist=false);
244 
245  global_KGB(InnerClass& G,
246  const GlobalTitsElement& x,
247  bool dual_twist=false); // generate KGB containing |x|
248 
249 // accessors
250  const GlobalTitsGroup& globalTitsGroup() const { return Tg; }
251 
252  TorusElement torus_part(KGBElt x) const
253  { return elt[x].torus_part(); }
254  const GlobalTitsElement& element(KGBElt x) const { return elt[x]; }
255 
256  bool compact(RootNbr alpha, const GlobalTitsElement& a) const;
257  KGBElt lookup(const GlobalTitsElement& x) const;
258 
259 // virtual methods
260  virtual std::ostream& print(std::ostream& strm, KGBElt x) const;
261 
262  private:
263  void generate_involutions(size_t n);
264  void generate(size_t predicted_size, bool dual_twist);
265 
266 }; // |class global_KGB|
267 
268 
269 
270 // Fokko's |class KGB|
271 
272 
273 /*
274  A KGB object represents the orbits of K on G/B for a particular real form,
275  in the form of a graph structure (cross actions an Cayley transforms), plus
276  some additional data that permit interpreting its elements in the context.
277 
278  This class adds some information with respect to that kept in |KGB_base|,
279  and most importantly carries out the actual filling of the |KGB_base| base
280  object (the graph structure). As additional data that are held in this
281  derived class there is the |TitsCoset| used during construction (really an
282  attribute of the square class of the real form), and the torus parts
283  (relative to the base point) that distinguish K\G/B elements in the same
284  fiber. This class also provides the possibility to generate and store the
285  Bruhat order on the set.
286 */
287 
288 class KGB : public KGB_base
289 {
290 
291  enum State { BruhatConstructed, NumStates };
292 
293  const RealReductiveGroup& G; // to access base grading vector |g_rho_check|
294 
295  std::vector<inv_index> Cartan;
296 
297  std::vector<TorusPart> left_torus_part; // of size |size()|
298  BitSet<NumStates> d_state;
299 
305  BruhatOrder* d_bruhat;
306 
308  TitsCoset* d_base; // pointer, because constructed late by constructor
309 
310  public:
311 
312 // constructors and destructors
313  explicit KGB(RealReductiveGroup& GR,
314  const BitMap& Cartan_classes, bool dual_twist=false);
315 
316  ~KGB(); // { delete d_bruhat; delete d_base; } // these are owned (or NULL)
317 
318 // copy, assignment and swap
319 // these are currently reserved; if defined, they shoud take care of |d_bruhat|
320  private:
321  KGB(const KGB&);
322  KGB& operator=(const KGB&);
323  public:
324 
325 // accessors
326 
328  const TitsCoset& basedTitsGroup() const { return *d_base; }
330  const TitsGroup& titsGroup() const { return d_base->titsGroup(); }
331 
332  TorusPart torus_part(KGBElt x) const { return left_torus_part[x]; }
333  // reconstruct from |torus_part| a |TorusElement| as in |global_KGB|
334  RatCoweight base_grading_vector() const; // offset for |torus_part_global|
335  RatCoweight torus_factor(KGBElt x) const; // will be $\theta^t$-fixed
336 
337  TitsElt titsElt(KGBElt x) const; // get KGB element |x| as a |TitsElt|
338  size_t torus_rank() const; // the (non-semisimple) rank of torus parts.
339 
340  Grading base_grading() const { return d_base->base_grading(); }
341 
342  // as the name suggests, the following assumes |alpha| simple-imaginary
344  { return d_base->simple_imaginary_grading(torus_part(x),alpha); }
345 
346  KGBElt lookup(TitsElt a) const; // by value
347 
348 
349 // manipulators
350 
351 // Creates Hasse diagram for Bruhat order on KGB and returns reference to it
352  BruhatOrder& bruhatOrder() { fillBruhat(); return *d_bruhat; }
353 
354  const poset::Poset& bruhatPoset(); // this creates full poset on demand
355 
356 // virtual method
357  virtual std::ostream& print(std::ostream& strm, KGBElt x) const;
358 
359 // private methods
360 private:
361  bool is_dual_twist_stable(const RealReductiveGroup& GR, TorusPart& shift)
362  const; // auxiliary to see if this dual KGB can be twist-stable
363 
364  void fillBruhat();
365 
366 }; // |class KGB|
367 
368 /* ****************** function definitions **************************** */
369 
370 // general cross action in root $\alpha$
371 KGBElt cross(const KGB_base& kgb, KGBElt x, RootNbr alpha);
372 
373 // general (inverse) Cayley transform in root $\alpha$ (nci or real)
374 KGBElt any_Cayley (const KGB_base& kgb, KGBElt x, RootNbr alpha);
375 
377 
378 } // |namespace kgb|
379 
380 } // |namespace atlas|
381 
382 
383 #endif
unsigned int InvolutionNbr
Definition: Atlas.h:281
Class definitions and function declarations for the class Status.
WeylElt TwistedInvolution
Definition: Atlas.h:231
virtual std::ostream & print(std::ostream &strm, KGBElt x) const
Definition: kgb.h:190
TorusElement torus_part(KGBElt x) const
Definition: kgb.h:252
const GlobalTitsGroup & globalTitsGroup() const
Definition: kgb.h:250
DescentSet desc
Definition: kgb.h:66
RatWeight label() const
Definition: kgb.h:231
bool operator!=(const type_expr &x, const type_expr &y)
Definition: axis-types.h:374
unsigned int inv_index
Definition: kgb.h:58
KGB_base(const InnerClass &GC, unsigned int ss_rank)
Definition: kgb.h:98
bool isComplex(size_t j) const
Definition: gradings.h:76
KGBElt Hermitian_dual(KGBElt x) const
Definition: kgb.h:143
std::vector< inv_index > Cartan
records Cartan classes of involutions
Definition: kgb.h:295
KGBElt dual
Definition: kgb.h:67
RankFlags DescentSet
Definition: Atlas.h:331
#define shift()
Definition: cweave.c:116
KGB_base(const KGB_base &org)
Definition: kgb.h:108
KGBEltPair inverse_Cayley_image
Definition: kgb.h:77
bool simple_imaginary_grading(KGBElt x, RootNbr alpha) const
Definition: kgb.h:343
std::vector< KGBElt > first_of_tau
to help find range of elements with fixed twisted involution
Definition: kgb.h:93
const TwistedInvolution & nth_involution(inv_index n) const
Definition: kgb.h:146
const gradings::Status & status(KGBElt x) const
Definition: kgb.h:160
bool isComplexDescent(weyl::Generator s, KGBElt x) const
Definition: kgb.h:164
const GlobalTitsElement & element(KGBElt x) const
Definition: kgb.h:254
size_t size() const
Definition: kgb.h:120
Grading base_grading() const
Definition: kgb.h:340
const TwistedWeylGroup & twistedWeylGroup() const
Definition: kgb.cpp:102
const TitsCoset & basedTitsGroup() const
The based Tits group.
Definition: kgb.h:328
Definition: kgb.h:235
std::vector< inv_index > inv_loc
Definition: kgb.h:90
const RootDatum & rootDatum() const
Definition: kgb.cpp:100
State
Definition: kgb.h:291
virtual ~KGB_base()
Definition: kgb.h:116
std::vector< KGB_elt_entry > Pooltype
Definition: kgb.h:224
inv_index nr_involutions() const
Definition: kgb.h:121
Definition: kgb.h:217
const RealReductiveGroup & G
Definition: kgb.h:293
Definition: kgb.h:63
KGBElt Cayley_image
Definition: kgb.h:76
TitsCoset * d_base
Owned pointer to the based Tits group.
Definition: kgb.h:308
gradings::Status status
Definition: kgb.h:65
BruhatOrder * d_bruhat
Owned pointer to the Bruhat order on KGB (or NULL).
Definition: kgb.h:305
KGBEltPair tauPacket(const TwistedInvolution &) const
Definition: kgb.cpp:119
Class definitions and function declarations for WeylGroup.
EltInfo()
Definition: kgb.h:69
KGBElt cayley(weyl::Generator s, KGBElt x) const
Definition: kgb.h:130
const DescentSet & descent(KGBElt x) const
Definition: kgb.h:157
RatWeight fingerprint
Definition: kgb.h:221
BruhatOrder & bruhatOrder()
Definition: kgb.h:352
std::pair< KGBElt, KGBElt > KGBEltPair
Definition: Atlas.h:342
BitSet< NumStates > d_state
Definition: kgb.h:298
void reserve(size_t n)
Definition: kgb.cpp:160
const InnerClass & ic
Definition: kgb.h:60
std::vector< GlobalTitsElement > elt
Definition: kgb.h:238
std::vector< InvolutionNbr > inv_nrs
Definition: kgb.h:89
KGBfields()
Definition: kgb.h:79
KGBElt cross(weyl::Generator s, KGBElt x) const
Definition: kgb.h:128
Definition: kgb.h:288
KGBElt cross_image
Definition: kgb.h:75
size_t weylLength(KGBElt x) const
Definition: kgb.h:175
unsigned int KGBElt
Definition: Atlas.h:339
Definition: gradings.h:53
const TwistedInvolution & involution(KGBElt x) const
Definition: kgb.h:149
Definition: weyl.h:780
KGBEltPair packet(KGBElt x) const
Definition: kgb.h:178
gradings::Status::Value status(weyl::Generator s, KGBElt x) const
Definition: kgb.h:161
std::vector< std::vector< KGBfields > > data
Definition: kgb.h:85
const InnerClass & innerClass() const
Definition: kgb.h:123
virtual CartanNbr Cartan_class(KGBElt x) const
Definition: kgb.cpp:147
Represents a poset by the matrix of order relations.
Definition: poset.h:39
std::vector< TorusPart > left_torus_part
Definition: kgb.h:297
unsigned short CartanNbr
Definition: Atlas.h:301
void add_element()
Definition: kgb.cpp:168
KGBElt any_Cayley(weyl::Generator s, KGBElt x) const
Definition: kgb.h:134
std::vector< EltInfo > info
Definition: kgb.h:86
size_t packet_size(const TwistedInvolution &) const
Definition: kgb.cpp:130
Value
Definition: gradings.h:59
weyl::TI_Entry tw
Definition: kgb.h:220
const GlobalTitsGroup Tg
Definition: kgb.h:237
InvolutionNbr inv_nr(KGBElt x) const
Definition: kgb.cpp:141
unsigned int length(KGBElt x) const
Definition: kgb.h:140
KGBEltPair inverseCayley(weyl::Generator s, KGBElt x) const
Definition: kgb.h:132
unsigned long n
Definition: axis.cpp:77
bool isAscent(weyl::Generator s, KGBElt x) const
Definition: kgb.h:170
bool isDoubleCayleyImage(weyl::Generator s, KGBElt x) const
Definition: kgb.h:167
Definition: Atlas.h:38
const TitsGroup & titsGroup() const
The Tits group.
Definition: kgb.h:330
InvolutionNbr involution_index(KGBElt x) const
Definition: kgb.h:196
TorusElement t_rep
Definition: kgb.h:219
unsigned short RootNbr
Definition: Atlas.h:216
SmallBitVector TorusPart
Definition: Atlas.h:256
bool isDescent(weyl::Generator s, KGBElt x) const
Definition: kgb.h:158
unsigned char Generator
Definition: Atlas.h:226
Definition: common.h:36
RankFlags Grading
Definition: Atlas.h:289
const WeylGroup & weylGroup() const
Definition: kgb.cpp:101
const WeightInvolution & involution_matrix(KGBElt x) const
Definition: kgb.h:152
size_t rank() const
Definition: kgb.h:119
TorusPart torus_part(KGBElt x) const
Definition: kgb.h:332
Definition: kgb.h:55