diff --git a/ippl/src/Meshes/Mesh.h b/ippl/src/Meshes/Mesh.h
index bd5429ab16645c770130da8869e757240486c106..89f6a69c7b4409799c3f8c3579f1d05b220219bc 100644
--- a/ippl/src/Meshes/Mesh.h
+++ b/ippl/src/Meshes/Mesh.h
@@ -23,7 +23,7 @@
 // include files
 #include "FieldLayout/FieldLayout.h"
 #include "FieldLayout/FieldLayoutUser.h"
-
+#include "Utility/UserList.h"
 
 // Enumeration used for specifying mesh boundary conditions. Mesh BC are used
 // for things like figuring out how to return the mesh spacing for a cell 
diff --git a/ippl/test/6dtrack/GTChargedParticles/GTChargedParticles.cpp b/ippl/test/6dtrack/GTChargedParticles/GTChargedParticles.cpp
index d06b34b721df963ec2fe7769b627fadee93b08a2..70464dc99f2c46bec1380e0619d4beceb1474907 100644
--- a/ippl/test/6dtrack/GTChargedParticles/GTChargedParticles.cpp
+++ b/ippl/test/6dtrack/GTChargedParticles/GTChargedParticles.cpp
@@ -642,7 +642,6 @@ void ChargedParticles<pl>::writeRestartInfo(string Fn, unsigned turn) {
     partof_m << spos_m << endl;
     partof_m << lost_num << endl;
     partof_m << lost2_num << endl;
-    //    gräfli isch doch schön im engadin!
     for (unsigned i=0; i < nloc; i++)
       partof_m << R[i](0) << setw(pwi) << " \t" 
 	       << P[i](0) << setw(pwi) << " \t" 
@@ -657,7 +656,7 @@ void ChargedParticles<pl>::writeRestartInfo(string Fn, unsigned turn) {
       smsg->put(node);
       bool res = Ippl::Comm->send(smsg, node, tag1);	
       if (! res) 
-	ERRORMSG("Ippl::Comm->send(smsg, 0, tag1) failed " << endl;);  
+          ERRORMSG("Ippl::Comm->send(smsg, 0, tag1) failed " << endl;);  
       // now wait
       Message* rmsg =  Ippl::Comm->receive_block(node, tag2);
       delete(rmsg);
diff --git a/opt-pilot/Expression/SumErrSq.h b/opt-pilot/Expression/SumErrSq.h
index b3dcb1360934464c3031a69eaa8e1cd224d6b343..778d60b6617cf02fbd6e8d6de20929f3321ab4a2 100644
--- a/opt-pilot/Expression/SumErrSq.h
+++ b/opt-pilot/Expression/SumErrSq.h
@@ -87,14 +87,6 @@ private:
 
     // define a mapping to arguments in argument vector
     boost::tuple<std::string, std::string, std::string> argument_types;
-    // :FIXME: unused enum
-#if 0
-    enum {
-          measurement_filename
-        , var_name
-        , stat_filename
-    } argument_type_id;
-#endif
 };
 
 #endif
diff --git a/src/Algorithms/CavityAutophaser.cpp b/src/Algorithms/CavityAutophaser.cpp
index ea6a09a3c80b0a1ca8d890e9e66cc16ff814c5ae..2fa5ade912b68fa87dc666a13d99370eac1af316 100644
--- a/src/Algorithms/CavityAutophaser.cpp
+++ b/src/Algorithms/CavityAutophaser.cpp
@@ -37,18 +37,16 @@ double CavityAutophaser::getPhaseAtMaxEnergy(const Vector_t &R,
     initialP_m = Vector_t(0, 0, euclidean_norm(P));
     double tErr  = (initialR_m(2) - R(2)) * sqrt(dot(P,P) + 1.0) / (P(2) * Physics::c);
     double initialEnergy = Util::getEnergy(P, itsReference_m.getM()) * 1e-6;
-    double originalPhase = 0.0, newPhase = 0.0, AstraPhase = 0.0;
+    double newPhase = 0.0, AstraPhase = 0.0;
     double initialPhase = guessCavityPhase(t + tErr);
     double optimizedPhase = 0.0;
-    double amplitude = 0.0;
-    double designEnergy = 0.0;
     double finalEnergy = 0.0;
 
     RFCavity *element = static_cast<RFCavity *>(itsCavity_m.get());
-    amplitude = element->getAmplitudem();
-    designEnergy = element->getDesignEnergy();
-    originalPhase = element->getPhasem();
-    bool apVeto = element->getAutophaseVeto();
+    double amplitude     = element->getAmplitudem();
+    double designEnergy  = element->getDesignEnergy();
+    double originalPhase = element->getPhasem();
+    bool   apVeto        = element->getAutophaseVeto();
     double basePhase = std::fmod(element->getFrequencym() * (t + tErr), Physics::two_pi);
 
     if (!apVeto) {
diff --git a/src/Algorithms/ParallelSliceTracker.cpp b/src/Algorithms/ParallelSliceTracker.cpp
index 7eceeb56a8bd4b5d5931e8ae106cdaf5637cca92..294823fad46671c4cb7cc0c55ec6ac3df7b65403 100644
--- a/src/Algorithms/ParallelSliceTracker.cpp
+++ b/src/Algorithms/ParallelSliceTracker.cpp
@@ -222,7 +222,7 @@ void ParallelSliceTracker::computeExternalFields() {
     IpplTimings::startTimer(timeFieldEvaluation_m);
 
     Vector_t externalE, externalB, KR, KT;
-    bool globalEOL_m;
+    //bool globalEOL_m;
 
     for (int i = 0; i < itsBunch_m->getLocalNum(); i++) {
 
@@ -238,7 +238,7 @@ void ParallelSliceTracker::computeExternalFields() {
         unsigned long rtv = itsOpalBeamline_m->getFieldAt(i, pos, ls,
                 currentSimulationTime_m , externalE, externalB);
 
-        globalEOL_m = globalEOL_m && (rtv & BEAMLINE_EOL);
+        //globalEOL_m = globalEOL_m && (rtv & BEAMLINE_EOL);
 
         itsOpalBeamline_m->getKFactors(i, pos, ls, currentSimulationTime_m, KR, KT);
 
diff --git a/src/Algorithms/lomb.h b/src/Algorithms/lomb.h
index b4e7d708962cf1f5332ac99ace13617e833ebbb2..7fb78bf7528c689a6080917d1bc06ea17dec1347 100644
--- a/src/Algorithms/lomb.h
+++ b/src/Algorithms/lomb.h
@@ -16,7 +16,6 @@ typedef struct {
 
 typedef std::vector<LOMB_TYPE>::const_iterator CI_lt;
 typedef std::vector<double>::const_iterator CI_vd;
-typedef std::vector<float >::const_iterator CI_vf;
 
 class Lomb_eq : public std::unary_function<LOMB_TYPE, bool> {
     double b;
@@ -25,20 +24,6 @@ public:
     bool operator()(const LOMB_TYPE &c) const {return c.y == b;}
 };
 
-class Compare_XPos {
-public:
-    bool operator()(const LOMB_TYPE &a, const LOMB_TYPE &b)
-    { return a.y < b.y; }
-
-};
-
-class Countlomb {
-public:
-    bool operator()(const LOMB_TYPE &a, const double &b)
-    { return a.y == b; }
-
-};
-
 class LOMB_class {
 private:
 
@@ -46,7 +31,7 @@ private:
 
 public:
 
-    LOMB_class(int);          // constructor
+    explicit LOMB_class(int);  // constructor
     virtual ~LOMB_class(void); //destructor
 
     int period(std::vector<LOMB_TYPE> *indata, std::vector<LOMB_TYPE> *outdata,
diff --git a/src/Algorithms/lomb.hpp b/src/Algorithms/lomb.hpp
index ed0bbd30a11e5b70a4463b9abed5d73b2aba692f..b33fdaf3ad1d2fb678055515e8aa3732c1425483 100644
--- a/src/Algorithms/lomb.hpp
+++ b/src/Algorithms/lomb.hpp
@@ -8,15 +8,6 @@
 #include "lomb.h"
 #include <iostream>
 
-bool operator <(const LOMB_TYPE &a, const LOMB_TYPE &b) {
-    return a.y < b.y;
-}
-
-bool operator ==(const LOMB_TYPE &a, const double &b) {
-    return a.y == b;
-}
-
-
 LOMB_class::LOMB_class(int)
 /*---------------------------------------------------------------------------*
  * constructor
diff --git a/src/BasicActions/Option.cpp b/src/BasicActions/Option.cpp
index 21beb31ff2bd4ccb3ee17f4b8064dafb177b3231..cdb34acdc7d74ae2c968d3367524fdc5d2c40b01 100644
--- a/src/BasicActions/Option.cpp
+++ b/src/BasicActions/Option.cpp
@@ -168,7 +168,7 @@ Option::Option():
                       ("CZERO", "If set to true a symmetric distribution is created -> centroid == 0.0 ", cZero);
 
     itsAttr[RNGTYPE] =  Attributes::makeString
-                        ("RNGTYPE", "RANDOM (default), Quasi-random number gernerators: HALTON, SOBOL, NIEDERREITER (Gsl ref manual 18.5)", rngtype);
+                        ("RNGTYPE", "RANDOM (default), Quasi-random number generators: HALTON, SOBOL, NIEDERREITER (Gsl ref manual 18.5)", rngtype);
 
 
     itsAttr[CLOTUNEONLY] =  Attributes::makeBool
diff --git a/src/Classic/AbsBeamline/Cyclotron.cpp b/src/Classic/AbsBeamline/Cyclotron.cpp
index 7def06c9211eaa5d65de9fb2d848ea04b22e4d8b..6ed5413bb8a41318eba34884941a18442d5f232d 100644
--- a/src/Classic/AbsBeamline/Cyclotron.cpp
+++ b/src/Classic/AbsBeamline/Cyclotron.cpp
@@ -7,7 +7,7 @@
 // ------------------------------------------------------------------------
 //
 // Definitions for class: Cyclotron
-//   Defines the abstract interface for a sector bend magnet.
+//   Defines the abstract interface for a cyclotron.
 //
 // ------------------------------------------------------------------------
 // Class category: AbsBeamline
diff --git a/src/Classic/AbsBeamline/Cyclotron.h b/src/Classic/AbsBeamline/Cyclotron.h
index c4991065fe4a7002dc041a299332facd590a10a7..11b9e2612def3fbf68a03dec150b35ba01c450f7 100644
--- a/src/Classic/AbsBeamline/Cyclotron.h
+++ b/src/Classic/AbsBeamline/Cyclotron.h
@@ -10,7 +10,7 @@
 // ------------------------------------------------------------------------
 //
 // Definitions for class: Cyclotron
-//   Defines the abstract interface for a sector bend magnet.
+//   Defines the abstract interface for a cyclotron.
 //
 // ------------------------------------------------------------------------
 // Class category: AbsBeamline
diff --git a/src/Classic/Algorithms/Quaternion.h b/src/Classic/Algorithms/Quaternion.h
index e6afe6de0885f4087476e3963a979b520aa98810..e16fcfd29f2606608665184237317ec24ac274ca 100644
--- a/src/Classic/Algorithms/Quaternion.h
+++ b/src/Classic/Algorithms/Quaternion.h
@@ -1,8 +1,6 @@
 #ifndef OPAL_QUATERNION_H
 #define OPAL_QUATERNION_H
 
-#include <limits>
-
 #include "AppTypes/Vektor.h"
 #include "Algorithms/Vektor.h"
 
diff --git a/src/Classic/BeamlineCore/CyclotronRep.cpp b/src/Classic/BeamlineCore/CyclotronRep.cpp
index b255ff5de5484bef289035a787fd14eec83d0c91..cfc210b7dd7edda1d68783c7ed18e85772ba1b67 100644
--- a/src/Classic/BeamlineCore/CyclotronRep.cpp
+++ b/src/Classic/BeamlineCore/CyclotronRep.cpp
@@ -7,7 +7,7 @@
 // ------------------------------------------------------------------------
 //
 // Class: CyclotronRep
-//   Defines a concrete representation for a sector (curved) bend.
+//   Defines a concrete representation for a cyclotron.
 //
 // ------------------------------------------------------------------------
 // Class category: BeamlineCore
@@ -20,10 +20,8 @@
 
 #include "BeamlineCore/CyclotronRep.h"
 #include "AbsBeamline/ElementImage.h"
-#include "Channels/IndexedChannel.h"
 #include "Channels/IndirectChannel.h"
 #include "ComponentWrappers/CyclotronWrapper.h"
-#include <cctype>
 
 // Attribute access table.
 // ------------------------------------------------------------------------
@@ -83,26 +81,13 @@ ElementBase *CyclotronRep::clone() const {
 
 
 Channel *CyclotronRep::getChannel(const std::string &aKey, bool create) {
-    if(aKey[0] == 'a'  ||  aKey[0] == 'b') {
-        int n = 0;
-
-        for(std::string::size_type k = 1; k < aKey.length(); k++) {
-            if(isdigit(aKey[k])) {
-                n = 10 * n + aKey[k] - '0';
-            } else {
-                return 0;
-            }
-        }
-    } else {
-        for(const Entry *table = entries; table->name != 0; ++table) {
-            if(aKey == table->name) {
-                return new IndirectChannel<CyclotronRep>(*this, table->get, table->set);
-            }
-        }
-
-        return ElementBase::getChannel(aKey, create);
+    for(const Entry *entry = entries; entry->name != 0; ++entry) {
+      if(aKey == entry->name) {
+        return new IndirectChannel<CyclotronRep>(*this, entry->get, entry->set);
+      }
     }
-    return 0;
+
+    return ElementBase::getChannel(aKey, create);
 }
 
 
@@ -154,10 +139,8 @@ void CyclotronRep::setField(const BMultipoleField &f) {
     field = f;
 }
 
-
-
 ElementBase *CyclotronRep::makeFieldWrapper() {
     ElementBase *wrap = new CyclotronWrapper(this);
     wrap->setName(getName());
     return wrap;
-}
+}
\ No newline at end of file
diff --git a/src/Classic/Fields/SectorField.cpp b/src/Classic/Fields/SectorField.cpp
index 3bd2f5198d655c39c923a1420267ce087bc30ffe..b65b7c7aed34d356825afbb24031fe8727199f28 100644
--- a/src/Classic/Fields/SectorField.cpp
+++ b/src/Classic/Fields/SectorField.cpp
@@ -104,7 +104,7 @@ void SectorField::setPolarBoundingBox
                "Bounding box minimum y was greater than maximum y"
                ));
     }
-    if (bbMinY > bbMaxY) {
+    if (bbMinPhi > bbMaxPhi) {
         throw(LogicalError(
                "SectorField::SetPolarBoundingBox",
                "Bounding box minimum angle was greater than maximum angle"
diff --git a/src/Classic/Structure/LossDataSink.cpp b/src/Classic/Structure/LossDataSink.cpp
index c70794c044b6f2884cbbbf6690a63129617d59b8..364d8d74ca581eac07894e59b3e436df25d491a4 100644
--- a/src/Classic/Structure/LossDataSink.cpp
+++ b/src/Classic/Structure/LossDataSink.cpp
@@ -495,10 +495,10 @@ void LossDataSink::splitSets(unsigned int numSets) {
     const size_t nLoc = x_m.size();
     size_t avgNumPerSet = nLoc / numSets;
     std::vector<size_t> numPartsInSet(numSets, avgNumPerSet);
-    size_t test = numSets * avgNumPerSet;
+    // size_t test = numSets * avgNumPerSet;
     for (unsigned int j = 0; j < (nLoc - numSets * avgNumPerSet); ++ j) {
         ++ numPartsInSet[j];
-        ++ test;
+        // ++ test;
     }
 
     if (/*nLoc > 0 && */time_m.size() == nLoc) {
diff --git a/src/Classic/Utilities/Options.cpp b/src/Classic/Utilities/Options.cpp
index b1c2818ee1d6246a1d11641c9f419ebdd62d65f9..403c71174744ed716a7ebb83780652a9469f629b 100644
--- a/src/Classic/Utilities/Options.cpp
+++ b/src/Classic/Utilities/Options.cpp
@@ -36,8 +36,6 @@ namespace Options {
 
     bool enableHDF5 = true;
 
-    // bool efDump = false;
-
     // The global random generator.
     Random rangen;
 
diff --git a/src/Classic/Utilities/Options.h b/src/Classic/Utilities/Options.h
index b44a827427bfcd152964cfa258e463ccf9f74daf..bf8046c439cc1915a4ae009bab84d1791b4a2aef 100644
--- a/src/Classic/Utilities/Options.h
+++ b/src/Classic/Utilities/Options.h
@@ -62,10 +62,6 @@ namespace Options {
 
     extern bool idealized;
 
-    // CKR: nowhere used
-    // // true if in bet mode
-    // extern bool bet;
-
     /// Trace flag.
     //  If true, print CPU time before and after each command.
     extern bool mtrace;
@@ -84,10 +80,6 @@ namespace Options {
     /// The frequency to dump the phase space, i.e.dump data when step%psDumpFreq==0
     extern int psDumpFreq;
 
-    // CKR: nowhere used
-    // /// Dump centroid when R >rDump
-    // extern double rDump;
-
     /// The frequency to dump statistical values, e.e. dump data when step%statDumpFreq==0
     extern int statDumpFreq;
 
@@ -129,9 +121,6 @@ namespace Options {
 
     extern bool ebDump;
 
-    // CKR: nowhere used
-    // extern bool efDump;
-
     // if true opal find the phases in the cavities, such that the energy gain is at maximum
     extern int autoPhase;
 
@@ -147,11 +136,13 @@ namespace Options {
     /// number of old left hand sides used to extrapolate a new start vector
     extern int nLHS;
 
+    /// random number generator
     extern std::string rngtype;
 
     /// Do closed orbit and tune calculation only.
     extern bool cloTuneOnly;
 
+    /// opal version of input file
     extern int version;
     
 #ifdef ENABLE_AMR
diff --git a/src/Structure/BoundaryGeometry.h b/src/Structure/BoundaryGeometry.h
index 1de6b5ac03486832132ed49c03b59a9ac015ca22..88ef82e9109411cadcf9a9d21e749077cb3cc024 100644
--- a/src/Structure/BoundaryGeometry.h
+++ b/src/Structure/BoundaryGeometry.h
@@ -36,10 +36,10 @@ extern Inform* gmsg;
 
 namespace BGphysics {
     enum TPHYACTION {
-        Nop = 0x01,                 // tringle is transparent to particle like beam window
+        Nop = 0x01,                 // triangle is transparent to particle like beam window
         Absorption = 0x02,          // triangle has no field and secondary emission
         FNEmission = 0x04,          // triangle has field emission
-        SecondaryEmission = 0x08    // trangle has secondary emission
+        SecondaryEmission = 0x08    // triangle has secondary emission
     };
 }
 
diff --git a/src/opal.cpp b/src/opal.cpp
index a67c83d98e70f86d61762bb02c8480dacb9ccbe2..8c36a5c0168b758ddd4cf988a23069edad6ba7d6 100644
--- a/src/opal.cpp
+++ b/src/opal.cpp
@@ -18,18 +18,17 @@ extern Inform *gmsg;
 int run_opal(char *arg[], std::string inputfile, int restartStep, MPI_Comm comm) {
 
     std::string::size_type startExtension    = inputfile.find_last_of('.');
-    std::string::size_type startRelativePath = inputfile.find_last_of('/');
-    std::string relativePath("");
-    if (startRelativePath != std::string::npos) {
-        relativePath = inputfile.substr(0, startRelativePath + 1);
-    }
+    // std::string::size_type startRelativePath = inputfile.find_last_of('/');
+    // std::string relativePath("");
+    // if (startRelativePath != std::string::npos) {
+    //     relativePath = inputfile.substr(0, startRelativePath + 1);
+    // }
     std::string outputFileName = inputfile.substr(0,startExtension) + ".out";
     std::ofstream output(outputFileName.c_str());
 
     MPI_Barrier(comm);
 
-    // int narg = 5, remove = 1;
-    IpplInfoWrapper *newippl = new IpplInfoWrapper(inputfile, comm);//narg, arg, remove, comm);
+    IpplInfoWrapper *newippl = new IpplInfoWrapper(inputfile, comm);
     gmsg = new Inform("OPAL ", output);
     IpplInfo::Info->setDestination(output);
     IpplInfo::Error->setDestination(output);
@@ -47,8 +46,8 @@ int run_opal(char *arg[], std::string inputfile, int restartStep, MPI_Comm comm)
     try {
         is = new FileStream(inputfile);
     } catch(...) {
-      is = 0;
-	throw new OpalException("run_opal", "Could not open inputfile: " + inputfile);
+        is = 0;
+        throw new OpalException("run_opal", "Could not open inputfile: " + inputfile);
     }
 
     // run simulation
diff --git a/tests/classic_src/AbsBeamline/ScalingFFAGMagnetTest.cpp b/tests/classic_src/AbsBeamline/ScalingFFAGMagnetTest.cpp
index 9f186faf1a7635907015fec2e8a13d37b6c96b3e..1790714e69bb246aac0dae8bb27d6473f5f698b1 100644
--- a/tests/classic_src/AbsBeamline/ScalingFFAGMagnetTest.cpp
+++ b/tests/classic_src/AbsBeamline/ScalingFFAGMagnetTest.cpp
@@ -298,7 +298,7 @@ TEST_F(ScalingFFAGMagnetTest, DFCoefficientsTest) {
       {+25./2.*3./4., 0., +1./2.*3./4.+25./6./4., 0., +1./6./4.}, // n = 4
     };
     std::vector< std::vector<double> > coeffs = sector_m->getDfCoefficients();
-    ASSERT_GE(coeffs.size(), 5);
+    ASSERT_GE(coeffs.size(), (size_t)5);
     for (size_t n = 0; n < 5; ++n) {
         ASSERT_EQ(coeffs[n].size(), n+1);
         for (size_t i = 0; i < coeffs[n].size(); ++i) {
@@ -322,7 +322,7 @@ TEST_F(ScalingFFAGMagnetTest, DFCoefficientsTanDeltaTest) {
       {+25./2.*3./4., -25./6./4.*2.*3.*2.-10.*3/4., -999., -999., -999.}, // n = 4
     };
     std::vector< std::vector<double> > coeffs = sector_m->getDfCoefficients();
-    ASSERT_GE(coeffs.size(), 4);
+    ASSERT_GE(coeffs.size(), (size_t)4);
     for (size_t n = 0; n < 4; ++n) {
         ASSERT_EQ(coeffs[n].size(), n+1);
         for (size_t i = 0; i < coeffs[n].size(); ++i) {
diff --git a/tests/classic_src/Fields/Interpolation/NDGridTest.cpp b/tests/classic_src/Fields/Interpolation/NDGridTest.cpp
index 5811a3157e717ab81418d0df9930aad4f43769f9..0b983290f1db4433e80d433be8958c468d3a8c01 100644
--- a/tests/classic_src/Fields/Interpolation/NDGridTest.cpp
+++ b/tests/classic_src/Fields/Interpolation/NDGridTest.cpp
@@ -121,7 +121,7 @@ TEST_F(NDGridTest, Constructor3Test) {
     interpolation::NDGrid grid1(gridCoordinates);
     ASSERT_EQ(grid1.getPositionDimension(), 2);
     for (int i = 0; i < 2; ++i) {
-        size_t size = gridCoordinates[i].size();
+        int size = gridCoordinates[i].size();
         ASSERT_EQ(grid1.size(i), size);
         EXPECT_NEAR(grid1.coord(1, i), gridCoordinates[i][0], 1e-12) << "Failed for i " << i;
         EXPECT_NEAR(grid1.coord(i+2, i), gridCoordinates[i][size-1], 1e-12) << "Failed for i " << i;
@@ -138,8 +138,8 @@ TEST_F(NDGridTest, CoordTest) {
     interpolation::NDGrid grid_var(gridCoordinates);
     const interpolation::NDGrid grid_const(gridCoordinates);
     for (int i = 0; i < 2; ++i) {
-            EXPECT_NEAR(grid_var.coord(1, i), gridCoordinates[i][0], 1e-12) << "Failed for i " << i;
-            EXPECT_NEAR(grid_const.coord(1, i), gridCoordinates[i][0], 1e-12) << "Failed for i " << i;
+        EXPECT_NEAR(grid_var.coord(1, i), gridCoordinates[i][0], 1e-12) << "Failed for i " << i;
+        EXPECT_NEAR(grid_const.coord(1, i), gridCoordinates[i][0], 1e-12) << "Failed for i " << i;
     }
 }
 
@@ -240,7 +240,7 @@ TEST_F(NDGridTest, SetCoordTest) {
     double xNew[] = {5., 10., 12., 15.};
     grid_m->setCoord(0, 4, xNew);
     std::vector<double> xTest = grid_m->coordVector(0);
-    EXPECT_EQ(xTest.size(), 4);
+    EXPECT_EQ(xTest.size(), (unsigned int)4);
     for (size_t i = 0; i < 4; ++i) {
         EXPECT_EQ(xTest[i], xNew[i]);
     }
@@ -249,10 +249,10 @@ TEST_F(NDGridTest, SetCoordTest) {
 TEST_F(NDGridTest, BeginEndTest) {
     OpalTestUtilities::SilenceTest silencer;
 
-    ASSERT_EQ(grid_m->begin().getState().size(), 2);
+    ASSERT_EQ(grid_m->begin().getState().size(), (unsigned int)2);
     EXPECT_EQ(grid_m->begin().getState()[0], 1);
     EXPECT_EQ(grid_m->begin().getState()[1], 1);
-    ASSERT_EQ(grid_m->end().getState().size(), 2);
+    ASSERT_EQ(grid_m->end().getState().size(), (unsigned int)2);
     EXPECT_EQ(grid_m->end().getState()[0], 3); // one past the last (2, 3)
     EXPECT_EQ(grid_m->end().getState()[1], 1);
 }
diff --git a/tests/classic_src/Fields/Interpolation/PPSolveFactoryTest.cpp b/tests/classic_src/Fields/Interpolation/PPSolveFactoryTest.cpp
index 3acb27fcc06c2e9aa4c3a2a77b700c57ead5c904..ac6946271c5f126d51a1c36e726e385af077e28f 100644
--- a/tests/classic_src/Fields/Interpolation/PPSolveFactoryTest.cpp
+++ b/tests/classic_src/Fields/Interpolation/PPSolveFactoryTest.cpp
@@ -58,10 +58,10 @@ void test_points(int dim, int lower, int upper, std::vector< std::vector<int> >
       if (upper < 0)
           upper_size = 0;
       // size should be difference in area of the squares
-      EXPECT_EQ(pts.size(), upper_size - lower_size);
+      EXPECT_EQ(pts.size(), (unsigned int)(upper_size - lower_size));
       for (size_t i = 0; i < pts.size(); ++i) {
           // each pts element should have length dim
-          EXPECT_EQ(pts[i].size(), dim);
+          EXPECT_EQ(pts[i].size(), (size_t)dim);
           // each pts element should have indices with lower < size <= upper
           bool in_bounds = true;
           for (int j = 0; j < dim; ++j) {
@@ -154,7 +154,7 @@ TEST_F(PPSolveFactoryTestFixture, TestSolvePolynomialQuadratic) {
     // first check that the polynomial at 0, 0, 0 is the same as ref
     std::vector<double> zero(3, 0.);
     SquarePolynomialVector* test = patch2->getPolynomialVector(&zero[0]);
-    EXPECT_EQ(patch2->getValueDimension(), 2);
+    EXPECT_EQ(patch2->getValueDimension(), (unsigned int)2);
     MMatrix<double> testCoeffs = test->GetCoefficientsAsMatrix();
     std::cout << "Ref" << std::endl;
     std::cout << refCoeffs << std::endl;
@@ -344,7 +344,7 @@ TEST(PPSolveFactoryTest, TestThreeDSolveSinCos) {
             std::stringstream ss;
             ss << "smooth: " << smooth_order << " poly: " << pp_order;
             plot(100, start, end, ppVec.back(), np, ss.str());
-            EXPECT_EQ(ppVec.back()->getValueDimension(), 3);
+            EXPECT_EQ(ppVec.back()->getValueDimension(), (unsigned int)3);
         }
     }
     std::cout << "Testing" << std::endl;
diff --git a/tests/classic_src/Fields/Interpolation/SolveFactoryTest.cpp b/tests/classic_src/Fields/Interpolation/SolveFactoryTest.cpp
index 731af303353aa6b29daac069f71aecdf71153ce1..03ace2e9e42a4e76b18a45695337d379397769b1 100644
--- a/tests/classic_src/Fields/Interpolation/SolveFactoryTest.cpp
+++ b/tests/classic_src/Fields/Interpolation/SolveFactoryTest.cpp
@@ -63,8 +63,8 @@ TEST(SolveFactoryTest, TestSolveNoDerivs) {
     SquarePolynomialVector* vec = fac.PolynomialSolve(values,
                                                       deriv_pos);
     MMatrix<double> testCoeffs = vec->GetCoefficientsAsMatrix();
-    ASSERT_EQ(testCoeffs.num_row(), 3);
-    ASSERT_EQ(testCoeffs.num_col(), 9);
+    ASSERT_EQ(testCoeffs.num_row(), (size_t)3);
+    ASSERT_EQ(testCoeffs.num_col(), (size_t)9);
     for (size_t i = 0; i < 3; ++i)
         for (size_t j = 0; j < 3; ++j)
             EXPECT_NEAR(testCoeffs(i+1, j+1), refCoeffs(i+1, j+1), 1e-6);
diff --git a/tests/classic_src/Fields/Interpolation/SquarePolynomialVectorTest.cpp b/tests/classic_src/Fields/Interpolation/SquarePolynomialVectorTest.cpp
index 85ac6092580f590c0579682c9dd021fd4d429617..bad61c86ede53d21a68219086bb769f3ca571fa4 100644
--- a/tests/classic_src/Fields/Interpolation/SquarePolynomialVectorTest.cpp
+++ b/tests/classic_src/Fields/Interpolation/SquarePolynomialVectorTest.cpp
@@ -38,10 +38,10 @@ TEST(SquarePolynomialVectorTest, TestConstructorDestructor) {
     OpalTestUtilities::SilenceTest silencer;
 
     SquarePolynomialVector test1;
-    EXPECT_EQ(test1.PointDimension(), 0);
-    EXPECT_EQ(test1.ValueDimension(), 0);
-    EXPECT_EQ(test1.GetCoefficientsAsMatrix().num_col(), 0);
-    EXPECT_EQ(test1.GetCoefficientsAsMatrix().num_row(), 0);
+    EXPECT_EQ(test1.PointDimension(), (unsigned int)0);
+    EXPECT_EQ(test1.ValueDimension(), (unsigned int)0);
+    EXPECT_EQ(test1.GetCoefficientsAsMatrix().num_col(), (unsigned int)0);
+    EXPECT_EQ(test1.GetCoefficientsAsMatrix().num_row(), (unsigned int)0);
 
     std::vector<double> data(18);
     for (size_t i = 0; i < data.size(); ++i)
@@ -49,8 +49,8 @@ TEST(SquarePolynomialVectorTest, TestConstructorDestructor) {
     MMatrix<double> refCoeffs(2, 9, &data[0]); // 2x9 -> c, x, y, xy, xx, xxy, xxyy, xyy, yy,
     SquarePolynomialVector test2(2, refCoeffs);
     MMatrix<double> testCoeffs = test2.GetCoefficientsAsMatrix();
-    ASSERT_EQ(testCoeffs.num_row(), 2);
-    ASSERT_EQ(testCoeffs.num_col(), 9);
+    ASSERT_EQ(testCoeffs.num_row(), (unsigned int)2);
+    ASSERT_EQ(testCoeffs.num_col(), (unsigned int)9);
     for (size_t i = 0; i < testCoeffs.num_row(); ++i) {
         for (size_t j = 0; j < testCoeffs.num_col(); ++j) {
             EXPECT_EQ(testCoeffs(i+1, j+1), refCoeffs(i+1, j+1));