source: sasview/sansmodels/include/core_shell_cylinder.h @ 08648c0

ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalccostrafo411magnetic_scattrelease-4.1.1release-4.1.2release-4.2.2release_4.0.1ticket-1009ticket-1094-headlessticket-1242-2d-resolutionticket-1243ticket-1249ticket885unittest-saveload
Last change on this file since 08648c0 was 503a972, checked in by Mathieu Doucet <doucetm@…>, 13 years ago

more include dir in a more sensible place

  • Property mode set to 100644
File size: 2.7 KB
Line 
1#if !defined(core_shell_cylinder_h)
2#define core_shell_cylinder_h
3#include "parameters.hh"
4
5/**
6 * Structure definition for core-shell cylinder parameters
7 */
8//[PYTHONCLASS] = CoreShellCylinderModel
9//[DISP_PARAMS] = radius, thickness, length, axis_theta, axis_phi
10//[DESCRIPTION] = <text>P(q,alpha)= scale/Vs*f(q)^(2) + bkg,  where: f(q)= 2(core_sld
11//                      - solvant_sld)* Vc*sin[qLcos(alpha/2)]
12//                      /[qLcos(alpha/2)]*J1(qRsin(alpha))
13//                      /[qRsin(alpha)]+2(shell_sld-solvent_sld)
14//                      *Vs*sin[q(L+T)cos(alpha/2)][[q(L+T)
15//                      *cos(alpha/2)]*J1(q(R+T)sin(alpha))
16//                      /q(R+T)sin(alpha)]
17//
18//                      alpha:is the angle between the axis of
19//          the cylinder and the q-vector
20//                      Vs: the volume of the outer shell
21//                      Vc: the volume of the core
22//                      L: the length of the core
23//              shell_sld: the scattering length density
24//                      of the shell
25//                      solvent_sld: the scattering length density
26//                      of the solvent
27//                      bkg: the background
28//                      T: the thickness
29//              R+T: is the outer radius
30//              L+2T: The total length of the outershell
31//                      J1: the first order Bessel function
32//              theta: axis_theta of the cylinder
33//              phi: the axis_phi of the cylinder...
34//              </text>
35//[FIXED]= <text> axis_phi.width; axis_theta.width; length.width;radius.width; thickness.width</text>
36//[ORIENTATION_PARAMS]= axis_phi; axis_theta;axis_phi.width; axis_theta.width
37
38class CoreShellCylinderModel{
39public:
40  // Model parameters
41
42  /// Core radius [A]
43  //  [DEFAULT]=radius=20.0 [A]
44  Parameter radius;
45
46  /// Scale factor
47  //  [DEFAULT]=scale=1.0
48  Parameter scale;
49
50  /// Shell thickness [A]
51  //  [DEFAULT]=thickness=10.0 [A]
52  Parameter thickness;
53
54  /// Core length [A]
55  //  [DEFAULT]=length=400.0 [A]
56  Parameter length;
57
58  /// Core SLD [1/A^(2)]
59  //  [DEFAULT]=core_sld=1.0e-6 [1/A^(2)]
60  Parameter core_sld;
61
62  /// Shell SLD [1/A^(2)]
63  //  [DEFAULT]=shell_sld=4.0e-6 [1/A^(2)]
64  Parameter shell_sld;
65
66  /// Solvent SLD [1/A^(2)]
67  //  [DEFAULT]=solvent_sld=1.0e-6 [1/A^(2)]
68  Parameter solvent_sld;
69
70  /// Incoherent Background [1/cm]
71  //  [DEFAULT]=background=0 [1/cm]
72  Parameter background;
73
74  /// Orientation of the long axis of the core-shell cylinder w/respect incoming beam [deg]
75  //  [DEFAULT]=axis_theta=90.0 [deg]
76  Parameter axis_theta;
77
78  /// Orientation of the long axis of the core-shell cylinder in the plane of the detector [deg]
79  //  [DEFAULT]=axis_phi=0.0 [deg]
80  Parameter axis_phi;
81
82  // Constructor
83  CoreShellCylinderModel();
84
85  // Operators to get I(Q)
86  double operator()(double q);
87  double operator()(double qx, double qy);
88  double calculate_ER();
89  double evaluate_rphi(double q, double phi);
90};
91
92#endif
Note: See TracBrowser for help on using the repository browser.