If you don't have access to the source code of a struct or class, is there a way to know the members of that struct or class? Specifically, i want to know the names, order, and data types of the members.
I'd like to be able to introspect a C++ class for its name, contents (i.e. members and their types) etc. I'm talking native C++ here, not managed C++, which has reflection. I realise C++ supplies some limited information using RTTI. Which additional libraries (or other techniques) could supply this information?
Stability region for two step Nyström method I have the following two step Nyström method: $u_{k+1}=u_{k-1}+2h\cdot f(u_k)$. I want to know the stability region, so I wrote this as $w_{k+1} = A\cdot w_k$ with $A=\left(\begin{matrix} 2h\lambda &amp; 1 \\ 1 &amp; 0\end{matrix}\right)$ and $w_k = (u_{k},u_{k-1})^t$. I use the sample/test equation $u'=\lambda\cdot u = f(u)$ with $\lambda\in\mathbb{C}$. To find the stability region I must set some limitations on the matrix A.  Do I want the whole vector $w_{k+1}$ to go to the zero vector as $k$ goes to infinity, or just the first component that contains $u_{k+1}$? I don't think I can let the second component go to zero, since the matrix just has a $1$ in the bottomleft corner. So I think I want $2h\lambda$ to be negative in the reals (like Forward Euler) , or at least less than 1? I'm unfortunately just guessing at this point.  For (Forward) Euler we have $u_{k+1}=u_k + h\cdot f(u_k) = (1 + h\lambda)u_k$ and so we require that $h\lambda$ does not have a positive real part.  So I guess I also want some anologue for matrices being less than 1? I do not know how to deal with the matrices since the left hand vector not only contains $u_{k+1}$ but also the old $u_k$. Should we add more badges for asking questions? This proposal was superseded , which improves on the core concept.   Early on, there was a question about whether Stack Overflow should . At the time,  was:  Getting answers is reward enough for asking questions.  Even then, Stack Overflow was getting more than enough questions, so it didn't make much sense to incentivize more questions.  lists the badges that can be earned by asking quality questions. (There are at least 8). But looking at the list of recent , it looks more like a list of . These badges are difficult to come by in the first place, and they're much harder to earn on sites like  even though there are some  on that site. It turns out that . We , but we still need plenty of oysters. The Student bronze badge is awarded for the first upvoted1 question. There are no equivalent gold or silver badges. Therefore, I'd like to propose the following:  Student—Asked first question with score of 1 or more Sophomore—Asked 10 questions with score of 1 or more Socrates—Asked 50 questions with score of 1 or more  Do you have any suggestions of better names/levels?  To give you an idea of how many of these badges would be awarded, I wrote . The results2 for the original trilogy: users   gold silver bronze none    Site Name  ------- ---- ------ ------ ------- ---------  3000344 7127 67713  805778 2194566 Stack Overflow 235053  115  1698   53073  181980  Super User 156773  53   1191   40063  116710  Server Fault  The gold version on SO would be slightly more rare than  and more common than . Obviously, there would be fewer badges for smaller sites: 5545    1    18     917    4628    Philosophy 4032    4    41     802    3230    History  5663    3    28     917    4746    Parenting   Several older sites would get none at all: 5778    null 29     1063   4715    Quantitative Finance 7884    null 20     927    6957    Project Management 4333    null 17     1630   2703    Motor Vehicle Maintenance and Repair  These smaller sites get at most . I suspect that a gold or silver badge would encourage site regulars to increase that number without sacrificing quality. Certainly the requirement for those questions to stay in positive territory would prevent a person from flooding the site3 with terrible questions in order to get the badge.   1. The [original spec](https://blog.stackoverflow.com/2008/07/stack-overflow-badge-feedbac/) didn't consider voting at all for Student and Teacher.   2. Your results will vary from mine since I'm looking at slightly newer data. The bronze badge count also differs from the number of [Student](https://stackoverflow.com/help/badges/2/student) badges because the badge isn't revoked when a user's question is later downvoted or deleted.   3. There is a potential problem with cookie-cutter or variation-on-a-theme questions. However, I think the typical tools for closing and deleting questions will prevent people from gaming the system for these badges. In contemporary American English usage, I come across sentences like:   I ain’t got no money.  Ain’t no man like him.    Saying ain’t no sounds incorrect to me because it is a double negative.  What is the origin of this particular construction? I wasn’t able to find anything online related to the origins of this incorrect usage. Correct way of mounting a Windows share I mounted a Windows share to my Ubuntu 11.10 system via adding the following line to the /etc/fstab:  //serveraddr/sharedfolder /mnt/foldername/ smbfs credentials=/home/myname/.smbpasswd 0 0  using the .  But there's a problem with the permissions. The owner of the mount folder is root. I can not create any folders or files in the mounted point is I don't become the root. Even I can not change the ownership to my default user via   sudo chown -R myname .  I googled and saw that it might stem from the fact that Windows file formats (fat32/ntfs) can not save ownership. But when I connect to the same location via samba as   smb://serveraddr/sharedfolder  by providing my credentials, I have the privileges to write without being the root.  How can I make it to let me write to the mounted folder? I have come across both the phrases - 'on the internet' and 'over the internet.'   I'm pretty sure that both are correct but then which to use when?  Please note, I'm well aware of all over the Internet which I'm not concerned about. I have to prove this : "$n^7-n$ is a multiple of 7". This is what I have done this so far :  $P(n):n^7-n$ On putting $n=1,$ $P(1):1^7-1=0$, which is a multiple of 7. So, $P(1)$ is true. Let $P(k)$ be a multiple of 7. So, $k^7-k$ is a multiple of 7. So, $k^7-k=7m$, where $m$ is any natural number. Let $P(k+1)$ be true, Hence, $(k+1)^7-(k+1)$ is a multiple of 7.  Now, how do I evaluate $(k+1)^7$ without using the binomial theorem ? Or is there some other way to do it ? Sarrus Rule with LaTeX Start a longtable in Latex at top of next page I want to use the longtable environment for a table. However, I do not know how to place it at the top of the next page, as I can do with the table environment. Do you know how to do it? I believe it is what the Germans call "". English itself has no such equivalent word. (Although it has been adopted as a .)  Does an idiom exist that describes it? I've recently beat the Ender Dragon. I've heard there is a way to respawn her. How do I do that? Polygon intersection using turf js I am a freelancer programmer and so far I have only worked on projects on Windows platform. I don't have much idea about OS X hardware. I am not looking for a very high end configuration but integrated development environment and one database server should just run fine. I have a Dell laptop i7 processor, 8 GB RAM, 1 TB HDD; I am fairly satisfied with the performance. I am mainly going to use it for app development and not for any rich graphics app development.  What are the minimum and recommended hardware requirements for Xcode development on OS X? Helix on a cylinder Let $F$ be a field and $f: \mathbb{Z} \to F$ be a ring epimorphism. I'm taking Calculus II next semester so I don't have all the tools from it to back me up but something came up in a discussion this evening that asked me to prove that the following sequence converges. As I'm new to formal math I'm hoping someone can verify my proof, especially step $6$. I must prove that $$\lim_{n\to\infty}P_n=b$$ where $$P_{n+1} = P_n + \frac{b-P_n}{2}$$ $$P_0 = a$$ and $a,b \in \mathbb{R}$ such that $a&gt;b$ My proof goes as follows:   We must prove that $$\lim_{n\to\infty}P_n=b$$  That is, $\forall\epsilon&gt;0$ there exists a $\delta$ such that there exists an $n$ satisfying $$n&gt;\delta \iff b-P_n&lt;\epsilon$$  First, let us prove that $P_n$ is bounded by $b$ by contradiction. Let us choose an $i$ such that $P_i &lt; b$ and $P_{i+1}&gt;b$. Then we have $P_{i+1} = P_i + \Delta P$ where $\Delta P &gt; b-P_i$. but this is impossible because by the definition of the recurrence $\Delta P = \frac{b-P_i}{2} &lt; b-P_i$. Therefore, $P_i$ is bounded from above by $b$.  Additionally, it is trivial to show that $P_{i+1} &gt; P_i$.  With this in mind, choose an arbitrary $\epsilon$. We need to show that there exists an $n$ such that $P_n &gt; b-\epsilon$. Assume the contrary, that $P_n$ is bounded by $\epsilon$.  Using a similar argument to what which was used before, assume $P_n$ is bounded by $\epsilon$ and then there exists a $P_i$ such that $P_{i+1}\not &gt; P_i$. But this results in a contradiction with (4)  Therefore, $P_n$ is not bounded by $\epsilon$ and we have proved what we want to prove. Calculating the average area of the states listed in states.txt Need someone to calculate the average area, in square miles, of the states listed in states.txt. States.txt (file): State           Population   SqMi      Region  ------------------------------------------ California           39.37   163.7       West Texas                29.36   268.6      South Florida              21.73    65.7      South New_York             19.33    54.7  NorthEast Pennsylvania         12.78    46.1  NorthEast Illinois             12.59    57.9    Midwest Ohio                 11.69    44.8    Midwest Georgia              10.71    59.4      South North_Carolina       10.60    53.8      South Michigan             9.97    96.7    Midwest  Output should look like this: Average Area: 82.85 square miles  Note my awk program will be ran like this: awk –f &lt;file.awk&gt; states.txt Updated DNS zone can't be seen from my local network How to redirect apache /var/www to the home directory and access all the directories and files in my home directory? Astronauts land on planet, met by aliens impersonating their deceased relatives When I was young, I read a chilling story of astronauts coming to an unknown planet and found to their delight  the occupants were all members of their family who were deceased. Each crew member goes off to their respective childhood homes to relive memories.   One astronaut however in the same bedroom as his brother suddenly wonders if aliens may have searched the memories of himself and fellow crew members and used this to gain power over the intruders. His brother asks suspiciously what he's thinking and doesn't believe the answer. The last scene shows astronauts being buried by aliens whose faces melt from human into something terrifying.   Anyone know the name of the story and author? I thought it might be something like Coming Home, but only a guess. According to the definition on , a multiple  is a root with  $n\geq 2$. For example, in the equation $(x-1)^2 = 0$, $1$ it the multiple (double) root.  Question: Why is $x = 1$ the multiple root of $(x-1)^2 = 0$?  What does multiplicity mean in this case? According to Wolfram multiplicity is the number of values for which a condition holds, or the number of times for which a polynomial equation has a root at a given point. In what way does the polynomial $x^2 - 2x + 1 = 0$ have multiple roots?