From 0dea0e9169edeac3793d40f64477dbb41082350c Mon Sep 17 00:00:00 2001
From: Gareth Tribello <gareth.tribello@gmail.com>
Date: Fri, 12 May 2017 09:35:19 +0100
Subject: [PATCH] Fixed bug that affects fibonacci grid on some machines

---
 src/gridtools/GridVessel.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gridtools/GridVessel.cpp b/src/gridtools/GridVessel.cpp
index 126b05208..196991e6e 100644
--- a/src/gridtools/GridVessel.cpp
+++ b/src/gridtools/GridVessel.cpp
@@ -219,7 +219,7 @@ unsigned GridVessel::getIndex( const std::vector<double>& point ) const {
 unsigned GridVessel::getFibonacciIndex( const std::vector<double>& p ) const {
   plumed_dbg_assert( gtype==fibonacci );
   // Convert input point to coordinates on cylinder
-  unsigned k=2; double phi = atan2( p[2], p[0] ), sinthet2 = 1 - p[1]*p[1];
+  int k=2; double phi = atan2( p[2], p[0] ), sinthet2 = 1 - p[1]*p[1];
   // Calculate power to raise golden ratio
   if( sinthet2<epsilon ) { k = 2; }
   else {
-- 
GitLab