|
From: | Prof. Dr. Peter Schulz |
Subject: | behaviour of "save" function by saving int16 vector |
Date: | Fri, 8 May 2020 23:37:53 +0200 |
User-agent: | Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 |
Hi,why is octave, when using "save" for writing an int16 vector/matrix with -ascii option, writing the integer numbers in exponential form and not as plain integer numbers?
I'd like to adjust this so that I only have pure integer numbers in the file like they
are shown in the workspace window. Is it possible? Kind regards Peter Schulz fs = 48000; freq1 = 1000; tone1 = 0.5*sin(2*pi*freq1* (1:.1*fs)/fs); freq2 = 1011; tone2 = 0.25*sin(2*pi*freq2* (1:.1*fs)/fs); tone_sum = tone1 + tone2; tone_sum_int16 = int16(round(tone_sum * 0x7fff)); save -ascii tone_mix.txt tone_sum_int16;
[Prev in Thread] | Current Thread | [Next in Thread] |