Commit fd0ce4e5 authored by berenger-bramas's avatar berenger-bramas

Homogeneous file name added

git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/scalfmm/scalfmm/trunk@4 2616d619-271b-44dc-8df4-d4a8f33a7222
parent 4fb8f536
......@@ -14,6 +14,7 @@ Doc/html/
#ignore temporary files
tmp/
*.tmp
*.temp
*~
*TAGS
*#*#
Hello Wordl 2 the return
// /!\ Please, you must read the license at the bottom of this page
//#define FUSE_MPI
#define FUSE_MPI
#ifdef FUSE_MPI
// Compile by mpic++ testApplication.cpp -o testApplication.exe
// run by mpirun -np 4 ./testApplication
// Compile by mpic++ testApplication.cpp ../Sources/Utils/FAssertable.cpp -o testApplication.exe
// run by mpirun -np 4 ./testApplication.exe
#include "../Sources/Utils/FMpiApplication.hpp"
#define ApplicationImplementation FMpiApplication
#else
// Compile by g++ testApplication.cpp -o testApplication.exe
// Compile by g++ testApplication.cpp ../Sources/Utils/FAssertable.cpp -o testApplication.exe
#include "../Sources/Utils/FSingleApplication.hpp"
#define ApplicationImplementation FSingleApplication
#endif
......
......@@ -29,7 +29,7 @@ protected:
// optional : doing something before assert calls FApp->exit
void calledBeforeExit() const {
std::cout << "assert is false we will quit what can I do...?\n";
std::cout << "assert is false we will quit! what can I do...?\n";
}
};
......
......@@ -2,11 +2,10 @@
#include "../Sources/Utils/FDebug.hpp"
// Compile by : g++ testDebug.cpp ../Sources/Utils/FDebug.cpp -o testFDebug.exe
// Compile by : g++ testDebug.cpp ../Sources/Utils/FDebug.cpp -o testDebug.exe
/**
* In this file we show how to use the debug module
* please refere to the source of testDebug.cpp directly to knwo more
*/
int main(void){
......@@ -18,10 +17,10 @@ int main(void){
FDEBUG( FDebug::Controller.writeVariableFromLine( "i", i, __LINE__, __FILE__););
// Write a developer information
FDEBUG( FDebug::Controller.writeFromLine("Strange things happend here!", __LINE__, __FILE__); )
FDEBUG( FDebug::Controller.writeFromLine("Strange things are there!", __LINE__, __FILE__); )
// Change stream type
FDEBUG( FDebug::Controller.writeToFile("FDebug.out"); )
FDEBUG( FDebug::Controller.writeToFile("testDebug.out.temp"); )
FDEBUG( FDebug::Controller << "Hello Wordl 2 the return\n");
return 0;
......
......@@ -18,16 +18,16 @@
#include "../Sources/Files/FBasicLoader.hpp"
// Compile by : g++ testLoader.cpp ../Sources/Utils/FAssertable.cpp -o testLoader.exe
// Compile by : g++ testLoader.cpp ../Sources/Utils/FAssertable.cpp -O2 -lgomp -fopenmp -o testLoader.exe
// Fake cell class
class TestCell{
};
/**
* In this file we show an example of BasicParticule and BasicLoader use
* Démarrage de /home/berenger/Dropbox/Personnel/FMB++/FMB++-build-desktop/FMB++...
* Inserting particules ...
* Inserting 2000000 particules ...
* Done (5.77996).
* Deleting particules ...
* Done (0.171918).
......@@ -36,11 +36,12 @@ class TestCell{
int main(int , char ** ){
// we store all particules to be able to dealloc
FList<FBasicParticule*> particules;
const char* const filename = "testLoader.basic.temp";
// open basic particules loader
FBasicLoader<FBasicParticule> loader("../FMB++/Tests/particules.basic.txt");
FBasicLoader<FBasicParticule> loader(filename);
if(!loader.isValide()){
std::cout << "Loader Error\n";
std::cout << "Loader Error, " << filename << "is missing\n";
return 1;
}
......@@ -48,7 +49,7 @@ int main(int , char ** ){
FOctree<FBasicParticule, TestCell, 10, 3> tree(loader.getBoxWidth(),loader.getCenterOfBox());
// -----------------------------------------------------
std::cout << "Inserting particules ..." << std::endl;
std::cout << "Inserting " << loader.getNumberOfParticules() << " particules ..." << std::endl;
const double InsertingStartTime = omp_get_wtime();
for(int idx = 0 ; idx < loader.getNumberOfParticules() ; ++idx){
FBasicParticule* const part = new FBasicParticule();
......
......@@ -16,7 +16,8 @@
#include "../Sources/Core/FAbstractParticule.hpp"
// Compile by : g++ testOctree.cpp ../Sources/Utils/FAssertable.cpp -o testOctree.exe
// We use openmp to count time (portable and easy to manage)
// Compile by : g++ testOctree.cpp ../Sources/Utils/FAssertable.cpp -O2 -lgomp -fopenmp -o testOctree.exe
/**
* In this file we show how to use octree
......@@ -28,6 +29,8 @@
* Deleting particules ...
* Done (0.0791715).
*/
// Fake particule class
class TestParticule : public FAbstractParticule {
F3DPosition pos;
public:
......@@ -38,7 +41,7 @@ public:
return pos;
}
};
// Fake cell class
class TestCell{
};
......
......@@ -16,10 +16,12 @@
#include "../Sources/Core/FAbstractParticule.hpp"
// Compile by : g++ testOctreeIter.cpp ../Sources/Utils/FAssertable.cpp -o testOctreeIter.exe
// We use openmp to count time (portable and easy to manage)
// Compile by : g++ testOctreeIter.cpp ../Sources/Utils/FAssertable.cpp -lgomp -fopenmp -O2 -o testOctreeIter.exe
/**
* In this file we show how to use octree with iteration
NbLevels = 5 & NbSubLevels = 2 & NbPart = 2000000
Creating particules ...
Done (0.263944s).
......@@ -53,6 +55,8 @@ Done (0.716064s).
Deleting particules ...
Done (0.0830964s).
*/
// Fake particule class
class TestParticule : public FAbstractParticule {
F3DPosition pos;
public:
......@@ -64,6 +68,7 @@ public:
}
};
// Fake cell class
class TestCell{
};
......@@ -71,13 +76,13 @@ class TestCell{
int main(int , char ** ){
const int NbLevels = 10;
const int NbSubLevels = 3;
const long NbPart = 2E5;
const long NbPart = 2E6;
FList<TestParticule*> particules;
srand ( 1 ); // volontary set seed to constant
// -----------------------------------------------------
std::cout << "Creating particules ..." << std::endl;
std::cout << "Creating " << NbPart << " particules ..." << std::endl;
const double CreatingStartTime = omp_get_wtime();
for(long idxPart = 0 ; idxPart < NbPart ; ++idxPart){
particules.pushFront(new TestParticule(F3DPosition(double(rand())/RAND_MAX,double(rand())/RAND_MAX,double(rand())/RAND_MAX)));
......
......@@ -11,7 +11,6 @@
/**
* In this file we show how to use the thread module
* please refere to the source of testDebug.cpp directly to knwo more
*/
......
......@@ -2,7 +2,7 @@
#include "../Sources/Containers/FList.hpp"
// compile by g++ flistUTest.cpp -o testFile.exe
// compile by g++ utestList.cpp -o utestList.exe
/**
* This file is a unit test for the FList class
......
#include "FUTester.hpp"
// compile by g++ testUTest.cpp -o test.exe
// compile by g++ utestTest.cpp -o utestTest.exe
/** this class show a simple example of unit test */
class MyTest : public FUTester<MyTest> {
......
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