source: git/kernel/fglmvec.h @ fbc7cb

jengelh-datetimespielwiese
Last change on this file since fbc7cb was bc2606, checked in by Oleksandr Motsak <motsak@…>, 10 years ago
Compiler warnings elimination
  • Property mode set to 100644
File size: 1.8 KB
Line 
1// emacs edit mode for this file is -*- C++ -*-
2
3/****************************************
4*  Computer Algebra System SINGULAR     *
5****************************************/
6/*
7* ABSTRACT - The FGLM-Algorithm
8*   header file for fglmvec.cc. See fglmvec.cc for details.
9*/
10
11#ifndef FGLMVEC_H
12#define FGLMVEC_H
13
14#include <coeffs/numbers.h>
15
16class fglmVectorRep;
17
18class fglmVector
19{
20protected:
21    fglmVectorRep * rep;
22    void makeUnique();
23    fglmVector( fglmVectorRep * rep );
24public:
25    fglmVector();
26    fglmVector( int size );
27    fglmVector( int size, int basis );
28    fglmVector( const fglmVector & v );
29    ~fglmVector();
30#ifndef HAVE_EXPLICIT_CONSTR
31    void mac_constr( const fglmVector & v);
32    void mac_constr_i( int size);
33    void clearelems();
34#endif
35    int size() const;
36    int numNonZeroElems() const;
37
38    void nihilate( const number fac1, const number fac2, const fglmVector v );
39    fglmVector & operator = ( const fglmVector & v );
40
41    int operator == ( const fglmVector & );
42    int operator != ( const fglmVector & );
43    int isZero();
44    int elemIsZero( int i );
45
46    fglmVector & operator += ( const fglmVector & );
47    fglmVector & operator -= ( const fglmVector & );
48    fglmVector & operator *= ( const number & );
49    fglmVector & operator /= ( const number & );
50    friend fglmVector operator - ( const fglmVector & v );
51    friend fglmVector operator + ( const fglmVector & lhs, const fglmVector & rhs );
52    friend fglmVector operator - ( const fglmVector & lhs, const fglmVector & rhs );
53    friend fglmVector operator * ( const fglmVector & v, const number n );
54    friend fglmVector operator * ( const number n, const fglmVector & v );
55
56    number getconstelem( int i ) const;
57    number & getelem( int i );
58    void setelem( int i, number & n );
59
60    number gcd() const;
61    number clearDenom();
62};
63
64#endif
Note: See TracBrowser for help on using the repository browser.