How do I change dynamically a background color of a WPF:s button
C# Change A Button's Background Color
Proving that $\gcd(2^m - 1, 2^n - 1) = 2^{\gcd(m,n )} - 1$ Somewhere on Stack Exchange I saw the equation     $$\gcd(2^m-1,2^n-1)=2^{\gcd(m,n)}-1.$$   I had never seen this before, so I started trying to prove it. Without success...  Can anyone explain me (so actually prove) why this equation is true?  And can we say the same when replacing the '$2$' by any integer number '$a$'? The nautilus-open-terminal package adds a menu/right-click option to open a terminal in the current directory.  I want to change this from opening gnome-terminal to opening terminator. , however these instructions do not appear to be valid any more, and I can't find any place in the system settings where the default emulator can be changed.  I also tried:  $ sudo update-alternatives --config x-terminal-emulator   choosing  * 0            /usr/bin/terminator               50        auto mode   But this does not appear to have any effect. Any idea how I can get this to work? Blender worked fine before I installed a GPU to my PC. Is it the GPU? How can I fix this? I already reinstalled to the latest version. When I try to move a cube, the orange outline only moves but not the cube and I cant click it. Rendering an animation the way 3D view looks Is there some way to render exactly whats in the camera view in the 3D view? By that I mean just like a screenshot really, all paths, lamps, and cameras, just like things look in the camera view. The reason I can't just take a screenshot is that I need an animation and it would be too cumbersome to take 1000+ screenshots! Refereeing papers on behalf of a professor: should it be listed on a CV? My professor sometimes asks me to referee papers for him.  Should I list the corresponding journals in the professionals activity section of my CV? What is the purpose of JNDI I'm using the plugin  which registers it's own post type but the capability is assigned to "post".   I want to change it to "manage_options".  Is there a correct way without altering the plugin to do that? Calling a hook, a function or whatever?   public function register_post_type() {      $labels = array (         'name'               =&gt; _x( 'Custom Code', 'post type general name' ),         'singular_name'      =&gt; _x( 'Custom Code', 'post type singular name' ),         'menu_name'          =&gt; _x( 'Custom CSS &amp; JS', 'admin menu' ),         'name_admin_bar'     =&gt; _x( 'Custom Code', 'add new on admin bar' ),         'add_new'            =&gt; _x( 'Add Custom Code', 'add new' ),         'add_new_item'       =&gt; __( 'Add Custom Code' ),         'new_item'           =&gt; __( 'New Custom Code' ),         'edit_item'          =&gt; __( 'Edit Custom Code' ),         'view_item'          =&gt; __( 'View Custom Code' ),         'all_items'          =&gt; __( 'All Custom Code' ),         'search_items'       =&gt; __( 'Search Custom Code' ),         'parent_item_colon'  =&gt; __( 'Parent Custom Code:' ),         'not_found'          =&gt; __( 'No Custom Code found.' ),         'not_found_in_trash' =&gt; __( 'No Custom Code found in Trash.' ),     );     $args   = array (         'labels'              =&gt; $labels,         'description'         =&gt; __( 'Custom CSS and JS code' ),         'public'              =&gt; false,         'publicly_queryable'  =&gt; false,         'show_ui'             =&gt; true,         'show_in_menu'        =&gt; true,         'menu_position'       =&gt; 100,         'menu_icon'           =&gt; 'dashicons-plus-alt',         'query_var'           =&gt; false,         'rewrite'             =&gt; array ( 'slug' =&gt; 'custom-css-js' ),         'capability_type'     =&gt; 'post', // &lt;--- I want to manipulate this         'has_archive'         =&gt; true,         'hierarchical'        =&gt; false,         'exclude_from_search' =&gt; true,         'menu_position'       =&gt; null,         'can_export'          =&gt; false,         'supports'            =&gt; array ( 'title' ),     );      register_post_type( 'custom-css-js', $args ); }   The above code is in custom-css-js.php lines 200-239. Let's say I am building a logistic regression model where the dependent variable is binary and can take the values $0$ or $1$. Let the independent variables be $x_1, x_2, ..., x_m$ - there are $m$ independent variables. Let's say for the $k$th independent variable, the bivariate analysis shows a U-shaped trend - i.e., if I group $x_k$ into $20$ bins each containing roughly equal number of observations and calculate the 'bad rate' for each bin - # observations where y = 0 / total observations in each bin - then I get a U shaped curve.  My questions are:   Can I directly use $x_k$ as input while estimating the beta parameters? Are any statistical assumptions violated which might cause significant error in estimating the parameters? Is it necessary to 'linearize' this variable through a transformation (log, square, product with itself, etc.)? I am trying to solve the following two problems:  1) Prove that the functions $\cos(z)$, $\sin(z)$ are surjective over the complex numbers.  2) Find all $z \in \mathbb C$: $cos(z) \in \mathbb R$ and find all $z \in \mathbb C$: $\sin(z) \in \mathbb R$.  For 1),I've tried to prove it for the function $\cos(z)$ (I suppose the other one is analogue)  so I've used the fact that $\cos(z)=\dfrac{e^{iz}+e^{-iz}}{2}$.  Let $w \in \mathbb C$, I want to show there exists $z \in \mathbb C : f(z)=w$, i.e., $\dfrac{e^{iz}+e^{-iz}}{2}=w$, multiplying by $2$ and then by $e^{iz}$ yields $e^{2iz}+1=2we^{iz}$ iff $e^{2iz}-2we^{iz}+1=0$.   I don't know if this approach is the correct one but here I've replaced $e^{iz}$ by $x$, so the solutions of the equation would be the roots of the polynomial $p(x)=x^2-2wx+1$, by the quadratic formula, I get that $x \in \{\dfrac{2w+w_0}{2},\dfrac{2w-w_0}{2}\}$, where $w_0^2=4w^2-4$.  Then, $e^{iz} \in \{\dfrac{2w+w_0}{2},\dfrac{2w-w_0}{2}\}$. At this point I got lost, I would like to explicitly show that $z$ exists and I can't see existence directly from the fact that $e^{iz}=\dfrac{2w+w_0}{2}$ or $e^{iz}=\dfrac{2w-w_0}{2}$.  First I thought of taking logarithm of both sides of the equation ir order to solve for $z$, but this is not a legitimate operation unless $e^{iz} \in \mathbb R$.   I couldn't go any farther.  For point 2) I have no idea what to do, should I use the identity $\cos(z)=\dfrac{e^{iz}+e^{-iz}}{2}$?  I would appreciate some help with the two points (specially with point 2), at least in 1) I could do something).   Btw, Happy new year! Currently, once an edit by a user without full edit privilege is suggested, it can be either approved or rejected.  There is a known edge case that cause suggested edits to get auto rejected: (aka edit conflict)   User with full edit privilege click "edit" and start typing. Let's name this user Joe. Since the user from previous step did not yet send the edit, users without full edit privilege can still click the "edit" as well, oblivious to the fact someone else is editing the same post in those very seconds. Such user click "edit" too and start typing. Let's name this user Kenny. Kenny is faster than Joe: he send his edit first, creating new suggested edit. Joe is still typing. Joe finally done typing. He send his edit to its merry way oblivious to the consequences. As result of the full edit made by Joe, Kenny's suggested edit is kicked away and rejected. Boom.   This is all known and reported many times.  where the user got it hard with at least two auto rejections in short period of time. Some concrete examples: , , .  For edge case, it became pretty thick edge. This is not just minor hassle: enough rejections, and the user is banned from suggesting for a whole week: and remember we're talking here about good edits made by good users. The above used to count for the ban, but . Thanks Gilles for requesting such a change!   I know it was already suggested to lock edits and similar solutions, but I suggest whole different approach: instead of auto rejecting the suggested edit, dismiss it, i.e. cancel it like it never existed same way a bounty can be revoked by moderator.  In the edit suggestion page it will show "Dismissed" instead of Approved or Rejected maybe with a tooltip explaining what caused this. This will soften the blow from those edge cases, taking the edge out of them. :) I have to format my entire disk and reinstall Ubuntu.  I have installed a lot of software on my current system. And I will have to reinstall all those updates, drivers and applications too.  Is there any way I can make an .iso image of my installed Ubuntu along with all the software, preferences, drivers etc in it ?  Is there any way I can back up my whole OS along with all its software, drives, updates and all ? I'm a newbie in WordPress. I'm trying to understand how it generates the XHTML pages. I guess it's the function of do_action( 'hook-name' ) , but I'm stuck with the understanding of the instruction isset( $wp_filter['all] ) when reading the function do_action because I don't understand what is the meaning of the word all.  Is it a PHP feature or a WordPress one? I just read this very insightful post , where the author stated that the variance of $\hat\beta$ is:  $$\text{var}(\hat\beta) = \sigma^2(\textbf{X}^\prime \textbf{X})^{-1}.$$  I couldn't figure out why it is like this. Can anyone elaborate a bit? One of the joys of working for a government healthcare agency is having to deal with all of the paranoia around dealing with PHI (Protected Health Information). Don't get me wrong, I'm all for doing everything possible to protect people's personal information (health, financial, surfing habits, etc.), but sometimes people get a little too jumpy.  Case in point: One of our state customers recently found out that the browser provides the handy feature to save your password. We all know that it has been there for a while and is completely optional and is up to the end user to decide whether or not it is a smart decision to use or not. However, there is a bit of an uproar at the moment and we are being demanded to find a way to disable that functionality for our site.  Question: Is there a way for a site to tell the browser not to offer to remember passwords? I've been around web development a long time but don't know that I have come across that before.  Any help is appreciated. Person, Persons, People, Peoples When does the set enter set theory? I wonder about the foundations of set theory and my question can be stated in some related forms:   If we base Zermelo–Fraenkel set theory on first order logic, does that mean first order logic is not allowed to contain the notion of sets? The axioms of Zermelo–Fraenkel set theory seem to already expect the notion of a set to be defined. Is there are pre-definition of what we are dealing with? And where? In set theory, if a function is defined as a set using tuples, why or how does first order logic and the axioms of Zermelo–Fraenkel set theory contain parameter dependend properties $\psi(u_1,u_2,q,...)$, which basically are functions? Last upgrade crashes network manager (no internet connection, no applet) While upgrading today, something caused my wireless network manager to disappear. Not even connecting via wired connection.  This error is being shown by files:  **(nm-applet:2716): WARNING **: Could not initialize NMClient /org/freedesktop/NetworkManager: The name org.freedesktop.NetworkManager was not provided by any .service files   (nm-applet:2716): nm-applet-WARNING **: Error connecting to ModemManager: Error calling StartServiceByName for org.freedesktop.ModemManager1: GDBus.Error:org.freedesktop.DBus.Error.Spawn.ExecFailed: Cannot launch daemon, file not found or permissions invalid   (nm-applet:2716): nm-applet-WARNING **: Could not find ShellVersion property on org.gnome.Shell after 5 tries   (nm-applet:2716): nm-applet-WARNING **: Failed to register as an agent: (2) The name org.freedesktop.NetworkManager was not provided by any .service files    Is there a patch I can download through windows and send through to my ubuntu, or is it a case of having to reload everything? I tried running two versions back but still no internet access. An irreducible polynomial in a subfield of $\mathbb{C}$ has no multiple roots in $\mathbb{C}$ C++, array of objects without I read an interesting question here in the forum () and came up with the following doubt: even though its diffraction angle is too small to be detected, if we had the possibility to detect it, what would the diffraction of a soccer ball through a pair of posts look like? I mean, in the case of electrons, there is a screen in which the diffraction pattern can be appreciated. But what about this case? Would we see lots of soccer balls in different places or what?