Top
Back: semicontqh
Forward: spmul
FastBack: spcurve_lib
FastForward: Invariant theory
Up: spectrum_lib
Top: Singular Manual
Contents: Table of Contents
Index: Index
About: About this document

D.5.10.4 spadd

Procedure from library spectrum.lib (see spectrum_lib).

Usage:
spadd(s1,s2); list s1, s2

Return:
a list containing the sum of the two spectra s1 and s2

Example:
 
LIB "spectrum.lib";
ring r=0,(x,y),ds;
list s1=spectrumnd(x5+x2y2+y5);
s1;
==> [1]:
==>    11
==> [2]:
==>    6
==> [3]:
==>    7
==> [4]:
==>    1,7,9,1,11,13,3
==> [5]:
==>    2,10,10,1,10,10,2
==> [6]:
==>    1,2,2,1,2,2,1
list s2=spectrumnd(x2+y3);
s2;
==> [1]:
==>    2
==> [2]:
==>    1
==> [3]:
==>    2
==> [4]:
==>    5,7
==> [5]:
==>    6,6
==> [6]:
==>    1,1
spadd(s1,s2);
==> [1]:
==>    13
==> [2]:
==>    7
==> [3]:
==>    9
==> [4]:
==>    1,7,5,9,1,11,7,13,3
==> [5]:
==>    2,10,6,10,1,10,6,10,2
==> [6]:
==>    1,2,1,2,1,2,1,2,1


Top Back: semicontqh Forward: spmul FastBack: spcurve_lib FastForward: Invariant theory Up: spectrum_lib Top: Singular Manual Contents: Table of Contents Index: Index About: About this document
            User manual for Singular version 2-0-0, February 2001, generated by texi2html.