FairRoot/PandaRoot
|
#include <iostream>
#include <iomanip>
#include <fstream>
#include <math.h>
#include <string>
#include <sstream>
#include <vector>
Go to the source code of this file.
Macros | |
#define | outerDiam 82.2000 |
#define | innerDiam 31.8000 |
#define | tubeInnerDiam 1.0000 |
#define | tubeOuterDiam 1.0060 |
#define | tubeSeperation 1.0100 |
#define | wireDiam 0.0020 |
#define | tubeLength 150.0000 |
#define | safety 0.2000 |
#define | sttCenterX 0. |
#define | sttCenterY 0. |
#define | sttCenterZ 35. |
#define | innerCoverThickness 0.1000 |
#define | outerCoverThickness 0.1000 |
#define | panelthickness 0.1000 |
#define | pipeDiam 4.0000 |
#define | noSupport 0 |
#define | skewangle 3. |
#define | pi 3.141592653589793238512808959406186204433 |
#define | cave "cave" |
#define | sttassembly "stt01assembly" |
#define | innerCylinder "stt01innerCylinder" |
#define | outerCylinder "stt01outerCylinder" |
#define | panel1 "stt01box#1" |
#define | panel2 "stt01box#2" |
#define | panel3 "stt01box#3" |
#define | panel4 "stt01box#4" |
#define | air "air" |
#define | AlBe "STTsupport" |
#define | mylar "mylar" |
#define | HeMixture "STTmix9010_2bar" |
#define | W "tungsten" |
Functions | |
void | writename (char const *name, bool support=false, bool leftside=false) |
void | writemother (char const *name, bool original=true, bool support=false) |
void | writecylsupport (char const *name, bool firstone) |
void | writemedium (char *name) |
void | writetube (double inner, double outer, double length) |
void | writehalftube (double inner, double outer, double length) |
void | writepanel (char const *name, bool firstone, double xthick, double ythick, double length, int side) |
void | writetrans (double x, double y, double z) |
void | writerot (double x00, double x01, double x02, double x10, double x11, double x12, double x20, double x21, double x22) |
bool | putStraw (double posX, double posY, double posZ) |
void | plotrotright (double x, double y, double z) |
void | plotrotleft (double x, double y, double z) |
bool | putStrawRotatedShortLeft (double posX, double posY, double posZ, double xvector, double yvector, double zvector, double length) |
bool | putStrawRotatedShortRight (double posX, double posY, double posZ, double xvector, double yvector, double zvector, double length) |
bool | putStrawRotatedLeft (double posX, double posY, double posZ, double xvector, double yvector, double zvector, double length) |
bool | putStrawRotatedRight (double posX, double posY, double posZ, double xvector, double yvector, double zvector, double length) |
void | placeSingleLayerStraightExact (double ringteller) |
void | placeSingleLayerSkewedRight (double ringposition) |
void | placeSingleLayerSkewedLeft (double ringposition) |
void | makeDoubleLayerStraightExact (double &startRadius) |
void | makeSingleLayerStraightExact (double &startRadius) |
void | makeDoubleLayerSkewedRight (double startRadius) |
void | makeDoubleLayerSkewedLeft (double startRadius) |
int | main () |
Variables | |
static int | counter1 |
static int | counter2 |
static int | counter3 |
static int | counter4 |
static int | counter5 |
static int | counter6 |
static int | tubeteller |
static int | axialtubeteller |
static int | skewedtubeteller |
static int | shortskewedtubeteller |
static double | maximumradius = 0 |
static double | minimumradius = 100000 |
#define air "air" |
Definition at line 70 of file createSTT_150.C.
Referenced by main().
#define AlBe "STTsupport" |
Definition at line 71 of file createSTT_150.C.
Referenced by main(), and writepanel().
#define cave "cave" |
Definition at line 60 of file createSTT_150.C.
Referenced by main().
#define HeMixture "STTmix9010_2bar" |
Definition at line 73 of file createSTT_150.C.
Referenced by putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
#define innerCoverThickness 0.1000 |
Definition at line 49 of file createSTT_150.C.
Referenced by main(), makeSingleLayerStraightExact(), and putStraw().
#define innerCylinder "stt01innerCylinder" |
Definition at line 62 of file createSTT_150.C.
Referenced by main().
#define innerDiam 31.8000 |
Definition at line 35 of file createSTT_150.C.
Referenced by main(), and putStraw().
#define mylar "mylar" |
Definition at line 72 of file createSTT_150.C.
Referenced by putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
#define noSupport 0 |
Definition at line 54 of file createSTT_150.C.
Referenced by main().
#define outerCoverThickness 0.1000 |
Definition at line 50 of file createSTT_150.C.
Referenced by main(), and putStraw().
#define outerCylinder "stt01outerCylinder" |
Definition at line 63 of file createSTT_150.C.
Referenced by main().
#define outerDiam 82.2000 |
Definition at line 34 of file createSTT_150.C.
Referenced by main(), and putStraw().
#define panel1 "stt01box#1" |
Definition at line 64 of file createSTT_150.C.
Referenced by main().
#define panel2 "stt01box#2" |
Definition at line 65 of file createSTT_150.C.
Referenced by main().
#define panel3 "stt01box#3" |
Definition at line 66 of file createSTT_150.C.
Referenced by main().
#define panel4 "stt01box#4" |
Definition at line 67 of file createSTT_150.C.
Referenced by main().
#define panelthickness 0.1000 |
Definition at line 52 of file createSTT_150.C.
Referenced by main(), placeSingleLayerSkewedLeft(), placeSingleLayerSkewedRight(), and putStraw().
#define pi 3.141592653589793238512808959406186204433 |
Definition at line 58 of file createSTT_150.C.
Referenced by placeSingleLayerSkewedLeft(), placeSingleLayerSkewedRight(), plotrotleft(), plotrotright(), and writehalftube().
#define pipeDiam 4.0000 |
Definition at line 53 of file createSTT_150.C.
Referenced by main(), placeSingleLayerSkewedLeft(), placeSingleLayerSkewedRight(), putStraw(), and writehalftube().
#define safety 0.2000 |
Definition at line 42 of file createSTT_150.C.
Referenced by placeSingleLayerSkewedLeft(), and placeSingleLayerSkewedRight().
#define skewangle 3. |
Definition at line 56 of file createSTT_150.C.
Referenced by placeSingleLayerSkewedLeft(), placeSingleLayerSkewedRight(), plotrotleft(), plotrotright(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
#define sttassembly "stt01assembly" |
Definition at line 61 of file createSTT_150.C.
Referenced by main(), putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), putStrawRotatedShortRight(), and writepanel().
#define sttCenterX 0. |
Definition at line 44 of file createSTT_150.C.
#define sttCenterY 0. |
Definition at line 45 of file createSTT_150.C.
#define sttCenterZ 35. |
Definition at line 47 of file createSTT_150.C.
Referenced by main().
#define tubeInnerDiam 1.0000 |
Definition at line 36 of file createSTT_150.C.
Referenced by putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
#define tubeLength 150.0000 |
Definition at line 40 of file createSTT_150.C.
Referenced by main(), placeSingleLayerSkewedLeft(), placeSingleLayerSkewedRight(), and putStraw().
#define tubeOuterDiam 1.0060 |
Definition at line 37 of file createSTT_150.C.
Referenced by putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
#define tubeSeperation 1.0100 |
Definition at line 38 of file createSTT_150.C.
Referenced by main(), makeDoubleLayerSkewedLeft(), makeDoubleLayerSkewedRight(), makeDoubleLayerStraightExact(), makeSingleLayerStraightExact(), placeSingleLayerSkewedLeft(), placeSingleLayerSkewedRight(), and placeSingleLayerStraightExact().
#define W "tungsten" |
Definition at line 74 of file createSTT_150.C.
Referenced by putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
#define wireDiam 0.0020 |
Definition at line 39 of file createSTT_150.C.
Referenced by putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
int main | ( | void | ) |
Definition at line 1460 of file createSTT_150.C.
References air, AlBe, axialtubeteller, cave, counter1, counter2, counter3, counter4, counter5, counter6, innerCoverThickness, innerCylinder, innerDiam, makeDoubleLayerSkewedLeft(), makeDoubleLayerSkewedRight(), makeDoubleLayerStraightExact(), maximumradius, minimumradius, noSupport, outerCoverThickness, outerCylinder, outerDiam, panel1, panel2, panel3, panel4, panelthickness, pipeDiam, shortskewedtubeteller, skewedtubeteller, sqrt(), sttassembly, sttCenterZ, tubeLength, tubeSeperation, tubeteller, writecylsupport(), writehalftube(), writemedium(), writename(), writepanel(), writerot(), and writetrans().
void makeDoubleLayerSkewedLeft | ( | double | startRadius | ) |
Definition at line 1450 of file createSTT_150.C.
References placeSingleLayerSkewedLeft(), sqrt(), and tubeSeperation.
Referenced by main().
void makeDoubleLayerSkewedRight | ( | double | startRadius | ) |
Definition at line 1443 of file createSTT_150.C.
References placeSingleLayerSkewedRight(), sqrt(), and tubeSeperation.
Referenced by main().
void makeDoubleLayerStraightExact | ( | double & | startRadius | ) |
Definition at line 1387 of file createSTT_150.C.
References placeSingleLayerStraightExact(), sqrt(), and tubeSeperation.
Referenced by main().
void makeSingleLayerStraightExact | ( | double & | startRadius | ) |
Definition at line 1420 of file createSTT_150.C.
References innerCoverThickness, placeSingleLayerStraightExact(), sqrt(), and tubeSeperation.
void placeSingleLayerSkewedLeft | ( | double | ringposition | ) |
Definition at line 982 of file createSTT_150.C.
References cos(), i, limit, panelthickness, pi, pipeDiam, putStrawRotatedLeft(), putStrawRotatedShortLeft(), safety, sin(), skewangle, sqrt(), tubeLength, tubeSeperation, and zpos.
Referenced by makeDoubleLayerSkewedLeft().
void placeSingleLayerSkewedRight | ( | double | ringposition | ) |
Definition at line 599 of file createSTT_150.C.
References cos(), fabs(), i, limit, panelthickness, pi, pipeDiam, putStrawRotatedRight(), putStrawRotatedShortRight(), safety, sin(), skewangle, sqrt(), tubeLength, tubeSeperation, and zpos.
Referenced by makeDoubleLayerSkewedRight().
void placeSingleLayerStraightExact | ( | double | ringteller | ) |
Definition at line 548 of file createSTT_150.C.
References i, putStraw(), sqrt(), tubeSeperation, and zpos.
Referenced by makeDoubleLayerStraightExact(), and makeSingleLayerStraightExact().
void plotrotleft | ( | double | x, |
double | y, | ||
double | z | ||
) |
Definition at line 284 of file createSTT_150.C.
References cos(), counter6, pi, sin(), and skewangle.
Referenced by putStrawRotatedLeft(), and putStrawRotatedShortLeft().
void plotrotright | ( | double | x, |
double | y, | ||
double | z | ||
) |
Definition at line 263 of file createSTT_150.C.
References cos(), counter6, pi, sin(), and skewangle.
Referenced by putStrawRotatedRight(), and putStrawRotatedShortRight().
bool putStraw | ( | double | posX, |
double | posY, | ||
double | posZ | ||
) |
Definition at line 177 of file createSTT_150.C.
References axialtubeteller, HeMixture, innerCoverThickness, innerDiam, maximumradius, minimumradius, mylar, outerCoverThickness, outerDiam, panelthickness, pipeDiam, sqrt(), sttassembly, tubeInnerDiam, tubeLength, tubeOuterDiam, tubeteller, W, wireDiam, writemedium(), writemother(), writename(), writerot(), writetrans(), and writetube().
Referenced by placeSingleLayerStraightExact().
bool putStrawRotatedLeft | ( | double | posX, |
double | posY, | ||
double | posZ, | ||
double | xvector, | ||
double | yvector, | ||
double | zvector, | ||
double | length | ||
) |
Definition at line 416 of file createSTT_150.C.
References HeMixture, mylar, plotrotleft(), sin(), skewangle, skewedtubeteller, sttassembly, tubeInnerDiam, tubeOuterDiam, tubeteller, W, wireDiam, writemedium(), writemother(), writename(), writerot(), writetrans(), and writetube().
Referenced by placeSingleLayerSkewedLeft().
bool putStrawRotatedRight | ( | double | posX, |
double | posY, | ||
double | posZ, | ||
double | xvector, | ||
double | yvector, | ||
double | zvector, | ||
double | length | ||
) |
Definition at line 480 of file createSTT_150.C.
References HeMixture, mylar, plotrotright(), sin(), skewangle, skewedtubeteller, sttassembly, tubeInnerDiam, tubeOuterDiam, tubeteller, W, wireDiam, writemedium(), writemother(), writename(), writerot(), writetrans(), and writetube().
Referenced by placeSingleLayerSkewedRight().
bool putStrawRotatedShortLeft | ( | double | posX, |
double | posY, | ||
double | posZ, | ||
double | xvector, | ||
double | yvector, | ||
double | zvector, | ||
double | length | ||
) |
Definition at line 301 of file createSTT_150.C.
References HeMixture, mylar, plotrotleft(), shortskewedtubeteller, sin(), skewangle, sttassembly, tubeInnerDiam, tubeOuterDiam, tubeteller, W, wireDiam, writemedium(), writemother(), writename(), writerot(), writetrans(), and writetube().
Referenced by placeSingleLayerSkewedLeft().
bool putStrawRotatedShortRight | ( | double | posX, |
double | posY, | ||
double | posZ, | ||
double | xvector, | ||
double | yvector, | ||
double | zvector, | ||
double | length | ||
) |
Definition at line 358 of file createSTT_150.C.
References HeMixture, mylar, plotrotright(), shortskewedtubeteller, sin(), skewangle, sttassembly, tubeInnerDiam, tubeOuterDiam, tubeteller, W, wireDiam, writemedium(), writemother(), writename(), writerot(), writetrans(), and writetube().
Referenced by placeSingleLayerSkewedRight().
void writecylsupport | ( | char const * | name, |
bool | firstone | ||
) |
void writehalftube | ( | double | inner, |
double | outer, | ||
double | length | ||
) |
void writemedium | ( | char * | name | ) |
Definition at line 110 of file createSTT_150.C.
References counter3.
Referenced by main(), putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
void writemother | ( | char const * | name, |
bool | original = true , |
||
bool | support = false |
||
) |
Definition at line 92 of file createSTT_150.C.
References counter2.
Referenced by putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
void writename | ( | char const * | name, |
bool | support = false , |
||
bool | leftside = false |
||
) |
Definition at line 84 of file createSTT_150.C.
References counter1.
Referenced by main(), putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
void writepanel | ( | char const * | name, |
bool | firstone, | ||
double | xthick, | ||
double | ythick, | ||
double | length, | ||
int | side | ||
) |
Definition at line 133 of file createSTT_150.C.
References AlBe, and sttassembly.
Referenced by main().
void writerot | ( | double | x00, |
double | x01, | ||
double | x02, | ||
double | x10, | ||
double | x11, | ||
double | x12, | ||
double | x20, | ||
double | x21, | ||
double | x22 | ||
) |
Definition at line 167 of file createSTT_150.C.
References counter6.
Referenced by main(), putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
void writetrans | ( | double | x, |
double | y, | ||
double | z | ||
) |
Definition at line 161 of file createSTT_150.C.
References counter5.
Referenced by main(), putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
void writetube | ( | double | inner, |
double | outer, | ||
double | length | ||
) |
Definition at line 116 of file createSTT_150.C.
References counter4.
Referenced by putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
|
static |
Definition at line 77 of file createSTT_150.C.
Referenced by main(), and putStraw().
|
static |
Definition at line 26 of file createSTT_150.C.
Referenced by main(), and writename().
|
static |
Definition at line 27 of file createSTT_150.C.
Referenced by main(), writecylsupport(), and writemother().
|
static |
Definition at line 28 of file createSTT_150.C.
Referenced by main(), and writemedium().
|
static |
Definition at line 29 of file createSTT_150.C.
Referenced by main(), writehalftube(), and writetube().
|
static |
Definition at line 30 of file createSTT_150.C.
Referenced by main(), and writetrans().
|
static |
Definition at line 31 of file createSTT_150.C.
Referenced by main(), plotrotleft(), plotrotright(), and writerot().
|
static |
Definition at line 80 of file createSTT_150.C.
Referenced by main(), and putStraw().
|
static |
Definition at line 81 of file createSTT_150.C.
Referenced by main(), and putStraw().
|
static |
Definition at line 79 of file createSTT_150.C.
Referenced by main(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().
|
static |
Definition at line 78 of file createSTT_150.C.
Referenced by main(), putStrawRotatedLeft(), and putStrawRotatedRight().
|
static |
Definition at line 76 of file createSTT_150.C.
Referenced by main(), putStraw(), putStrawRotatedLeft(), putStrawRotatedRight(), putStrawRotatedShortLeft(), and putStrawRotatedShortRight().