Commit 4a748fef authored by Spencer Sherwin's avatar Spencer Sherwin
Browse files

Merge branch 'master' into fix/InterpField

parents cdfe8b48 c2214494
///////////////////////////////////////////////////////////////////////////////
//
// File GitRevision.cpp
//
// For more information, please see: http://www.nektar.info
//
// The MIT License
//
// Copyright (c) 2006 Scientific Computing and Imaging Institute,
// University of Utah (USA) and Department of Aeronautics, Imperial
// College London (UK).
//
// License for the specific language governing rights and limitations under
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
// Description: Constants for git SHA1 hash and branch name
//
///////////////////////////////////////////////////////////////////////////////
#ifndef GITREVISION_H
#define GITREVISION_H
#include <LibUtilities/BasicConst/GitRevision.h>
#include <string>
namespace Nektar
{
namespace NekConstants
{
extern const std::string kGitSha1 = "@GIT_SHA1@";
extern const std::string kGitBranch = "@GIT_REFSPEC@";
}
}
#endif
///////////////////////////////////////////////////////////////////////////////
//
// File GitRevision.h
//
// For more information, please see: http://www.nektar.info
//
// The MIT License
//
// Copyright (c) 2006 Scientific Computing and Imaging Institute,
// University of Utah (USA) and Department of Aeronautics, Imperial
// College London (UK).
//
// License for the specific language governing rights and limitations under
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
// Description: Constants for git SHA1 hash and branch name
//
///////////////////////////////////////////////////////////////////////////////
#ifndef GITREVISION_H
#define GITREVISION_H
#include <string>
#include <LibUtilities/LibUtilitiesDeclspec.h>
namespace Nektar
{
namespace NekConstants
{
LIB_UTILITIES_EXPORT extern const std::string kGitSha1;
LIB_UTILITIES_EXPORT extern const std::string kGitBranch;
}
}
#endif
......@@ -40,6 +40,8 @@
#include <LibUtilities/BasicUtils/FieldIO.h>
#include <LibUtilities/BasicUtils/FileSystem.h>
#include <LibUtilities/BasicConst/GitRevision.h>
#include "zlib.h"
#include <set>
......@@ -475,7 +477,7 @@ namespace Nektar
ASSERTL0(fileNames.size() == elementList.size(),"Outfile names and list of elements ids does not match");
cout << "Writing MultiFile data in : " << outFile << endl;
cout << "Writing multi-file data: " << outFile << endl;
TiXmlElement * root = new TiXmlElement("NEKTAR");
doc.LinkEndChild(root);
......@@ -985,12 +987,11 @@ namespace Nektar
// Git information
// If built from a distributed package, do not include this
#ifdef GIT_SHA1
ProvenanceMap["GitSHA1"] = string(GIT_SHA1);
#endif
#ifdef GIT_BRANCH
ProvenanceMap["GitBranch"] = string(GIT_BRANCH);
#endif
if (NekConstants::kGitSha1 != "GITDIR-NOTFOUND")
{
ProvenanceMap["GitSHA1"] = NekConstants::kGitSha1;
ProvenanceMap["GitBranch"] = NekConstants::kGitBranch;
}
TiXmlElement * infoTag = new TiXmlElement("Metadata");
root->LinkEndChild(infoTag);
......
SET(BasicConstHeaders
./BasicConst/NektarUnivConsts.hpp
./BasicConst/NektarUnivTypeDefs.hpp
./BasicConst/NektarUnivConsts.hpp
./BasicConst/NektarUnivTypeDefs.hpp
./BasicConst/GitRevision.h
)
SET(BasicUtilsHeaders
......@@ -42,7 +43,6 @@ SET(BasicUtilsSources
./BasicUtils/XmlUtil.cpp
)
SET(CommunicationHeaders
./Communication/Comm.h
./Communication/CommSerial.h
......@@ -264,7 +264,7 @@ SET(ExpressionTemplates
)
SET(BaseHeaders
LibUtilitiesDeclspec.h
LibUtilitiesDeclspec.h
)
SOURCE_GROUP("Basic Const" FILES ${BasicConstHeaders})
......@@ -278,7 +278,6 @@ SOURCE_GROUP("Linear Algebra Sources" FILES ${LinearAlgebraSources})
SOURCE_GROUP("Memory Headers" FILES ${MemoryHeaders})
SOURCE_GROUP("Memory Sources" FILES ${MemorySources})
SOURCE_GROUP("Polylib Headers" FILES ${PolyLibHeaders})
SOURCE_GROUP("Polylib Sources" FILES ${PolylibSources})
......@@ -315,27 +314,27 @@ SET(LibUtilityHeaders
${BaseHeaders}
)
# Define the git branch and SHA1 hash if we are in a git repository. This is
# stored in an automatically generated file so that the source tree is not built
# on commit/update.
SET(GitRevisionFile "${CMAKE_CURRENT_BINARY_DIR}/GitRevision.cpp")
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/BasicConst/GitRevision.cpp.in
${GitRevisionFile})
SET(LibUtilitySources
${BasicUtilsSources}
${FoundationSources}
${PolylibSources}
${CommunicationSources}
${LinearAlgebraSources}
${InterpreterSources}
${KernelSources}
${LinearAlgebraSources}
${InterpreterSources}
${KernelSources}
${TimeIntegrationSources}
${FFTSources}
${FFTSources}
${MemorySources}
${GitRevisionFile}
)
# Define the git branch and SHA1 hash if we are in a git repository
# Only apply to FieldIO.cpp to minimise rebuilding on git commit/update.
IF (NOT ${GIT_REFSPEC} STREQUAL "GITDIR-NOTFOUND")
SET_PROPERTY(SOURCE ${CMAKE_CURRENT_SOURCE_DIR}/BasicUtils/FieldIO.cpp
APPEND PROPERTY COMPILE_DEFINITIONS
GIT_SHA1=\"${GIT_SHA1}\" GIT_BRANCH=\"${GIT_REFSPEC}\")
ENDIF ()
ADD_DEFINITIONS(-DLIB_UTILITIES_EXPORTS)
ADD_NEKTAR_LIBRARY(LibUtilities lib ${NEKTAR_LIBRARY_TYPE} ${LibUtilitySources} ${LibUtilityHeaders})
......
......@@ -42,34 +42,6 @@ namespace Nektar
{
namespace LocalRegions
{
#if 0
void Expansion3D::AddHDGHelmholtzTraceTerms(
const NekDouble tau,
const Array<OneD, const NekDouble> &inarray,
Array<OneD,StdRegions::StdExpansionSharedPtr> &FaceExp,
const StdRegions::VarCoeffMap &dirForcing,
Array<OneD,NekDouble> &outarray)
{
ASSERTL0(&inarray[0] != &outarray[0],
"Input and output arrays use the same memory");
int f,cnt;
int order_f;
int nfaces = GetNfaces();
Array<OneD, const NekDouble> tmp;
cnt = 0;
for(f = 0; f < nfaces; ++f)
{
order_f = FaceExp[f]->GetNcoeffs();
Vmath::Vcopy(order_f,tmp = inarray + cnt, 1, FaceExp[f]->UpdateCoeffs(), 1);
FaceExp[f]->BwdTrans(FaceExp[f]->GetCoeffs(), FaceExp[f]->UpdatePhys());
AddHDGHelmholtzFaceTerms(tau, f, FaceExp[f], dirForcing, outarray);
cnt += order_f;
}
}
#endif
// evaluate additional terms in HDG face. Note that this assumes that
// edges are unpacked into local cartesian order.
void Expansion3D::AddHDGHelmholtzFaceTerms(
......
......@@ -75,15 +75,6 @@ namespace Nektar
const StdRegions::VarCoeffMap &dirForcing,
Array<OneD, NekDouble> &outarray);
#if 0
inline void AddHDGHelmholtzTraceTerms(
const NekDouble tau,
const Array<OneD, const NekDouble> &inarray,
Array<OneD,StdRegions::StdExpansionSharedPtr> &FaceExp,
const StdRegions::VarCoeffMap &dirForcing,
Array<OneD,NekDouble> &outarray);
#endif
inline void AddNormTraceInt(
const int dir,
Array<OneD,StdRegions::StdExpansionSharedPtr> &FaceExp,
......
......@@ -645,49 +645,16 @@ namespace Nektar
inline DNekMatSharedPtr GetStdMatrix(const StdMatrixKey &mkey)
{
return m_stdMatrixManager[mkey];
/*
map<StdMatrixKey, DNekMatSharedPtr>::iterator it = m_stdMatrixManager.find(mkey);
if (it == m_stdMatrixManager.end())
{
return (m_stdMatrixManager[mkey] = CreateStdMatrix(mkey));
}
else
{
return it->second;
}
*/
}
inline DNekBlkMatSharedPtr GetStdStaticCondMatrix(const StdMatrixKey &mkey)
{
return m_stdStaticCondMatrixManager[mkey];
/*
map<StdMatrixKey, DNekBlkMatSharedPtr>::iterator it = m_stdStaticCondMatrixManager.find(mkey);
if (it == m_stdStaticCondMatrixManager.end())
{
return (m_stdStaticCondMatrixManager[mkey] = CreateStdStaticCondMatrix(mkey));
}
else
{
return it->second;
}
*/
}
inline IndexMapValuesSharedPtr GetIndexMap(const IndexMapKey &ikey)
inline IndexMapValuesSharedPtr GetIndexMap(const IndexMapKey &ikey)
{
return m_IndexMapManager[ikey];
/*
map<IndexMapKey, IndexMapValuesSharedPtr>::iterator it = m_IndexMapManager.find(ikey);
if (it == m_IndexMapManager.end())
{
return (m_IndexMapManager[ikey] = CreateIndexMap(ikey));
}
else
{
return it->second;
}
*/
}
const Array<OneD, const NekDouble>& GetPhysNormals(void)
......@@ -731,8 +698,8 @@ namespace Nektar
{
return v_GetEorient(edge);
}
StdRegions::Orientation GetPorient(int point)
StdRegions::Orientation GetPorient(int point)
{
return v_GetPorient(point);
}
......@@ -1327,10 +1294,6 @@ namespace Nektar
LibUtilities::NekManager<StdMatrixKey, DNekBlkMat, StdMatrixKey::opLess> m_stdStaticCondMatrixManager;
LibUtilities::NekManager<IndexMapKey, IndexMapValues, IndexMapKey::opLess> m_IndexMapManager;
//static std::map<StdMatrixKey, DNekMatSharedPtr> m_stdMatrixManager;
//static std::map<StdMatrixKey, DNekBlkMatSharedPtr> m_stdStaticCondMatrixManager;
//static std::map<IndexMapKey, IndexMapValuesSharedPtr> m_IndexMapManager;
DNekMatSharedPtr CreateStdMatrix(const StdMatrixKey &mkey)
{
return v_CreateStdMatrix(mkey);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment