summaryrefslogtreecommitdiff
path: root/lib/superfox/twkfreq2.f90
diff options
context:
space:
mode:
authorChristoph Berg <myon@debian.org>2024-09-30 22:36:11 +0200
committerChristoph Berg <myon@debian.org>2024-09-30 22:36:11 +0200
commit4320ce238aae1fe87fc9f379cdd816e9317885fa (patch)
treeb9d97364486fc8b7f79e8e877d5d491bb061740f /lib/superfox/twkfreq2.f90
parentfbaeaa72f63f22bf0b53d634f6809cbdfbb46c9f (diff)
New upstream version 2.7.0~rc7+repackupstream/2.7.0_rc7+repack
Diffstat (limited to 'lib/superfox/twkfreq2.f90')
-rwxr-xr-xlib/superfox/twkfreq2.f9019
1 files changed, 19 insertions, 0 deletions
diff --git a/lib/superfox/twkfreq2.f90 b/lib/superfox/twkfreq2.f90
new file mode 100755
index 00000000..443088c6
--- /dev/null
+++ b/lib/superfox/twkfreq2.f90
@@ -0,0 +1,19 @@
+subroutine twkfreq2(c3,c4,npts,fsample,fshift)
+
+! Adjust frequency of complex waveform
+
+ complex c3(npts)
+ complex c4(npts)
+ complex w,wstep
+ data twopi/6.283185307/
+
+ w=1.0
+ dphi=fshift*twopi/fsample
+ wstep=cmplx(cos(dphi),sin(dphi))
+ do i=1,npts
+ w=w*wstep
+ c4(i)=w*c3(i)
+ enddo
+
+ return
+end subroutine twkfreq2