How to secure private class field with PHP OO?
How come the PHP private class var is not private?
I would like to format binary or hexadecimal numbers with a space separator at each 2 or 4 digit (or any other value like 8 digit or more).  A small picture is better than a long explanation, here is what I would like to do:    As you can see in this mwe, I use the fmtcount package with padzeroes:      \documentclass{article}     \usepackage[utf8]{inputenc}         \usepackage[T1]{fontenc}               \usepackage{fmtcount}     \begin{document}             Binary value : {\padzeroes[16]\binarynum{129}}$_{(2)}$ %             should display 0000 0000 1000 0001$_{(2)}$              Hexadecimal value: {\padzeroes[8]\Hexadecimalnum{65000}}$_{(16)}$ %             should display  00 00 FD E8$_{(2)}$     \end{document}   What I want to do is displaying numbers with various radix (2, 3, 7, 8, 10, 16) given a decimal number and format these numbers correctly with spaces and leading 0 (without having to perform the conversion by myself).  I already found some posts with similar questions, but none of them achieve this (they display number with thousand separators, like the numprint package, every 3 digits; or they do not make it automatic). Here are these posts :         EDIT two other linked questions:       I also prefer to use pdflatex. How do I calculate the CRC32 (Cyclic Redundancy Checksum) of a string in .NET? Calculationg base-resistor between microcontroller and transistor I'm curious, when connecting my 2N2222 transistor's base to a PWM output pin on my Arduino, I know the Arduino can deliver a maximum of 40mA current. The 2N2222 only requires around 5 to 10 mA on it's base to switch the collector and emitter. Now, when calculating the base-resistor under "normal" conditions where I'm merely switching it directly from Vcc, the following applies:   However, when putting in a 500 ohm or 1K resistor in (1K for 5mA) directly it works great. But putting it in between the Arduino and the transistor, the transistor doesn't switch.  I suspect thus, that the resistance is too high of the base-resistor. Therefore, we may very well not need a base-resistor.  But, according to spec, the Arduino can deliver 40mA. So, am I correct in assuming the folling: 1) I should calculate the perceived resistance that the Arduino is giving, if it goes high to 5Volt and only gives 40mA, and then 2) Subtract that from the 500ohm resistor needed to make the transistor operate optimally.  Example:    So, I'm theorising that I have to then put in a 375 ohm resistor in to make the total resistance between the Arduino and the base resistor 500 ohm.  Somehow this doesn't feel right. Keep in mind, I'm not an electronic engineer, so I might have the cat by the tail here :P Name for the center amplitude of a sine wave I am trying to find the name for the value at the center of a sine wave $$ y(t) = A\sin (kx \pm \omega t+\varphi) + D $$ i.e. the offset $D$ of the wave in the $y$-direction.  calls it Center Amplitude, but further googling this name is difficult and does not provide any further sources. I also found the expression , but I'm not sure that it refers to the same thing. Is there a commonly used name for the $y$-direction-offset of a sine wave? I have a specific requirement (probably silly!) for testing a browser of Chrome. I realize this requirement isn't the most logical, but politics being what they may I'd like to know the technical workaround.  I need to test a site in version, let's say, 28 of Google Chrome. Obviously Google runs a silent updater which can be disabled, but at this point they don't (to my knowledge) release old archives of the MSI installers (which I can easily use to reinstall and force a no-update option for testing). If we can get this working on a single instance then there's a possibility that a virtual machine or some other workaround will give us an easy restore point to meet this test.  If anyone has a good idea of where to start here that would be amazing.  I've already floated the "why are we doing this question?" and the answer is that it is part of the requirements so we need to make a best effort.  UPDATE:   FileHippo appears to only archive the online installer (automatic update)  OldApps doesn't archive Chrome anymore  OldVersion doesn't appear to have any Chrome Archives   UPDATE 2:  - The accepted answer's server is the correct solution here at this point in time. Basically speaking you're looking for the full install (30 or so MB). If you have an 800K file it is the online installer which automatically updates. Taking ownership of comments on migrated questions When a question is migrated to a SE site that I'm not registered to, I can't claim ownership of my comments. An example question:   I registered only after the question was migrated and can't delete my comments. I always like to perform some garbage collection of noise comments made by me. (like on the example question)  Would it be possible to claim ownership of comments in this scenario? Is this a bug? Determinant of block matrix with commuting blocks I know that given a $2N \times 2N$ block matrix with $N \times N$ blocks like   $$\mathbf{S} = \begin{pmatrix} A &amp; B\\  C &amp; D \end{pmatrix}$$  we can calculate $$\det(\mathbf{S})=\det(AD-BD^{-1}CD)$$ and so clearly if $D$ and $C$ commute this reduces to $\det(AD-BC)$, which is a very nice property.   My question is, for a general $nN\times nN$ matrix with $N\times N$ blocks where all of the blocks commute with each other, can we find the determinant in a similar way? That is, by first finding the determinant treating the blocks like scalars and then taking the determinant of the resulting $N\times N$ matrix.  Thanks in advance! Mail.app crashes constantly, even after deleting mail profile and cache Humorous time travel short story about a man's dealings with other versions of himself Okay, similar questions to this have been asked before, but not about the particular short story I am trying to find.  It was in an anthology of short sci fi stories, possibly award winning ones or at least someone's compilation of favourites. (I think)   It was a long time ago, maybe 1970s or 80s, so the story could date back to even the 1960s for all I know, but probably the 1970s.  It was the funniest story about time travel where a person meets incarnations of himself, that I have ever read. It was either derivative of 'By His Bootstraps' or the other way around, but my recollection is that this story was funnier.  Maybe my memory is playing tricks on me and it WAS 'By His Bootsraps', but I am almost certain that it wasn't, because when I read that recently it seemed unfamiliar and not as funny.  In the one I am trying to recall, the guy is also bemused and irritated by the behaviour of other incarnations of himself, like the Heinlen story, but the repartee between versions of himself and his extreme frustration is much more hilarious.  I have a vague recollection that he is in a spaceship during the story, but not absolutely sure. There seemed to be a lot of clambering around, ladders, bulkheads, etc, unlike the Heinlen story.  I'm almost certain it isn't any of the commonly suggested stories and I'm quite sure it wasn't a short film where he shoots his older self, or a full length novel. Someone will have read it and (un)remembered it fondly like me, I feel sure! If you know what a number mod two different primes is (3 and 2) in this case, how can you tell what the mod is of the two products? What intuitive notion is formalized by "natural transformation" in category theory? What is the Linux equivalent to Windows' Program Files? Incorrect indentation for tag listing questions loaded via AJAX I am seeing a weird indentation for questions loaded via AJAX (i.e., by clicking the n question(s) with new activity link). The following screenshot was taken before I clicked the link:  And this is after the new question was loaded:  A browser refresh resolves the problem (as can be expected). It was tested with Chrome 88 and Firefox 85 on  (Catalina). Sometimes you just want to let out some steam, and troll about some technology or software. You are not looking for any answers, but for users with similar experiences and interesting stories. So why not create a separate discussion site (trolling.stackoverflow.com?), where you could ask questions like "why do you hate technology X" or "What are the stupidest bugs you encountered in X"? When do we use "at" and "in" with "arrive" talking about place, not time? I am having trouble coming up with a consistent method of determining the direction of static friction.  So far the best I have come up with is: it should oppose the relative acceleration the contact point would have parallel to the surface of contact in its absence.  This seems to work up to a point:   A block sits on a rug. The rug is pulled to the left. The relative acceleration of the block to the rug is to the right. So static friction must act (in the frame of the rug) to the left.  A cyclist makes a turn to the right and leans to the right. The torque that his weight puts about the contact point will make it accelerate to the left relative to the ground in the absence of friction. So the ground sees static friction pointing to the right. A coin rotates with a turntable. In the absence of static friction, the table sees a centrifugal force on the coin that will make it accelerate away radially from the centre of rotation. So friction must act radially towards the centre of rotation, in the frame of the table.   But then I run into some difficulties.   (already solved; see first answer) A cyclist makes a turn to the right. As a result he leans to the right. The resulting torque around the centre of mass causes the point of contact to slide to the left in the absence of static friction, so static friction must act to the right. However, now the cyclist as a whole must make circular motion with static friction acting as the centripetal force. As there is no torque, this means the contact point must move along with the centre of mass and therefore act as something with an acceleration to the right. So according to my understanding of static friction, another layer of it must now be added acting to the left. Why is it not? A car enters a banked curve with speed $v$. Suppose the curve is banked at the right angle for the car to make circular motion in the absence of friction. In the absence of any static friction, therefore, the car's acceleration points towards the centre of the banked curve. However, in this case the car's acceleration still has a downward component along the slope. My understanding of the direction of static friction means therefore, when it is added in, it should act up the slope. But in reality no static friction is produced in such a case.   Can someone explain what is wrong with my method of finding the direction of friction? Or if there is nothing wrong, how have I misapplied it in this case to create this paradox? Using C++ library in C code I have a C++ library that provides various classes for managing data.  I have the source code for the library.  I want to extend the C++ API to support C function calls so that the library can be used with C code and C++ code at the same time.  I'm using GNU tool chain (gcc, glibc, etc), so language and architecture support are not an issue.  Are there any reasons why this is technically not possible?  Are there any gotcha's that I need to watch out for?  Are there resources, example code and/or documentation available regarding this?    Some other things that I have found out:   Use the following to wrap your C++ headers that need to be used by C code.     #ifdef __cplusplus extern "C" {   #endif   //   // Code goes here ...   //   #ifdef __cplusplus   } // extern "C"   #endif    Keep "real" C++ interfaces in separate header files that are not included by C.  Think  here.  Using #ifndef __cplusplus #error stuff helps here to detect any craziness. Careful of C++ identifiers as names in C code Enums varying in size between C and C++ compilers.  Probably not an issue if you're using GNU tool chain, but still, be careful. For structs follow the following form so that C does not get confused.  typedef struct X { ... } X  Then use pointers for passing around C++ objects, they just have to be declared in C as struct X where X is the C++ object.   All of this is courtesy of a friend who's a wizard at C++. How to show bibliography alphabetically with biblatex? How many solutions $X^{10} - I=0$ has in $M_2(\mathbb{R})$? How many solutions $X^{10} - I=0$ has in $M_2(\mathbb{R})$? Where $M_2(\mathbb{R})$ denotes the set of $2 \times 2$ real matrices.  I absolutely have no idea of where I should start from. $I$ and $-I$ solve the equation, but are there any other non-trivial solutions? Are there infinitely many solutions? How do I ping a website or IP address with Python?