Energy Vibration And Shell

Source: reference-book. Raw markdown: /raw/docs/reference-book/1-introduction/energy-vibration-and-shell.md

Let's introduce three high-level abstract concepts.

In Simorg's world, everything exists in the form of a Vibration. The concept of Vibration is similar to <<<Event>>> in a CPL, but soon we will see it's more than that. Let's see it by an example,

 $myVar

here <<<myVar>>> is a variable and at some point it can be vibrated.

Now, each Vibration needs a space. According to programming language terminology these spaces are called scopes. For example putting our variable inside curly braces like,

{
  $myVar
}

Simorg calls these spaces a Shell. Shells are a fundamental part of simorg's world modeling. Everything is a Shell and Vibrations are always wrapped in a shell. Simorg doesn't have the familiar concept of functions anymore. Although in some use cases the shells are appearing as classical functions.
Shells can wrap each other to create more complex structures. So the whole universe of simorg is build on top of interactions between vibrations and shells.

Long story short, the goal of writing simorg code is to create spaces in which data flows in order to become more conscious.

This behavior can be seen when we add a const vibration to our app like,

{
  "Hello World!" $myVar
}

This simple application can be represented by this shell diagram. As the engine starts, our <<<"Hello World!">>> value literal is first to vibrate. Then this vibration is reaching our variable <<<myString>>> and causing it to vibrate.

$$$ShellDiagram diagramId=REFERENCE_BOOK_0_INTRO_02_ENERGY_VIBRATION_AND_SHELL_HELLO_WORLD$$$

This diagram is using a slow motion animation to show what is happening behind vibrations and how they are wrapped by shells so creating new layers of data. Each color is representing a unique identity, or according to simorg's terminology a Frequency. As the vibrations move between shells, they are acquiring different frequencies. Frequency is the unique characteristic of a shell.

So simorg's engine is providing a medium in which the vibration can shape and flow. When a shell vibrates it adds its characteristic to underlying vibration (data). Thanks to this newly added layer, the data (vibration) becomes more conscious so it can flow inside more spaces and vibrate more shells. This cycle continues forever until data is reaching its destination.

Now that we have some basic ideas about Vibration and Shell, we can explain the Energy.

Actually, both Vibration and Shell are dealing with Energy in one way or another. A Vibration is a source of Energy that has been released. We call it vibration and not an "event" because it is an active element and a driving force of our application hence the energy. A Shell, on the other hand, is acting as a container/channel/vessel/space in which this energy can be at rest or flow. So Vibrations can happen inside a shell or later we will see they even can impact shells by entering or exiting from them. While vibrations are flowing in the system, they usually pass from multiple shells. These interactions gradually add new characteristics to our vibrations. We will discuss it in more details in next section.

As developers, we usually deal with data, and based on the business rules we decide how data should flow in our code. In Simorg, data is the vibration or energy. So in the above example, we can consider the <<<"Hello World!">>> string as our data which, is vibrated by Simorg's engine so it can flow in our system. Everything starts with a vibration.

As mentioned before, Simorg is changing the classical forms and brings a new form of thinking about software and digital elements.

Simorg equates Existence with vibration. Everything in the engine e.g. variables, constants exist because they can vibrate. In Simorg’s ontology, each being exists in order to create an impact and/or to be influenced in return. This leads to a purely byte-level, event-driven worldview which is executed by data hence we call it vibration.

In a not shell a vibration is representing an event and data driven paradigm woven together becoming the same.

Thanks to this approach Simorg completely removed the abstract unnecessary concept of Nothingness (null, undefined, None, nil etc.). How Nothingness can contain energy to flow?

$$$AlertBox type=INFO title=Amazing Topic Of Nothingness message=For many years owners of thought were puzzled by the concept of nothingness! Of course the state of nothingness is a valid state in the process of creating a new universe but it needs to be handled naturally. We as software engineers have seen the down side of mixing nothingness and existence in past decades by experiencing all forms of exceptions and errors in this regard! We forgot that nothingness doesn't need its own handlers but it should be solved by existence itself just as how the light removes the darkness $$$

Now, when you hear the terms vibration, energy and shell, the first thing that comes to mind is a physical system—and that is totally fine. Physical concepts are wrapping low-level mathematical concepts. So in order to be able to create a digital universe on top of our mathematical engine, we need to first create a physical layer on top of it. The limitless nature of mathematics needs to be limited by physical rules in order to create a bounded digital universe.

Don't worry if these concepts sound a bit unusual at first glance. Soon we will see how they work in action using many examples.

About Runtime

Let's briefly talk about simorg's engine.

Pure event driven nature of simorg is introducing new paradigms in programming. In this approach, the order of the code is no longer important, unless for some reason you decide to make it important. Vibration is determining what needs to go next not the line of the code that we write. Of course variable declaration is the only exception to this rule. A Variable declaration needs to be done before the usage. For now we are just focusing on logic.

For example, these two code snippets are equivalent and both of them will successfully log the value of <<<x>>> using logger operator <<<:?>>> the same exact way.

$x 
10  x
x ? // logger is after variable's assignment
$x 
x ? // logger is before variable's assignment
10  x

This is quite natural for simorg because the code now is completely event driven.

Simorg's engine is using a concept called <<<Tick>>>. Tick, is a unit of processing in which engine gathers as much as possible vibrations to process them. During a tick vibrations are sent to target shells in order to be processed then results are gathered in order to shape the next tick. This process continues until there are no more vibrations in the queue.

This architecture is leading to interesting results.

  • Parallel processing and multi-threading is now handled by engine.
  • Engine is free to use different hardwares as it sees fit to the amount of processing needed in a tick. It means it can decide to use GPU along the CPU or any other ASIC.

$$$test.svg$$$

For now, we will stop there and come back to this topic in more details in future.