diff --git a/src/privatepgtypes.cpp b/src/privatepgtypes.cpp
index 032facfe949572624a3523c71dc9b1de9a491680..7b49a313f42b04057e83120b568e82b5528fff20 100644
--- a/src/privatepgtypes.cpp
+++ b/src/privatepgtypes.cpp
@@ -127,4 +127,55 @@ namespace PatternGeneratorJRL
     reset();
   }
 
+
+  void
+  convex_hull_t::rotate(const double & angle)
+  {
+
+      double c_a = cos(angle);
+      double s_a = sin(angle);
+
+      for( int j=0;j<X.size();j++ )
+        {
+          X[j] = ( X[j]*c_a - Y[j]*s_a );
+          Y[j] = ( X[j]*s_a + Y[j]*c_a );
+        }
+
+  }
+
+  convex_hull_s::convex_hull_s(const int & size)
+  {
+    resize(size);
+    reset();
+  }
+
+  convex_hull_s::convex_hull_s()
+  {
+
+  }
+
+  void
+  convex_hull_t::reset()
+  {
+    X.clear();
+    Y.clear();
+  }
+
+  void
+  convex_hull_t::resize(const int & size)
+    {
+      X.resize(size);
+      Y.resize(size);
+    }
+
+  void
+  convex_hull_t::set(const double * arrayX, const double * arrayY)
+    {
+      for(int i=0;i<X.size();i++)
+        {
+          X[i] = arrayX[i];
+          Y[i] = arrayY[i];
+        }
+    }
+
 }
diff --git a/src/privatepgtypes.h b/src/privatepgtypes.h
index 15cf210458beff0e65c89f2a13d2c35daf014a63..de92018d9b79d67cef66b6e742ac9a764031373e 100644
--- a/src/privatepgtypes.h
+++ b/src/privatepgtypes.h
@@ -149,12 +149,43 @@ namespace PatternGeneratorJRL
   /// \brief Linear constraints
   struct linear_constraint_s
   {
-    ublas::compressed_vector<double> A;
+    boost_ublas::compressed_vector<double> A;
     double b;
   };
   typedef struct linear_constraint_s
   linear_constraint_t;
 
+  /// \brief Set of 2-dimensional point
+  struct convex_hull_s
+  {
+
+    MAL_VECTOR(X,double);
+    MAL_VECTOR(Y,double);
+
+    /// \brief Rotate the points around the origin by angle
+    ///
+    /// \param[in] angle
+    void rotate(const double & angle);
+
+    /// \brief Resize members to the desired number of points
+    ///
+    /// \param[in] size
+    void resize(const int & size);
+
+    /// \brief Set the point values
+    ///
+    /// \param[in] X
+    /// \param[in] Y
+    void set(const double * arrayX, const double * arrayY);
+
+    /// \brief Set all points to zero
+    void reset();
+
+    convex_hull_s(const int & size);
+    convex_hull_s();
+
+  };
+  typedef struct convex_hull_s convex_hull_t;
 }
 
 #endif /* _PATTERN_GENERATOR_INTERNAL_PRIVATE_H_ */