docs: def bend_miter(angle, Di=None, Re=None, roughness=0.0, L_unimpeded=None,
                 method='Rennels'):
      r'''Returns loss coefficient for any single-joint miter bend in a pipe
      of angle `angle`, diameter `Di`, Reynolds number `Re`, roughness
      `roughness` unimpeded downstream length `L_unimpeded`, and using the 
      specified method. This calculation has four methods available.
      The 'Rennels' method is based on a formula and extends to angles up to 
      150 degrees. The 'Crane' method extends only to 90 degrees; the 'Miller'
      and 'Blevins' methods extend to 120 degrees.
      
      The Rennels [1]_ formula is:
          
      .. math::
          K = 0.42\sin(\alpha/2) + 2.56\sin^3(\alpha/2)
  
      The 'Crane', 'Miller', and 'Blevins' methods are all in part graph or 
      tabular based and do not have straightforward formulas.
  
      .. figure:: fittings/bend_miter.png
         :scale: 25 %
         :alt: Miter bend, one joint only; after [1]_
  
      Parameters
      ----------
      angle : float
          Angle of bend, [degrees]
      Di : float, optional
          Inside diameter of pipe, [m]
      Re : float, optional
          Reynolds number of the pipe (no specification if inlet or outlet
          properties should be used), [m]
      roughness : float, optional
          Roughness of bend wall, [m]   
      L_unimpeded : float, optional
          The length of unimpeded pipe without any fittings, instrumentation,
          or flow disturbances downstream (assumed 20 diameters if not 
          specified), [m]
      method : str, optional
          The specified method to use; one of 'Rennels', 'Miller', 'Crane', 
          or 'Blevins', [-]
  
      Returns
      -------
      K : float
          Loss coefficient with respect to either upstream or downstream 
          diameter, [-]
  
      Notes
      -----
      This method is designed only for single-jointed miter bends. It is common
      for miter bends to have two or three sections, to further reduce the loss
      coefficient. Some methods exist in [2]_ for taking this into account. 
      Because the additional configurations reduce the pressure loss, it is
      "common practice" to simply ignore their effect and accept the slight
      overdesign.
      
      The following figure illustrates the different methods.
  
      .. plot:: plots/bend_miter.py
  
      Examples
      --------
      >>> bend_miter(150)
      2.7128147734758103
      >>> bend_miter(Di=.6, angle=45, Re=1e6, roughness=1e-5, L_unimpeded=20, 
      ... method='Miller')
      0.2944060416245167
  
      References
      ----------
      .. [1] Rennels, Donald C., and Hobart M. Hudson. Pipe Flow: A Practical
         and Comprehensive Guide. 1st edition. Hoboken, N.J: Wiley, 2012.
      .. [2] Miller, Donald S. Internal Flow Systems: Design and Performance
         Prediction. Gulf Publishing Company, 1990.
      .. [3] Crane Co. Flow of Fluids Through Valves, Fittings, and Pipe. Crane,
         2009.
      .. [4] Blevins, Robert D. Applied Fluid Dynamics Handbook. New York, N.Y.: 
         Van Nostrand Reinhold Co., 1984.
      '''
      if method is None:
          method = 'Rennels'
      if method == 'Rennels':
          angle_rad = radians(angle)
          sin_half_angle = sin(angle_rad*0.5)
          return 0.42*sin_half_angle + 2.56*sin_half_angle*sin_half_angle*sin_half_angle
      elif method == 'Crane':
          factor = interp(angle, bend_miter_Crane_angles, bend_miter_Crane_fds)
          return ft_Crane(Di)*factor
      elif method == 'Miller':
          return bend_miter_Miller(Di=Di, angle=angle, Re=Re, roughness=roughness, L_unimpeded=L_unimpeded)
      elif method == 'Blevins':
          # data from Idelchik, Miller, an earlier ASME publication
          # For 90-120 degrees, a polynomial/spline would be better than a linear fit
          K_base = interp(angle, bend_miter_Blevins_angles, bend_miter_Blevins_Ks)
          return K_base*(2E5/Re)**0.2
      else:
          raise ValueError('Specified method not recognized; methods are %s'
                           %(bend_miter_methods))