1*364Sceastha /*
2*364Sceastha * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
3*364Sceastha * Use is subject to license terms.
4*364Sceastha */
5*364Sceastha
60Sstevel@tonic-gate /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
70Sstevel@tonic-gate /* All Rights Reserved */
80Sstevel@tonic-gate
90Sstevel@tonic-gate /*
100Sstevel@tonic-gate * Copyright (c) 1980 Regents of the University of California.
110Sstevel@tonic-gate * All rights reserved. The Berkeley software License Agreement
120Sstevel@tonic-gate * specifies the terms and conditions for redistribution.
130Sstevel@tonic-gate */
14*364Sceastha
15*364Sceastha #pragma ident "%Z%%M% %I% %E% SMI"
160Sstevel@tonic-gate
17*364Sceastha #include "e.h"
18*364Sceastha #include "e.def"
190Sstevel@tonic-gate
20*364Sceastha void
integral(int p,int p1,int p2)21*364Sceastha integral(int p, int p1, int p2)
22*364Sceastha {
230Sstevel@tonic-gate #ifndef NEQN
240Sstevel@tonic-gate if (p1 != 0)
250Sstevel@tonic-gate printf(".ds %d \\h'-0.4m'\\v'0.4m'\\*(%d\\v'-0.4m'\n", p1, p1);
260Sstevel@tonic-gate if (p2 != 0)
270Sstevel@tonic-gate printf(".ds %d \\v'-0.3m'\\*(%d\\v'0.3m'\n", p2, p2);
280Sstevel@tonic-gate #endif
290Sstevel@tonic-gate if (p1 != 0 && p2 != 0)
300Sstevel@tonic-gate shift2(p, p1, p2);
310Sstevel@tonic-gate else if (p1 != 0)
320Sstevel@tonic-gate bshiftb(p, SUB, p1);
330Sstevel@tonic-gate else if (p2 != 0)
340Sstevel@tonic-gate bshiftb(p, SUP, p2);
35*364Sceastha if (dbg)
36*364Sceastha printf(".\tintegral: S%d; h=%d b=%d\n",
37*364Sceastha p, eht[p], ebase[p]);
380Sstevel@tonic-gate lfont[p] = ROM;
390Sstevel@tonic-gate }
400Sstevel@tonic-gate
41*364Sceastha void
setintegral(void)42*364Sceastha setintegral(void)
43*364Sceastha {
440Sstevel@tonic-gate char *f;
450Sstevel@tonic-gate
460Sstevel@tonic-gate yyval = oalloc();
470Sstevel@tonic-gate f = "\\(is";
480Sstevel@tonic-gate #ifndef NEQN
49*364Sceastha printf(".ds %d \\s%d\\v'.1m'\\s+4%s\\s-4\\v'-.1m'\\s%d\n",
50*364Sceastha yyval, ps, f, ps);
510Sstevel@tonic-gate eht[yyval] = VERT(EM(1.15, ps+4));
520Sstevel@tonic-gate ebase[yyval] = VERT(EM(0.3, ps));
53*364Sceastha #else /* NEQN */
540Sstevel@tonic-gate printf(".ds %d %s\n", yyval, f);
550Sstevel@tonic-gate eht[yyval] = VERT(2);
560Sstevel@tonic-gate ebase[yyval] = 0;
57*364Sceastha #endif /* NEQN */
580Sstevel@tonic-gate lfont[yyval] = rfont[yyval] = ROM;
590Sstevel@tonic-gate }
60