Recent

Author Topic: The sound of the universe;)  (Read 10070 times)

mpknap

  • Full Member
  • ***
  • Posts: 155
The sound of the universe;)
« on: November 04, 2020, 08:03:00 pm »
I recently saw on the pages of probably NASA, sonification of galaxies and other deep sky objects. Example:

https://www.youtube.com/watch?v=IHdLGA146sg
 
Anyone know how to do something similar in Lazarus?
Load picture and play pitch dependent of pixel brightness.

I've been looking through the sound libraries and can't see the idea.


winni

  • Hero Member
  • *****
  • Posts: 3197
Re: The sound of the universe;)
« Reply #1 on: November 04, 2020, 10:27:42 pm »
 Hi!

The basic idea for this is that everything is a wave.

In the micro world with high frequency waves for your mobile or TV or radio through the air .
In "our" world like listening to waves between 20 and 20.000 Hertz.
Or watching colors between 450 and 750 THz

Now you can enlarge the system to the planets: Jupiter needs 11.7 years for one turn.
The oktave comes into the play: if you bisect or duplicate a frequency you get the next deeper or higher octave.  If you do that often enough you get into the range of the ear or the eye:

You now can build a relationship between a planet and a color or a tone.

One of the very first programms (applications were not invented ....) on a Comodore 64 was the "Sound of the planets" were they did exactly that: Build a relationship from Mercury to Pluto to their tones. (Yes, Pluto was a Planet then! ) Sometimes nice, sometime sharp.

So the algorithm is very easy. But where you have to take care is the range of the Double or the Int64. I don't know if they are wide enough for Color To Sound..

And for the colors you got the HSL model (Hue - Saturation - Lightness) which represent the rainbow colors - starting from red up to indigo.

If any questions: ask.

Winni


Fred vS

  • Hero Member
  • *****
  • Posts: 3505
    • StrumPract is the musicians best friend
Re: The sound of the universe;)
« Reply #2 on: November 04, 2020, 11:01:35 pm »
@ Winni.

Perfectly explained.

You may also create relation between colors and musical notes (7 colors of rainbow and 7 notes in music).
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

Fred vS

  • Hero Member
  • *****
  • Posts: 3505
    • StrumPract is the musicians best friend
Re: The sound of the universe;)
« Reply #3 on: November 04, 2020, 11:25:12 pm »
Quote
(Yes, Pluto was a Planet then! )

Hum, we have to re-count the votes....

https://www.space.com/pluto-still-a-planet-nasa-chief-says.html
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

dsiders

  • Hero Member
  • *****
  • Posts: 1377
Re: The sound of the universe;)
« Reply #4 on: November 05, 2020, 12:08:16 am »
@ Winni.

Perfectly explained.

You may also create relation between colors and musical notes (7 colors of rainbow and 7 notes in music).

Really? The black keys must have been a bonus...
Preview the next Lazarus documentation release at: https://dsiders.gitlab.io/lazdocsnext

Fred vS

  • Hero Member
  • *****
  • Posts: 3505
    • StrumPract is the musicians best friend
Re: The sound of the universe;)
« Reply #5 on: November 05, 2020, 12:26:17 am »
@ Winni.

Perfectly explained.

You may also create relation between colors and musical notes (7 colors of rainbow and 7 notes in music).

Really? The black keys must have been a bonus...

Hum, I was talking about the names.

Of course there are comas between notes on a violin, on a piano sharp (or flat) black keys ,...

But, afaik, there are only 7 names for notes: Do, Ré, Mi, Fa, Sol, La, Si (or A, B, C , D, E, F, G in English notation).

The same for the colors of the rainbow, there are colors between 2 names.

Those 7 names of colors of Rainbow are: Red, Orange, Yellow, Green, Blue, Indigo and Violet.

I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

winni

  • Hero Member
  • *****
  • Posts: 3197
Re: The sound of the universe;)
« Reply #6 on: November 05, 2020, 12:30:46 am »
Hi!

Thanx Fred.

With the waves you can build realy crazy relationships:

Check on which frequency your phones is working.
Now check out the color ...

Check on which channel (= frequency) your favourite TV is broadcasting.
Compute the tone ....
Or look if there is a fitting planet

I always found the frequeny stuff fascinating but good old Johannes Kepler gave me the thrill.
For example he computed for the visible planets (up to Saturn) the relationship between the small axis and the long axis. And then he interpreted it as  two music notes. 

Kepler was so much more than only an astronomer.

And now to Pluto:
Thanx for the link. Yes this Nasa man is right.
What are they afraid of?
The "wonderful" arrangement gets lost. Starting with Pluto: very elliptical,  17° away from the other planets. And a lot of other "space trash" is behind Pluto  Like  a TransPluto first called Xenia. Now it is named Eris. There are now 8 other "objects" detected. With not so "nice" ellipses around the sun.

Voyager 4 might have seen some of  them .....

Winni

« Last Edit: November 05, 2020, 12:40:41 am by winni »

winni

  • Hero Member
  • *****
  • Posts: 3197
Re: The sound of the universe;)
« Reply #7 on: November 05, 2020, 12:38:19 am »

Really? The black keys must have been a bonus...

Hi!

Sell the white keys as ivory. With the remaing 5 black keys you can play Pentatonic.
That's what was used in a lot of natural tribes.

It is said that this way the Blues was created:

When the slaves were forced to America they were unshure about the third and the seventh:
They did not have that. So they used the minor or the  major or something inbetween:
The Blues was born.

Winni

Fred vS

  • Hero Member
  • *****
  • Posts: 3505
    • StrumPract is the musicians best friend
Re: The sound of the universe;)
« Reply #8 on: November 05, 2020, 12:58:44 am »
Sell the white keys as ivory. With the remaing 5 black keys you can play Pentatonic.

OK, done (but I've kept the Fa key cause I love to play Take 5).
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

winni

  • Hero Member
  • *****
  • Posts: 3197
Re: The sound of the universe;)
« Reply #9 on: November 05, 2020, 01:10:24 am »

OK, done (but I've kept the Fa key cause I love to play Take 5).

Strange 5/4
Only Led Zeppelin did that in heavy Rock'n'Roll

Winni

Fred vS

  • Hero Member
  • *****
  • Posts: 3505
    • StrumPract is the musicians best friend
Re: The sound of the universe;)
« Reply #10 on: November 05, 2020, 01:20:36 am »
I recently saw on the pages of probably NASA, sonification of galaxies and other deep sky objects. Example:

https://www.youtube.com/watch?v=IHdLGA146sg
 
Anyone know how to do something similar in Lazarus?
Load picture and play pitch dependent of pixel brightness.

I've been looking through the sound libraries and can't see the idea.

For the image you may use BGRABitmap library.
https://github.com/bgrabitmap/bgrabitmap

For the sound, if you want to play sounds from files or memory, produce sine-wave sounds or combine both, you may use uos library.
https://github.com/fredvs/uos/

Also available through the Online Package Manager.
Main Menu --> Package -->  Online Package Manager --> UOS

« Last Edit: November 05, 2020, 01:37:59 am by Fred vS »
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

jamie

  • Hero Member
  • *****
  • Posts: 6836
Re: The sound of the universe;)
« Reply #11 on: November 05, 2020, 01:26:37 am »
I recently saw on the pages of probably NASA, sonification of galaxies and other deep sky objects. Example:

https://www.youtube.com/watch?v=IHdLGA146sg
 
Anyone know how to do something similar in Lazarus?
Load picture and play pitch dependent of pixel brightness.

I've been looking through the sound libraries and can't see the idea.

If you install the Acs package which can be found in the Online package manager near the top of the list, it gives you simple controls to record or play sounds.
you can create yourown sounds and play them through this interface.

 as for the octives, you can create them via the RGB color values as you scan it veritically.

The only true wisdom is knowing you know nothing

winni

  • Hero Member
  • *****
  • Posts: 3197
Re: The sound of the universe;)
« Reply #12 on: November 05, 2020, 01:33:18 am »
Hi!

BGRAbitmap is available through the  Online Package Manager.

Main Menu --> Package -->  Online Package Manager

Winni

Fred vS

  • Hero Member
  • *****
  • Posts: 3505
    • StrumPract is the musicians best friend
Re: The sound of the universe;)
« Reply #13 on: November 05, 2020, 02:19:22 am »

OK, done (but I've kept the Fa key cause I love to play Take 5).

Strange 5/4
Only Led Zeppelin did that in heavy Rock'n'Roll

Winni

I like too the 7/4  (Pink Floyd and Money).
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

dsiders

  • Hero Member
  • *****
  • Posts: 1377
Re: The sound of the universe;)
« Reply #14 on: November 05, 2020, 02:25:57 am »

OK, done (but I've kept the Fa key cause I love to play Take 5).

Strange 5/4
Only Led Zeppelin did that in heavy Rock'n'Roll

Winni

I like too the 7/4  (Pink Floyd and Money).

And just for fun, the 13/4 sections in Have a Cigar.
Preview the next Lazarus documentation release at: https://dsiders.gitlab.io/lazdocsnext

 

TinyPortal © 2005-2018