image thumbnail

Fresnel integrals

version (5.04 KB) by Christos Saragiotis
Calculates FresnelC, FresnelS integrals and their variations (C_1, C_2 and S_1 and S_2)


Updated 29 Oct 2008

View License

FRESNEL(X) calculates the values of the Fresnel integrals for real values of vector X,
C = \int_0^x cos(pi*t^2/2) dt, (0a)
S = \int_0^x sin(pi*t^2/2) dt (0b)
Also, it evaluates the following variations of the Fresnel integrals
C1 = \sqrt(2/pi) \int_0^x cos(t^2) dt, (1a)
S1 = \sqrt(2/pi) \int_0^x sin(t^2) dt (1b)
C2 = \sqrt(1/2/pi) \int_0^x cos(t) / \sqrt(t) dt, (2a)
S2 = \sqrt(1/2/pi) \int_0^x sin(t) / \sqrt(t) dt (2b)

The integrals are calculated as follows:
- Values of X in the interval [-5,5] are looked up in Table 7.7 in [1] and interpolated ('cubic'), if necessary. This table has values of the Fresnel integrals with 7 significant digits and even linear interpolation gives an error of no more than 3e-004.
- Values outside the interval [-5,5] are evaluated using the approximations under Table 7.7 in [1]. The error is less than

NOTE: The Tables were OCR'ed and although thoroughly checked, there might be some mistakes. Please let me know if you find any.

[1] Abramowitz, M. and Stegun, I. A. (Eds.). "Error Function and Fresnel Integrals." Ch. 7 in "Handbook of mathematical functions with formulas, Graphs, and mathematical tables", 9th printing. New York: Dover, pp. 295-329, 1970.

>> Y = fresnel(X,'c');
returns the Fresnel C integral according to eq. (0a)
>> Y = fresnel(X,'s',2);
returns the Fresnel S integral values according to eq. (2b)
>> [C,S] = fresnel(X,[],1)
returns the both the Fresnel C and S integral values according to eqs. (1a), (1b)
>> [C,S] = fresnel(X,[])
returns the both the Fresnel C and S integral values according to eqs. (0a), (0b)

Cite As

Christos Saragiotis (2021). Fresnel integrals (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2008a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Inspired: FresnelS and FresnelC

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!