## Use of undefined constant MCRYPT_RIJNDAEL_256 – assumed ‘MCRYPT_RIJ NDAEL_256

I got an error when i execute this command

php bin/magento setup:upgrade && php bin/magento setup:di:compile && #php bin/magento setup:static-content:deploy && chown -R www-data:www-data . &&  rm -rf var/cache && rm -rf var/di && rm -rf var/page_cache/ && rm -rf var/generation/ && rm -rf var/view_preprocessed/ 

the error is

“Use of undefined constant MCRYPT_RIJNDAEL_256 – assumed ‘MCRYPT_RIJ NDAEL_256”

when i was checking my server, and show the phpinfo(), the extension for mcrypt has been enabled properly, so what is the real problem?

## openVAS: uninitialized constant OpenVASOMP::OMPConnectionError

I was searching in many forums regarding this issue like here and here, but they were mentioning using port 9390. I launched OpenVAS on port 9390, but I still get the same error.

I am using openVAS in msfconsole on Kali Linux. I load openVAS successfully, but when I try to connect, it shows me this error.

  openvas_connect root toor 127.0.0.1 9390     [*] Connecting to OpenVAS instance at 127.0.0.1:9390 with username root...     [-] Error while running command openvas_connect: uninitialized constant OpenVASOMP::OMPConnectionError      Call stack:     /usr/share/metasploit-framework/plugins/openvas.rb:195:in rescue in cmd_openvas_connect'     /usr/share/metasploit-framework/plugins/openvas.rb:189:in cmd_openvas_connect'     /usr/share/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:501:in run_command'     /usr/share/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:453:in block in run_single'     /usr/share/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:447:in each'     /usr/share/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:447:in run_single'     /usr/share/metasploit-framework/lib/rex/ui/text/shell.rb:151:in run'     /usr/share/metasploit-framework/lib/metasploit/framework/command/console.rb:48:in start'     /usr/share/metasploit-framework/lib/metasploit/framework/command/base.rb:82:in start'     /usr/bin/msfconsole:49:in <main>' 

## How can you find all unbalanced parens in a string in linear time with constant memory?

I was given the following problem during an interview:

Gives a string which contains some mixture of parens (not brackets or braces– only parens) with other alphanumeric characters, identify all parens that have no matching paren.

For example, in the string “)(ab))”, indices 0 and 5 contain parens that have no matching paren.

I put forward a working O(n) solution using O(n) memory, using a stack and going through the string once adding parens to the stack and removing them from the stack whenever I encountered a closing paren and the top of the stack contained an opening paren.

Afterwards, the interviewer noted that the problem could be solved in linear time with constant memory (as in, no additional memory usage besides what’s taken up by the input.)

I asked how and she said something about going through the string once from the left identifying all open parens, and then a second time from the right identifying all close parens….or maybe it was the other way around. I didn’t really understand and didn’t want to ask her to hand-hold me through it.

Can anyone clarify the solution she suggested?

## Update each element to product of all others in linear time, constant additional space, no division

Question: I am trying to solve question 6.10.1 from Elements of Programming Interviews. I have only been able to find an $$O(nlog(n))$$ time and $$O(log(n))$$ additional space algorithm. The task is as follows:

Given an array of integers, devise an algorithm to update each element to the product of all other elements in the array without using division. The algorithm must run in $$O(n)$$ time and $$O(1)$$ additional space.

Example: $$<1, 2, 3>$$ should be updated to $$<2*3, 1*3, 1*2>$$.

My $$O(nlog(n))$$ time and $$O(log(n))$$ additional space solution:

Let $$a = $$.

Define the function $$f(a, start, end) : Z$$ over an array $$a$$. $$start$$ and $$end$$ define the inclusive start and end indices in $$a$$. The function returns the product of all elements in the range. $$f(a, 1, l)$$ produces the result.

Define $$length = (end – start) + 1$$. Run the appropriate of the following alternatives:

1. If $$length = 1$$, set $$a_{start} = 1$$ and return the original $$a_{start}$$.
2. If $$length = 2$$, swap $$a_{start}$$ and $$a_{end}$$ and return their product.
3. If $$length > 2$$:
• Set $$leftEnd = floor(length / 2)$$.
• Set $$productLeft = f(array, start, leftEnd)$$.
• Set $$productRight = f(array, leftEnd + 1, end)$$.
• For $$i \in [start, leftEnd]$$, replace $$a_i$$ with $$a_i * productRight$$,
• For $$i \in [leftEnd + 1, end]$$, replace $$a_i$$ with $$a_i * productLeft$$. Return $$productLeft * productRight$$.

Complexity: At each level of recursion, we call $$f$$ once on each half of the input, and then we multiply each half with the product from the other half. This gives $$O(nlog(n))$$ time. The maximum allocation size at each call level is $$O(1)$$, and there are $$log(n/2)$$ levels of recursion, so this means $$O(log(n))$$ additional space allocation.

Vince’s $$O(n)$$ time and $$O(n)$$ additional space solution:

Let $$a = $$.

1. Set $$product = 1$$.
2. For $$i \in [1, l]$$, set $$b_i = product$$ and set $$product = product * a_i$$.
3. Set $$product = a_l$$. For $$i \in [l – 1, 1]$$, set $$oldElement = a_i$$ set $$a_i = b_i * product$$, and set $$product = product * oldElement$$.

## Is $f(cn)$ always $O(f(n))$ for constant $c$ and any function $f$?

This seems to be true for any function I can think of, but I’m not quite sure how to prove it. Is there a proof of this proposition for any such function or a counter-example?

## How to prove a set of delay differential equations never converge (the delay is not constant)

Two functions $$x(t)$$ and $$y(t)$$ are coupled via: $$\dot X(t) = a Y(t)-b,Y(t+X(t))=X(t)$$

where $$a<0, b$$ is a constant.

I am mostly confused with the second equation. What is the mathematical term for this kind of delay differential equation? What kind of initial condition do I need to specify?

It is obvious that, if $$X(0)=Y(0)=b/a$$, then the system will stay stable for all $$t>0$$.

Through doing some simulation also back of envelope thinking, it seems that when $$X(0)=Y(0)=0$$, then the system may never converge to an equilibrium/stable solution. However, I have no idea what type of proof technique is required to show that.

Thanks!

## A possible surprise involving Euler’s constant $e$

Let

\begin{align*} c_n &= n!(e-\sum_{k=0}^n \frac{1}{k!}) \ u_n &= \lfloor{\frac{1}{c_n} \rfloor} \ v_n &= \lfloor{\frac{1}{1/c_n-\lfloor{u_n} \rfloor}} \rfloor \end{align*}

Are $$u_n = n$$ and $$v_n = n+1$$ for all $$n \geq 0$$?

## Smooth map with null differential at each point are constant on the connected component of the domain

Let $$F:M\to N$$ be a smooth map between smooth manifolds $$M$$ and $$N$$ (with or without boundary).

I want to show that $$dF_p:T_pM\to T_{F(p)}N$$ is the zero map for each $$p\in M$$ if and only if $$F$$ is constant on each component of $$M$$.

Here is my argument:

Suppose $$F$$ is constant on each component of $$M$$, and let’s show that $$dF_p:T_pM\to T_{F(p)}N$$ is the zero map for each $$p\in M$$.

Let $$p\in M$$ and let $$U$$ be the component of $$M$$ containing $$p$$. Since $$M$$ is locally path connected, I know that $$U$$ is open in $$M$$. By hypothesis we have $$F_{|U}:U\to N$$ is consant. Then $$d(F_{|U})_p:T_pU\to T_{F(p)}N$$ is the zero map: let be $$v\in T_pU$$ and $$f\in C^{\infty}(N)$$, then $$d(F_{|U})_p(v)(f)=v(f\circ F_{|U})=0$$ since $$f\circ F_{|U}$$ is costant from $$U$$ to $$\mathbb{R}$$. Since $$d(\iota)_p:T_pU \to T_pM$$ is isomprhism, and since we have that $$dF_p\circ d(\iota)_p=d(F_{|U})_p$$, we have that also $$dF_p$$ is the zero map.

We have to prove the converse (But here my problems begin) The best I have thought is this:

For simplicity suppose $$M$$ itself is connected. We know that $$dF_p:T_pM\to T_{F(p)}N$$ is the zero map for each $$p∈M$$ and we have to prove that $$F:M→N$$ is constant.

I want to show that $$F$$ is locally constant, i.e. each point $$p$$ in $$M$$ has an open neighborhood in $$M$$ such that $$F$$ is constant on this neighborhood.

Let $$p\in M$$ and let $$(U,\phi=(x^1,\dots,x^m))$$ be a chart on $$M$$ in $$p$$. Then $$\{{\frac{\partial}{\partial x^i}}|_p\}$$ is a basis for $$T_pM$$. By hypothesis we know that $$dF_p(\frac{\partial}{\partial x^i}|_p)(f)=0$$ for each $$f∈C^∞(N)$$, i.e. $$\partial_i|_{\phi(p)}(f\circ F \circ \phi^{-1})=0$$. We can suppose that $$U$$ and thus $$\phi(U)$$ are connceted, so by Ordinary Analysis we have thaht $$f\circ F \circ \phi^{-1}$$ is constant on $$\phi(U)$$. But $$\phi$$ is a diffeomorphism, so we have thaht $$f \circ F:U\to N$$ is constant, for each $$f∈C^∞(N)$$.

Now suppose there are $$p\ne q \in M$$ such that $$F(p) \ne F(q)$$. I want to construct a function $$f∈C^∞(N)$$ such that $$f(F(p))\ne f(F(q))$$.

The best I come out is: suppose there is a smooth chart $$(V,\psi)$$ on $$N$$ containing $$F(p)$$ and $$F(q)$$ and such that there is $$K$$ closed subset of $$N$$ such that $$K\subseteq V$$. Since $$\psi$$ is injective, then $$\psi (F(p))\ne \psi( F(q))$$, so they differ by at least a component, say the $$j$$ component. Let $$\pi_j:\mathbb{R}^n\to \mathbb{R}$$ the $$j$$ projection, and consider $$\psi \circ \pi_j:\psi(V)\to \mathbb{R}$$. Extend this function to a function $$f∈C^∞(N)$$ such that $$f$$ and $$\psi \circ \pi_j$$ agree on $$K$$. Then we have $$f(F(p))\ne f(F(q))$$ which is a contraddiction.

I know that this is quite completely wrong (I did many not-necessarily-true assumptions). And maybe this argument does not work in the case of manifolds with boundary.

So can anyone help me with observations/ sugestions/ hints, or even a full solution? Thank you.

I mention that this is Problem 3.1 in John Lee’s Book “Introduction to smooth manifolds, 2 edition”

After taking the above screenshot, I cleared the entire notifications list. Within the next three minutes (usually even less), the list was already overflowing again.

I’ve learned to manage the symptom by navigating to the Download Manager application settings; hitting FORCE STOP, followed by CLEAR DATA, and CLEAR CACHE. Although the notifications slowly start showing up again. Just one at first, but gradually increasing in number with each occurance. Within a day or two, the numbers are usually back out of control.

I have no idea what it’s supposedly attempting to download, or why. But whatever it is, it’s not instigated by myself. I could just disable download notifications, but I’d rather identify the underlying problem and kill it directly. Needless to say, I’m not too keen on my devices automatically trying to download random mystery files from the internet. Any ideas? Thanks.

FYI: The device in question is a ZTE Blade L5 smartphone.

## Local martingale with constant stopping time

Let $$M_t$$ be a continuous local martingale (there exist an almost surely divergent sequence of stopping times $$(T_n)$$ such that $$M^{T_n}$$ is a square integrable martingale).

Is it true that for each constant stopping time $$T$$ (i.e. $$T(\omega) = T$$ a.s.) $$M^T$$ is a square integrable martingale?

If it is not the case, what is a counterexample?