Skip to content
Snippets Groups Projects
Commit cb58a245 authored by 数学の武士's avatar 数学の武士
Browse files

Function name fixes

parent f4ee4655
Branches
Tags
No related merge requests found
......@@ -58,9 +58,9 @@ if(USE_CXX)
endif(USE_CXX)
set(SOURCES_F
srcF/sfx_io.f90
srcF/sfx_data.f90
srcF/sfx_common.f90
srcF/sfx_io.f90
srcF/sfx_config.f90
srcF/sfx_esm.f90
srcF/sfx_esm_param.f90
......@@ -87,7 +87,7 @@ set(HEADERS_F
if(USE_CXX)
set(SOURCES_C
srcC/sfx_call_cxx.c
srcC/sfx_model_compute_flux_c.c
)
set(HEADERS_C
......@@ -99,7 +99,7 @@ if(USE_CXX)
srcCXX/model_base.cpp
srcCXX/sfx_esm.cpp
srcCXX/sfx_sheba.cpp
srcCXX/sfx_call_class_func.cpp
srcCXX/sfx_model_compute_flux_cxx.cpp
)
set(HEADERS_CXX
includeCU/sfx_surface.cuh
......@@ -109,7 +109,7 @@ if(USE_CXX)
includeCXX/model_base.h
includeCXX/sfx_esm.h
includeCXX/sfx_sheba.h
includeCXX/sfx_call_class_func.h
includeCXX/sfx_model_compute_flux_cxx.h
)
list(APPEND HEADERS_DIRS includeCU/)
list(APPEND HEADERS_DIRS includeCXX/)
......
......@@ -5,7 +5,7 @@
extern "C" {
#endif
void surf_flux_esm_CXX(struct sfxDataVecTypeC* sfx,
void esm_compute_flux_cxx(struct sfxDataVecTypeC* sfx,
struct meteoDataVecTypeC* meteo,
const struct sfx_esm_param_C* model_param,
const struct sfx_surface_param* surface_param,
......@@ -13,7 +13,7 @@ extern "C" {
const struct sfx_phys_constants* constants,
const int grid_size);
void surf_flux_sheba_CXX(struct sfxDataVecTypeC* sfx,
void sheba_compute_flux_cxx(struct sfxDataVecTypeC* sfx,
struct meteoDataVecTypeC* meteo,
const struct sfx_sheba_param_C* model_param,
const struct sfx_surface_param* surface_param,
......
#include <stdlib.h>
#include <stdio.h>
#include "sfx_call_class_func.h"
#include "sfx_model_compute_flux_cxx.h"
// #include "../includeC/sfx_call_cxx.h"
// -------------------------------------------------------------------------- //
void get_surface_fluxes_esm (struct sfxDataVecTypeC* sfx,
void esm_compute_flux_c (struct sfxDataVecTypeC* sfx,
struct meteoDataVecTypeC* meteo,
const struct sfx_esm_param_C* model_param,
const struct sfx_surface_param* surface_param,
......@@ -12,10 +12,10 @@ void get_surface_fluxes_esm (struct sfxDataVecTypeC* sfx,
const struct sfx_phys_constants* constants,
const int *grid_size)
{
surf_flux_esm_CXX(sfx, meteo, model_param, surface_param, numerics, constants, *grid_size);
esm_compute_flux_cxx(sfx, meteo, model_param, surface_param, numerics, constants, *grid_size);
}
void get_surface_fluxes_sheba (struct sfxDataVecTypeC* sfx,
void sheba_compute_flux_c (struct sfxDataVecTypeC* sfx,
struct meteoDataVecTypeC* meteo,
const struct sfx_sheba_param_C* model_param,
const struct sfx_surface_param* surface_param,
......@@ -23,5 +23,5 @@ void get_surface_fluxes_sheba (struct sfxDataVecTypeC* sfx,
const struct sfx_phys_constants* constants,
const int *grid_size)
{
surf_flux_sheba_CXX(sfx, meteo, model_param, surface_param, numerics, constants, *grid_size);
sheba_compute_flux_cxx(sfx, meteo, model_param, surface_param, numerics, constants, *grid_size);
}
\ No newline at end of file
#include <stdlib.h>
#include <stdio.h>
#include "sfx_call_class_func.h"
#include "sfx_model_compute_flux_cxx.h"
#include "sfx_esm.h"
#include "sfx_sheba.h"
#include <vector>
// -------------------------------------------------------------------------- //
void surf_flux_esm_CXX (sfxDataVecTypeC* sfx,
void esm_compute_flux_cxx (sfxDataVecTypeC* sfx,
meteoDataVecTypeC* meteo,
const sfx_esm_param_C* model_param,
const sfx_surface_param* surface_param,
......@@ -23,7 +23,7 @@ void surf_flux_esm_CXX (sfxDataVecTypeC* sfx,
#endif
}
void surf_flux_sheba_CXX (sfxDataVecTypeC* sfx,
void sheba_compute_flux_cxx (sfxDataVecTypeC* sfx,
meteoDataVecTypeC* meteo,
const sfx_sheba_param_C* model_param,
const sfx_surface_param* surface_param,
......
......@@ -56,7 +56,8 @@ module sfx_esm
end type
INTERFACE
SUBROUTINE get_surface_fluxes_esm(sfx, meteo, model_param, surface_param, numerics, constants, grid_size) BIND(C)
SUBROUTINE esm_compute_flux_f(sfx, meteo, model_param, surface_param, numerics, constants, grid_size) BIND(C, &
name="esm_compute_flux_c")
use sfx_data
use, intrinsic :: ISO_C_BINDING, ONLY: C_INT, C_PTR
Import :: sfx_esm_param_C, sfx_esm_numericsType_C
......@@ -68,7 +69,7 @@ module sfx_esm
type(sfx_surface_param) :: surface_param
type(sfx_esm_numericsType_C) :: numerics
type(sfx_phys_constants) :: constants
END SUBROUTINE get_surface_fluxes_esm
END SUBROUTINE esm_compute_flux_f
END INTERFACE
#endif
......@@ -130,7 +131,7 @@ contains
meteo_c_ptr = C_LOC(meteo_c)
sfx_c_ptr = C_LOC(sfx_c)
call get_surface_fluxes_esm(sfx_c_ptr, meteo_c_ptr, model_param, surface_param, numerics_c, phys_constants, n)
call esm_compute_flux_f(sfx_c_ptr, meteo_c_ptr, model_param, surface_param, numerics_c, phys_constants, n)
#else
do i = 1, n
#ifdef SFX_FORCE_DEPRECATED_ESM_CODE
......
......@@ -55,7 +55,8 @@ module sfx_sheba
end type
INTERFACE
SUBROUTINE get_surface_fluxes_sheba(sfx, meteo, model_param, surface_param, numerics, constants, grid_size) BIND(C)
SUBROUTINE sheba_compute_flux_f(sfx, meteo, model_param, surface_param, numerics, constants, grid_size) BIND(C, &
name="sheba_compute_flux_c")
use sfx_data
use, intrinsic :: ISO_C_BINDING, ONLY: C_INT, C_PTR
Import :: sfx_sheba_param_C, sfx_sheba_numericsType_C
......@@ -67,7 +68,7 @@ module sfx_sheba
type(sfx_surface_param) :: surface_param
type(sfx_sheba_numericsType_C) :: numerics
type(sfx_phys_constants) :: constants
END SUBROUTINE get_surface_fluxes_sheba
END SUBROUTINE sheba_compute_flux_f
END INTERFACE
#endif
......@@ -129,7 +130,7 @@ contains
meteo_c_ptr = C_LOC(meteo_c)
sfx_c_ptr = C_LOC(sfx_c)
call get_surface_fluxes_sheba(sfx_c_ptr, meteo_c_ptr, model_param, surface_param, numerics_c, phys_constants, n)
call sheba_compute_flux_f(sfx_c_ptr, meteo_c_ptr, model_param, surface_param, numerics_c, phys_constants, n)
#else
do i = 1, n
meteo_cell = meteoDataType(&
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment