SUBROUTINE LAXES(X0,Y0,ANGLE,VMIN,VMAX,LENGTH,NFORM, 1 TITLE,NCHRS,SIZE,JUST) C C This subroutine will draw and annotate a logarithmic C axes as described by the input variables. C C X0,Y0 Location of the "origin" in scale inches relative C to the relocatable origin. C ANGLE Angle in degrees of the axis with respect to a C rightward going horizontal, positive angle being C in the counterclockwise direction. C VMIN Value at the "origin", rounded downwards to the C next lowest whole minor division. C VMAX Value at the end of the axis, rounded upwards to C the next higher minor division. C LENGTH Length of the axis in scale inches. Note: LENGTH C is assumed to be declared REAL. C NFORM Format of the annotation. C NFORM = 1 Suffix. C 2 Decimal. C 3 Exponential. C TITLE Character string containing the title. C NCHRS In absolute value, the number of characters in the C title. If positive, the annotation is to the C left of the axis (typical Y); if negative, to the C right (typical X). C SIZE Character size in scale inches for annotation. The C title will be 1.5*SIZE. C JUST Optional character specifying the justification C of the lines in the TITLE; Default: 'C'. C C Notes: Assuming an X axis to be at either 0 or 180 degrees and a C Y axis to be at +/-90 degrees, this subroutine will also set the C appropriate variables in COMMON /PSTN/ to allow calls to either C SUBROUTINE PSTN or SUBROUTINE NTSP. These two subroutines provide C an easy method of scaling and unscaling data. C COMMON /PLTR/ ILun, IDev, IsTerm, IMode, IXMax, IYMax, 1 Cnvrsn, CMag, CnvMag, IX0, IY0, KSetNo, IFancy, IBfDv3, 1 CSize, DeltaH, DeltaV, Upsiln, CosUp, SinUp, WidAdj COMMON /PSTN/ XZero, XScale, LogX, 1 YZero, YScale, LogY, YMin COMMON /AXESC/ CS, SN, SGN, TX, TY, DX, DY, 1 MIN, MIDL, MAX, MIDU, UMAX, WMAX, IFORM, JUSTFY REAL LENGTH LOGICAL LogX, LogY C C - IF NO PLOTTING IS TO BE DONE, RETURN. IF( ILun .EQ. 0 ) RETURN NARG = 0 CALL NUMARG( NARG ) IF( ( NARG .EQ. 10 ) .OR. ( NARG .EQ. 11 ) ) GO TO 100 CALL OTSERR( 80 ) STOP C C - SAVE THE PRESENT PLOTTER STATUS. 100 CSAVE = CSize USAVE = Upsiln IX0S = IX0 IY0S = IY0 C C - CALCULATE THE JUSTIFICATION OF THE TITLE LINES. JUSTFY = 2 IF( NARG .EQ. 12 ) GO TO 200 CALL ITWAS( JUST, 'LCR', 3, JUSTFY ) IF( JUSTFY .EQ. 4 ) JUSTFY = 2 C C - SET NEW RELOCATABLE ORIGIN AND CHARACTER SET. 200 CALL CLRALL CALL CALPLT(X0,Y0,-3) CALL SIZEUP( ABS(SIZE), 0. ) C C - DRAW THE AXIS. CALL LAXES1(ANGLE,VMIN,VMAX,LENGTH,NFORM,NCHRS) IF( SIZE .LE. 0 ) GO TO 300 C C - ANNOTATE THE AXIS. CALL LAXES2 C C - LABEL THE AXIS AND FILL COMMON /PSTN/. CALL LAXES3(X0,Y0,ANGLE,LENGTH,TITLE,NCHRS,SIZE) C C - RETURN THE PLOTTER TO FORMER STATUS. 300 CALL SIZEUP(CSAVE,USAVE) CALL CLRALL IX0 = IX0S IY0 = IY0S C RETURN END