Attention une mise à jour du service Gitlab va être effectuée le mardi 18 janvier (et non lundi 17 comme annoncé précédemment) entre 18h00 et 18h30. Cette mise à jour va générer une interruption du service dont nous ne maîtrisons pas complètement la durée mais qui ne devrait pas excéder quelques minutes.

Commit 953a3dd9 authored by BRAMAS Berenger's avatar BRAMAS Berenger
Browse files
parents 78a1905a faaf232f
...@@ -226,7 +226,7 @@ extern "C" void ChebKernel_L2P(void* leafCell, int nbParticles, const int* parti ...@@ -226,7 +226,7 @@ extern "C" void ChebKernel_L2P(void* leafCell, int nbParticles, const int* parti
reinterpret_cast<UserData *>(inKernel)->insertedPositions[particleIndexes[i]*3+2]); reinterpret_cast<UserData *>(inKernel)->insertedPositions[particleIndexes[i]*3+2]);
double Phi = reinterpret_cast<UserData *>(inKernel)->myPhyValues[particleIndexes[i]]; double Phi = reinterpret_cast<UserData *>(inKernel)->myPhyValues[particleIndexes[i]];
tempContainer->push(pos,particleIndexes[i],Phi); tempContainer->push(pos,particleIndexes[i],Phi);
} }
//Get our structures //Get our structures
ChebCellStruct * leafCellStruct = reinterpret_cast<ChebCellStruct *>(leafCell); ChebCellStruct * leafCellStruct = reinterpret_cast<ChebCellStruct *>(leafCell);
//get real cheb cell //get real cheb cell
...@@ -247,14 +247,14 @@ extern "C" void ChebKernel_L2P(void* leafCell, int nbParticles, const int* parti ...@@ -247,14 +247,14 @@ extern "C" void ChebKernel_L2P(void* leafCell, int nbParticles, const int* parti
forcesToFill[indexes[idxPart]*3+0] += tempContainer->getForcesX()[idxPart]; forcesToFill[indexes[idxPart]*3+0] += tempContainer->getForcesX()[idxPart];
forcesToFill[indexes[idxPart]*3+1] += tempContainer->getForcesY()[idxPart]; forcesToFill[indexes[idxPart]*3+1] += tempContainer->getForcesY()[idxPart];
forcesToFill[indexes[idxPart]*3+2] += tempContainer->getForcesZ()[idxPart]; forcesToFill[indexes[idxPart]*3+2] += tempContainer->getForcesZ()[idxPart];
} }
delete tempContainer; delete tempContainer;
tempContainer=nullptr; tempContainer=nullptr;
} }
void ChebKernel_P2P(int nbParticles, const int* particleIndexes, void ChebKernel_P2P(int nbParticles, const int* particleIndexes,
const int * sourceParticleIndexes[27],int sourceNbPart[27],void* inKernel){ const int * sourceParticleIndexes[27],int sourceNbPart[27],void* inKernel){
//Create temporary FSimpleLeaf for target //Create temporary FSimpleLeaf for target
......
...@@ -119,14 +119,16 @@ int main(int argc, char ** av){ ...@@ -119,14 +119,16 @@ int main(int argc, char ** av){
int treeHeight = atoi(av[2]); int treeHeight = atoi(av[2]);
} }
double* particleXYZ = malloc(sizeof(double)*3*nbPart);
double* physicalValues = malloc(sizeof(double)*nbPart);
double boxWidth = 1.0; double boxWidth = 1.0;
double boxCenter[3]; double boxCenter[3];
boxCenter[0] = boxCenter[1] = boxCenter[2] = 0.0; boxCenter[0] = boxCenter[1] = boxCenter[2] = 0.0;
//Allocation of the positions and physical values
double* particleXYZ = malloc(sizeof(double)*3*nbPart);
double* physicalValues = malloc(sizeof(double)*nbPart);
{ {
printf("Creating Particles:\n"); printf("Creating Particles:\n");
int idxPart; int idxPart;
...@@ -274,7 +276,7 @@ int main(int argc, char ** av){ ...@@ -274,7 +276,7 @@ int main(int argc, char ** av){
nbPartOkay++; nbPartOkay++;
} }
else{ else{
//printf("id : %d : %e, %e, %e\n",idxPart,diffX,diffY,diffZ); printf("id : %d : %e, %e, %e\n",idxPart,diffX,diffY,diffZ);
} }
//That part is to verify with our usual exec' if everything is alright //That part is to verify with our usual exec' if everything is alright
if(idxPart == 0 || idxPart == nbPart/2 || idxPart == nbPart-1){ if(idxPart == 0 || idxPart == nbPart/2 || idxPart == nbPart-1){
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment