code: def _pdf(self, xloc, left, right, cache):
          
          left = evaluation.get_forward_cache(left, cache)
          right = evaluation.get_forward_cache(right, cache)
  
          if isinstance(left, Dist):
              if isinstance(right, Dist):
                  raise evaluation.DependencyError(
                      "under-defined distribution {} or {}".format(left, right))
          elif not isinstance(right, Dist):
              return numpy.inf
          else:
              left, right = right, left
  
          xloc = (xloc.T-numpy.asfarray(right).T).T
          output = evaluation.evaluate_density(left, xloc, cache=cache)
          assert output.shape == xloc.shape
          return output
docs: Probability density function.
  
          Example:
              >>> print(chaospy.Uniform().pdf([-2, 0, 2, 4]))
              [0. 1. 0. 0.]
              >>> print(chaospy.Add(chaospy.Uniform(), 2).pdf([-2, 0, 2, 4]))
              [0. 0. 1. 0.]
              >>> print(chaospy.Add(2, chaospy.Uniform()).pdf([-2, 0, 2, 4]))
              [0. 0. 1. 0.]
              >>> print(chaospy.Add(1, 1).pdf([-2, 0, 2, 4])) # Dirac logic
              [ 0.  0. inf  0.]