Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
But it's okay to eat fish, cause they don't have many feet and ...
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  5 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
A.D. Fundum  
View profile  
 More options Oct 24 2011, 4:12 am
Newsgroups: comp.os.os2.multimedia, comp.os.os2.programmer.misc
From: "A.D. Fundum" <what.e...@neverm.ind>
Date: Mon, 24 Oct 2011 10:12:09 +0200
Local: Mon, Oct 24 2011 4:12 am
Subject: But it's okay to eat fish, cause they don't have many feet and ...
Like spacing door hinges when hanging a new door, is there a
way/formula/trick to improve the DosBeep()-code below in such a way
that the different frequencies sound as different as possible to a
human, while the difference between two frequencies sounds spaced
properly?

For example, it may be hard to hear the difference between 38,000 and
39,000 Hz while the difference between 100 and 716 Hz is very, very
clear. So a fixed value (here: 616) doesn't work well for all
frequencies.

--

#define INCL_DOSPROCESS
#include <os2.h>
int main(void)
{
ULONG frequency;

for (frequency=100;frequency<4000;frequency+=616)
   DosBeep(frequency,(ULONG)250);

return 0;


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Lars Erdmann  
View profile  
 More options Oct 24 2011, 12:50 pm
Newsgroups: comp.os.os2.multimedia, comp.os.os2.programmer.misc
From: "Lars Erdmann" <lars.erdm...@arcor.de>
Date: Mon, 24 Oct 2011 18:50:50 +0200
Local: Mon, Oct 24 2011 12:50 pm
Subject: Re: But it's okay to eat fish, cause they don't have many feet and ...
You need an linear increase in spacing (I think). Frequency ranges double
with every octave.

A : 220 Hz
a1: 440 Hz
a2: 880 Hz
a3: 1760 Hz
etc.

You can fit a curve y = f(x) to these values. The 12 "intermediate" half
notes are evenly spaced on the x axis, the resulting frequency can be found
on the y axis.

Therefore something like this:

for (frequency=100,step=1;frequency<4000;frequency+=(step*C),step++)
  DosBeep(frequency,(ULONG)250);

with "C" being a constant.

Lars

"A.D. Fundum" <what.e...@neverm.ind> schrieb im Newsbeitrag
news:o8uYFJ3iqTdG-pn2-t4dl26oX2GCF@localhost...


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
James J. Weinkam  
View profile  
 More options Oct 24 2011, 7:44 pm
Newsgroups: comp.os.os2.multimedia, comp.os.os2.programmer.misc
From: "James J. Weinkam" <j...@cs.sfu.ca>
Date: Mon, 24 Oct 2011 16:44:04 -0700
Local: Mon, Oct 24 2011 7:44 pm
Subject: Re: But it's okay to eat fish, cause they don't have many feet and ...

A.D. Fundum wrote:
> Like spacing door hinges when hanging a new door, is there a
> way/formula/trick to improve the DosBeep()-code below in such a way
> that the different frequencies sound as different as possible to a
> human, while the difference between two frequencies sounds spaced
> properly?

> For example, it may be hard to hear the difference between 38,000 and
> 39,000 Hz while the difference between 100 and 716 Hz is very, very
> clear. So a fixed value (here: 616) doesn't work well for all
> frequencies.

You need a geometric sequence, not an arithmetic one; i.e., constant ratio, not constant difference.

If you look at a piano keyboard, the interval between two adjacent keys is a semitone. If even
tempered tuning is used, the ratio of the frequencies of two adjacent keys is 2**(1/12). The A above
middle C is normally tuned to 440Hz (concert pitch). The lowest note on the piano is then 27.5Hz.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
A.D. Fundum  
View profile  
 More options Oct 25 2011, 6:56 am
Newsgroups: comp.os.os2.programmer.misc, comp.os.os2.multimedia
From: "A.D. Fundum" <what.e...@neverm.ind>
Date: Tue, 25 Oct 2011 12:56:20 +0200
Local: Tues, Oct 25 2011 6:56 am
Subject: Re: But it's okay to eat fish, cause they don't have many feet and ...
 > You need an linear increase in spacing (I think).
 > Therefore something like this:

 > for
(frequency=100,step=1;frequency<4000;frequency+=(step*C),step++)
 > DosBeep(frequency,(ULONG)250);

 > with "C" being a constant.

Exactly, thanks! IRL I've another frequency range and a fixed number
of "piano keys", but that;'s an easy adjustment.

--


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
A.D. Fundum  
View profile  
 More options Oct 25 2011, 7:41 am
Newsgroups: comp.os.os2.programmer.misc, comp.os.os2.multimedia
From: "A.D. Fundum" <what.e...@neverm.ind>
Date: Tue, 25 Oct 2011 13:41:36 +0200
Local: Tues, Oct 25 2011 7:41 am
Subject: Re: But it's okay to eat fish, cause they don't have many feet and ...
 > If you look at a piano keyboard, the interval between two
 > adjacent keys is a semitone.

Right, an equal interval indeed was the underlying problem.

 > If even tempered tuning is used, the ratio of the frequencies
 > of two adjacent keys is 2**(1/12). The A above middle C is
 > normally tuned to 440Hz (concert pitch). The lowest note on
 > the piano is then 27.5Hz.

And thanks for expanding this to the frequency range.

--


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »