anchor.diff:           xmid, ymid, zmin, &
            x_inclination, y_inclination, z_inclination, &
            x_shear, y_shear, z_shear, &
  -         0.0, "  revolution")
  +         0.0_plflt, "  revolution")
      enddo
   
      ! x = xmax.
  -   call plschr(0., 1.0)
  +   call plschr(0._plflt, 1.0_plflt)
      do i = 1,NREVOLUTION
  -      omega = 2.*PI*((i-1)/(PLFLT)NREVOLUTION)
  +      omega = 2.*PI*((i-1)/dble(NREVOLUTION))
         sin_omega = sin(omega)
         cos_omega = cos(omega)
         x_inclination = 0.
  
positive.code:    ! would be domega = 0.)
     domega = 0.05
     call pladv(0)
     call plvpor(-0.15, 1.15, -0.05, 1.05)
     call plwind(-1.2, 1.2, -0.8, 1.5)
     call plw3d(1.0, 1.0, 1.0, xmin, xmax, ymin, ymax, zmin, zmax, 20., 45.)
  
     call plcol0(2)
     call plbox3("b",   "", xmax-xmin, 0, &
  
negative.code:                "bcd", "", zmax-zmin, 0)
  
     ! y = ymax.
     call plschr(0.0_plflt, 1.0_plflt)
     x_inclination = 1.
     y_inclination = 0.
     z_inclination = 0.
     y_shear = 0.
     do i = 1,NSHEAR
        omega = domega + 2.*PI*((i-1)/dble(NSHEAR))
        sin_omega = sin(omega)
        cos_omega = cos(omega)
        x_shear = 0.5*xrange*sin_omega
        z_shear = 0.5*zrange*cos_omega
        call plptex3( &
           xmid, ymax, zmax -(zmax-0.2)*(dble(i)/dble(NSHEAR-1)), &
           x_inclination, y_inclination, z_inclination, &
           x_shear, y_shear, z_shear, &
           0.5_plflt, "shear for y = y#dmax#u")
     enddo
  
     ! x = xmax.
     call plschr(0.0_plflt, 1.0_plflt)
     x_inclination = 0.
     y_inclination = -1.
     z_inclination = 0.
     x_shear = 0.
     do i = 1,NSHEAR
        omega = domega + 2.*PI*((i-1)/dble(NSHEAR))
        sin_omega = sin(omega)
        cos_omega = cos(omega)
        y_shear = -0.5*yrange*sin_omega
        z_shear = 0.5*zrange*cos_omega
        call plptex3( &
           xmax, ymid, zmax -(zmax-0.2)*((i-1)/dble(NSHEAR-1)), &
           x_inclination, y_inclination, z_inclination, &
           x_shear, y_shear, z_shear, &
           0.5_plflt, "shear for x = x#dmax#u")
     enddo
  
     ! z = zmin.
     call plschr(0.0_plflt, 1.0_plflt)
     x_inclination = 1.
     y_inclination = 0.
     z_inclination = 0.
     z_shear = 0.
     do i = 1,NSHEAR
        omega = domega + 2.*PI*((i-1)/dble(NSHEAR))
        sin_omega = sin(omega)
        cos_omega = cos(omega)
        y_shear = 0.5*yrange*cos_omega
        x_shear = 0.5*xrange*sin_omega
        call plptex3( &
           xmid, ymax -(ymax-0.2)*(dble(i)/dble(NSHEAR-1)), zmin, &
           x_inclination, y_inclination, z_inclination, &
           x_shear, y_shear, z_shear, &
           0.5_plflt, "shear for z = z#dmin#u")
     enddo
     ! Draw minimal 3D grid to finish defining the 3D box.
     call plmesh(x, y, z, DRAW_LINEXY)
  
     ! Page 4: Demonstrate drawing a string on a 3D path.
     call pladv(0)
     call plvpor(-0.15_plflt, 1.15_plflt, -0.05_plflt, 1.05_plflt)
     call plwind(-1.2_plflt, 1.2_plflt, -0.8_plflt, 1.5_plflt)
     call plw3d(1.0_plflt, 1.0_plflt, 1.0_plflt, xmin, xmax, ymin, ymax, zmin, zmax, 40._plflt, -30._plflt)
  
     call plcol0(2)
     call plbox3("b",   "", xmax-xmin, 0, &
                 "b",   "", ymax-ymin, 0, &
                 "bcd", "", zmax-zmin, 0)
  
     call plschr(0.0_plflt, 1.2_plflt)
     ! domega controls the spacing between the various characters of the
     ! string and also the maximum value of omega for the given number
     ! of characters in pstring.
  