Home > Scripts > Models > lorz1.m

iFit/lorz1

PURPOSE ^

y = lorz1(p, x, [y]) : Lorentzian without background

SYNOPSIS ^

function y=lorz1(varargin)

DESCRIPTION ^

 y = lorz1(p, x, [y]) : Lorentzian without background

   iFunc/lorz1 Lorentzian fitting function without background
     y = p(1)*p(3)/2/pi ./ ((x-p(2)).^2 +(p(3)/2).^2);

   The Amplitude is 2/pi/p(3)

 lorz1(width)          creates a model with a specified width
 lorz1([ parameters ]) creates a model with specified model parameters

 Reference: http://en.wikipedia.org/wiki/Lorentzian_function

 input:  p: Lorentzian model parameters (double)
            p = [ Intensity Centre HalfWidth ]
          or 'guess'
         x: axis (double)
         y: when values are given and p='guess', a guess of the parameters is performed (double)
 output: y: model value
 ex:     y=lorz1([1 0 1], -10:10); or plot(lorz1)

 Version: Aug. 22, 2017
 See also iFunc, iFunc/fits, iFunc/plot, gauss, lorz
 (c) E.Farhi, ILL. License: EUPL.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:
Generated on Tue 22-Aug-2017 11:03:30 by m2html © 2005. iFit (c) E.Farhi/ILL EUPL 1.1