anchor.diff:               found = .true.
             endif
          enddo
  -
  +       
       case(2)
          do while (.not.found)
             np=np+1
  
positive.code:        node_xyz(3,np) = node_xyz(3,np-1) - 0.5_dp
         node_xyz(1,np) = node_xyz(1,np-1) + 0.5_dp
      enddo
  
      np=202
      nodes(np) = np
      node_xyz(1,np) = node_xyz(1,151) - 0.5_dp
  
negative.code:     num_data = ncount
      close (10)
      write(*,'('' Read'',I7,'' data points from file'')') num_data
      
  !!! allocate arrays now that we know the size required
      if(allocated(data_xyz)) deallocate(data_xyz)
      if(allocated(data_weight)) deallocate(data_weight)
      allocate(data_xyz(3,num_data))
      allocate(data_weight(3,num_data))
      
  !!! read the data point information
      !readfile = trim(datafile)//'.ipdata'
      open(10, file=datafile, status='old')
      read(unit=10, fmt="(a)", iostat=ierror) buffer
      
      !set the counted number of data points to zero
      ncount = 0
      read_line_of_data : do
  