First steps in computer science

I wonder how to start studying theoretical computer science and how to apply it to my programming. I am quite familiar with the basic programming, as I have been programming mainly in C ++, but also in Java in recent years. Therefore, I do not necessarily need an introduction to programming.

What I am aiming for at the beginning may be something quite broad, so there is a broad overview of computer science, as I do not know exactly where I would like to study in it. But it might also be nice to have instructions where to look to further study a particular aspect. However, this is exactly what I find helpful, and I am open to any recommendations.

Computer Science – The correctness of a statement regarding the pumping lemma and the regular language

I studied automaton theory and came across the pumping lemma, which I understand as:

To let $ mathcal {A} = langle Sigma, Q, q_0, F, delta rangle $ to be an NFA. Accept $ x in L ( mathcal {A}) $ s.t. $ | x | geq | Q | $, Then can be divided into x $ u, v, w, | v | geq 1 $s.t. $ x = uvw $ and for everyone $ i geq 0 $. $ uv ^ iw in L ( mathcal {A}) $

I had to consider if the following statement is correct:

To let $ L $ be a language. If for every word $ x in L $, there is $ u, v, w $s.t. $ uvw = x $ and for everyone $ i geq 0 $. $ uv ^ iw in L $, then $ L $ is regular

My idea is that no matter what $ u, v, w $ we decide to partition $ x $We can always construct NFAs that accept $ u, v, w $, respectively. And we can also construct an NFA that accepts $ v ^ i $ to the $ i geq 0 $, So if we take over the Union of NFAs, we'll get it $ A_x = bigcup ^ {} _ {uvw s.t uvw = x} A_ {uvw} $, Where $ A_ {uvw} $ is the NFA that has accepted the words of the form $ uv ^ iw $, to the $ i geq 0 $, if $ uvw = x $, If we take the Union of these NFAs, we get $ A_x $This is the NFA that takes care of all the possible words that are generated by $ x $, The final NFA is then $ A = bigcup {} _ {x in L} A_x $, in order to $ L $ is regular.

But I'm really new to automata theory, so I'm not sure if my idea is right. Every answer is grateful, thanks in advance.

Logic – Euclidean Models – Computer Science Stack Exchange

It is indeed true. As an indication, the Euclidean property
$$ xRy quad & quad xRz implies yRz $$
does not require the $ x, y, z $ to be different. So, for example, it implies
$$ xRy quad & quad xRy implies yRy. $$

Try to construct a 4-world counterexample model $ w, x, y, z $ Where $ phi $ just stops in $ z $ and where $ wRx, xRy, yRz $,

Help the science and make money $

Guys, I want to share a great site to make money – Lifeinspace – lifeinspace.org

With Lifeinspace you can borrow the free computing power of your computer for scientific calculations and be rewarded for it.

It's very simple, you do not have to do anything.
All you have to do is register and start earning
lifeinspace.org

Let me describe in more detail
1. Register on the website.
2. Log in to your profile.
3. Click the button to start the calculation process when data is available for the calculation process.
4. In your profile, you can see the number of clusters of processed data and how much money you have received.
5. If the amount is greater than $ 5, you can pay on Paypal
6. If you receive the money for your Paypal, please write your feedback on this topic.

Help the science and make money

Guys, I want to share a great site to make money – https://lifeinspace.org

With Lifeinspace you can borrow the free computing power of your computer for scientific calculations and be rewarded for it.

It's very simple, you do not have to do anything.
All you have to do is register and start earning

https://lifeinspace.org

Deadlocks in the Operating System – Computer Science Stack Exchange

I assume you know that $ 4 $ Conditions that are required for the system to be in a deadlock.

Let's see if there are any $ n $ Processes in the system $ P_1, P_2, P_3, ……, P_n $ Where

process $ P_1 $ requires $ x_1 $ commodity units $ R $

process $ P_2 $ requires $ x_2 $ resource units $ R $

process $ P_3 $ requires $ x_3 $ resource units $ R $

…..

process $ P_n $ requires $ x_n $ resource units $ R $

In the worst case, for a deadlock to exist, the number of units each process contains is one less than the maximum requirement. So we can say that the system is deadlocked.

process $ P_1 $ keeps $ x_1 -1 $ resource units $ R $

process $ P_2 $ keeps $ x_2 -1 $ resource units $ R $

process $ P_3 $ keeps $ x_3 -1 $ resource units $ R $

…..

process $ P_n $ keeps $ x_n -1 $ resource units $ R $

To overcome the impasse, we only need one resource unit $ R $ In the system.
This is because this unit is assigned to one of the processes, executed, and then releases the resources it contains that can be used by other processes.

From here we can say

Maximum number of resource units $ R $ that secures deadlock

$ = (x_1-1) + (x_2-1) + (x_3-1) + …. + (x_n-1) $

$ = (x_1 + x_2 + x_3 + …. + x_n) – n $

$ = sum_ {x = 1} ^ nx_i – n $

Now in your question, $ n = 6 $ and $ x_i = 2 $, The values ​​of $ x_i $ and $ n $

$ = 2 + 2 + 2 + 2 + 2 + 2 – 6 $

$ = 6 $

So the maximum units of $ R $ required to cause deadlock $ 6 $

Which subjects do you need to study to write science fiction novels?

Nothing. No costs at all.

Fiction. Is not it. Just put it together in a crazy logic and justify it yourself. Actually, if you've been in class from elementary school to high school, you should get along perfectly. Most do not, shitty sci-fi stories.

If you had gone to college and studied one of these sciences, you would not write science fiction. They would hate it and stick to the truth instead.

Algorithms – Non-Boolean SAT – Computer Science Stack Exchange

I was wondering how complex SAT tests are with variables $ x_i = 0 lor 1 lor 2 dots lor n $, where clauses are of the form $ x_i = a implies x_j neq b $, When $ n = 2 $We have 2SAT with linear time algorithms. Meanwhile, if $ n> 2 $If we can then almost convert it to 2SAT by having Boolean variables $ x_ {i, a} $ according to the statement $ x_i = a $However, this allows $ x_ {i, 1} = x_ {i, 2} = dots = x_ {i, n} = 0 $that would leave $ x_i $ unallocated.