How can i use a function like soundsc to convert a table to a sound
1 view (last 30 days)
Show older comments
Hello everyone, For university work, i had to modelize a guitare string in motion. That's done but now i have my motion, i want to know if i can get the sound due to this mouvement as a sound file, or just a sound to the speaker. After research on the matlab help, i found 2 function : sound and soundsc. My probleme is that i don't understand very well how it's work. When i put a table of the energy of my string in the time, a sound come but, with some parasites. There are my questions :
- First, what is exactly the difference between sound and soundsc ?
- These function need a table of maximum 2 line, i don't understad very well what it is needed for parameter, could you explain ?
Thank's for your answer.
0 Comments
Answers (1)
Star Strider
on 29 May 2015
The sound function sends the audio signal to the speaker without altering it. The soundsc function scales it to be between [-1,+1] first.
Both functions take between 1 and 3 arguments, the signal vector (or matrix if a stereo signal), the sampling frequency (the default is 8192 Hz), and the bit depth of the signal (default is 8). Only the first argument is required.
2 Comments
Star Strider
on 29 May 2015
In your application, it would be string motion. You would need to supply your vector of guitar-string simulation results and the sampling frequency you chose in your simulation. You may want to experiment with various bit depths.
See Also
Categories
Find more on Simulation, Tuning, and Visualization in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!