This file is indexed.

/usr/include/avogadro/obeigenconv.h is in libavogadro-dev 1.1.1-0ubuntu2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/**********************************************************************
  obeigenconv - Collection of functions to convert between Eigen and
  OpenBabel vectors / matrices

  Copyright (C) 2011 by David C. Lonie

  This file is part of the Avogadro molecular editor project.
  For more information, see <http://avogadro.openmolecules.net/>

  This source code is released under the New BSD License, (the "License").

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
 ***********************************************************************/

#ifndef OBEIGENCONV_H
#define OBEIGENCONV_H

#include <openbabel/math/vector3.h>
#include <openbabel/math/matrix3x3.h>

#include <Eigen/Core>

namespace Avogadro {

  inline Eigen::Matrix3d OB2Eigen(const OpenBabel::matrix3x3 &obm)
  {
    Eigen::Matrix3d mat;
    mat(0,0)=obm.Get(0,0);mat(0,1)=obm.Get(0,1);mat(0,2)=obm.Get(0,2);
    mat(1,0)=obm.Get(1,0);mat(1,1)=obm.Get(1,1);mat(1,2)=obm.Get(1,2);
    mat(2,0)=obm.Get(2,0);mat(2,1)=obm.Get(2,1);mat(2,2)=obm.Get(2,2);
    return mat;
  }

  inline OpenBabel::matrix3x3 Eigen2OB(const Eigen::Matrix3d &mat)
  {
    OpenBabel::matrix3x3 obm;
    obm.Set(0,0,mat(0,0));obm.Set(0,1,mat(0,1));obm.Set(0,2,mat(0,2));
    obm.Set(1,0,mat(1,0));obm.Set(1,1,mat(1,1));obm.Set(1,2,mat(1,2));
    obm.Set(2,0,mat(2,0));obm.Set(2,1,mat(2,1));obm.Set(2,2,mat(2,2));
    return obm;
  }

  inline Eigen::Vector3d OB2Eigen(const OpenBabel::vector3 &obv)
  {
    Eigen::Vector3d vec (obv.x(), obv.y(), obv.z());
    return vec;
  }

  inline OpenBabel::vector3 Eigen2OB(const Eigen::Vector3d &vec)
  {
    OpenBabel::vector3 obv (vec.x(), vec.y(), vec.z());
    return obv;
  }
}
#endif