From 5de5e5e8892243a0c993f4a395940e04e05ba1b0 Mon Sep 17 00:00:00 2001 From: EamonnGlynn Date: Mon, 20 May 2024 16:02:30 -0400 Subject: [PATCH 1/8] Added StrainRate to c.cpp, c.h, mesh.cpp and mesh.hpp --- src/pmpo_c.cpp | 44 +++++++++++++++++++++++++++++++++++++++++++- src/pmpo_c.h | 2 ++ src/pmpo_mesh.cpp | 4 ++++ src/pmpo_mesh.hpp | 12 +++++++++--- 4 files changed, 58 insertions(+), 4 deletions(-) diff --git a/src/pmpo_c.cpp b/src/pmpo_c.cpp index f4d57aa1..5f8cc451 100644 --- a/src/pmpo_c.cpp +++ b/src/pmpo_c.cpp @@ -673,7 +673,7 @@ void polympo_setMeshOnSurfDispIncr_f(MPMesh_ptr p_mpmesh, const int nComps, cons //copy the host array to the device Kokkos::parallel_for("set mesh dispIncr", nVertices, KOKKOS_LAMBDA(const int iVtx){ vtxField(iVtx,0) = array_d(0,iVtx); - vtxField(iVtx,1) = array_d(1,iVtx); + vtxField(iVtx,1) = array_d(1,iVtx);wait but }); } @@ -699,6 +699,48 @@ void polympo_getMeshOnSurfDispIncr_f(MPMesh_ptr p_mpmesh, const int nComps, cons Kokkos::deep_copy(arrayHost, array_d); } +void polympo_setMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, const double *xNormal, const double *yNormal, const double *zNormal, const double *xyShear, const double *xzShear, const double *yzShear){ + //check mpMesh is valid + checkMPMeshValid(p_mpmesh); + auto p_mesh = ((polyMPO::MPMesh*)p_mpmesh)->p_mesh; + + //check the size + PMT_ALWAYS_ASSERT(p_mesh->getNumVertices()==nVertices); + + auto strainRate = p_mesh->getMeshField(); + auto h_strainRate = Kokkos::create_mirror_view(strainRate); + for(int i = 0; i < nVertices; i++){ + h_strainRate(i,0) = xNormal[i]; + h_strainRate(i,1) = yNormal[i]; + h_strainRate(i,2) = zNormal[i]; + h_strainRate(i,3) = xyShear[i]; + h_strainRate(i,4) = xzShear[i]; + h_strainRate(i,5) = yzShear[i]; + } + Kokkos::deep_copy(strainRate, h_strainRate); +} + +void polympo_getMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, double *xNormal, double *yNormal, double *zNormal, double *xyShear, double *xzShear, double *yzShear){ + //check mpMesh is valid + checkMPMeshValid(p_mpmesh); + auto p_mesh = ((polyMPO::MPMesh*)p_mpmesh)->p_mesh; + + //check the size + PMT_ALWAYS_ASSERT(p_mesh->getNumVertices()==nVertices); + + auto strainRate = p_mesh->getMeshField(); + auto h_strainRate = Kokkos::create_mirror_view_and_copy(Kokkos::HostSpace(), strainRate); + for(int i = 0; i < nVertices; i++){ + xNormal[i] = h_strainRate(i,0); + yNormal[i] = h_strainRate(i,1); + zNormal[i] = h_strainRate(i,2); + xyShear[i] = h_strainRate(i,3); + xzShear[i] = h_strainRate(i,4); + yzShear[i] = h_strainRate(i,5); + } +} + + void polympo_push_f(MPMesh_ptr p_mpmesh){ checkMPMeshValid(p_mpmesh); ((polyMPO::MPMesh*)p_mpmesh) ->push(); diff --git a/src/pmpo_c.h b/src/pmpo_c.h index c310c05c..f53476af 100644 --- a/src/pmpo_c.h +++ b/src/pmpo_c.h @@ -62,6 +62,8 @@ void polympo_setMeshOnSurfVeloIncr_f(MPMesh_ptr p_mpmesh, const int nComps, cons void polympo_getMeshOnSurfVeloIncr_f(MPMesh_ptr p_mpmesh, const int nComps, const int nVertices, double* array);//vec2d void polympo_setMeshOnSurfDispIncr_f(MPMesh_ptr p_mpmesh, const int nComps, const int nVertices, const double* array);//vec2d void polympo_getMeshOnSurfDispIncr_f(MPMesh_ptr p_mpmesh, const int nComps, const int nVertices, double* array);//vec2d +void polympo_setMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, const double* xNormal, const double* yNormal, const double* zNormal, const double* xyShear, const double* xzShear, const double* yzShear); +void polympo_getMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, double* xNormal, double* yNormal, double* zNormal, double* xyShear, double* xzShear, double* yzShear); // calculations void polympo_push_f(MPMesh_ptr p_mpmesh); diff --git a/src/pmpo_mesh.cpp b/src/pmpo_mesh.cpp index 78b3a7be..3bf9fb76 100644 --- a/src/pmpo_mesh.cpp +++ b/src/pmpo_mesh.cpp @@ -37,6 +37,10 @@ namespace polyMPO{ auto vtxRotLatLonIncrMapEntry = meshFields2TypeAndString.at(MeshF_RotLatLonIncr); PMT_ALWAYS_ASSERT(vtxRotLatLonIncrMapEntry.first == MeshFType_VtxBased); vtxRotLatLonIncr_ = DoubleVec2dView(vtxRotLatLonIncrMapEntry.second,numVtxs_); + + auto vtxStrainRateMapEntry = meshFields2TypeAndString.at(MeshF_StrainRate); + PMT_ALWAYS_ASSERT(vtxStrainRateMapEntry.first == MeshFType_VtxBased); + vtxStrainRate_ = DoubleSymMat3dView(vtxStrainRateMapEntry.second,numVtxs_); } void Mesh::computeRotLatLonIncr(){ diff --git a/src/pmpo_mesh.hpp b/src/pmpo_mesh.hpp index 3f94256a..20172861 100644 --- a/src/pmpo_mesh.hpp +++ b/src/pmpo_mesh.hpp @@ -25,7 +25,8 @@ enum MeshFieldIndex{ MeshF_Vel, MeshF_OnSurfVeloIncr, MeshF_OnSurfDispIncr, - MeshF_RotLatLonIncr + MeshF_RotLatLonIncr, + MeshF_StrainRate }; enum MeshFieldType{ MeshFType_Invalid = -2, @@ -39,10 +40,11 @@ const std::map Date: Mon, 20 May 2024 16:35:37 -0400 Subject: [PATCH 2/8] added a coma in a list --- src/pmpo_mesh.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pmpo_mesh.hpp b/src/pmpo_mesh.hpp index 20172861..b6d0ee31 100644 --- a/src/pmpo_mesh.hpp +++ b/src/pmpo_mesh.hpp @@ -43,7 +43,7 @@ const std::map Date: Mon, 20 May 2024 16:46:11 -0400 Subject: [PATCH 3/8] fixed naming error --- src/pmpo_c.cpp | 2 +- src/pmpo_mesh.hpp | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/pmpo_c.cpp b/src/pmpo_c.cpp index 5f8cc451..a8f64a96 100644 --- a/src/pmpo_c.cpp +++ b/src/pmpo_c.cpp @@ -673,7 +673,7 @@ void polympo_setMeshOnSurfDispIncr_f(MPMesh_ptr p_mpmesh, const int nComps, cons //copy the host array to the device Kokkos::parallel_for("set mesh dispIncr", nVertices, KOKKOS_LAMBDA(const int iVtx){ vtxField(iVtx,0) = array_d(0,iVtx); - vtxField(iVtx,1) = array_d(1,iVtx);wait but + vtxField(iVtx,1) = array_d(1,iVtx); }); } diff --git a/src/pmpo_mesh.hpp b/src/pmpo_mesh.hpp index b6d0ee31..cfc5ac79 100644 --- a/src/pmpo_mesh.hpp +++ b/src/pmpo_mesh.hpp @@ -26,7 +26,7 @@ enum MeshFieldIndex{ MeshF_OnSurfVeloIncr, MeshF_OnSurfDispIncr, MeshF_RotLatLonIncr, - MeshF_StrainRate + MeshF_VtxStrainRate }; enum MeshFieldType{ MeshFType_Invalid = -2, @@ -44,7 +44,7 @@ const std::map Date: Mon, 20 May 2024 16:48:02 -0400 Subject: [PATCH 4/8] sam issue as previous commit but in a different file --- src/pmpo_mesh.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pmpo_mesh.cpp b/src/pmpo_mesh.cpp index 3bf9fb76..2f7ae6e4 100644 --- a/src/pmpo_mesh.cpp +++ b/src/pmpo_mesh.cpp @@ -38,7 +38,7 @@ namespace polyMPO{ PMT_ALWAYS_ASSERT(vtxRotLatLonIncrMapEntry.first == MeshFType_VtxBased); vtxRotLatLonIncr_ = DoubleVec2dView(vtxRotLatLonIncrMapEntry.second,numVtxs_); - auto vtxStrainRateMapEntry = meshFields2TypeAndString.at(MeshF_StrainRate); + auto vtxStrainRateMapEntry = meshFields2TypeAndString.at(MeshF_VtxStrainRate); PMT_ALWAYS_ASSERT(vtxStrainRateMapEntry.first == MeshFType_VtxBased); vtxStrainRate_ = DoubleSymMat3dView(vtxStrainRateMapEntry.second,numVtxs_); } From 3f4c3b483454ac844236c1cb3b88924214ed09b2 Mon Sep 17 00:00:00 2001 From: Eamonn Date: Mon, 27 May 2024 17:48:46 -0400 Subject: [PATCH 5/8] Added test cases in fortan --- src/pmpo_fortran.f90 | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/src/pmpo_fortran.f90 b/src/pmpo_fortran.f90 index d1d14a35..0162c4fc 100644 --- a/src/pmpo_fortran.f90 +++ b/src/pmpo_fortran.f90 @@ -537,6 +537,32 @@ subroutine polympo_getMeshOnSurfDispIncr(mpMesh, nComps, nVertices, array) & type(c_ptr), value :: array end subroutine !--------------------------------------------------------------------------- + !> @brief set the verte strain rate from a host array + !> @param mpmesh(in/out) MPMesh object + !> @param nVertices(in) numVertices + !> @param x/y/zNormal(in) input mesh normal strain rate 1D array (numVtx) + !> @param xy/xz/yzShear(in) input mesh shear strain rate 1D array (numVtx) + subroutine polympo_setMeshVtxStrainRate(mpMesh, nVertices, xNormal, yNormal, zNormal, xyShear, xzShear, yzShear) & + bind(C, NAME='polympo_setMeshVtxStrainRate_f') + use :: iso_c_binding + type(c_ptr), value :: mpMesh + integer(c_int), value :: nVertices + type(c_ptr), intent(in), value :: xNormal, yNormal, zNormal, xyShear, xzShear, yzShear + end subroutine + !--------------------------------------------------------------------------- + !> @brief get the verte strain rate from polyMPO + !> @param mpmesh(in/out) MPMesh object + !> @param nVertices(in) numVertices + !> @param x/y/zNormal(in/out) output mesh normal strain rate 1D array (numVtx), allocated by user + !> @param xy/xz/yzShear(in/out) output mesh shear strain rate 1D array (numVtx), allocated by user + subroutine polympo_getMeshVtxStrainRate(mpMesh, nVertices, xNormal, yNormal, zNormal, xyShear, xzShear, yzShear) & + bind(C, NAME='polympo_getMeshVtxStrainRate_f') + use :: iso_c_binding + type(c_ptr), value :: mpMesh + integer(c_int), value :: nVertices + type(c_ptr), value :: xNormal, yNormal, zNormal, xyShear, xzShear, yzShear + end subroutine + !--------------------------------------------------------------------------- !> @brief calculate the MPs from given mesh vertices rotational latitude !> longitude, update the MP slices !> MPs MUST have rotated flag set to True(>0) From efb2d77b4354874a7bf47a5e28cc07d7cff603a8 Mon Sep 17 00:00:00 2001 From: EamonnGlynn Date: Sat, 1 Jun 2024 18:59:18 -0400 Subject: [PATCH 6/8] Added test cases for VtxStrainRate functions --- test/testFortran.f90 | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/test/testFortran.f90 b/test/testFortran.f90 index 8bf0f367..948c6815 100644 --- a/test/testFortran.f90 +++ b/test/testFortran.f90 @@ -139,6 +139,23 @@ program main call assert((xArray(i) .eq. i+value1), "Assert MeshVel u-component Velocity Fail") call assert((yArray(i) .eq. value2-i), "Assert MeshVel v-component Velocity Fail") end do + + !VtxStrainRate needs 6 arrays, using x,y,zArray for all + do i = 1, nverts + xArray(i) = i + value1 + yArray(i) = value2 - i + zArray(i) = i + (value1 * value2) + end do + call polympo_setMeshVtxStrainRate(mpMesh, nverts, c_loc(xArray),c_loc(yArray),c_loc(zArray),c_loc(xArray),c_loc(yArray),c_loc(zArray)) + xArray = -1 + yArray = -1 + zArray = -1 + call polympo_getMeshVtxStrainRate(mpMesh, nverts, c_loc(xArray),c_loc(yArray),c_loc(zArray),c_loc(xArray),c_loc(yArray),c_loc(zArray)) + do i = 1, nverts + call assert((xArray(i) .eq. i+value1), "Assert MeshVtxStrainRate xx-component Velocity Fail") + call assert((yArray(i) .eq. value2-i), "Assert MeshVtxStrainRate yy-component Velocity Fail") + call assert((zArray(i) .eq. i+(value1*value2)), "Assert MeshVtxStrainRate zz-component Velocity Fail") + end do deallocate(MParray) deallocate(Mesharray) From 4b2f0503d0d6b5b24f7530c2e79a6ca693534c32 Mon Sep 17 00:00:00 2001 From: EamonnGlynn Date: Sat, 1 Jun 2024 19:45:08 -0400 Subject: [PATCH 7/8] fixed line length in fortran file --- test/testFortran.f90 | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/test/testFortran.f90 b/test/testFortran.f90 index 948c6815..c15a25c8 100644 --- a/test/testFortran.f90 +++ b/test/testFortran.f90 @@ -140,21 +140,26 @@ program main call assert((yArray(i) .eq. value2-i), "Assert MeshVel v-component Velocity Fail") end do - !VtxStrainRate needs 6 arrays, using x,y,zArray for all + !VtxStrainRate needs 6 arrays, using x,y,zArrays for all 6 do i = 1, nverts xArray(i) = i + value1 yArray(i) = value2 - i zArray(i) = i + (value1 * value2) end do - call polympo_setMeshVtxStrainRate(mpMesh, nverts, c_loc(xArray),c_loc(yArray),c_loc(zArray),c_loc(xArray),c_loc(yArray),c_loc(zArray)) + call polympo_setMeshVtxStrainRate(mpMesh, nverts, c_loc(xArray),c_loc(yArray), & + c_loc(zArray),c_loc(xArray),c_loc(yArray),c_loc(zArray)) xArray = -1 yArray = -1 zArray = -1 - call polympo_getMeshVtxStrainRate(mpMesh, nverts, c_loc(xArray),c_loc(yArray),c_loc(zArray),c_loc(xArray),c_loc(yArray),c_loc(zArray)) + call polympo_getMeshVtxStrainRate(mpMesh, nverts, c_loc(xArray),c_loc(yArray), & + c_loc(zArray),c_loc(xArray),c_loc(yArray),c_loc(zArray)) do i = 1, nverts - call assert((xArray(i) .eq. i+value1), "Assert MeshVtxStrainRate xx-component Velocity Fail") - call assert((yArray(i) .eq. value2-i), "Assert MeshVtxStrainRate yy-component Velocity Fail") - call assert((zArray(i) .eq. i+(value1*value2)), "Assert MeshVtxStrainRate zz-component Velocity Fail") + call assert((xArray(i) .eq. i+value1), & + "Assert MeshVtxStrainRate xx-component Velocity Fail") + call assert((yArray(i) .eq. value2-i), & + "Assert MeshVtxStrainRate yy-component Velocity Fail") + call assert((zArray(i) .eq. i+(value1*value2)), & + "Assert MeshVtxStrainRate zz-component Velocity Fail") end do deallocate(MParray) From 3dfd84240cad3013a6917007e04a8a7c2b8e13c5 Mon Sep 17 00:00:00 2001 From: Eamonn Date: Sun, 9 Jun 2024 17:07:24 -0400 Subject: [PATCH 8/8] fixed indentation, change strain rate functions and tests to take 1 2d array instead of 6 1d arrays --- src/pmpo_c.cpp | 29 +++++++++++----------- src/pmpo_c.h | 4 +-- src/pmpo_fortran.f90 | 14 +++++------ src/pmpo_mesh.hpp | 4 +-- test/testFortran.f90 | 58 +++++++++++++++++++++----------------------- 5 files changed, 52 insertions(+), 57 deletions(-) diff --git a/src/pmpo_c.cpp b/src/pmpo_c.cpp index a8f64a96..a4e97fed 100644 --- a/src/pmpo_c.cpp +++ b/src/pmpo_c.cpp @@ -699,7 +699,8 @@ void polympo_getMeshOnSurfDispIncr_f(MPMesh_ptr p_mpmesh, const int nComps, cons Kokkos::deep_copy(arrayHost, array_d); } -void polympo_setMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, const double *xNormal, const double *yNormal, const double *zNormal, const double *xyShear, const double *xzShear, const double *yzShear){ +void polympo_setMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, const double** forceArray){ + //forceArray has 6 entries, each entry must have nVertices values //check mpMesh is valid checkMPMeshValid(p_mpmesh); auto p_mesh = ((polyMPO::MPMesh*)p_mpmesh)->p_mesh; @@ -710,17 +711,17 @@ void polympo_setMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, co auto strainRate = p_mesh->getMeshField(); auto h_strainRate = Kokkos::create_mirror_view(strainRate); for(int i = 0; i < nVertices; i++){ - h_strainRate(i,0) = xNormal[i]; - h_strainRate(i,1) = yNormal[i]; - h_strainRate(i,2) = zNormal[i]; - h_strainRate(i,3) = xyShear[i]; - h_strainRate(i,4) = xzShear[i]; - h_strainRate(i,5) = yzShear[i]; + h_strainRate(i,0) = forceArray[0][i]; + h_strainRate(i,1) = forceArray[1][i]; + h_strainRate(i,2) = forceArray[2][i]; + h_strainRate(i,3) = forceArray[3][i]; + h_strainRate(i,4) = forceArray[4][i]; + h_strainRate(i,5) = forceArray[5][i]; } Kokkos::deep_copy(strainRate, h_strainRate); } -void polympo_getMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, double *xNormal, double *yNormal, double *zNormal, double *xyShear, double *xzShear, double *yzShear){ +void polympo_getMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, double** forceArray){ //check mpMesh is valid checkMPMeshValid(p_mpmesh); auto p_mesh = ((polyMPO::MPMesh*)p_mpmesh)->p_mesh; @@ -731,12 +732,12 @@ void polympo_getMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, do auto strainRate = p_mesh->getMeshField(); auto h_strainRate = Kokkos::create_mirror_view_and_copy(Kokkos::HostSpace(), strainRate); for(int i = 0; i < nVertices; i++){ - xNormal[i] = h_strainRate(i,0); - yNormal[i] = h_strainRate(i,1); - zNormal[i] = h_strainRate(i,2); - xyShear[i] = h_strainRate(i,3); - xzShear[i] = h_strainRate(i,4); - yzShear[i] = h_strainRate(i,5); + forceArray[0][i] = h_strainRate(i,0); + forceArray[1][i] = h_strainRate(i,1); + forceArray[2][i] = h_strainRate(i,2); + forceArray[3][i] = h_strainRate(i,3); + forceArray[4][i] = h_strainRate(i,4); + forceArray[5][i] = h_strainRate(i,5); } } diff --git a/src/pmpo_c.h b/src/pmpo_c.h index f53476af..b5314034 100644 --- a/src/pmpo_c.h +++ b/src/pmpo_c.h @@ -62,8 +62,8 @@ void polympo_setMeshOnSurfVeloIncr_f(MPMesh_ptr p_mpmesh, const int nComps, cons void polympo_getMeshOnSurfVeloIncr_f(MPMesh_ptr p_mpmesh, const int nComps, const int nVertices, double* array);//vec2d void polympo_setMeshOnSurfDispIncr_f(MPMesh_ptr p_mpmesh, const int nComps, const int nVertices, const double* array);//vec2d void polympo_getMeshOnSurfDispIncr_f(MPMesh_ptr p_mpmesh, const int nComps, const int nVertices, double* array);//vec2d -void polympo_setMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, const double* xNormal, const double* yNormal, const double* zNormal, const double* xyShear, const double* xzShear, const double* yzShear); -void polympo_getMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, double* xNormal, double* yNormal, double* zNormal, double* xyShear, double* xzShear, double* yzShear); +void polympo_setMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, const double** forceArray); +void polympo_getMeshVtxStrainRate_f(MPMesh_ptr p_mpmesh, const int nVertices, double** forceArray); // calculations void polympo_push_f(MPMesh_ptr p_mpmesh); diff --git a/src/pmpo_fortran.f90 b/src/pmpo_fortran.f90 index 0162c4fc..b49c0202 100644 --- a/src/pmpo_fortran.f90 +++ b/src/pmpo_fortran.f90 @@ -540,27 +540,25 @@ subroutine polympo_getMeshOnSurfDispIncr(mpMesh, nComps, nVertices, array) & !> @brief set the verte strain rate from a host array !> @param mpmesh(in/out) MPMesh object !> @param nVertices(in) numVertices - !> @param x/y/zNormal(in) input mesh normal strain rate 1D array (numVtx) - !> @param xy/xz/yzShear(in) input mesh shear strain rate 1D array (numVtx) - subroutine polympo_setMeshVtxStrainRate(mpMesh, nVertices, xNormal, yNormal, zNormal, xyShear, xzShear, yzShear) & + !> @param forceArray(in) input mesh strain rate 2D array (6,numVtx) + subroutine polympo_setMeshVtxStrainRate(mpMesh, nVertices, forceArray) & bind(C, NAME='polympo_setMeshVtxStrainRate_f') use :: iso_c_binding type(c_ptr), value :: mpMesh integer(c_int), value :: nVertices - type(c_ptr), intent(in), value :: xNormal, yNormal, zNormal, xyShear, xzShear, yzShear + type(c_ptr), intent(in), value :: forceArray end subroutine !--------------------------------------------------------------------------- !> @brief get the verte strain rate from polyMPO !> @param mpmesh(in/out) MPMesh object !> @param nVertices(in) numVertices - !> @param x/y/zNormal(in/out) output mesh normal strain rate 1D array (numVtx), allocated by user - !> @param xy/xz/yzShear(in/out) output mesh shear strain rate 1D array (numVtx), allocated by user - subroutine polympo_getMeshVtxStrainRate(mpMesh, nVertices, xNormal, yNormal, zNormal, xyShear, xzShear, yzShear) & + !> @param forceArray(in/out) output mesh strain rate 2D array (6,numVtx) + subroutine polympo_getMeshVtxStrainRate(mpMesh, nVertices, forceArray) & bind(C, NAME='polympo_getMeshVtxStrainRate_f') use :: iso_c_binding type(c_ptr), value :: mpMesh integer(c_int), value :: nVertices - type(c_ptr), value :: xNormal, yNormal, zNormal, xyShear, xzShear, yzShear + type(c_ptr), value :: forceArray end subroutine !--------------------------------------------------------------------------- !> @brief calculate the MPs from given mesh vertices rotational latitude diff --git a/src/pmpo_mesh.hpp b/src/pmpo_mesh.hpp index cfc5ac79..c0b4df8c 100644 --- a/src/pmpo_mesh.hpp +++ b/src/pmpo_mesh.hpp @@ -40,11 +40,11 @@ const std::map