Skip to content

Commit

Permalink
KCore, Post: passing function from fortran to C
Browse files Browse the repository at this point in the history
  • Loading branch information
benoit128 committed Oct 24, 2024
1 parent dd930cc commit a24bed4
Show file tree
Hide file tree
Showing 11 changed files with 25 additions and 1,255 deletions.
1 change: 1 addition & 0 deletions Cassiopee/Converter/Converter/Expression/node.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ namespace Expression
class ast::node
{
public:
virtual ~node() {}
/**
* @brief Evaluate the node at index i
* @details evaluate the node at index i. If this node is not a terminal node
Expand Down
3 changes: 1 addition & 2 deletions Cassiopee/Intersector/PolyMeshTools/aggloCells.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
along with Cassiopee. If not, see <http://www.gnu.org/licenses/>.
*/


# include <string>
# include <sstream>
# include "intersector.h"
Expand Down Expand Up @@ -215,7 +214,7 @@ PyObject* K_INTERSECTOR::agglomerateCellsWithSpecifiedFaces(PyObject* self, PyOb
K_FLD::IntArray & cnt = *cn;

E_Int* pgsList=NULL;
E_Int size, nfld;
E_Int size=0, nfld=1;
if (py_pgs != Py_None)
K_NUMPY::getFromNumpyArray(py_pgs, pgsList, size, nfld, 1);

Expand Down
10 changes: 3 additions & 7 deletions Cassiopee/KCore/KCore/Fld/FldArray.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,6 @@ extern "C" void k6setallbvaluesatf_(const E_Int& sizeLoc,
const E_Int& nj,
const E_Int& nk,
const E_Int& border);
extern "C" void k6fldsqrt_(E_Float* _data,
const E_Int& sizeTotLoc);

// Set rake for a compact array
#define SETRAKE \
Expand Down Expand Up @@ -1031,17 +1029,15 @@ E_Int FldArray<T>::indMax(E_Int inc, E_Int nfld) const
TEMPLATE_T
void FldArray<T>::sqrt()
{
k6fldsqrt_(_data, _nfldLoc*_sizeMax);
/*
#pragma omp parallel default(shared)
#pragma omp parallel
{
for (E_Int n = 0; n < _nfldLoc; n++)
{
T* pt = _rake[n];
#pragma omp for
#pragma omp for
for (E_Int i = 0; i < _sizeLoc; i++) pt[i*_stride] = std::sqrt(pt[i*_stride]);
}
}*/
}
}

//OK---------------------------------------------------------------------------
Expand Down
Loading

0 comments on commit a24bed4

Please sign in to comment.