fieker-DuValspielwiese
Last change
on this file since 405ebc was
4a81ec,
checked in by Hans Schönemann <hannes@…>, 27 years ago
|
* hannes/michael: libfac-0.3.0
git-svn-id: file:///usr/local/Singular/svn/trunk@708 2c84dea3-7e68-4137-9b89-c4e89433aadc
|
-
Property mode set to
100644
|
File size:
1.1 KB
|
Line | |
---|
1 | /* Copyright 1997 Michael Messollen. All rights reserved. */ |
---|
2 | //////////////////////////////////////////////////////////// |
---|
3 | // emacs edit mode for this file is -*- C++ -*- |
---|
4 | // static char * rcsid = "@(#) $Id: class.cc,v 1.3 1997-09-12 07:19:53 Singular Exp $"; |
---|
5 | //////////////////////////////////////////////////////////// |
---|
6 | |
---|
7 | // #pragma implementation |
---|
8 | |
---|
9 | #include "class.h" |
---|
10 | |
---|
11 | template <class T> |
---|
12 | Substitution<T>& Substitution<T>::operator= ( const Substitution<T>& f ) |
---|
13 | { |
---|
14 | if ( this != &f ) { |
---|
15 | _factor = f._factor; |
---|
16 | _exp = f._exp; |
---|
17 | } |
---|
18 | return *this; |
---|
19 | } |
---|
20 | |
---|
21 | template <class T> |
---|
22 | Substitution<T>& Substitution<T>::operator= ( const T & f ) |
---|
23 | { |
---|
24 | _factor = f; |
---|
25 | _exp = 1; |
---|
26 | return *this; |
---|
27 | } |
---|
28 | |
---|
29 | template <class T> |
---|
30 | int operator== ( const Substitution<T> &f1, const Substitution<T> &f2 ) |
---|
31 | { |
---|
32 | return (f1.exp() == f2.exp()) && (f1.factor() == f2.factor()); |
---|
33 | } |
---|
34 | |
---|
35 | #ifndef NOSTREAMIO |
---|
36 | template <class T> |
---|
37 | void Substitution<T>::print ( ostream& s ) const |
---|
38 | { |
---|
39 | s << "(" << factor() << ")^" << exp(); |
---|
40 | } |
---|
41 | #endif |
---|
42 | |
---|
43 | //////////////////////////////////////////////////////////// |
---|
44 | /* |
---|
45 | $Log: not supported by cvs2svn $ |
---|
46 | Revision 1.3 1997/04/25 22:38:04 michael |
---|
47 | Version for libfac-0.2.1 |
---|
48 | |
---|
49 | */ |
---|
Note: See
TracBrowser
for help on using the repository browser.