First step in reorganizing the installation of the musrfit documentation (further commits will follow)

This commit is contained in:
Bastian M. Wojek
2011-08-06 09:51:21 +00:00
parent 4490f103f3
commit 254d849079
241 changed files with 39 additions and 18 deletions

View File

@@ -42,7 +42,7 @@ using namespace std;
// Constructor of the TrimSPData class -- reading all available trim.SP-rge-files with a given name into std::vectors
//--------------------
TTrimSPData::TTrimSPData(const string &path, map<double, string> &energies, bool debug) {
TTrimSPData::TTrimSPData(const string &path, map<double, string> &energies, bool debug, unsigned int highRes) {
// sort the energies in ascending order - this might be useful for later applications (energy-interpolations etc.)
// after the change from the vector to the map this is not necessary any more - since maps are always ordered!
@@ -101,6 +101,12 @@ TTrimSPData::TTrimSPData(const string &path, map<double, string> &energies, bool
vnzz.clear();
goodFile = false;
fIsNormalized.push_back(false);
if (highRes) {
UseHighResolution(iter->first);
}
} else {
cerr << "TTrimSPData::TTrimSPData: " << energyStr << " does not seem to be a valid unmodified TRIM.SP output file!" << endl;
continue;
@@ -113,9 +119,6 @@ TTrimSPData::TTrimSPData(const string &path, map<double, string> &energies, bool
fOrigDataNZ = fDataNZ;
for(unsigned int i(0); i<fEnergy.size();++i)
fIsNormalized.push_back(false);
fEnergyIter = fEnergy.end();
}
@@ -146,7 +149,7 @@ void TTrimSPData::UseHighResolution(double e) {
}
fDataZ[i] = vecZ;
fDataNZ[i] = vecNZ;
fOrigDataNZ[i] = vecNZ;
//fOrigDataNZ[i] = vecNZ;
fDZ[i] = 1.;
fIsNormalized[i] = false;
return;
@@ -494,7 +497,7 @@ void TTrimSPData::ConvolveGss(double w, double e) const {
if(fEnergyIter != fEnergy.end()) {
unsigned int i(fEnergyIter - fEnergy.begin());
z = fDataZ[i];
nz = fOrigDataNZ[i];
nz = fDataNZ[i];
for(unsigned int k(0); k<z.size(); k++) {
gss.push_back(exp(-z[k]*z[k]/200.0/w/w));

View File

@@ -43,7 +43,7 @@ class TTrimSPData {
public:
TTrimSPData(const string&, map<double, string>&, bool debug = false);
TTrimSPData(const string&, map<double, string>&, bool debug = false, unsigned int highRes = 0);
~TTrimSPData() {
fDataZ.clear();
@@ -60,6 +60,7 @@ public:
vector<double> OrigDataNZ(double) const;
double DataDZ(double) const;
void UseHighResolution(double);
void SetOriginal() {fOrigDataNZ = fDataNZ;}
void WeightLayers(double, const vector<double>&, const vector<double>&) const;
double LayerFraction(double, unsigned int, const vector<double>&) const;
double GetNofZ(double, double) const;