complexity theory – Classes of Functions Closed Under Polynomial Composition – Papadimitriou Exercise 7.4.4

I am studying Computation complexity using Papadimitrious’s book: “Computational Complexity”.

I am trying to do Problem 7.4.4:

“Let $C$ be a class of functions from nonnegative integers to nonnegative integers. We say that $C$ is closed under left polynomial composition if $f(n) in C$ implies $p(f(n))=O(g(n))$ for some $g(n) in C$, for all polynomials $p(n)$. We say that $C$ is closed under right polynomial composition if $f(n) in C$ implies $f(p(n))=O(g(n))$ for some $g(n) in C$, for all polynomials $p(n)$.

Intuitively, the first closure property implies that the corresponding complexity class is “computational model-independent”, that is, it is robust under reasonable changes in the underlying model of computation (from RAM’s to Turing machines, to multistring Turing machines, etc.) while closure under right polynomial composition suggests closure under reductions (see the next chapter).”

Which of the following classes of functions are closed under left polynomial composition, and which under right polynomial composition?

(a) – ${n^k: k > 0 }$

(b) – ${k cdot n: k > 0 }$

(c) – ${k^n : k > 0 }$

(d) – ${2^{n^k} : k > 0 }$

(e) – ${log^k n: k > 0 }$

(f) – ${log n}$

After understanding the definition of closed under left/right polynomial composition, I think I was able to solve items (a), (b), (c) and (f). However, I was not able to solve items (d) and (e).

My solution for item (a):

Closed Under Left Polynomial Composition: consider an arbitrary $f(n) in C$ and an arbitrary polynomial $p(n)$. Then, $f(n)$ is of the form $n^{k’}$, for some $k’ > 0$ and therefore $p(f(n))$ is a polynomial. Let $k”$ be the degree of the polynomial $p(f(n))$. Take $g(n) = n^{k”} in C$ and we have $p(f(n)) = O(g(n))$.

Closed Under Right Polynomial Composition: same reasoning.

My solution for item (b):

Not Closed Under Left Polynomial Composition: consider as a counterexample $f(n) = n in C$ and $p(n) = n^2$. Then, $p(f(n)) = n^2$. For every $g(n) = k n in C$ we have $O(g(n)) = O(n)$. Since $n^2 neq O(n)$ we conclude.

Not Closed Under Right Polynomial Composition: the previous counterexample applies.

My solution for item (c):

Closed Under Left Polynomial Composition: Consider an arbitrary $f(n) = k_1^n$ and a polynomial $p(n)$. Notice that $p(f(n))$ is a polynomial in $k_1^n$. For sufficiently large $n$, there exists some $k_2$ such that $p(n) leq n^{k_2}$ and therefore $p(f(n)) leq (f(n))^{k_2} = (k_1^{n})^{k_2} = (k_1^{k_2})^n$. Therefore, taking $g(n) = (k_1^{k_2})^n in C$ we obtain that $p(f(n)) = O(g(n))$.

Not Closed Under Right Polynomial Composition: Consider as a counterexample $f(n) = 2^n$ and $p(n) = n^2$. Then, $f(p(n)) = 2^{n^2}$, which is greater than $g(n) = k^n$, for every fixed value of $k$, if $n$ is sufficiently large. Therefore, $f(p(n)) not in O(g(n))$.

My solution for (f):

Not Closed Under Left Polynomial Composition: Consider as a counterexample $f(n) = log n$ and $p(n) = n^2$. Then, $p(f(n)) = log^2 n$. Also, $g(n) in C$ implies that $g(n) = O(log n)$. We have $log^2 n not in O(log n)$.

Closed Under Right Polynomial Composition: If $f(n) in C$ then $f(n) = log n$. Given an arbitrary polynomial $p(n)$, we have that there exists some $k’$ such that, for sufficiently large $n$, $p(n) < n^{k’}$. Then, for sufficiently large $n$:
$ f(p(n)) leq f(n^{k’}) = log n^{k’} = k’ log n = O(log n) = O(g(n)).$

Can anyone help me with items (d) and (e)?

Thanks in advance. Of course, corrections/comments on the other items are also welcomed.

fa.functional analysis – When is a linear subspace to be closed in all compatible topologies

Let $V$ be a real vectors space, and $W$ be a linear subspace.

Say $W$ is obviously closed if, for every topology on $V$ that makes $V$ a Hausdorff locally convex topological vector space, the subspace $W$ is closed in $V$.

We know $V$ is obviously closed, and any finite-dimensional subspace of $V$ is obviously closed. Is there a known characterization of which subspaces are obviously closed? Are there other sufficient conditions for a subspace to be obviously closed? Are there other known examples?

Download is paused on Play Store when closed in the background

Downloading apps on my new Vivo Y30, whenever I try to download to an app, I have to keep Play Store running on the background. When I try to close, my download pauses. It only resumes when I open the app again. I just want to close background process to avoid having slow performance when using my phone. Any answers will be accepted.

Detecting and understanding malware/spyware [closed]

Recently, stumbled upon the new FB 500m+ leak and decided to satisfy my curiosity and poke around.

Basically just wanted to see how 500m+ user records were kept and what info was released( it was pretty much all publicly scrapable data with ocassional email address.)

Curiosity satisfied, I guess.
BUT.. what is this! Slowed response, unusually high resource usage, ridiculous boot times, amongst other things this laptop just got a lot worse! Could it be… has BonziBuddy finally returned? No seemingly just another piece of malware…

…no results from Defender, MalwareBytes, all the big names.

Well to be expected I guess when you download dodgy shit, but I’d love to know what is happening in the background of my computer right now.

So my hopefully decipherable question is this:

1 Ignore anti-virus programs.

2 Using the simple tools we have at our disposal(taskmanager/monitoring active net connections/sniffing packets with wireshark.)
Is it possible for a layman to figure out exactly what is going on in the background of their computer?

I can open wireshark but I cannot figure out what is what, going where, or for what purpose(admittedly I know nothing about this software)

I can run netstat, which is like the simple-mans wireshark without the packets displayed, look at active connections and corresponding local address and foreign address, along with PID, trace that to an executable, but do I know what is actually happening?

Is it impossible to see exactly what processes are doing what because without the original code we end up with undecipherable compiled jargon?

I can see files behaving strangely(unprecedented resource hog) but that alone is meaningless, what is it actually doing and can I find out?

To those people understand my ramblings and this field of computing a bit more and are impartial enough to want to shed light, what do YOU do when you have had an infection slip under the radar? Restore/Reformat? Do you use virtual machines on suspect files? What are your red flags? Dont you ever have a desire to pirate software you cant allow yourself to buy, because its for a short period of time or the use is not for commercial gain but simply out of good old primate curiosity?

Wallet source code for altcoin [closed]

I have followed this guide to create an altcoin: https://www.hackster.io/pjdecarlo/how-to-make-a-cryptocurrency-using-litecoin-v0-15-source-fb5e82

It comes with a desktop wallet app but there is no web wallet.

I wanted to check with you guys if you know any source code for a web wallet application that I could use that is compatible with litecoin source code.

Please do let me know.

ssh – kex_exchange_identification: Connection closed by remote host

Trying to connect to web servers running on Centos 7 via jump server, earlier this connection used to work fine without any problems, but not sure now what went wrong.

Following is the status

$ ssh -vvv abc@JUMP_SERVER_IP -J 10.10.0.5 -i .ssh/id_rsa_iit
OpenSSH_8.2p1 Ubuntu-4ubuntu0.2, OpenSSL 1.1.1f  31 Mar 2020
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: include /etc/ssh/ssh_config.d/*.conf matched no files
debug1: /etc/ssh/ssh_config line 21: Applying options for *
debug2: resolve_canonicalize: hostname JUMP_SERVER_IP is address
debug1: Setting implicit ProxyCommand from ProxyJump: ssh -vvv -W '[%h]:%p' 10.10.0.5
debug1: Executing proxy command: exec ssh -vvv -W '[JUMP_SERVER_IP]:22' 10.10.0.5
debug1: identity file .ssh/id_rsa_iit type 0
debug1: identity file .ssh/id_rsa_iit-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.2
OpenSSH_8.2p1 Ubuntu-4ubuntu0.2, OpenSSL 1.1.1f  31 Mar 2020
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: include /etc/ssh/ssh_config.d/*.conf matched no files
debug1: /etc/ssh/ssh_config line 21: Applying options for *
debug2: resolve_canonicalize: hostname 10.10.0.5 is address
debug2: ssh_connect_direct
debug1: Connecting to 10.10.0.5 [10.10.0.5] port 22.
debug1: connect to address 10.10.0.5 port 22: Connection timed out
ssh: connect to host 10.10.0.5 port 22: Connection timed out
kex_exchange_identification: Connection closed by remote host