1 /* zzlogy.f -- translated by f2c (version 19961017).
2 You must link the resulting object file with the libraries:
3 -lf2c -lm (in that order)
4 */
5
6 #include "f2c.h"
7
8
9
10
zzlogy_(real * x,real * y1,real * y2,integer * ndec,real * tmaj,real * tmin)11 /* Subroutine */ int zzlogy_(real *x, real *y1, real *y2, integer *ndec, real
12 *tmaj, real *tmin)
13 {
14 /* Initialized data */
15
16 static real tmlog[8] = { .30103f,.47712f,.60206f,.69897f,.77815f,.84509f,
17 .90309f,.95424f };
18
19 /* System generated locals */
20 integer i__1;
21
22 /* Local variables */
23 static integer idec, imin;
24 static real dymaj, xmajr, ymajr, xminr, yy;
25 extern /* Subroutine */ int zzline_(real *, real *, real *, real *);
26
27
28 /* Draw a log axis from (X,Y1) to (X,Y2) [physical coordinates], */
29 /* with NDEC decades and the major and minor tic mark lengths in */
30 /* TMAJ and TMIN, respectively. */
31
32 /* This array is LOG10 of 2,3,...,9; it is used to space the */
33 /* minor divisions. */
34
35 /* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
36 */
37 zzline_(x, y1, x, y2);
38 if (*tmaj == 0.f || *tmin == 0.f) {
39 goto L8000;
40 }
41 xmajr = *x + *tmaj;
42 xminr = *x + *tmin;
43 dymaj = (*y2 - *y1) / *ndec;
44 ymajr = *y1;
45 zzline_(x, &ymajr, &xmajr, &ymajr);
46
47 i__1 = *ndec;
48 for (idec = 1; idec <= i__1; ++idec) {
49 if (*tmin != 0.f) {
50 for (imin = 1; imin <= 8; ++imin) {
51 yy = ymajr + tmlog[imin - 1] * dymaj;
52 zzline_(x, &yy, &xminr, &yy);
53 /* L100: */
54 }
55 }
56 ymajr += dymaj;
57 zzline_(x, &ymajr, &xmajr, &ymajr);
58 /* L200: */
59 }
60
61 L8000:
62 return 0;
63 } /* zzlogy_ */
64
65