# Physics 203 at Portland State 2014

### Site Tools

digital_sound_project
A PCRE internal error occured. This might be caused by a faulty plugin

====== Differences ====== This shows you the differences between two versions of the page.

digital_sound_project [2014/05/29 06:23]
wikimanager [Digitizing the sound]
digital_sound_project [2014/06/04 03:53] (current)
Line 288: Line 288:
SetAxis bottom 0,​.04</​code> ​ SetAxis bottom 0,​.04</​code> ​
* This highlights the striking differences in intensity.         * This highlights the striking differences in intensity.
+  -  The other thing is I have been looking at Fourier series calculations and have seen the use of integrals when looking at the Fourier coefficients. Should I be concerned about this?
+    * **Answer**: there are two kinds of Fourier transforms: [[wp>​Fourier transform|continuous]] (liked by theorists) and [[wp>​Discrete Fourier transform|discrete]] (used in numerical computations). The two kinds are closely related, and in the limit of small grid spacing (small dwell time $\Delta t$) they approximately give the same results. But, the continuous transform uses integrals, whereas the discrete one uses simple sums.  You don't need to worry about this too much, just use it as a tool that already works. When you write about it, just say that it decomposes the time-dependent signal into a linear superposition of pure sine and cosine waves at various frequencies on a frequency grid, and gives you the combined amplitude at each frequency, as a function of the point on the frequency grid.
+  - Is there a way to copy and paste the plots from Igor pro into a document or is there another way to display the plots in a document?
+    * **Answer**: You can use
+      * "​screenshots"​ (will work for any screen content, not just IGOR plots) ​
+        * explained in [[white_noise_project#​software_and_data_analysis|the white noise project, Software and data analysis, Item 10]] <- click on the green link
+      * Or, in IGOR, after clicking on your graph, go to the ''​File''​ menu, ''​Save Graphics...''​ submenu, and select ​
+        * the format (PNG or JPEG_
+        * resolution (Other DPI, then 300)
+        * file name -- the name of the picture file that IGOR will create for you
+        * path (home -- will save in the same directory on your computer where you have saved your .pxp experiment
+        * force overwrite -- if you already have that picture file and want to improve it
+      * Then just insert the picture file into your report as picture
+
+====Tips and suggestions====
+  - You can simulate clipping by using the following commands (assuming you want to clip ''​wave2''​ that already exists):
+    * the function ''​=min(...,​...)''​ returns the smaller of the two arguments
+    * the function ''​=max(...,​...)''​ returns the larger of the two arguments
+    * before you start, you need to set up your ''​low''​ and ''​high''​ variables fist: <​code>​Wavestats/​Q wave2; print V_min,V_max // this line finds the min and max of wave2
+Variable/G clip_perc=80 // this creates a variable for storing the clipping percentage
+Variable/G low=clip_perc*V_min/​100,​high=clip_perc*V_max/​100 // sets low and high thresholds for clipping</​code>​
+      * Here the ''​%%//​%%''​ is the "​comment"​ symbol, it tells IGOR to ignore the remainder of the line, allowing you to comment your code
+    * now create another wave and combine the ''​min()''​ and ''​max()''​ as ''​max(low,​min(high,​...))'':​ <​code>​Duplicate/​O wave2,​wave2_clipped // create an identical wave2_clipped first
+wave2_clipped=max(low,​min(high,​wave2)) // now do the clipping</​code>​ to limit the values in wave2_clipped to be within the [low,high] range
+    * you can achieve different levels of clipping by setting ''​clip_perc''​ closer to 0 (more severe clipping) or closer to 100 (more gentle)
+    * you can display the clipped wave as a plot, calculate and display its spectrum, and play it to listen how it sounds
+
=====References and Footnotes===== =====References and Footnotes=====
====Cited references==== ====Cited references====