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 c52f66f was
b4679de,
checked in by Jae Cho <jhjcho@…>, 15 years ago
|
added 2d and model descpt + correction on polydisp. para.
|
-
Property mode set to
100644
|
File size:
1.1 KB
|
Rev | Line | |
---|
[34c3020] | 1 | /** |
---|
| 2 | * Scattering model for the form factor from a lyotropic lamellar phase |
---|
| 3 | * @author: Gervaise B. Alina / UTK |
---|
| 4 | */ |
---|
| 5 | |
---|
| 6 | #include "lamellarFF_HG.h" |
---|
| 7 | #include <math.h> |
---|
| 8 | #include "libCylinder.h" |
---|
| 9 | #include <stdio.h> |
---|
| 10 | #include <stdlib.h> |
---|
| 11 | |
---|
| 12 | |
---|
| 13 | /** |
---|
| 14 | * Function to evaluate 1D scattering function |
---|
| 15 | * @param pars: parameters of the form factor from a lyotropic lamellar phase |
---|
| 16 | * @param q: q-value |
---|
| 17 | * @return: function value |
---|
| 18 | */ |
---|
| 19 | double lamellarFF_HG_analytical_1D(LamellarFF_HGParameters *pars, double q) { |
---|
| 20 | double dp[7]; |
---|
[b4679de] | 21 | |
---|
[34c3020] | 22 | // Fill paramater array |
---|
| 23 | dp[0] = pars->scale; |
---|
| 24 | dp[1] = pars->t_length; |
---|
| 25 | dp[2] = pars->h_thickness; |
---|
| 26 | dp[3] = pars->sld_tail; |
---|
| 27 | dp[4] = pars->sld_head; |
---|
| 28 | dp[5] = pars->sld_solvent; |
---|
| 29 | dp[6] = pars->background; |
---|
[b4679de] | 30 | |
---|
[34c3020] | 31 | // Call library function to evaluate model |
---|
[b4679de] | 32 | return LamellarFF_HG(dp, q); |
---|
[34c3020] | 33 | } |
---|
| 34 | |
---|
| 35 | double lamellarFF_HG_analytical_2D(LamellarFF_HGParameters *pars, double q, double phi){ |
---|
[b4679de] | 36 | return lamellarFF_HG_analytical_1D(pars,q); |
---|
[34c3020] | 37 | } |
---|
| 38 | double lamellarFF_HG_analytical_2DXY(LamellarFF_HGParameters *pars, double qx, double qy){ |
---|
[b4679de] | 39 | return lamellarFF_HG_analytical_1D(pars,sqrt(qx*qx+qy*qy)); |
---|
[34c3020] | 40 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.