Commit 794cd55b authored by Pawel Sznajder's avatar Pawel Sznajder
Browse files

Merge branch 'master' into 'subtraction_constant_0121'

# Conflicts:
#   CMakeLists.txt
parents 3d2a8548 865213f4
......@@ -2,3 +2,9 @@
/.settings/
/lib/
/PARTONS.doxyfile.bak
CMakeCache.txt
CMakeFiles/
Makefile
PARTONS_autogen/
cmake_install.cmake
install_manifest.txt
\ No newline at end of file
# BASIC DEFINITIONS ========================================================================
# define minimum version of cmake
cmake_minimum_required(VERSION 2.6)
cmake_minimum_required(VERSION 3.2)
# define project name and its language
project(PARTONS CXX)
# define c++ standard and issue all the warning demanded by this standard
add_definitions(-std=c++98 -pedantic)
if (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
add_definitions(-std=c++11 -pedantic -Wno-vla-extension)
else()
add_definitions(-std=c++11 -pedantic -Wno-vla-extension -fext-numeric-literals)
endif()
set(CMAKE_CXX_STANDARD 11)
if (NOT DEFINED CMAKE_MACOSX_RPATH)
set(CMAKE_MACOSX_RPATH 0)
endif()
# VERSION ==================================================================================
......@@ -17,9 +26,24 @@ file(READ ${CMAKE_SOURCE_DIR}/data/version.txt VERSION_STR)
# strip spaces
string(STRIP ${VERSION_STR} VERSION_STR)
# get major and minor versions
string(REGEX REPLACE "\\.[0-9]*" "" PARTONS_VERSION_MAJOR ${VERSION_STR})
string(REGEX REPLACE "[0-9]*\\." "" PARTONS_VERSION_MINOR ${VERSION_STR})
# get major, minor and patch versions
string(REGEX MATCH "^[0-9]*\\." TMP_STR ${VERSION_STR})
string(REGEX REPLACE "\\." "" PARTONS_VERSION_MAJOR ${TMP_STR})
string(REGEX MATCH "\\.[0-9]*\\." TMP_STR ${VERSION_STR})
string(REGEX REPLACE "\\." "" PARTONS_VERSION_MINOR ${TMP_STR})
string(REGEX MATCH "\\.[0-9]*$" TMP_STR ${VERSION_STR})
string(REGEX REPLACE "\\." "" PARTONS_VERSION_PATCH ${TMP_STR})
message("-- PARTONS version is: " ${PARTONS_VERSION_MAJOR} "." ${PARTONS_VERSION_MINOR} "." ${PARTONS_VERSION_PATCH})
execute_process(COMMAND bash -c "cd ${CMAKE_SOURCE_DIR}; git branch | grep '\*' | cut -d ' ' -f2 2> /dev/null" OUTPUT_VARIABLE PARTONS_GIT_BRANCH)
execute_process(COMMAND bash -c "cd ${CMAKE_SOURCE_DIR}; git rev-parse HEAD 2> /dev/null" OUTPUT_VARIABLE PARTONS_GIT_REVISION)
string(REGEX REPLACE "\n$" "" PARTONS_GIT_BRANCH "${PARTONS_GIT_BRANCH}")
string(REGEX REPLACE "\n$" "" PARTONS_GIT_REVISION "${PARTONS_GIT_REVISION}")
message("-- Git branch (revision): " ${PARTONS_GIT_BRANCH} " (" ${PARTONS_GIT_REVISION} ")")
# configure
configure_file(${CMAKE_SOURCE_DIR}/cmake/Version/PartonsVersion.h_in ${CMAKE_SOURCE_DIR}/include/partons/PartonsVersion.h)
......@@ -34,21 +58,46 @@ set(CMAKE_INCLUDE_CURRENT_DIR ON)
# FIND LIBRARIES ===========================================================================
# find libraries: Qt4
find_package(Qt4 REQUIRED QtCore QtSql QtXmlPatterns)
# add some useful macros and variables
include(${QT_USE_FILE})
add_definitions(${QT_DEFINITIONS})
# find libraries: additional modules
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
# find libraries: SFML
find_package(SFML COMPONENTS system REQUIRED)
# find libraries: Qt
find_package(Qt5 COMPONENTS Core Sql XmlPatterns QUIET)
# find libraries: CLN
find_package(CLN REQUIRED)
if(${Qt5_FOUND})
find_package(Qt5Widgets QUIET)
if (Qt5Widgets_FOUND)
set(QT_VERSION ${Qt5Widgets_VERSION})
else()
set(QT_VERSION "5.??.??")
endif()
set(QT_LIBRARY_CORE "Qt5::Core")
set(QT_LIBRARY_SQL "Qt5::Sql")
set(QT_LIBRARY_XML "Qt5::XmlPatterns")
message("-- Found Qt5: " ${QT_VERSION})
else()
find_package(Qt4 COMPONENTS QtCore QtSql QtXmlPatterns QUIET)
if(${Qt4_FOUND})
set(QT_VERSION ${QT_VERSION_MAJOR}.${QT_VERSION_MINOR}.${QT_VERSION_PATCH})
set(QT_LIBRARY_CORE "Qt4::QtCore")
set(QT_LIBRARY_SQL "Qt4::QtSql")
set(QT_LIBRARY_XML "Qt4::QtXmlPatterns")
message("-- Found Qt4: " ${QT_VERSION})
else()
message(FATAL_ERROR "Neither Qt5 nor Qt4 found in this system")
endif()
endif()
# find libraries: ElementaryUtils
find_package(ElementaryUtils REQUIRED)
......@@ -56,13 +105,63 @@ find_package(ElementaryUtils REQUIRED)
# find libraries: NumA++
find_package(NumA++ REQUIRED)
# find libraries: SFML
find_package(SFML COMPONENTS system REQUIRED)
# find libraries: CLN
find_package(CLN REQUIRED)
# find libraries: GSL
find_package(GSL REQUIRED)
# find libraries: Apfel++
find_package(Apfel++ REQUIRED)
# find libraries: LHAPDF
find_package(LHAPDF REQUIRED)
# directories containing headers
include_directories(${QT_INCLUDE_DIRS} ${SFML_INCLUDE_DIR} ${CLN_INCLUDE_DIR} ${ELEMENTARY_UTILS_INCLUDE_DIR} ${NUMA_INCLUDE_DIR})
include_directories(${QT_INCLUDE_DIRS} ${ElementaryUtils_INCLUDE_DIR} ${NumA++_INCLUDE_DIR} ${SFML_INCLUDE_DIR} ${CLN_INCLUDE_DIR} $(GSL_INCLUDE_DIRS) ${Apfel++_INCLUDE_DIR} ${LHAPDF_INCLUDE_DIR})
include_directories(include)
# ENVIRONMENT VARIABLES ========================================================================
file(READ ${ElementaryUtils_INCLUDE_DIR}/ElementaryUtils/ElementaryUtilsVersion.h VERSION_STR)
string(REGEX MATCH "ELEMENTARY_UTILS_GIT_BRANCH[ \t]*[^\t\n]*\n" ELEMUTILS_BRANCH "${VERSION_STR}")
string(REGEX REPLACE "ELEMENTARY_UTILS_GIT_BRANCH[ \t]*" "" ELEMUTILS_BRANCH "${ELEMUTILS_BRANCH}")
string(REGEX REPLACE "\"" "" ELEMUTILS_BRANCH "${ELEMUTILS_BRANCH}")
string(STRIP ${ELEMUTILS_BRANCH} ELEMUTILS_BRANCH)
string(REGEX MATCH "ELEMENTARY_UTILS_GIT_REVISION[ \t]*[^\t\n]*\n" ELEMUTILS_REVISION ${VERSION_STR})
string(REGEX REPLACE "ELEMENTARY_UTILS_GIT_REVISION[ \t]*" "" ELEMUTILS_REVISION "${ELEMUTILS_REVISION}")
string(REGEX REPLACE "\"" "" ELEMUTILS_REVISION "${ELEMUTILS_REVISION}")
string(STRIP "${ELEMUTILS_REVISION}" ELEMUTILS_REVISION)
file(READ ${NumA++_INCLUDE_DIR}/NumA/NumAVersion.h VERSION_STR)
string(REGEX MATCH "NUMA_GIT_BRANCH[ \t]*[^\t\n]*\n" NUMA_BRANCH ${VERSION_STR})
string(REGEX REPLACE "NUMA_GIT_BRANCH[ \t]*" "" NUMA_BRANCH "${NUMA_BRANCH}")
string(REGEX REPLACE "\"" "" NUMA_BRANCH "${NUMA_BRANCH}")
string(STRIP "${NUMA_BRANCH}" NUMA_BRANCH)
string(REGEX MATCH "NUMA_GIT_REVISION[ \t]*[^\t\n]*\n" NUMA_REVISION ${VERSION_STR})
string(REGEX REPLACE "NUMA_GIT_REVISION[ \t]*" "" NUMA_REVISION "${NUMA_REVISION}")
string(REGEX REPLACE "\"" "" NUMA_REVISION "${NUMA_REVISION}")
string(STRIP "${NUMA_REVISION}" NUMA_REVISION)
file(READ ${CMAKE_SOURCE_DIR}/include/partons/PartonsVersion.h VERSION_STR)
string(REGEX MATCH "PARTONS_GIT_BRANCH[ \t]*[^\t\n]*\n" PARTONS_BRANCH ${VERSION_STR})
string(REGEX REPLACE "PARTONS_GIT_BRANCH[ \t]*" "" PARTONS_BRANCH "${PARTONS_BRANCH}")
string(REGEX REPLACE "\"" "" PARTONS_BRANCH "${PARTONS_BRANCH}")
string(STRIP "${PARTONS_BRANCH}" PARTONS_BRANCH)
string(REGEX MATCH "PARTONS_GIT_REVISION[ \t]*[^\t\n]*\n" PARTONS_REVISION ${VERSION_STR})
string(REGEX REPLACE "PARTONS_GIT_REVISION[ \t]*" "" PARTONS_REVISION "${PARTONS_REVISION}")
string(REGEX REPLACE "\"" "" PARTONS_REVISION "${PARTONS_REVISION}")
string(STRIP "${PARTONS_REVISION}" PARTONS_REVISION)
configure_file("${CMAKE_SOURCE_DIR}/data/config/environment_configuration.dat.in" "${CMAKE_SOURCE_DIR}/data/config/environment_configuration.dat")
# FINALIZE ==================================================================================
# generate list of source files
......@@ -75,7 +174,6 @@ file(
src/*
)
# define target library
set(LIBRARY_OUTPUT_PATH ${CMAKE_CURRENT_SOURCE_DIR}/lib)
......@@ -92,24 +190,32 @@ add_library(
target_link_libraries(
PARTONS
${QT_LIBRARIES}
${SFML_LIBRARIES}
${SFML_LIBRARIES}
${CLN_LIBRARIES}
${CLN_LIBRARIES}
${ELEMENTARY_UTILS_LIBRARIES}
${ElementaryUtils_LIBRARIES}
${NUMA_LIBRARIES}
${NumA++_LIBRARIES}
${GSL_LIBRARIES}
${Apfel++_LIBRARIES}
${LHAPDF_LIBRARIES}
${QT_LIBRARY_CORE}
${QT_LIBRARY_SQL}
${QT_LIBRARY_XML}
)
# install
install(TARGETS PARTONS
RUNTIME DESTINATION bin/PARTONS
LIBRARY DESTINATION lib/PARTONS
ARCHIVE DESTINATION lib/static/PARTONS)
install(DIRECTORY include/ DESTINATION include/PARTONS)
install(DIRECTORY data/ DESTINATION share/PARTONS/)
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib/static)
install(DIRECTORY include/ DESTINATION include)
install(DIRECTORY data DESTINATION share)
# APFEL++
find_program(Apfel++_CONFIG apfelxx-config REQUIRED)
if (Apfel++_CONFIG)
exec_program(${Apfel++_CONFIG}
ARGS --cppflags
OUTPUT_VARIABLE Apfel++_CXX_FLAGS
)
set(Apfel++_CXX_FLAGS ${Apfel++_CXX_FLAGS} CACHE STRING INTERNAL)
exec_program(${Apfel++_CONFIG}
ARGS --ldflags
OUTPUT_VARIABLE Apfel++_LIBRARIES
)
set(Apfel++_LIBRARIES ${Apfel++_LIBRARIES} CACHE STRING INTERNAL)
exec_program(${Apfel++_CONFIG}
ARGS --version
OUTPUT_VARIABLE Apfel++_VERSION
)
set(Apfel++_VERSION ${Apfel++_VERSION} CACHE STRING INTERNAL)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Apfel++ REQUIRED_VARS Apfel++_LIBRARIES VERSION_VAR Apfel++_VERSION)
else(Apfel++_CONFIG)
message(FATAL_ERROR "Apfel++ not found")
endif(Apfel++_CONFIG)
......@@ -26,7 +26,7 @@ function(_cl_get_version _out_major _out_minor _out_patch _cl_version_h)
message(FATAL_ERROR "failed to determine CL_VERSION_PATCHLEVEL, "
"expected a number, got ${${_out_patch}}")
endif()
message(STATUS "found CLN [${_cl_version_h}], version ${${_out_major}}.${${_out_minor}}.${${_out_patch}}")
#message(STATUS "found CLN [${_cl_version_h}], version ${${_out_major}}.${${_out_minor}}.${${_out_patch}}")
set(${_out_major} ${${_out_major}} PARENT_SCOPE)
set(${_out_minor} ${${_out_minor}} PARENT_SCOPE)
set(${_out_patch} ${${_out_patch}} PARENT_SCOPE)
......@@ -36,10 +36,10 @@ set(CLN_FOUND)
set(CLN_INCLUDE_DIR)
set(CLN_LIBRARIES)
include(FindPkgConfig)
if (PKG_CONFIG_FOUND)
pkg_check_modules(_cln cln)
endif()
#include(FindPkgConfig)
#if (PKG_CONFIG_FOUND)
# pkg_check_modules(_cln cln)
#endif()
find_path(CLN_INCLUDE_DIR NAMES cln/cln.h
HINTS ${_cln_INCLUDE_DIRS}
......@@ -74,6 +74,7 @@ if (CLN_INCLUDE_DIR)
endif()
endif()
set(CMAKE_REQUIRED_QUIET TRUE)
# Check if the version embedded into the library is the same as the one in the headers.
if (CLN_INCLUDE_DIR AND CLN_LIBRARIES AND NOT CMAKE_CROSSCOMPILING)
include(CheckCXXSourceRuns)
......
......@@ -2,18 +2,18 @@
#
# Once done this will define
#
# ELEMENTARY_UTILS_FOUND - system has Elementary_Utils lib
# ELEMENTARY_UTILS_LIBRARIES - the path of the library
# ELEMENTARY_UTILS_INCLUDE_DIR - the include directory
# ElementaryUtils_FOUND - system has Elementary_Utils lib
# ElementaryUtils_LIBRARIES - the path of the library
# ElementaryUtils_INCLUDE_DIR - the include directory
if (ELEMENTARY_UTILS_INCLUDE_DIR AND ELEMENTARY_UTILS_LIBRARIES)
if (ElementaryUtils_INCLUDE_DIR AND ElementaryUtils_LIBRARIES)
# in cache already
set(ELEMENTARY_UTILS_FOUND TRUE)
set(ElementaryUtils_FOUND TRUE)
else (ELEMENTARY_UTILS_INCLUDE_DIR AND ELEMENTARY_UTILS_LIBRARIES)
else (ElementaryUtils_INCLUDE_DIR AND ElementaryUtils_LIBRARIES)
find_path(ELEMENTARY_UTILS_INCLUDE_DIR ElementaryUtils/PropertiesManager.h
find_path(ElementaryUtils_INCLUDE_DIR ElementaryUtils/PropertiesManager.h
PATHS
${CMAKE_INSTALL_PREFIX}
${CMAKE_SOURCE_DIR}/../ElementaryUtils
......@@ -24,7 +24,7 @@ else (ELEMENTARY_UTILS_INCLUDE_DIR AND ELEMENTARY_UTILS_LIBRARIES)
PATH_SUFFIXES include/PARTONS include
)
find_library(ELEMENTARY_UTILS_LIBRARIES
find_library(ElementaryUtils_LIBRARIES
NAMES ElementaryUtils
PATHS
${CMAKE_INSTALL_PREFIX}
......@@ -36,7 +36,7 @@ else (ELEMENTARY_UTILS_INCLUDE_DIR AND ELEMENTARY_UTILS_LIBRARIES)
PATH_SUFFIXES lib/PARTONS lib64/PARTONS bin/PARTONS lib lib64 bin)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(ELEMENTARY_UTILS DEFAULT_MSG ELEMENTARY_UTILS_INCLUDE_DIR ELEMENTARY_UTILS_LIBRARIES)
find_package_handle_standard_args(ElementaryUtils DEFAULT_MSG ElementaryUtils_LIBRARIES)
endif(ELEMENTARY_UTILS_INCLUDE_DIR AND ELEMENTARY_UTILS_LIBRARIES)
endif(ElementaryUtils_INCLUDE_DIR AND ElementaryUtils_LIBRARIES)
# LHAPDF
find_program(LHAPDF_CONFIG lhapdf-config REQUIRED)
if (LHAPDF_CONFIG)
exec_program(${LHAPDF_CONFIG}
ARGS --cppflags
OUTPUT_VARIABLE LHAPDF_CXX_FLAGS
)
set(LHAPDF_CXX_FLAGS ${LHAPDF_CXX_FLAGS} CACHE STRING INTERNAL)
exec_program(${LHAPDF_CONFIG}
ARGS --ldflags
OUTPUT_VARIABLE LHAPDF_LIBRARIES
)
set(LHAPDF_LIBRARIES ${LHAPDF_LIBRARIES} CACHE STRING INTERNAL)
exec_program(${LHAPDF_CONFIG}
ARGS --version
OUTPUT_VARIABLE LHAPDF_VERSION
)
set(LHAPDF_VERSION ${LHAPDF_VERSION} CACHE STRING INTERNAL)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(LHAPDF REQUIRED_VARS LHAPDF_LIBRARIES VERSION_VAR LHAPDF_VERSION)
endif(LHAPDF_CONFIG)
......@@ -2,18 +2,18 @@
#
# Once done this will define
#
# NUMA_FOUND - system has NumA++ lib
# NUMA_LIBRARIES - the path of the library
# NUMA_INCLUDE_DIR - the include directory
# NumA++_FOUND - system has NumA++ lib
# NumA++_LIBRARIES - the path of the library
# NumA++_INCLUDE_DIR - the include directory
if (NUMA_INCLUDE_DIR AND NUMA_LIBRARIES)
if (NumA++_INCLUDE_DIR AND NumA++_LIBRARIES)
# in cache already
set(NUMA_FOUND TRUE)
set(NumA++_FOUND TRUE)
else (NUMA_INCLUDE_DIR AND NUMA_LIBRARIES)
else (NumA++_INCLUDE_DIR AND NumA++_LIBRARIES)
find_path(NUMA_INCLUDE_DIR NAMES NumA/integration/Integrator.h NumA++/integration/Integrator.h
find_path(NumA++_INCLUDE_DIR NAMES NumA/integration/Integrator.h NumA++/integration/Integrator.h
PATHS
${CMAKE_INSTALL_PREFIX}
${CMAKE_SOURCE_DIR}/../numa
......@@ -26,7 +26,7 @@ else (NUMA_INCLUDE_DIR AND NUMA_LIBRARIES)
PATH_SUFFIXES include/PARTONS include
)
find_library(NUMA_LIBRARIES
find_library(NumA++_LIBRARIES
NAMES NumA NumA++
PATHS
${CMAKE_INSTALL_PREFIX}
......@@ -40,7 +40,7 @@ else (NUMA_INCLUDE_DIR AND NUMA_LIBRARIES)
PATH_SUFFIXES lib/PARTONS lib64/PARTONS bin/PARTONS lib lib64 bin)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(NUMA DEFAULT_MSG NUMA_INCLUDE_DIR NUMA_LIBRARIES)
find_package_handle_standard_args(NumA++ DEFAULT_MSG NumA++_LIBRARIES)
endif(NUMA_INCLUDE_DIR AND NUMA_LIBRARIES)
endif(NumA++_INCLUDE_DIR AND NumA++_LIBRARIES)
......@@ -365,5 +365,7 @@ endif()
# handle success
if(SFML_FOUND AND NOT SFML_FIND_QUIETLY)
message(STATUS "Found SFML ${SFML_VERSION_MAJOR}.${SFML_VERSION_MINOR}.${SFML_VERSION_PATCH} in ${SFML_INCLUDE_DIR}")
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(SFML REQUIRED_VARS SFML_LIBRARIES VERSION_VAR SFML_VERSION_MINOR)
endif()
set(SFML_VERSION "${SFML_VERSION_MAJOR}-${SFML_VERSION_MINOR}-${SFML_VERSION_PATCH}")
\ No newline at end of file
......@@ -7,7 +7,11 @@
* This file is used to define PARTONS version number and it is set by CMake.
*/
#define PARTONS_VERSION(major,minor) (((major) << 8) + (minor))
#define PARTONS_VERSION(major,minor,patch) (1000000*major + 1000*minor + patch)
#define PARTONS_VERSION_MAJOR @PARTONS_VERSION_MAJOR@
#define PARTONS_VERSION_MINOR @PARTONS_VERSION_MINOR@
#define PARTONS_VERSION_CODE PARTONS_VERSION(PARTONS_VERSION_MAJOR, PARTONS_VERSION_MINOR)
\ No newline at end of file
#define PARTONS_VERSION_PATCH @PARTONS_VERSION_PATCH@
#define PARTONS_VERSION_CODE PARTONS_VERSION(PARTONS_VERSION_MAJOR, PARTONS_VERSION_MINOR, PARTONS_VERSION_PATCH)
#define PARTONS_GIT_BRANCH "@PARTONS_GIT_BRANCH@"
#define PARTONS_GIT_REVISION "@PARTONS_GIT_REVISION@"
\ No newline at end of file
/environment_configuration.dat
......@@ -2,17 +2,14 @@
# The content of this file is stored in the database during the insertion of data,
# so latter one can easily reproduce the used computational environment.
# You can fill the field system with the content of the command "uname -a",
# and fill the other fields with the software versions.
# E.g. g++: 4.9.2
system:
g++:
qt:
smfl:
eigen3:
cln:
gsl:
elementary-utils:
numa:
partons:
system: @CMAKE_SYSTEM_NAME@ @CMAKE_SYSTEM_VERSION@
g++: @CMAKE_CXX_COMPILER_ID@ @CMAKE_CXX_COMPILER_VERSION@
qt: @QT_VERSION@
smfl: @SFML_VERSION@
cln: @CLN_VERSION@
gsl: @GSL_VERSION@
apfel++: @Apfel++_VERSION@
lhapdf: @LHAPDF_VERSION@
elementary-utils: @ELEMUTILS_BRANCH@/@ELEMUTILS_REVISION@
numa: @NUMA_BRANCH@/@NUMA_REVISION@
partons: @PARTONS_BRANCH@/@PARTONS_REVISION@
......@@ -39,5 +39,6 @@ computation.nb.processor = 1
# Maximum size of batch for a given type (in one task several batches may be run in separate threads)
gpd.service.batch.size = 10000
collinear_distribution.service.batch.size = 10000
ccf.service.batch.size = 1000
observable.service.batch.size = 1000
......@@ -10,7 +10,7 @@ scenario_hash_sum VARCHAR(40));
CREATE TABLE environment_configuration (
env_conf_id INTEGER NOT NULL AUTO_INCREMENT PRIMARY KEY,
env_conf_store_date TIMESTAMP,
env_conf_configuration VARCHAR(255),
env_conf_configuration VARCHAR(10000),
env_conf_hash_sum VARCHAR(40));
CREATE TABLE computation (
......@@ -24,6 +24,11 @@ scenario_task_index_number INTEGER,
scenario_id INTEGER NOT NULL,
computation_id INTEGER NOT NULL);
CREATE TABLE collinear_distribution_type (
collinear_distribution_type_id INTEGER NOT NULL PRIMARY KEY,
collinear_distribution_type_short_name VARCHAR(10),
collinear_distribution_type_long_name VARCHAR(255));
CREATE TABLE gpd_type (
gpd_type_id INTEGER NOT NULL PRIMARY KEY,
gpd_type_short_name VARCHAR(10),
......@@ -44,6 +49,16 @@ physical_unit_type_id INTEGER NOT NULL PRIMARY KEY,
physical_unit_type_short_name VARCHAR(10),
physical_unit_type_long_name VARCHAR(255));
CREATE TABLE meson_type (
meson_type_id INTEGER NOT NULL PRIMARY KEY,
meson_type_short_name VARCHAR(10),
meson_type_long_name VARCHAR(255));
CREATE TABLE meson_polarization (
meson_polarization_id INTEGER NOT NULL PRIMARY KEY,
meson_polarization_short_name VARCHAR(10),
meson_polarization_long_name VARCHAR(255));
CREATE VIEW result_info_view AS
SELECT c.computation_id, c.computation_date, sc.scenario_task_index_number, ec.env_conf_hash_sum, s.scenario_hash_sum
FROM computation c
......@@ -52,6 +67,32 @@ INNER JOIN scenario_computation sc ON sc.computation_id = c.computation_id
INNER JOIN scenario s ON sc.scenario_id = s.scenario_id
ORDER BY c.computation_id;
/* === collinear_distribution_type === */
INSERT INTO collinear_distribution_type (collinear_distribution_type_id, collinear_distribution_type_short_name, collinear_distribution_type_long_name)
VALUES ('0', 'UNDEFINED', 'UNDEFINED');
INSERT INTO collinear_distribution_type (collinear_distribution_type_id, collinear_distribution_type_short_name, collinear_distribution_type_long_name)
VALUES ('1', 'ALL', 'ALL');
INSERT INTO collinear_distribution_type (collinear_distribution_type_id, collinear_distribution_type_short_name, collinear_distribution_type_long_name)
VALUES ('2', 'UnpolPDF', 'UnpolPDF');
INSERT INTO collinear_distribution_type (collinear_distribution_type_id, collinear_distribution_type_short_name, collinear_distribution_type_long_name)
VALUES ('3', 'PolPDF', 'PolPDF');
INSERT INTO collinear_distribution_type (collinear_distribution_type_id, collinear_distribution_type_short_name, collinear_distribution_type_long_name)
VALUES ('4', 'TransPDF', 'TransPDF');
INSERT INTO collinear_distribution_type (collinear_distribution_type_id, collinear_distribution_type_short_name, collinear_distribution_type_long_name)
VALUES ('5', 'UnpolFF', 'UnpolFF');
INSERT INTO collinear_distribution_type (collinear_distribution_type_id, collinear_distribution_type_short_name, collinear_distribution_type_long_name)
VALUES ('6', 'PolFF', 'PolFF');
INSERT INTO collinear_distribution_type (collinear_distribution_type_id, collinear_distribution_type_short_name, collinear_distribution_type_long_name)
VALUES ('7', 'TransFF', 'TransFF');
/* === gpd_type === */
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
......@@ -72,6 +113,45 @@ VALUES ('4', 'Ht', 'Ht');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('5', 'Et', 'Et');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('6', 'HTrans', 'HTrans');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('7', 'ETrans', 'ETrans');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('8', 'HtTrans', 'HtTrans');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('9', 'EtTrans', 'EtTrans');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('10', 'H3p', 'H3p');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('11', 'E3p', 'E3p');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('12', 'Ht3p', 'Ht3p');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('13', 'Et3p', 'Et3p');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('14', 'H3m', 'H3m');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('15', 'E3m', 'E3m');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('16', 'Ht3m', 'Ht3m');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('17', 'Et3m', 'Et3m');
INSERT INTO gpd_type (gpd_type_id, gpd_type_short_name, gpd_type_long_name)
VALUES ('18', 'EbarTrans', 'EbarTrans');
/* === quark_flavor === */
INSERT INTO quark_flavor (quark_flavor_id, quark_flavor_short_name, quark_flavor_long_name)
......@@ -241,3 +321,50 @@ VALUES ('38', 'rad', 'RAD');
INSERT INTO physical_unit_type (physical_unit_type_id, physical_unit_type_short_name, physical_unit_type_long_name)
VALUES ('39', 'mrad', 'MRAD');
/* === meson_type === */
INSERT INTO meson_type (meson_type_id, meson_type_short_name, meson_type_long_name)
VALUES ('0', 'UNDEFINED', 'UNDEFINED');
INSERT INTO meson_type (meson_type_id, meson_type_short_name, meson_type_long_name)
VALUES ('1', 'rho-', 'RHOMINUS');
INSERT INTO meson_type (meson_type_id, meson_type_short_name, meson_type_long_name)
VALUES ('2', 'rho0', 'RHO0');
INSERT INTO meson_type (meson_type_id, meson_type_short_name, meson_type_long_name)
VALUES ('3', 'rho+', 'RHOPLUS');
INSERT INTO meson_type (meson_type_id, meson_type_short_name, meson_type_long_name)
VALUES ('4', 'omega', 'OMEGA');
INSERT INTO meson_type (meson_type_id, meson_type_short_name, meson_type_long_name)
VALUES ('5', 'phi', 'PHI');
INSERT INTO meson_type (meson_type_id, meson_type_short_name, meson_type_long_name)
VALUES ('6', 'J/Psi', 'JPSI');
INSERT INTO meson_type (meson_type_id, meson_type_short_name, meson_type_long_name)
VALUES ('7', 'Upsilon', 'UPSILON');
INSERT INTO meson_type (meson_type_id, meson_type_short_name, meson_type_long_name)
VALUES ('8', 'pi-', 'PIMINUS');