V3FIT
|
This module containes functions used by the profiles. More...
Functions/Subroutines | |
real(rprec) pure function, public | two_power (x, b) |
A two power profile. More... | |
real(rprec) pure function, public | two_power_gs (x, b) |
A two power profile with added guassian peaks. More... | |
real(rprec) pure function | guassian (x, b) |
A profile with a single guassian peak. More... | |
real(rprec) pure function | guassian_int (x, b) |
A profile with a integrated single guassian peak. More... | |
logical function, public | function_test () |
Profile unit test function. More... | |
logical function, private | check (expected, received, testNum, name) |
Check a value. More... | |
This module containes functions used by the profiles.
|
private |
Check a value.
Checks that the expected value matches the recieved. Otherwise report an error.
[in] | expected | The known value. |
[in] | received | The known test value. |
[in] | testNum | The number of the test. |
[in] | name | The name of the test. |
Definition at line 231 of file functions.f.
logical function, public functions::function_test |
Profile unit test function.
This runs the associated unit tests and returns the result.
Definition at line 166 of file functions.f.
real(rprec) pure function functions::guassian | ( | real(rprec), intent(in) | x, |
real(rprec), dimension(0:20), intent(in) | b | ||
) |
A profile with a single guassian peak.
This defines a profile with a single guassian peak.
b(0)*Exp(-(x - b(1))/b(2)) ** 2 (1)
b(0) controls the amplitude. b(1) controls the mean. b(2) controls the width.
[in] | x | Point to evaluate function from. |
[in] | b | Array of profile parameters. |
Definition at line 106 of file functions.f.
real(rprec) pure function functions::guassian_int | ( | real(rprec), intent(in) | x, |
real(rprec), dimension(0:20), intent(in) | b | ||
) |
A profile with a integrated single guassian peak.
This defines a profile with a with an integarted single guassian peak.
Sqrt(2Pi)/2*b(0)*b(1)*(Erf(b(1)/b(2)) - Erf((b(1) - x)/b(2))) (1)
b(0) controls the amplitude. b(1) controls the mean. b(2) controls the width.
[in] | x | Point to evaluate function from. |
[in] | b | Array of profile parameters. |
Definition at line 137 of file functions.f.
real(rprec) pure function, public functions::two_power | ( | real(rprec), intent(in) | x, |
real(rprec), dimension(0:20), intent(in) | b | ||
) |
A two power profile.
A two power profiles is defined using 3 parameters.
b(0) * (1.0 - x ** b(1)) ** b(2) (1)
b(0) controls the profile amplitude. b(1) controls the profile width. b(2) controls the profile tail.
[in] | x | Point to evaluate function from. |
[in] | b | Array of profile parameters. |
Definition at line 40 of file functions.f.
real(rprec) pure function, public functions::two_power_gs | ( | real(rprec), intent(in) | x, |
real(rprec), dimension(0:20), intent(in) | b | ||
) |
A two power profile with added guassian peaks.
The power profile is defined as functions::two_power. Then up to 9 additional guassians peaks can be added.
two_power(x)*(1 + Sum[b(i)*Exp(-(x - b(i+1))/b(i+2)) ** 2]) (1)
Parameters beyond the first three control the additional guassians. b(i) controls the amplitude. b(i+1) controls the mean. b(i+2) controls the width.
[in] | x | Point to evaluate function from. |
[in] | b | Array of profile parameters. |
Definition at line 70 of file functions.f.