[503a972] | 1 | #if !defined(hollow_cylinder_h) |
---|
| 2 | #define hollow_cylinder_h |
---|
| 3 | #include "parameters.hh" |
---|
| 4 | |
---|
| 5 | /** |
---|
| 6 | * Structure definition for hollow cylinder parameters |
---|
| 7 | */ |
---|
| 8 | //[PYTHONCLASS] = HollowCylinderModel |
---|
| 9 | //[DISP_PARAMS] = core_radius, radius, length, axis_theta, axis_phi |
---|
| 10 | //[DESCRIPTION] = <text> P(q) = scale*<f*f>/Vol + bkg, where f is the scattering amplitude. |
---|
| 11 | // core_radius = the radius of core |
---|
| 12 | // radius = the radius of shell |
---|
| 13 | // length = the total length of the cylinder |
---|
| 14 | // sldCyl = SLD of the shell |
---|
| 15 | // sldSolv = SLD of the solvent |
---|
| 16 | // background = incoherent background |
---|
| 17 | // </text> |
---|
| 18 | //[FIXED]= <text> axis_phi.width; axis_theta.width; length.width;core_radius.width; radius</text> |
---|
| 19 | //[ORIENTATION_PARAMS]= axis_phi; axis_theta;axis_phi.width; axis_theta.width |
---|
| 20 | |
---|
| 21 | class HollowCylinderModel{ |
---|
| 22 | public: |
---|
| 23 | // Model parameters |
---|
| 24 | /// Scale factor |
---|
| 25 | // [DEFAULT]=scale=1.0 |
---|
| 26 | Parameter scale; |
---|
| 27 | |
---|
| 28 | /// Core radius [A] |
---|
| 29 | // [DEFAULT]=core_radius=20.0 [A] |
---|
| 30 | Parameter core_radius; |
---|
| 31 | |
---|
| 32 | /// Shell radius [A] |
---|
| 33 | // [DEFAULT]=radius=30.0 [A] |
---|
| 34 | Parameter radius; |
---|
| 35 | |
---|
| 36 | /// Hollow cylinder length [A] |
---|
| 37 | // [DEFAULT]=length=400.0 [A] |
---|
| 38 | Parameter length; |
---|
| 39 | |
---|
| 40 | /// SLD_cylinder [1/A^(2)] |
---|
| 41 | // [DEFAULT]=sldCyl=6.3e-6 [1/A^(2)] |
---|
| 42 | Parameter sldCyl; |
---|
| 43 | |
---|
| 44 | /// SLD_solvent [1/A^(2)] |
---|
| 45 | // [DEFAULT]=sldSolv=1.0e-6 [1/A^(2)] |
---|
| 46 | Parameter sldSolv; |
---|
| 47 | |
---|
| 48 | /// Incoherent Background [1/cm] |
---|
| 49 | // [DEFAULT]=background=0.01 [1/cm] |
---|
| 50 | Parameter background; |
---|
| 51 | |
---|
| 52 | /// Orientation of the long axis of the hollow cylinder w/respect incoming beam [deg] |
---|
| 53 | // [DEFAULT]=axis_theta=90.0 [deg] |
---|
| 54 | Parameter axis_theta; |
---|
| 55 | |
---|
| 56 | /// Orientation of the long axis of the hollow cylinder in the plane of the detector [deg] |
---|
| 57 | // [DEFAULT]=axis_phi=0.0 [deg] |
---|
| 58 | Parameter axis_phi; |
---|
| 59 | //Constructor |
---|
| 60 | HollowCylinderModel(); |
---|
| 61 | |
---|
| 62 | //Operators to get I(Q) |
---|
| 63 | double operator()(double q); |
---|
| 64 | double operator()(double qx , double qy); |
---|
| 65 | double calculate_ER(); |
---|
[6319646] | 66 | double calculate_VR(); |
---|
[503a972] | 67 | double evaluate_rphi(double q, double phi); |
---|
| 68 | }; |
---|
| 69 | |
---|
| 70 | #endif |
---|