## Algorithms – Binary search symbol table

Hello, I am trying to teach myself algorithms (Sedgewick) and have encountered the following problem:

``````3.1.15: Assume that searches are 1,000 times more frequent
than insertions for a BinarySearchST client. Estimate the
percentage of the total time that is devoted to insertions,
when the number of searches is 10^3, 10^6, and 10^9.
``````

As stated in the problem Search queries (S) = 1000 * Supplements (I)

• $$S = 10 ^ 3 to I = 1$$
• $$S = 10 ^ 6 to I = 10 ^ 3$$
• $$S = 10 ^ 9 to I = 10 ^ 6$$

At this point in the book, we use simple arrays and linked lists to back up the symbol table (inefficient hash maps, trees, and so on). This would mean that the search takes ~ log2 (N) and the insertion takes ~ N / 2 times (assuming a uniform distribution where the inserts are placed).

Is the calculation of the percentage of insertion for the search time approximately:

$$frac {Inserts times N / 2} {Searches times log_2 (N)}$$

Use $$Searches = 10 ^ 3 times Inserts$$ that reduces to

$$frac {N / 2} {(10 ^ 3 times log_2 (N)}$$

This would mean that the percentage is heavily dependent on the initial size of the symbol table and is not a steady percentage that we can use to answer the question.

Are there suggestions for what I missed? Should I make a guess about the initial size of the table?

## Number Theory – About solutions of two identities concerning the Euler's Totient function and the Pochhammer symbol or Stirling numbers of the second kind

In this article we refer to the Stirling numbers of the second kind as $${n bracket k}$$and the Pochhammer icon as $$(n) _k$$, On the other hand, we call the Euler's dead-ended function as $$varphi (n)$$,

We consider the following problems, which we only consider not trivial solutionsFor positive integers see below in the definition of the problems.

Problem 1 Find the non-trivial solutions $$(n, k, x, y)$$These are the solutions to integers $$1 leq k and for integers $$x> 1$$ and $$y> 1$$ from

$$varphi left ((n) _k right) = x ^ y.$$

Problem 2 Find the non-trivial solutions $$(n, k, x, y)$$These are the solutions to integers $$1 leq k and for integers $$x> 1$$ and $$y> 1$$ from

$$varphi left ({n bracket k} right) = x ^ y.$$

Examples.

A) The problem 1 has, for example, the non-trivial solutions $$(n, k, x, y) = (35,4,72,3)$$ and $$(16.6,24.5)$$,

B) The problem 2 has, for example, the non-trivial solutions $$(n, k, x, y) = (30,27,1512,2)$$,

I do not know if there is an aspect that highlights these issues. Is one of these problems potentially more interesting than the other?

Question. I would like to know how to start studying the non-trivial solutions, the problems mentioned in Problem 1 or for Problem 2. What can be a first professional statement about one of these problems? I ask, what is a first professional statement that can be made for some of these problems. Many thanks.

I ask that I know that asymptotics, heuristics, congruence, and divisibility are important facts when examining equations with integers, but I do not know which of the two problems is more interesting than the other (if that is) case), and I do not know how to see a first professional statement for some of these problems (the problem that is more appropriate to get statements about its solutions).

## Internal memory – SMS numbers preceded by the + symbol

I had problems sending text messages from Android via the number form:
`+ 852 xxxxxxxxxx`
At some point it worked, when I changed the number into the following form:
`011 852 xxxxxxxxxx`

In these examples, 852 is the country code and should only be representative of country codes in general.

Since Android the contact with one may be recorded `+` Type of format This is a surprising shortcoming. It can be considered a mistake if a number can be stored in a non-functional format.

Unfortunately, many of my Google contacts (that is, contact information that is not stored on the phone) are from `+` Format, so this shortcoming is uncomfortable. This seems to be a surprising flaw, so I am writing here to see if people have found a workaround.

## Tracking – What is the "#" symbol in the Google Analytics link?

This is the link today when I generate the tracking tail with Campaign URL Builder:

``````http://example.com#utm_source=Campaign%20Source&utm_medium=Campaign%20Medium&utm_campaign=Campaign%20Name
``````

Note the `#` Symbol after `example.com`, Why is not it? `&` as usual (or how else do I see)? What is the difference between the two symbols?

## r – hoverformat works only with the symbol \$, not with other currencies?

I'm doing a conspiracy `plot_ly` from `according to plan` Library.

I try to use it `S /` currency, that is the symbol for the Peruvian currency "nuevos soles".

Setting the currency symbol in hover format in the layout works only for US dollars:

``````plot_ly (ha, x = ~ periodo, y = ~ precio.actual, color = ~ ecommerce,
colors = c ("# BED800", "# 802D69", "# FF5500"))%>%
layout (yaxis = list (
hoverformat = & # 39; \$,. 2f & # 39;
))%>%
config (displayModeBar = FALSE)
``````

But if I use the "S /" symbol (note the space after the slash), the tooltip will not show a currency, just the integer.

``````plot_ly (ha, x = ~ periodo, y = ~ precio.actual, color = ~ ecommerce,
colors = c ("# BED800", "# 802D69", "# FF5500"))%>%
layout (yaxis = list (
hoverformat = & # 39; S /, .2f & # 39;
))%>%
config (displayModeBar = FALSE)
``````

Dates:

``````ha <- structure (list (periodo = structure (c (2L, 2L, 2L, 2L, 2L, 2L), .Label = c ("2017"),
"2016"), class = c ("ordered", "factor"), e-commerce = structure (c (2L,
2L, 2L, 2L, 2L, 2L), .Label = c ("falabella", "ripley", "linio"
), class = c ("ordered", "factor"), marca = c ("samsung", "samsung",
"lg", "lg", "samsung", "lg"), producto = c ("samsung tv led hd 32 & # 39; 32j4000",
"Samsung Smart TV LED FHD 48" "3D 48J6400", "LG Smart TV LED 43" full HD 43LH5700 ",
LG Smart TV LED 49 "Full HD 49lh5700", "Samsung Smart TV 50ju6500 LED UHD 50 "  "- Negro",
lg smart tv led 49 "" ultra hd tv 49uh6500 "), precio.antes = c (999,
2799, 1649, 1999, 3699, 2799), precio.actual = c (799, 1999, 1249,
1699, 2399, 2199), Pulgadas = c (32, 48, 43, 49, 50, 49), Rango = c ("S / .500 - S / .1500",
"S / .1500 - S / .2500", "S / .500 - S / .1500", "S / .1500 - S / .2500",
"S / .1500 - S / .2500", "S / .1500 - S / .2500"), descuento = c (-0.2002002002,
-0.285816362986781, -0.242571255306246, -0.150075037518759, -0.351446336847797,
-0.214362272240086)), row.names = c (NA, 6L), class = "data.frame")
``````

## labels – Can the "\$" symbol be considered universal when creating a cash-printed graph?

For non-dollar users, the & # 39; \$ & # 39; as understood strange something like a dollar, just like the Netflix symbol for many people around the world as a universal symbol of one Movie not available in " [their/your] Region",

You can say that "patriotism" is the cause (as the accepted answer seems to be) or you can say that pavlovian training is the cause, but both symbols have evolved so that a full localization was not done probably not working for non-users or non-Netflix regions, and that these users may be wasting their time clicking on this button (if they could use this precious time instead of watching the latest cute cat videos).

In any case, my point is that localization is important, especially for an invoicing system. It is not just the currency symbol that needs to be located, but also the punctuation. 1,000 euros may mean 1,000 euros for you, but for a Frenchman, the comma means that the amount is only 1 euro. And do not even let me start with VAT or sales tax, depending on where you are and with various other factors. In other cases, this may also mean that the credit / debit card from your home country is not working.

If the localization work has not yet been done (except for the simplest cases), as this is implied by your order from your boss / customer, you can also use this icon. It sends the right signal, expecting a potential user. And that's fine. I'm not saying that non-localized generic solutions are not right.

On the other hand, if one day you decide to use localization, use an icon that is overlaid with the corresponding UTF-8 currency (or an icon that is overlaid with another partially transparent icon). In other words, treat it like any other button. Do not encode the localized symbol with the image, but overlay it.

Luckily, our technology is so advanced that the average user can not notice that the final composite icon was created just for him at the time of installation or at the last second.

## How do I replace a noncommutative binary star multiplication symbol in an output?

For a better overview in my issue, I would like to replace ** nothing.
Since
fubar /. ** -> ""
not working I'm asking for help.

The ** is the noncommutative multiplication.

reference.wolfram.com/language/ref/NonCommutativeMultiply.html

Many Thanks!