code: public static Map<BioPAXElement, Set<PhysicalEntity>> getRelatedPhysicalEntityMap(
  		Collection<BioPAXElement> elements)
  	{
  		replaceXrefsWithRelatedER(elements);
  		Map<BioPAXElement, Set<PhysicalEntity>> map = new HashMap<BioPAXElement, Set<PhysicalEntity>>();
  
  		for (BioPAXElement ele : elements)
  		{
  			Set<PhysicalEntity> ents = getRelatedPhysicalEntities(ele, null);
  
  			if (!ents.isEmpty())
  			{
  				map.put(ele, ents);
  			}
  		}
  		return map;
  	}
docs: Maps each BioPAXElement to its related PhysicalEntity objects.
  
  @param elements Elements to map
  @return The mapping