source: sasview/sansmodels/src/sans/models/c_extensions/parallelepiped.h @ bdc25e2

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 bdc25e2 was 4628e31, checked in by Jae Cho <jhjcho@…>, 14 years ago

changed the unit of angles into degrees

  • Property mode set to 100644
File size: 2.5 KB
Line 
1/*
2        TODO: Add 2D model
3*/
4
5#if !defined(parallelepiped_h)
6#define parallelepiped_h
7/** Structure definition for Parallelepiped parameters
8 * [PYTHONCLASS] = ParallelepipedModel
9 * [DISP_PARAMS] = short_a, short_b, long_c,parallel_phi,parallel_psi, parallel_theta
10   [DESCRIPTION] = <text> Form factor for a rectangular solid with uniform scattering length density.
11
12                scale:Scale factor
13                short_a: length of short edge  [A]
14                short_b: length of another short edge [A]
15                long_c: length of long edge  of the parallelepiped [A]
16                sldPipe: Pipe_sld
17                sldSolv: solvent_sld
18                background:Incoherent Background [1/cm]
19                </text>
20        [FIXED]= <text>short_a.width; short_b.width; long_c.width;parallel_phi.width;parallel_psi.width; parallel_theta.width</text>
21        [ORIENTATION_PARAMS]= <text>parallel_phi;parallel_psi; parallel_theta; parallel_phi.width;parallel_psi.width; parallel_theta.width</text>
22
23
24 **/
25typedef struct {
26    /// Scale factor
27    //  [DEFAULT]=scale=1.0
28    double scale;
29    ///  Length of short edge of the parallelepiped [A]
30    //  [DEFAULT]=short_a=35 [A]
31    double short_a;
32        /// Length of short edge edge of the parallelepiped [A]
33    //  [DEFAULT]=short_b=75 [A]
34    double short_b;
35        /// Length of long edge of the parallelepiped [A]
36    //  [DEFAULT]=long_c=400 [A]
37    double long_c;
38    /// SLD_Pipe [1/A^(2)]
39    //  [DEFAULT]=sldPipe=6.3e-6 [1/A^(2)]
40    double sldPipe;
41    /// sldSolv [1/A^(2)]
42    //  [DEFAULT]=sldSolv=1.0e-6 [1/A^(2)]
43    double sldSolv;
44        /// Incoherent Background [1/cm]
45        //  [DEFAULT]=background=0.0 [1/cm]
46        double background;
47    /// Orientation of the parallelepiped axis w/respect incoming beam [deg]
48    //  [DEFAULT]=parallel_theta=0.0 [deg]
49    double parallel_theta;
50    /// Orientation of the longitudinal axis of the parallelepiped in the plane of the detector [deg]
51    //  [DEFAULT]=parallel_phi=0.0 [deg]
52    double parallel_phi;
53    /// Orientation of the cross-sectional minor axis of the parallelepiped in the plane of the detector [deg]
54    //  [DEFAULT]=parallel_psi=0.0 [deg]
55    double parallel_psi;
56
57
58} ParallelepipedParameters;
59
60
61
62/// 1D scattering function
63double parallelepiped_analytical_1D(ParallelepipedParameters *pars, double q);
64
65/// 2D scattering function
66double parallelepiped_analytical_2D(ParallelepipedParameters *pars, double q, double phi);
67double parallelepiped_analytical_2DXY(ParallelepipedParameters *pars, double qx, double qy);
68double parallelepiped_analytical_2D_scaled(ParallelepipedParameters *pars, double q, double q_x, double q_y);
69#endif
Note: See TracBrowser for help on using the repository browser.