extern “C” int VeksInit(UINT32 nElems, UINT32 nGlobalNodes, UINT32 aiElemConn[ ]); |
// Funcition: Initialize the solver |
extern “C” int VeksSetK(double afK[ ]); |
// Funcition: Set element stiffness matrices |
extern “C” int VeksSetDemF(double afF[ ]); |
// Funcition: Set element loads |
extern “C” int VeksSetU(double afU[ ]); |
// Funcition: Set nodal displacements |
extern “C” int VeksSetF(double afF[ ]); |
// Funcition: Set nodal loads |
extern “C” int VeksFixU(char abU[ ], double afU[ ]); |
// Funcition: Set nodal displacements |
extern “C” int VeksGetU(double afU[ ]); |
// Funcition: Get nodal displacements |
extern “C” int VeksSetC(double afC[ ]); |
// Funcition: Set element conductivity matrices |
extern “C” int VeksSetDemQ(double afQ[ ]); |
// Funcition: Set element thermal loads |
extern “C” int VeksSetQ(double afQ[ ]); |
// Funcition: Set nodal thermal loads |
extern “C” int VeksFixT(char abT[ ], double afT[ ]); |
// Funcition: Set nodal thermal constraints |
extern “C” int VeksGetT(double afT[ ]); |
// Funcition: Get nodal temperatures |
extern “C” __int64 VeksSolve(__int64 nMaxIter, double fTimeStep, double fUnbRatio, double fEps, unsigned int nPrint); |
// Funcition: Solve equations |
// The procedures for GPU analysis |
#include “Eks.h” |
int nRet = VeksInit(nElems, nGlobalNodes, aiElemConn); |
VeksSetK(afK); |
VeksSetDemF(afDemF); |
VeksFixU(abU, afU); |
VeksSetC(afC); VeksSetDemQ(afDemQ); |
VeksFixT(abT, afT); |
VeksSolve(nSteps, fTimeStep, fUnbRatio, fEps, nStipePrint); |
VeksGetU(afU); |
VeksGetT(afT); |