Piecewise functions and Convolution

119 views
Skip to first unread message

brombo

unread,
Sep 5, 2022, 11:42:49 AM9/5/22
to sympy
Would this be of any interest to anyone (see and run attached).  I have written a piecewise function class (not like the one already in sympy) where the piecewise function is defined on an ordered numerical grid (see attached).  The class in not finished but I can calculate the convolved powers of gate functions and will extend the class to calculate the convolution of two piecewise functions if sympy can integrate the member functions of the piecewise function.  My interest comes from knowing the Fourier transform of a gate function is a sinc function.  Thus the Fourier transform of a gate repeatedly convolved with itself is the power of a sinc function.  This is relevant to finding rf modulation envelopes that minimize  sidebands.  Please run the code an see if it of general interest and I will complete the class and documentation and submit it as an addition to sympy.
piecewise.py

brombo

unread,
Sep 6, 2022, 3:55:32 PM9/6/22
to sympy
Attached is the output of the latest piecewise.py (I got convolution, latex printing, and Asymptote ploting working)
convolutions.pdf
piecewise.pdf
Reply all
Reply to author
Forward
0 new messages