SasView / sasmodels

Package for calculation of small angle scattering models using OpenCL.
BSD 3-Clause "New" or "Revised" License
15 stars 27 forks source link

Add SASFit models to sasmodels #115

Open sasview-bot opened 5 years ago

sasview-bot commented 5 years ago

Compare SASfit with !SasView models and integrate missing SASfit models in !SasView. A list of !SasView vs. SASFit Models can be found under https://ess-ics.atlassian.net/wiki/display/SAS/SasView-SasFit+Overlapping+Models.

Migrated from http://trac.sasview.org/ticket/721

{
    "status": "new",
    "changetime": "2019-03-03T01:08:09",
    "_ts": "2019-03-03 01:08:09.821933+00:00",
    "description": "Compare SASfit with !SasView models and integrate missing SASfit models in !SasView. A list of !SasView vs. SASFit Models can be found under https://ess-ics.atlassian.net/wiki/display/SAS/SasView-SasFit+Overlapping+Models.",
    "reporter": "dirk",
    "cc": "",
    "resolution": "",
    "workpackage": "SasModels Model Issues",
    "time": "2016-10-07T13:34:27",
    "component": "sasmodels",
    "summary": "Compare Sasfit with Sasview models",
    "priority": "major",
    "keywords": "",
    "milestone": "sasmodels WishList",
    "owner": "dirk",
    "type": "enhancement"
}
sasview-bot commented 5 years ago

Trac update at 2016/10/07 16:19:18: dirk commented:

An ordered list with categories 1) New Models easy to integrate, 2) Sasfit "special" Models needing dicussion and 3) Covered in Sasview can be found under https://ess-ics.atlassian.net/wiki/display/SAS/Comparison.

butlerpd commented 5 years ago

Trac update at 2016/10/07 16:39:38: butler changed description from "Compare Sasfit with Sasview models and integrate missing SASFIT models in Sasview. A list of SasView vs. SasFit Models can be found under https://ess-ics.atlassian.net/wiki/display/SAS/SasView-SasFit+Overlapping+Models." to "Compare SASfit with !SasView models and integrate missing SASfit models in !SasView. A list of !SasView vs. SASFit Models can be found under https://ess-ics.atlassian.net/wiki/display/SAS/SasView-SasFit+Overlapping+Models."

butlerpd commented 5 years ago

Trac update at 2019/03/03 01:08:09: butler changed workpackage from "SasModels New Model" to "SasModels Model Issues"

RichardHeenan commented 4 years ago

Could someone track down the list of sasfit models etc, as the links above seem not to work at present??? Thanks!

pkienzle commented 4 years ago

The SasFit manual has a list of models in the table of contents. Many are already available in SasView, either directly or through reparameterization.

wpotrzebowski commented 4 years ago

@dehoni worked extensively on this on code camp V. Bellow are notes (probably some issues have been closed).

The list of SASview-Sasfit models can be cleaned up:

radial_profile_of... can be taken out of list. These are functions with the radial SLD profile for each model
akima8 is a spline interpolation

Implementation request for SASView

boucher sphere1/2 and boucher profile1/2

Description: analytical form factor model to determine the radial profile over sphere (see Sasfit doc and 1)

   http://trac.sasview.org/ticket/707

triaxial ellipsoidal core shell structure

    http://trac.sasview.org/ticket/708

spinodal model

Description: I(q) = I_max (1 + gamma/2) x2 / (gamma/2 +x(2+gamma) with I_max the scattering intensity at peak position, q_max the position of the correlation peak and ganmna is the decomposition epxonent background 2 .

http://trac.sasview.org/ticket/723

Broad peak:

    SASFit has the denominator to a power p. Idea is to build a generalised Broad Peak Model :

I(q) = scale_p/pow(q,exponent)+scale_l/pow((1.0 + pow((fabs(q-q_peak)*length_l),exponent_l) ),exponent_p)+ background

For q0 = 0, m = 2 and p = 1 one gets the Lorentz model. For q0 = 0, m = 2 and p = 2 The Broad-Peak model is identical to the Debye-

Anderson-Brumberger (dab) model. Which you then can save.

http://trac.sasview.org/ticket/724

CoreShellMicrogel:

    Description: Core shell structure with fuzzy interfaces of core and shell (see Sasfit Doc and 3)

http://trac.sasview.org/ticket/725

i_q__for_spin_misalignment:

Description: Magnetic structure factor describing the magnetic misalignment due to a particle with magnetocristalline anisotropy. In Sasfit, this is given for spherical particles, but it can be generealised for other shapes.

used fitting parameter K, applied field H, radius R and magnetic length l_H
fitting variables l_H= Sqrt(2A/(Ms Hi)) is actually itself a function of the field, so it should rather have as additional parameters A the exchange stiffness constant, and Ms the saturation magnetisation.
Moreover there exist another magnetic structure factor decribing spin canting due to magnetostatic dipolar fields around mmagnetic inhomogeneities. Please see 4 and references therein.

http://trac.sasview.org/ticket/726 Dependent on other models still do to

All superparamagnetic response models will need orientational distribution of the magnetic moments in magnetic models.

http://trac.sasview.org/ticket/713

Afterwards you can start to address the needed functions for Langevin distribution calculations:

sasfit_ff_langevin_tau: calculates Langevin Parameter from angular distribution of magnetic moments.

sasfit_ff_langevin: calculates magnetic moment from Langevin Parameter

time resolved SANS measurements work on the time dependence of intensity I(q FIXED, t) as function of static field B1, and oscillating magnetic field with amplitude B0, frequency nu and phase shift Rho.

Issue: Does Sasview allow data which are not I(q).

Note: Langevin are for monochromatic mode measurements and pulsed beam, time resolved mode is titled TISANE with different time resolution/smearing. Needs clarification/refactoring. Figure out where redundancies/duplications are, e.g.: Polarisation Analysis (PA) Models (4 states) are given as langevin/Tisane_down/up_down/up. It is possible to get the Polarised SANS Models (2 states): langevin_down/up by a simple sum of the PA models. SASFIT "special" models

Here discussion is needed how to integrate. Possibly one can refactor already existing models. Most of these models need proper references.

JuelichCoreShell

Description: It models a spherical core surrounded by two shells with parabolic and then star like density profile 5.

ellcylsh

Description: cylindrical shell with elliptical cross section.

fractal_series1/2/3

Description: Using the DAB model as form factor, the integration over a fractional size distribution of particles or sum of 2 or 3 of such distributions is performed.

All kind of variation of Form factors of core particle (cylinder, sphere, ...) surrounded by Gaussian chains (RW) or semi-flexible, self-avoiding chain (SAW) or power lax profile (a_Rc)

cylulv_chain_rw_
cylulv_chain_rw__tc
cylulv_chain_rw__nagg
ellulv_chain_rw_
ellulv_chain_rw__tc
ellulv_chain_rw__nagg
disc_chain_rw_
disc_chain_rw__nagg
disc_chain_rw__lc
sphulv_chain_rw_
sphulv_chain_rw__tc
sphulv_chain_rw__nagg

Form factor of short dimension (Pcs) for very anisometric systems (bilayers etc)

Possibly these can this be covered as limiting cases of existing models

pcs_ellcylsh
pcs_twoinfinitelythinlayers           
pcs_bilayergaus: bilayer with gaussian density profile
pcs_homogeneousplate: Plane with a homogeneous cross-section of thickness t
pcs_homogeneouscyl
pcs_layeredcentrosymmetricxs
pcs_plate_chains_rw_

sasfit_ff_magneticfieldalignedvesicleP2Psi/New: Form factor of aligned capped spheres 6.

c_r__for_spin_misalignment:

Description: Calculates the Correlation function C(r) of the magnetic misalignment around spherical particles with radius R with magnetic anisotropy K 7.

only makes sense if you want to fit the pair correlation function P(r)=r^2 C(r)
used fitting parameter K, applied field H, radius R and magnetic length l_H
fitting variables l_H= Sqrt(2A/(Ms Hi)) is actually itself a function of the field, so it should rather have as additional parameters A the exchange stiffness constant, and Ms the saturation magnetisation.

Missing Documentation

ellsh_sd_homoxs:???

cylsh_sd_homoxs: ???

disc_sd_homoxs: ???

ellsh_sd_bilayergauss: ??

cylsh_sd_bilayergauss:???

ellcylsh_sd_worm_ps1/2/3: ???

ellcylsh_sd_worm_kholodenko: ???

rodlike_micelle_plusprism: ???

triax_ellip_shell_sq_baba_ahmed_1/2: ???

kratkysphere: ??? Partially covered in SASView

rod

Description: a long, infinitely thin rod.

Might be covered with cylinder model for radius==0.
 http://trac.sasview.org/ticket/702: The cylinder model should give the formfactor of a long, infinitely thin rod or thin disk if diameter or lengh is set to zero, respectively.

linshell/radial_profile_of_linshell

Description: radial profile of LinShell which is a core shell form factor with a linear dependent contrast profile of the shell

covered by onion model in Sasview. Slighty different nomenclature in SASFit, which asks for ratios/fraction to calculate SLD slope.
 http://trac.sasview.org/ticket/695: Feature Request for Onion model: Is it possible to implement a linear slope for A !=0. Right now A !=0 gives a constant monotonic SLD given by SLDin.

beaucage_exppowlaw

with Rlarge=Rsmall covered in Sasview by unified_power_Rg in level2

beaucage_exppowlaw_2

with k=1 and Rlarge=Rsmall covered in Sasview by unified_power_Rg in level1

Covered in SASView

fuzzy_sphere

covered in Sasview. Scale differs by a factor of pi/2.

extended_guinier_law:

covered by guinier-porod in Sasview for porod exponent m->inf, but the scaling factor differs between Sasfit and Sasview

debye_anderson_brumberger: I_0/(1+(q*L)^2)^2

covered by dab in Sasview with  I_0= scale* L^3:  scale * L^3/(1 + (q*L)^2)^2.

expshell/radial_profile_of_expshell:

covered by onion model in Sasview

linshell2:

covered by onion model in Sasview

parallelepiped_abc:

covered by 1D parallelepiped model in Sasview

ornstein-zernicke:

covered by Lorentz model in Sasview

sphere_with_3_shells:

covered by core multi shell in Sasview

TeubnerStrey

covered by Teubner Strey

pearl-necklage

generalized_guinier_porod_law

covered by guinier porod in Sasview

Convergence of results of Sasview against Sasview were performed with testdata (please see testdata.zip ).