« first day (2242 days earlier)      last day (1154 days later) » 

12:10 AM
8
Q: qsort: Cast the comparator function itself or the parameters in the body of comparator function?

jjgThere are a couple of obvious ways to use qsort: cast in the comparator: int cmp(const void *v1, const void *v2) { const double *d1 = v1, *d2 = v2; : } qsort(p, n, sizeof(double), cmp); or cast the comparator: int cmp(const double *d1, const double *d2) { : } qsort(p, n, sizeof(dou...

 
 
1 hour later…
1:10 AM
13
Q: What is the proper format of writing raw strings with '$' in C++?

Amirreza A.I'm learning about raw strings in C++ from Here. Base on the definition on the site, a raw string should start with R"sequence( and end with )sequence where sequence can be any sequence of characters. One of the examples of the website is the following: R"&%$(string with \backslash)&%$" However, ...

 
 
2 hours later…
3:40 AM
3
Q: Explicit abelianization functor for groups

Francesco PolizziAssume that I have a short exact sequence of finitely presented groups $$1 \longrightarrow K \longrightarrow H \longrightarrow G \longrightarrow 1,$$ where $G$ is finite (but I do not know whether this is relevant for what follows). Applying abelianization, we get an exact sequence $$K_{\mathrm{...

 
 
2 hours later…
5:58 AM
4
Q: Vinogradov-Korobov for Dirichlet L-functions?

H A HelfgottWhere can one find a Vinogradov-Korobov zero-free region for Dirichlet L-functions? It has to be in a standard reference, but I'm having a non-trivial time finding it.

 
6:40 AM
2
Q: Richaud-Degert type quadratic extensions

MelankaA Richaud-Degert type real quadratic field is a number field of the form $K = \mathbb{Q}(\sqrt{d})$ where $d = {(an)}^2 + ka > 0$ for positive integers $a, n$ and $k \in \{ \pm 1, \pm 2, \pm 4 \}$, $-n < k \leq n$, $d \neq 5$ and $d$ square free. The reason to define such strange $d$ is that it t...

 
 
1 hour later…
7:40 AM
6
Q: MSVC cannot return an object that can be copied but cannot be moved

Devon CornwallWhile fiddling around with copy elision I came across this strange behavior: class Obj { public: Obj() = default; Obj(Obj&&) = delete; Obj(const Obj&) { std::cout << "Copy" << std::endl; } }; Obj f1() { Obj o; return o; // error C2280: move constructor is deleted } Obj f2() { Obj ...

 
8:22 AM
8
Q: C++ Constructor is ambiguous with std::map of the same key/value types

acikekHere's a class definition as an example. #include <string> #include <map> template <class T> class Collection { private: std::map<std::string, T> data; public: Collection() {} Collection(std::map<std::string, T> d) { data = d; } }; This works fine when initializing Collections w...

 
 
1 hour later…
9:40 AM
2
Q: Why cant we apply the square root of a negative number to equate more imaginary numbers?

TonsofluckIn mathematics, polynomials like $x^2-1$ would have a clear solution of $x=\pm 1$. However, without complex numbers could you solve $x^2+1$? No, there would be no possible solution without adding a new axis of imaginary numbers. Simply, we added this axis because it provided us with solutions wit...

 
 
12 hours later…
9:10 PM
2
Q: Wiener Corollary in "An introduction to harmonic analysis" by Yitzhak Katznelson

Christoff_ferlandI can't understand a lemma in "An introduction to harmonic analysis" by Yitzhak Katznelson which is stated as follows: Corollary. Let $\mu\in M(\mathbb T)$. Then $$\sum\limits_{\tau\in\mathbb T}|\mu(\{\tau\})|^2=\lim\limits_{N\rightarrow\infty }\frac{1}{2N+1}\sum\limits_{-N}^N|\hat\mu(n)|^2.$$ I...

 
9:28 PM
1
Q: Find three ways of forming the number 100 using 3,3,5,7

Albert.LangAs it says in the title. Rules: anything not explicitly allowed is forbidden. use 3, 3, 5, 7 and multiplication, division, sum, difference, unary minus, and exponentiation in any order. Parentheses are allowed for grouping. factorials, square roots, concatenation and decimal points are forbidden...

 

« first day (2242 days earlier)      last day (1154 days later) »