I have found doubt full awarding of Enlightened Badge  Look at here :   This badge was awarded on   as per the description of Enlightened badge..  First to answer and accepted with score of 10 or more. This badge can be awarded multiple times.    But on that question, answer have only 1 upvote an not accepted but badge was awarded. BUG!!

Formerly List of all badges with full descriptions.  What are badge name's requirements? Why didn't I get badge name ? Which badges can I earn multiple times?    Jump to:                    Note: Some badges are awarded based on score. The term score means the total number of upvotes minus the total number of downvotes.  Any badge with a *** next to it is one of 20 badges that count towards the  displayed on a moderator candidate in an election. The candidate score is a total of 40 points: the first 20 are awarded based on the user's rep divided by 1000 and rounded down; the second 20 represents the total number of unique badges earned of the 20 that count. Note that if the same badge is earned multiple times, it will only count once towards the candidate score.  Any badge with a "(retired)" next to it is no longer awarded, but is retained by users who previously earned them. See  for more info on what it means for a badge to be retired.       Visit the  of the  on any site to see a complete list of badges that you can filter by earned, unearned, or type.


I was trying the study a new subject in groups (from a book I have). I came acorss with the following question:  Consider:  $X=S_4$  $Y=\{e,(12)(34),(13)(24),(14)(23)\}$  How can I prove that:  $$\{gY:g\in X\}=\{Yg:g\in X\}$$

Let $K=\{(1),(1,2),(3,4),(2,4),(1,4),(2,3)\}$ is a subgrope of $S_4$, we want to show that it is a normal subgroup.  I know that i have to examine the condition of normality in $S_4$ i.e. for all $g\in S_4, g^{-1}Kg=K$. I think this takes times or I am missing something near. Please give me the right hint. Thank you.  Edit: $K = \{(1),(12)(34),(13)(24),(14)(23)\}.$


I read that (key, nonce) pair should be used only once for encryption of a message. My question is how confidentiality can be lost if two peers using a shared key use same (key, nonce) pair to encrypt their own messages (messages of peers would be different).

Suppose Alice wants to send encryptions (under a one-time pad) of $m_1$ and $m_2$ to Bob over a public channel.  Alice and Bob have a shared key $k$; however, both messages are the same length as the key $k$.  Since Alice is extraordinary lazy (and doesn't know about stream ciphers), she decides to just reuse the key.  Alice sends ciphertexts $c_1 = m_1 \oplus k$ and $c_2 = m_2 \oplus k$ to Bob through a public channel.  Unfortunately, Eve intercepts both of these ciphertexts and calculates $c_1 \oplus c_2 = m_1 \oplus m_2$.     What can Eve do with $m_1 \oplus m_2$?     Intuitively, it makes sense that Alice and Bob would not want $m_1 \oplus m_2$ to fall into Eve's hands, but how exactly should Eve continue with her attack?


I've got postfix and dovecot running on ports 25, 110, 587, 465, 993, 995 for the usual mail protocols. I can telnet into all ports except port 25 which you can see below. Any ideas on what's going on?  Remotely Telnet to port 25 (fails)  # telnet 192.168.1.100 25 Trying 192.168.1.100 ... telnet: connect to address 192.168.1.100: Operation timed out telnet: Unable to connect to remote host   Locally Telnet to port 25 (success)  # telnet localhost 25 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. 220 example.com.au ESMTP Postfix   Firewalld rules:  # firewall-cmd --list-all public (default, active)   interfaces: eth0   sources:   services: dhcpv6-client dns http https imaps pop3s smtp ssh   ports: 110/tcp 465/tcp 5432/tcp 587/tcp 143/tcp 2288/tcp 25/tcp   masquerade: no   forward-ports:   icmp-blocks:   rich rules:   My postfix main.cf has   inet_interfaces = $myhostname, localhost    and ss -plnt |grep :25 returns   LISTEN     0      100                       *:25                       *:*      users:(("master",30844,13)) LISTEN     0      100                      :::25                      :::*      users:(("master",30844,14))

On a rackspace cloud server, I opened up Putty and it WORKS if I do "telnet localhost 25" on the VPS, the postfix process is running as well  However, if I try to telnet remotely like "telnet domain.com 25" it doesn't work, I've tried "telnet domain.com 22" and it works.  C:\Users\Shane>telnet domain.com 25 Connecting To domain.com...Could not open connection to the host, on por t 25: Connect failed


I have a PSD of a website design. I like the layout but I would like to experiment with the color palette. Is there a way to swap colors? I was think something like variablizing the colors and then quickly swapping them or importing a color palette from Kuler.   This is what I'm looking at:

I'm looking for a way to use one color in multiple different layers, and then be able to change that color in all the layers in one single place.  Lets say that I have four layers using #ffffff. Now I want to know what my design looks like with #ffff00 instead. How can I do this without manually changing all four layers?  I can add that adjustment layer on hue/saturation is not really what I'm looking for. What I need is something like "change all #ffffff to #ffff00."


I would like to add geometry attributes (x y) to my point layer using py console.I know it is possible to calculate using the field calculator syntax, but then it creates a new layer which I want to avoid.  Basically below task using script.

I have a vector layer, populated with points, and I want to programmatically add to this layer.  The part related to the geometry works just out of the box, but I was having trouble with adding attribute values to the new features.  The problem is, when I add a new feature to the layer, I do not manage to specify fields. The feature would complain on exceptions.KeyError.          featureList = []         ## now add the computed points to the layer         for p in [p for p in points.values() if p['computed']]:             x, y = p['coordinates']             feature = QgsFeature()             layerPoint = transf.transform(QgsPoint(x, y))             feature.setGeometry(QgsGeometry.fromPoint(layerPoint))             feature['id'] = p['id']             featureList.append(feature)          layer.dataProvider().addFeatures(featureList)         layer.commitChanges()   And before you ask, obviously I'm sure it's the feature['id'] which is giving trouble, not the p['id'].  So the short version of the question was "how do I specify fields of a feature before it was ever part of a layer?"


Am getting an exception when am trying to start an Activity A from FragmentActivity B. The FragmentActivity B contains two tabs.It also contains a Home button on the custom action bar. When i click on the home button it should jump to activity A. But its not working. Here is the exception.   W/System.err(8394): java.lang.NullPointerException  W/System.err(8394):    at android.app.Activity.startActivityForResult(Activity.java:3190)  W/System.err(8394):    at android.app.Activity.startActivity(Activity.java:3297)  W/System.err(8394):    at com.brihaspathi.activity.BaseActivity.gotoHomeScreen(BaseActivity.java:220)  W/System.err(8394):    at com.brihaspathi.activity.BaseActivity$2.onClick(BaseActivity.java:208)  W/System.err(8394):    at android.view.View.performClick(View.java:3511)  W/System.err(8394):    at android.view.View$PerformClick.run(View.java:14105)  W/System.err(8394):    at android.os.Handler.handleCallback(Handler.java:605)  W/System.err(8394):    at android.os.Handler.dispatchMessage(Handler.java:92)  W/System.err(8394):    at android.os.Looper.loop(Looper.java:137)  W/System.err(8394):    at android.app.ActivityThread.main(ActivityThread.java:4484)  W/System.err(8394):    at java.lang.reflect.Method.invokeNative(Native Method)  W/System.err(8394):    at java.lang.reflect.Method.invoke(Method.java:511)  W/System.err(8394):    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:788)  W/System.err(8394):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:554)  W/System.err(8394):    at dalvik.system.NativeStart.main(Native Method)   And the function on Home button onclick   public void gotoHomeScreen(Activity act) {     try     {         Intent i = new Intent(act,MainActivity.class);         i.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);         startActivity(i);         act.finish();     }     catch(Exception e)     {         e.printStackTrace();     } }

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


Assuming any commonplace, but rigorous, definitions and properties of $\pi$, what could be a simple, rigorous and non-numerical argument for the following inequality?  $$\pi\neq\sqrt{2}+\sqrt{3}$$  By simple I mean within the framework of a typical elementary analysis course at university, say, and thereby excluding deeper properties like transcendence etc.   By non-numerical, I mean arguments that avoid calculating approximations.

How prove that $ \sqrt{2}+\sqrt{3}>\pi$? Maybe some easy way?


Can you please explain differences in following phrases:   I am thinking      I thinking       I think      I have been thinking

Non-native speakers often get confused about what the various tenses  and aspects mean in English. With input from some of the folk here I've put together a diagram that I hope will provide some clarity on the matter.  I offer it as the first answer to this question. Consider it a living document. Input is welcome, and good suggestions will be  incorporated into the diagram.    Nota bene: What this is not is a discussion of whether there are  more than two tenses in English. , to which this question is not intended to supply arguments one way or the other.  Here, the aim is to provide an overview of what constructions English-speaking people use for conveying information about actions referring to past, present, and future, and to provide it first and foremost to precisely the people who are likely to use "tense" as a catch-all term in their search, rather than to linguists who know better.  Breaking News There is now an excellent ELU blog article titled  . It is highly recommended reading.


i found this regular expression :           "^(([a-zA-Z0-9_\\-\\.]+)@([a-zA-Z0-9_\\-\\.]+)\\.([a-zA-Z]{2,5}){1,25})+([;.](([a-zA-Z0-9_\\-\\.]+)@([a-zA-Z0-9_\\-\\.]+)\\.([a-zA-Z]{2,5}){1,25})+)*$"   which validates a list of email like :   address1@gmail.com;adresse2@gmail.com  But i need to tweak it to validate in fact this sturcture :                     address1@gmail.com;adresse2@gmail.com;   and also just one email address with this structure :                    address1@gmail.com;   I also want to be able to validate email addresses containing + sign  ,  for example validating :             address1@gmail;adress2@gmail.com;addres+3@gmail.com;    as a valid list of emails.  Thank you for your help.

Is there a regular expression to validate an email address in JavaScript?


Are their any requirements to publish an article in a journal without a degree in the field? If so, what are they?  I was curious if people in general can publish in an journal when they have not obtained a degree in the field.

Is it possible to submit a paper to a scholarly, peer-reviewed journal without PhD? More specifically, what would be the bare minimum qualifications that would grant one the possibility of the paper being published in a peer-reviewed academic medium?


I was wondering whether there are any words in English that have three words spelt together like "eee" or "ooo". I'm not talking about abstract and meaningless words like "hmmm" or "zzz", but is there any other such word?

One of my friends argues that princessship is the only word which has 3 identical letter comes together (s) ,but I think there is no word such as princessship.  Can anyone tell me whether this is a real word, and if there are any more English words which have 3 letters consecutively?


So I was having an issue with json_encode returning null that I found the solution for , but I don't understand why it was an issue in the first place. The MySQL tables from which I was drawing the data are defined like  CREATE TABLE `super_table` (   `id` int(11) NOT NULL AUTO_INCREMENT,   `name` varchar(100) DEFAULT NULL,   `values` text,   `created` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,   PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8;   so shouldn't values and name be utf8 encoded already when I pull them out in PHP? A simplified version of what I'm doing:  $sql = "SELECT * FROM super_table"; $query = $mysqli->query($sql); $data = (object) $query->fetch_all(MYSQLI_ASSOC); foreach ($data as $key => $val) {     $data->$key = utf8_encode($val); } $result = array('success'=>$success, 'data'=>$data); echo json_encode($result);   Why does not doing the extra utf8_encode step sometimes yield a null result when I try to json_encode it?

I'm setting up a new server and want to support UTF-8 fully in my web application. I have tried this in the past on existing servers and always seem to end up having to fall back to ISO-8859-1.  Where exactly do I need to set the encoding/charsets? I'm aware that I need to configure Apache, MySQL, and PHP to do this — is there some standard checklist I can follow, or perhaps troubleshoot where the mismatches occur?  This is for a new Linux server, running MySQL 5, PHP, 5 and Apache 2.


I'm starting my master in Physics. I've taken some Quantum classes before, but nothing as serious as this. I would like now to really go in detail with all the concepts of QM. My professor recommended us to buy Quantum Theory by David Bohm, but I think is a little bit hard for me. I'm looking for a textbook that explain the derivation of the mathematical formulas given. Some recommendations ?

I'm really interested in quantum theory and would like to learn all that I can about it. I've followed a few tutorials and read a few books but none satisfied me completely. I'm looking for introductions for beginners which do not depend heavily on linear algebra or calculus, or which provide a soft introduction for the requisite mathematics as they go along.  What are good introductory guides to QM along these lines?


I have a URL which requires some parameters. The values of those parameters can be accented characters, so I absolutely need to UrlEncode them. Strangely, I see a difference between the behavior or Javascript and .NET.  Let's pretend I try to UrlEncode the word "éléphant". In JavaScript (according to this WebSite: ), I get the following: %E9l%E9phant. This appears correct to me. However, in .NET with this call (System.Web.HttpUtility.UrlEncode("éléphant")) I get "%c3%a9l%c3%a9phant". What is wrong? What am I missing? What should I do if I want to get %E9l%E9phant in .NET?  Thanks!

In JavaScript:  encodeURIComponent("©√") == "%C2%A9%E2%88%9A"   Is there an equivalent for C# applications? For escaping HTML characters I used:  txtOut.Text = Regex.Replace(txtIn.Text, @"[\u0080-\uFFFF]",     m => @"&#" + ((int)m.Value[0]).ToString() + ";");   But I'm not sure how to convert the match to the correct hexadecimal format that JS uses. For example this code:  txtOut.Text = Regex.Replace(txtIn.Text, @"[\u0080-\uFFFF]",     m => @"%" + String.Format("{0:x}", ((int)m.Value[0])));   Returns "%a9%221a" for "©√" instead of "%C2%A9%E2%88%9A". It looks like I need to split the string up into bytes or something.  Edit: This is for a windows app, the only items available in System.Web are: AspNetHostingPermission, AspNetHostingPermissionAttribute, and AspNetHostingPermissionLevel.


In a html structure like this

Countries visited in last 6days?

                                      <input type="text" id="countriesVisited">                     Countries visited in last 6days?                     <input type="hidden" id="countriesVisited-val" name="countriesVisited-val" value="">

Indonesiax

   The input box is autocomplete and each country is appending to the ul tag. I want to hide the div with id focusDiv when user clicked outside of this div

I have some HTML menus, which I show completely when a user clicks on the head of these menus. I would like to hide these elements when the user clicks outside the menus' area.  Is something like this possible with jQuery?  $("#menuscontainer").clickOutsideThisElement(function() {     // Hide the menus });


When passing the array of integer to a method and assigning it to different variables. Eg: to a=c,b=c; values changes in both a and b.   public static void main(String[] args) {     int arr[] = new int[]{1,2,3,4,5};   miniMaxSum(arr);   }  static void miniMaxSum(int[] arr) { int[] a = arr; int[] b =arr;  b[2] = 3;  //but here value changes in a also. }

I always thought Java uses pass-by-reference. However, I've seen a couple of blog posts (for example, ) that claim that it isn't (the blog post says that Java uses pass-by-value). I don't think I understand the distinction they're making. What is the explanation?


*-network UNCLAIMED           description: Network controller    product: RTL8821CE 802.11ac PCIe Wireless Network Adapter    vendor: Realtek Semiconductor Co., Ltd.    physical id: 0    bus info: pci@0000:01:00.0    version: 00    width: 64 bits    clock: 33MHz    capabilities: pm msi pciexpress cap_list    configuration: latency=0    resources: ioport:f000(size=256) memory:fea00000-fea0ffff  I installed today Kubuntu but my WIFI is not working at all. Also this is some output I get, can anybody please help me out with that? Otherwise I will reinstall Windows where I had never problems with networking. Thanks for any answers and help!

We just bought a Lenovo  (which is supposed to have the Intel 8265 for wireless). This laptop was bought in part because it is certified to run Ubuntu and as such to me at least it would make sense for things to work out of the box... but no such luck.  First, I installed Ubuntu 17.10 and after installation realised Wi-Fi was not working. I also tried Ubuntu 16.04 from a USB drive since that is the version of Ubuntu it is certified for, but no luck there either.  The wireless chip is not detected by lshw (or even lspci by the looks of it), ip link does not show a wireless interface, and the iwlwifi kernel module is not loaded at boot (I can load this myself using modprobe iwlwifi but this does not make Wi-Fi work). I think it is a combined Wi-Fi/Bluetooth chip, and Bluetooth does appear to work (or at least Bluetooth shows up in Gnome and rfkill list).  modinfo iwlwifi | grep 8265 shows me a file ending in -34 is supposedly loaded but only a file ending in -33 (and some other lower numbers) is present in /lib/firmware, if that helps).  I have also installed the Linux 4.14.9 kernel in an attempt to get things to work, but this did not resolve the issue either.  Further information  root@ThinkPad-E570:~# modinfo iwlwifi | grep 8265 firmware:       iwlwifi-8265-34.ucode root@ThinkPad-E570:~# rfkill list all 0: tpacpi_bluetooth_sw: Bluetooth     Soft blocked: no     Hard blocked: no 1: hci0: Bluetooth     Soft blocked: no     Hard blocked: no root@ThinkPad-E570:~# dmesg | grep iwl root@ThinkPad-E570:~# lspci -nnk | grep 0280 -A3 05:00.0 Network controller [0280]: Realtek Semiconductor Co., Ltd. Device [10ec:c821]     Subsystem: Lenovo Device [17aa:c024]   Update  I just noticed that the laptop does not have an Intel wireless chip at all, but in fact has a Realtek one... which means that the  of the shop I bought this laptop at were not accurate... Sigh. Same problem stands, however, just with a crappier wireless chip.


I noticed that it is difficult to determine the necessary and sufficient conditions for a graph to have an invertible adjacency matrix (I've seen the other related posts on M.S.E.). I was wondering if there are any interesting applications of invertible adjacency matrices.   For example, is there any information encoded in the product of two adjacency matrices? An interesting result I have read is that the $(i,j)$ entry of $A^k$ for an adjacency matrix $A$ of a graph $G$ counts the number of walks from the vertex $v_i$ to $v_k$ that use $k$ edges.

Which are the sufficient and necessary conditions for an undirected graph with no self edges (i.e. no loop of length $1$) to have an invertible adjacency matrix?  In this case, the adjacency matrix is symmetric (i.e. $A = A^\top$). Moreover, all the diagonal elements are $0$ and there is a $1$ in both the entries $(i,j)$ and $(j,i)$, with $i\neq j$, if and only if vertices $i$ and $j$ are connected.   A first necessary condition is the following: all vertices must have at least one connection, otherwise the relative row of $A$ is null. But what else?


I have a schengen visa validity from 13\6\2018 until 27\6\2018 and the duration of stay is 15 days , if i enter to schengen area at 20\6\2018 can i stay 15 days count start from enter means leaving on 10\7\2018 ?

I'm from Tunisia and I got a Schengen visa from the Austrian Embassy for  28 days, the “duration of stay”, and the number of entries is 1. But the validity of the visa is from 02/08/2015 to 13/09/2015.  Do I have to stay only 28 days, for example from 02/08/2015 to 29/08/2015 or can I stay there until 12/09/2015 ?  And if I have got to stay only 28 days, then can I choose the days of stay, that's mean can I stay in Austria for example from 09/08/2015 to 05/09/2015?


I want to write a CV with LaTeX and I'm wondering if someone could help me and give the beginning code of this CV:    I will inspire myself from it.

I want the code source for this CV, I have searched in moderncv template but  I didn't find the .tex for :    Can someone please help me?


Anyone know if there's a way to set a colour input (for a material) to match the colour of the closest material/mesh? For example, if I had a cube that I wanted to dynamically adopt the colour of the nearest surface - so if it touched a green surface it would be green, if it touched a red surface it would be red. Thanks :)

This will be a pretty complex question, many areas will be connected to it but it is for sure focused on one main problem. I'm not sure is it possible without heavy scripting and I didn't found anything on this topic elsewhere. So off we go.  Abstract:  I want to mix colors from different objects on collision.  Example. One cube is blue, second is yellow. Boom! Both are green.  I've made this little simulation:    Going deeper:  I think that the best option would be making material with RGB node, then, after taking color from another object mix them with MixRGB as below:    As you can see first problem is that Blender isn't mixing colors as it should, but let say it's close enough and leave it for now as is.  Second one is scenario with many objects. Using same approach will give us enormous amount of nodes - by adding another Mix and RGB. Replacing one color on the other hand doesn't give us proper mixing.   Solution for second problem could be making one RGB node from mixed values and waiting for another hit.  Wrap this up:  If there is any logic behind it, it could probably works like that:   Get RGB values of both objects. Detect collision. Mix values and replace existing RGB node value with new one. Wait for another hit.   Advanced usage:  You may ask: "What you want to do with this dummy?" and my answer is:     from Pyroevil.  In this script there is collision system so (as far as I know about Python scripting like Jon Snow) it will be matter of adding color change thingy to this. Or I'm just delusional.   It will be great thing to mix particle collision systems colors. It could open new way to simulate fluids. If it's possible to transfer particle color values to IsoSurface in CubeSurfer or any other mesher possibilities will be endless (nooo, it's just for pouring blood to milk).  Blend file:  Here is my blend file if somebody wants to play with it (Molecular Script needed).


I am quite new to learning python and was playing around with the math functions. I tried to create a function that would allow you to find certain powers e.g. squares, cubes. Why is it when I run the code below it lists most of the powers required but manages to miss some.    def more_powers():     print "For which power do you wish to find: "     power = int(raw_input("> "))      print "Choose the upperbound: "     n = int(raw_input("> "))      for num in range(2, n):         for base in range(2, num):             if log(num, base) / power == 1:                 print "%d is a power of %d." % (num, base)             else:                  base += 1   For which power do you wish to find: > 3 Choose the upperbound: > 5000 8 is a power of 2. 27 is a power of 3. 64 is a power of 4. 343 is a power of 7. 512 is a power of 8. 729 is a power of 9. 1331 is a power of 11. 1728 is a power of 12. 2197 is a power of 13. 2744 is a power of 14. 3375 is a power of 15. 4096 is a power of 16.   As you can see it misses out the equivalent power for 5, 6, 10 and 17.

Consider the following code:   0.1 + 0.2 == 0.3  ->  false   0.1 + 0.2         ->  0.30000000000000004   Why do these inaccuracies happen?


I have to find the last two decimal digits of the number $9^{{9}^{9}}$.  That's what I did:  $$m=100 , \phi(m)=40, a=9$$ $$(100,9)=1, \text{ so from Euler's theorem,we have :} 9^{40} \equiv 1 \pmod{100}$$  $$9^{{9}^{9}} \equiv 9^{9^{2+2+2+2+1}} \equiv 9^{9^2 \cdot 9^2 \cdot 9^2 \cdot 9^2 \cdot 9} \equiv 9^{81 \cdot 81 \cdot 81 \cdot 81 \cdot 9} \equiv 9^{(40+40+1) \cdot (40+40+1) \cdot (40+40+1) \cdot (40+40+1) \cdot 9} \equiv (9^{(40+40+1)})^{(40+40+1) \cdot (40+40+1) \cdot (40+40+1) \cdot 9} \equiv 9^9 \equiv 9^4 \cdot 9^4 \cdot 9 \equiv 6561 \cdot 6561 \cdot 9 \equiv 3721 \cdot 9 \\ \equiv 21 \cdot 9 \equiv 89 \pmod{100}$$  So,the last two digits are $8 \text{ and } 9$. $$$$But,is there also an other way two calculate the last two digits of $9^{{9}^{9}}$ or is the above the only one?

I tried to calculate the last two digits of $9^{9^9}$ using Euler's Totient theorem, what I got is that it is same as the last two digits of $9^9$.   How do I proceed further?


I'm trying out Linux (Kubuntu 20.04), moving from Windows 7, just to see how I feel about it. I installed Blender 2.83 and I'm having trouble opening up the start up file I have saved away with the settings I like. I can open it up, but the settings that I had are not taking effect at all. There are some special tweaks in there too, as I was indoctrinated into the 3D world through 3DS Max, and my Blender UI setup reflects that. Am I going to have to just go through and make changes all over again? Thanks.

I run Blender on several machines, it is a hassle to copy configs around, in order that you don't have to configure everything from scratch every time. Is there a sync functionality that does this?


I use a table and when I press a button, results are added to that table. The rows have a button that need to be selected, but it doesn't work  I want to click the button and alert what they say.  Link to fiddle:     var receitas = {   Lulas: ["Arroz de Lulas"],   Vaca: ["Bitoque", "Estufado de Vaca"] };  function get_receita(alimento) {   var pesquisa = [];   for (var key in receitas) {     if (receitas.hasOwnProperty(key)) {       if (key == alimento) {         pesquisa.push(receitas[key]);       };     };   };    return pesquisa[0]; };  $("#pesquisar_receita").click(function() {   var alimento = document.forms["form_refeicao"]["alimento"].value;   $("table").find("tr:gt(0)").remove();   //$("#resultados").css("display", "block");    var pesquisa = get_receita(alimento);   for (var i = 0; i < pesquisa.length; i++) {     //$("#resultado_"+i).text(pesquisa[i]);     $("table tr:last").after("
" + pesquisa[i] + "	<button>Escolher</button>
");   };    $("#resultados").css("display", "block"); });  $("table button").click(function() {   $(this).closest('tr').find('td').each(function(colIndex, c) {     refeicao = c.textContent;   });   alert(refeicao); })  <form id="form_refeicao" onSubmit="return false">
     Prato Principal:     <select id="alimento">       <option value="Vaca">Bife: Vaca</option>       <option value="Frango">Bife: Frango</option>       <option value="Porco">Bife: Porco</option>       <option value="Atum">Peixe: Atum</option>       <option value="Espadarte">Peixe: Espadarte</option>       <option value="Lulas">Peixe: Lulas</option>       <option value="Pescada">Peixe: Pescada</option>     </select>     <button id="pesquisar_receita">Pesquisar</button>

         Resultados:

 </form>

I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off.  This happens on page ready and works just fine.  The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound.  I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option.


So I downloaded Wine from the Software Center and it works very well. Unfortunately, the software center does not offer the latest version. My question is; when will the version be bumped to 1.6?

Why are packages in the official Ubuntu repositories older than the latest (upstream) versions from Debian Sid, PPAs, the authors, etc.?


REASONS FOR REFUSAL NRA v 1.0      You have applied for a visa to visit the UK. In deciding whether you meet the requirements of , I have considered:       your application    your immigration history      The decision      I have refused your application for a visit visa because I am not satisfied that you meet the requirements of paragraph(s) V4.2 (a)(b)(c)(e) of Appendix V because:   - You applied for a visa to visit your sister in the UK for 21 days. The documents that you provided do not demonstrate that you are related to your sponsor.    - You provided a supporting letter from your father however as there is no birth certificate I am not satisfied that you are related.    - I note that you are a child student and therefore you do not have your own income, however it is necessary for me to see your overall situation in Ghana. The documents that you provided do not demonstrate your personal circumstances in the home country.       In the view of the above I am therefore not satisfied that you intend to visit for a purpose that is permitted by the visitor routes and period as stated by you or that you will leave the UK at the end of your proposed visit. I am not satisfied that you will be adequately maintained and accommodated or will be able to meet the cost of your return or onward journey.

Many of the UK visa refusals we see here share a common pattern and the prevailing reasons refer to V 4.2 (a) and (c).    I do understand that, while the applicants may describe very different individual circumstances, there's a consistent pattern and, broadly, fall into specific categories:    Credibility (lifestyle, lack of ties, visit history, lies & omissions) Funding (insufficient funds, provenance of funds, funds parking) Sponsorship (family, friends, employer)   Question: What most commonly triggers a UK visa refusal where V 4.2 (a) and (c) are given as the grounds?  Secondarily: Given that there is a clear pattern, to what extent are these refusals predictable? Does sponsorship make a difference? Is there a set of personal circumstances, however abstract, where a refusal is all but guaranteed? For example, why do those we see here on TSE who sought entry for the PLAB or British Army appear to be refused with a common theme? Is there a uniform shortcoming or is it just discrimination?   PLAB: What is about applications for a visa, for the purpose of sitting the Professional and Linguistic Assessments Board (PLAB) exam, that seem to invite refusals. After all, the test is given so that international medical graduates can show that they qualify to practise medicine in the UK. The first part, PLAB 1, can be taken in centres outside of the UK. However, PLAB 2 can be taken only in the UK. Why can't you can't get a visa just to sit the exam, promising that you'll leave immediately after?    British Army: Since Commonwealth citizens are eligible to apply online to join, even those who don't reside in the UK, why is it so difficult to get a visa just to attend an interview to see whether you are suitable? Even with an invitation from the Army, such visa applications seem to be unsuccessful. Isn't a career in the British Army a valid reason?     Lastly:  After such a refusal, what approaches would increase the chance of a successful application?


It's pretty hard to get to page 500 when the navigation tool looks like this: 1 2 3 4 5 … 3896 next If clicking the ellipsis (…) produced a prompt allowing users to type in the desired page, that would be awesome. Editing the URL is not easy on small touchscreens. It's hard to click on the right character position in the URL. EDIT: Since this was closed as a duplicate for another question, I added my suggestion as an  over there.

My feature request is for the page navigation buttons that are on many of the different pages.  I would like to see, aside from the usual page buttons, a small input box and a "goto" button so that you can skip directly to a particular page. For example on the Tags page, the page navigation buttons have: [1] [2] [3] [4] [5] ... [353] [next] I would love to see: [1] [2] [3] [4] [5] ... [353] [next]  [inputbox][goto] That way the user can jump around the pages much quicker than only being able to skip ahead 2 pages at a time. Edit - added: Alternatively you could just have the [goto] button and then when it is clicked, have a small popup appear with the input area and another [goto] button, you can see an example of it here: , just goto the bottom and click on the button with [2 pages] on it to see the popup appear.


I have normal stereo headphones which work fine  On a specific PC running Windows 7 the external speaker and USB speakers work fine too  But when I plug in the headphones, all I hear is muffled music, no voice track? It sounds like it is being split into 5.1, and I am getting just the L & R components, and not the centre voice channel?  In the Playback devices (sound) control panel, I can adjust stereo or 5.1 for external speakers or USB speakers, but not for the headphones. The config button is grey out for them  Is this the problem, if so how do I fix it?

I'm using stereo headphones on Windows 8. When I play songs I can't hear them normally.  Instead I'm only able to hear just "blurry" music, so I can barely hear the voices singing.  How can I resolve this problem?


I recently got a new server. Freshly installed 16.04. I noticed the kernel running is 2.6.32. So I wanted to update it.   sudo apt-get install --reinstall linux-generic   Now I have this version: 4.4.0-21.37  I also had to install grub to use update-grub.   dpkg --list shows me only linux-headers/images of 4.4.0-21.37.  Also update-grub found kernels of that version.   But when I use uname it still tells me this  Linux london 2.6.32-042stab113.21 #1 SMP Wed Mar 23 11:05:25 MSK 2016 x86_64 x86   Yes I did reboot a couple times. Maybe you can help me.

I have ordered a VPS with Ubuntu 13.04 on it.  The VPS reports that the kernel is a 2.6.x-series kernel.  From what I have read, Ubuntu 13.04 has at least the 3.8.x series of kernels.  Is there a reason that my VPS is seeing a 2.6.x series kernel, and not a 3.8.x series kernel?


For example, let's say I have a level 8 Druid who has never seen a Quasit before, and I use the spell Conjure Animals to conjure 2 Quasits. On my next action, may I use my Wild Shape to change into a Quasit?

The Conjure Animals Spell doesn't seem to have any limitations on what you can conjure beside the number per CR, and that they have to be beasts. Seemingly you could conjure a creature that you've never seen before. Wild Shape on the other hand makes the distinction that you can only assume the shape of a beast that you have seen before. Is this a loop hole for Wild Shape? Could you conjure a Giant Owl, "see it", and then Wild Shape into a Giant Owl later?  Some of the distinctions that are making this tricky for me is that with the Conjure Animal Spell you aren't actually conjuring creatures, but "You summon fey spirits that take the form of beasts" (PHB 225). I'm interpreting this as these aren't actual beasts, merely impostors. There's something just not entirely real about these creatures, so they don't count as a creature that a druid has seen in the wild.  On the other hand, with Wild Shape you aren't actually turning into a real creature either, but you "assume the shape of a beast that you have seen before" (PHB 66). So maybe seeing the shape of the beast is enough to transform into it.  So, does a spirit in the form of a beast summoned with the Conjure Animal Spell count towards a creature that a druid has seen and can now Wild Shape into? Does it matter that it is a spirit and not a real creature, or is seeing its an impersonation or its shape enough for a druid to Wild Shape into it?


I'm new to digitization. I have the following map and I'm trying to digitize the purple features. Is there any way to automatically digitize all the purple lines on the map.

I want to digitize automatically old paper map that scanned to jpg  . I know that it's possible to digitize it with arc-map but I can not remember how to do it.


Let A and B be two $ n\times n$ matrcies over the field F.Prove that if (I-AB) is invertible, then (I-BA) is invertible and that $  (I-BA)^{-1}=I+B(I-AB)^{-1}A $  Using this result prove that AB and BA have precisely the same characteristic values in F.  My Attempt: For the first part I tried to prove the contrapositive ie I assumed (I-BA)X=0 has a non trivial solution and tried to show a non trivial solution for (I-AB)X=0. I could show this by making use of the fact that AB and BA have same eigen values but that method becomes circular in this case considering the follow up question mentioned at the end.Anyway even using that AB and BA have same eigen values I could not prove the expression for the inverse.I would request a solution which can then be used to prove that AB and BA have same eigen values and also proving the expression for the inverse.

The problem is from  Algebra by Artin, Chapter 1, Miscellaneous Problems, Exercise 8. I have been trying for a long time now to solve it but I am unsuccessful.      Let $A,B$ be $m \times n$ and $n \times m$ matrices. Prove that $I_m - AB$ is invertible if and only if $I_n - BA$ is invertible.    Please provide with only a hint.


One can derive a parametrization for ellipse in polar coordinates (origo at one of the focal points)  $$\varphi(t) = ct$$ $$r(\varphi) = \frac {k+1}{k+\cos(\varphi)} $$ where for width of ellipse $w$: $$k = 1+\frac{2}{w-2} = \frac w {w-2}$$ However, when I plot it, sampling from $t$ linearly, I get very  unevenly spaced sampling points.   How can I modify my parametrization to achieve same "speed" of linear sampling along the ellipse boundary for small $\varphi$ as for "large" $\varphi$ ($\approx \pi$)?  Answers which don't use calculus/analysis are of extra interest (as I think the pre-Newtonian astronomers did not have access to such advanced tools), but I won't forbid anyone to use it.

As an extension to  on equiangular fisheye distortion, how can I calculate equidistant points around an ellipse (or 1/4 segment of) given it's aspect ratio? When it's circular, I can use a simple angle increment around the central point, but as the aspect ratio gets smaller, the length of the arc gets shorter and the angles are no longer equidistant.


An example script is shown below. The meaning of the syntax - exec > >(tee -a "$file" "$sec_file") 2>&1 , is to print to the console the stdout and sdterr , and also to print to the files - /tmp/log.txt  the stdout and sdterr more /tmp/ppl #!/bin/bash  file=/tmp/log.txt sec_file=/tmp/log1.txt  exec > >(tee -a "$file" "$sec_file") 2>&1  echo "linux server is up "  but when I run the script as bash /tmp/ppl   it prints linux server is up  but then my prompt isn't shown. The prompt only appears after I press enter I am testing this on RHEL 7.5 and my bash version is 4.2.46(2)-release (x86_64-redhat-linux-gnu). What is wrong here?

The   echo one; echo two > >(cat); echo three;    command gives unexpected output.  I read this:  and many other articles about process substitution on the internet, but don't understand why it behaves this way.  Expected output:  one two three   Real output:  prompt$ echo one; echo two > >(cat); echo three; one three prompt$ two   Also, this two commands should be equivalent from my point of view, but they don't:  ##### first command - the pipe is used. prompt$ seq 1 5 | cat 1 2 3 4 5 ##### second command - the process substitution and redirection are used. prompt$ seq 1 5 > >(cat) prompt$ 1 2 3 4 5   Why I think, they should be the same? Because, both connects the seq output to the cat input through the anonymous pipe - .  Question: Why it behaves this way? Where is my error? The comprehensive answer is desired (with explanation of how the bash does it under the hood).


I Have an input  text  :   string DefaultInput = "Name : John | FamilyName : Doe |";   I Want to be able to Extract the "John" & "Doe" and maybe other values from 1 input using Regex  My Code :   Match m = Regex.Match(DefaultInput,"Name : (.*?) | FamilyName : (.*?) |"); this.textBox1.Text = "ProfileName : " + m.Groups[1].Value + "\r\nProfileFamilyName : " + m.Groups[2].Value;

I am tired of always trying to guess, if I should escape special characters like '()[]{}|' etc. when using many implementations of regexps.  It is different with, for example, Python, sed, grep, awk, Perl, rename, Apache, find and so on. Is there any rule set which tells when I should, and when I should not, escape special characters? Does it depend on the regexp type, like PCRE, POSIX or extended regexps?


Want to write Test case and unit test for this trigger      trigger Autoleadconversion on Lead (after insert, after update) {         for (Lead lead : Trigger.new) {             if (lead.isConverted == false) //to prevent recursion             {                 Database.LeadConvert lc = new Database.LeadConvert();                 lc.setLeadId(lead.Id);                  String oppName = lead.Name;                 lc.setOpportunityName(oppName);                 LeadStatus convertStatus = [SELECT Id, MasterLabel FROM                                              LeadStatus WHERE IsConverted=true LIMIT 1];                 lc.setConvertedStatus(convertStatus.MasterLabel);                 Database.LeadConvertResult lcr = Database.convertLead(lc);                 System.assert(lcr.isSuccess());                        }         }      }

This is a canonical question and answer developed by the community to help address common questions. If you've been directed here, or your question has been closed as a duplicate, please look through the resources here and use them to shape more specific questions. To browse all canonical questions and answers, including more unit test resources, navigate to the  tag.  This canonical question is intended to address several classes of common questions by providing a quick summary and links to comprehensive resources:   How do I start writing my first unit test?  How do I unit test this code?  I need help writing this unit test.   Salesforce Stack Exchange looks for detailed, specific questions that the community can help you with, and can't write tests on your behalf. We feel that working with the resources below can help you get started, and we encourage you to make an attempt to write your test and return to SFSE with your specific questions when you encounter challenges you can't resolve.


I came across a question where I think I am missing something fundamentally. The question is: Find the number of distinct solutions to the equation $x^2 \oplus \widehat{-1} = \hat{0}$ in $\mathbb{Z}_8$, this is where $\hat{a}$ is an equivalence class of congruence mod 8. I've tried to do things like: $x^2 - 1 = 8k \implies x = 8k \pm1 \implies x \equiv \pm1 (mod \ 8)$. How should I actually go about solving this sort of problem? Thanks

Is there a general way to solve quadratic equations modulo n? I know how to use Legendre and Jacobi symbols to tell me if there's a solution, but I don't know how to get a solution without resorting to guesswork. Some examples of my problems:  $x^2 = 8$ mod 2009 $x^2 + 3x + 1 = 0$ mod 13  Thanks


I'm looking for a proof that, given two sets $A$ and $B$, the cardinality of $A$ is less than $B$ implies the cardinality of the powerset of $A$ is less than the cardinality of the powerset of $B$.   In short, does $\overline{\overline {A}}<\overline{\overline {B}}\ \ $  imply   $ \ \ \overline{\overline {P(A)}} < \overline{\overline {P(B)}}$?  There seems to exist a clear method of proof for when $A$ and $B$ are finite (nonempty) sets, since there cannot exist a bijection between a finite set and a proper subset of itself, and hence $\overline{\overline {A}}<\overline{\overline {B}}$ implies there exists a bijection between $A$ and a proper subset of $B$, which one could use to construct a bijection between $P(A)$ and a proper subset of $P(B)$ and then apply the fact that there exists no bijection from $P(B)$ to a proper subset of itself.   But what about when $A$ and $B$ are infinite? How would we know that the proper subset of $P(B)$ which is bijective to $P(A)$ is not also bijective to $P(B)$?

Is it generally true that if $|P(A)|=|P(B)|$ then $|A|=|B|$?  Why? Thanks.


Can people edit pdfs generated from LaTeX?  I know adobe has a paid program that allows the editing of pdfs.  I ask because I would think this wouldn't work.  With a pdf generated from a Word, there is no code in the background that was need to make the document whereas some LaTeX documents aren't so simple in construction, behind the scenes.  Also, if it can be edited in this manner, we it be able to match the fonts?  What if they tried to edit an image that is floating?  Since the image is based LaTeX's best placement, would this screw up the document?

Is there an application (in Windows, Unix, or Mac) that allows you to edit the LaTeX generated PDF. I know there is pdfsync, but it only gives you the line, and then you have to search where in the line you want to make the change. This is OK sometimes, for a couple of changes, but when there are lots of changes it becomes really tedious.  I would really like to accelerate this process of correcting mistakes (mostly grammar, missing commas etc.). in my document, without going through all the markup.


I need to use a stack to push and pop lists with 2 numbers in them, that serve as XY coordinates in a program I'm making. It seems simple enough, so I just do  stack = []   to make the list I'll use as a stack. Now i make the coordinate variable  coord = [0,0]   and push it to the stack.  stack.append(coord)   Now, the stack is equal to  [[0, 0]]   and that's perfect. Now let's say I move up one, so my coord variables Y value updates like  coord[1] += 1   and coord equals  [0,1]   which is good. But wait! Even though I did nothing to the stack list, it now reads  [[0,1]]   when I wanted it to retain it's old value that I sent to it.  [[0,0]]   Why does this happen, and what can I do to accomplish what I want?  Just in case it wasn't clear, I want the stack to behave like  >>> stack = [] >>> stack []  >>> coord = [0,0] >>> stack.append(coord) >>> stack [[0, 0]]  >>> coord[1] += 1 >>> stack [[0, 0]]  >>> stack.append(coord) >>> stack [[0, 0], [0, 1]]   but this is what it does.  >>> stack = [] >>> stack []  >>> coord = [0,0] >>> stack.append(coord) >>> stack [[0, 0]]  >>> coord[1] += 1 >>> stack [[0, 1]]  >>> stack.append(coord) >>> stack [[0, 1], [0, 1]]   Changing coords[1] += 1 to coords[1] = coords[1] + 1 does not fix the problem, like it did .

I needed to create a list of lists in Python, so I typed the following: my_list = [[1] * 4] * 3  The list looked like this: [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]]    Then I changed one of the innermost values: my_list[0][0] = 5  Now my list looks like this: [[5, 1, 1, 1], [5, 1, 1, 1], [5, 1, 1, 1]]    which is not what I wanted or expected. Can someone please explain what's going on, and how to get around it?


My Ubuntu gets very slow because of too many apps, but when i check the system monitor, Ram use is 80% but swap is less than 5%. How do you let ubuntu use the swap more effectively?

I need a step-by-step, simple and easy way to configure swappiness.


So many questions show up on the right side of the page (Popular Questions) i.e:    So I was wondering if it is possible to filter these questions to only display the ones that I'm interested in seeing.  Also, it would be cool if we can do the same to the list of SE on the top of the page.

I was going to make a filter for the "" by excluding some sites from it.  I noticed  which talks about "negative filtering" but does not explain how one can do it or if it is possible.  There does not seem to be a way to do this, though.  On the filter page, my only options are:  So how can I do "All sites except [list]"? It would also be nice if this could include similar functionality with the meta checkbox.  Something like "All main & meta sites except..."


I want to light up an LED with 220 VAC using least components. These two circuits come to mind:    R1, R2 will be around 200K - 300K depending upon the brightness that I will need. Not much brightness is required so I can even go higher if I am able to get some amount of light out of the LED.  Which one (if any) will work?  (I am not much concerned with efficiency as these will be used as indicators when a high power device is turned on. For ex - a geyser. This circuit will be wired in parallel with the geyser to accomplish that. If I use 200K resistor, I'll be using up around 0.25 watts which will be negligible as compared to 1000 watts being consumed by the main device.)

I'm attempting to build an LED bed lamp that will be powered by 240V mains. The LEDs are  which if I use with a 12V supply and have calculated correctly will draw 0.24W each. I plan to use 5 or 6 of them in the lamp so will consume a maximum of 1.5W.  Initially I thought I'd use a transformer and bridge rectifier to get the required 12V DC but the transformer weighs a ton and is too bulky. The next option was to use a  but I'm wondering is there is a better way?  I think it would be possible to power the LEDs directly from mains using only a rectifier without mains and stepping down the voltage but then it's not safe. Are there any smallish components that can both isolate the mains and supply a DC voltage?


What do Online Dictionaries Say?  says each is used as an adverb in the following examples:  There are five leaflets – please take one of each. Each of the brothers has a different personality. It’s 500 miles each way. The bill comes to $80, so that’s $20 each   says each is a determiner and a pronoun in the following  each one of us was asked what went on (determiner) Derek had money from each of his five uncles (pronoun)  's entry for each states it is an adjective,  A rope was tied to each end of the boat. Each student had a different explanation.  a pronoun,  He took shot after shot, each missing by inches  and an adverb  They cost 50 cents each. We were allowed two tries each.  But  tells me that each is an indefinite pronoun  Each of the players has a doctor  and  (which btw I really like) says that each is an indefinite adjective  An indefinite adjective is used to describe a noun in a non-specific sense. The most common indefinite adjectives are: any, each, few, many, much, most, several, and some. They are often used to describe a noun to show an element of uncertainty. Indefinite adjectives should not be confused with indefinite pronouns. Indefinite adjectives modify nouns or pronouns. Indefinite pronouns are standalone pronouns   Examples  I gave my friends a book each I gave each a book I gave each of my three friends a book I gave a book to each one of my friends Each one of my friends received a book Each friend of mine received a book  I believe that all the sentences above are grammatical. If any are considered non-standard in English, please please tell me! QUESTIONS  For sentence No. 1, I cannot find a satisfying "tag" to place on each. Since the word "each" is placed at the end of a sentence, I suppose it must be an adverb but it feels like a quantifier to me because it tell me how many books, i.e. to each of my friends. Is each in No.1 an adverb? Why?  Sentence 2 is definitely a pronoun.  For sentences 3, 4, and 5 "each of" and "each one of" can be substituted with all of, with no loss in meaning. But are each of and each one of pronouns? If we use a pronoun to replace a noun phrase or a noun, then how can each in: each (one) of my friends be a pronoun? And I imagine it can't be an indefinite pronoun because we know exactly "how many" people in sentence 3. Oxford Dictionaries suggest that each of is a pronoun but each one of is a determiner.  In sentence 6 each is an adjective/determiner/indefinite adjective because it tells us something about the number of friends. Right?

I am looking at these two sentences:        M and W are letters that each have 4 strokes.   M and W are letters and  each has  4 strokes.      It seems that each is an adverb in (1) but a pronoun in (2). Can anyone explain why each is not a pronoun in (1)?


Let $f: \mathbb{R} \rightarrow \mathbb{R}$ be a $C^2(\mathbb{R})$ function which is also even (ie, $f(-x) = f(x)$). Prove that the function $F: \mathbb{R^n} \rightarrow \mathbb{R}$ defined by $F(x) = f(|x|)$ (where $|x|$ denotes the Euclidean norm of the vector $x$) is also $C^2(\mathbb{R^n})$.  It feels so simple, but I'm just not getting it, so any help would be appreciated.  Thanks!

This question is from an exercise in Way of Analysis (section 10.2.4 problem 20).  If $f: \mathbb{R} \rightarrow \mathbb{R}$ is $C^k$ and $f$ is even, then show $F: \mathbb{R}^n \rightarrow \mathbb{R}$ given by $F(x) = f(|x|)$ is also $C^k$.  $C^k$ just means the function has $k$ continuous derivatives, and $|x|$ is referring to the regular Euclidean norm.  I am not sure how to use the fact $f$ is even in the proof and having trouble for a general $k$. Any hints, even on a particular case like $k=2$, are welcome.  My workings:  As a comment suggests $f(x) = F(x)$ for $n = 1$. For $n = 2$, $F(x) = f(\sqrt {x_1^2 + x_2^2}).$ I'm stuck on where to proceed from here. Is there some form of induction here that I am not seeing?


I'm trying to type out some code to return the name of the current database. Literally every place I've seen says that you can type out   SELECT DATABASE()  to return that information, but when I try to do it in SSMS I get a syntax error for the DATABASE() function. No idea why it isn't working.

It is a bit of a "chicken or egg" kind of query, but can someone dreamup a query that can return the name of the current database instance in which the query executes? Believe me when I say I understand the paradox: why do you need to know the name of the database instance if you're already connected to execute the query? Auditing in a multi-database environment.  I've looked at all the @@ globals in Books Online. "SELECT @@servername" comes close, but I want the name of the database instance rather than the server.


I just installed Ubuntu first time.  I was checking instructions on the Internet about how to install. Someone said to use the second option i.e erase disk and install. I got idea that it will delete only windows partition but everything is gone now and i have two partitions now. Root n home respectively. I have lost extremely important data. Is there anyway that i can recover it. I really need it. Please help me now.

I have a Toshiba satellite A-200 laptop with a Vista OS on it with 4 NTFS partitions  (C:) Vista  (D:) Entertainment  (E:) Work  (F:) Sources   and I wanted to start using Ubuntu instead. So I tried it first from the live CD and everything was OK and all the partitions were shown and working and so I decided to install Ubuntu to replace Vista on the (C:) drive. After I did that I can no longer find my folders and files on the (D:), (E:), (F:) partitions and the only file system that is shown is one 198 GB although my HDD is 320 GB.  I can't access the lost data on the remaining 120 GB which I hope is still there and not totally lost  I am now working from the live CD but I am unable to install testdisk. Can I recover the Vista partitions by the product recovery CD to get my laptop back to the factory settings? Can I recover the NTFS partitions using a recovery program for Windows or will that make the problem worse?   I need these data badly as I don't have a backup for them.


I know this may not be a very specific question title, but I don't really know how to ask in my situation, sorry for that.  Here is the code pieces I find from MSDN blog :  void construct(T* const p, const T& t) const {     void * const pv = static_cast<void *>(p);     new (pv) T(t); }   The "new" here looks strange to me, help me understand this, please.

Has anyone here ever used C++'s "placement new"? If so, what for? It looks to me like it would only be useful on memory-mapped hardware.


Dear Community Members,  Given the outputs of the SPSS analysis, how can the exp (B ) and Beta values be interpreted in terms of odd ratio ? and in relation to how the independent variable affects the probability of outcome variables (choice of adaptation)?.  Thank you  George

I'm somewhat new to using logistic regression, and a bit confused by a discrepancy between  my interpretations of the following values which I thought would be the same:    exponentiated beta values  predicted probability of the outcome using beta values.    Here is a simplified version of the model I am using, where undernutrition and insurance are both binary, and wealth is continuous:  Under.Nutrition ~ insurance + wealth   My (actual) model returns an exponentiated beta value of .8 for insurance, which I would interpret as:     "The probability of being undernourished for an insured individual is .8 times the probability of being undernourished for an uninsured individual."   However, when I calculate the difference in probabilities for individuals by putting in values of 0 and 1 into the insurance variable and the mean value for wealth, the difference in undernutrition is only .04. That is calculated as follows:   Probability Undernourished = exp(β0 + β1*Insurance + β2*Wealth) /                              (1+exp(β0 + β1*Insurance + β2*wealth))   I would really appreciate it if someone could explain why these values are different, and what a better interpretation (particularly for the second value) might be.     Further Clarification Edits As I understand it, the probability of being under-nourished for an uninsured person (where B1 corresponds to insurance) is:  Prob(Unins) = exp(β0 + β1*0 + β2*Wealth) /               (1+exp(β0 + β1*0+ β2*wealth))   While the Probability of being under-nourished for an insured person is:  Prob(Ins)= exp(β0 + β1*1 + β2*Wealth) /            (1+exp(β0 + β1*1+ β2*wealth))   The odds of being undernourished for an uninsured person compared to an insured person is:  exp(B1)   Is there a way to translate between these values (mathematically)? I'm still a bit confused by this equation (where I should probably be a different value on the RHS):  Prob(Ins) - Prob(Unins) != exp(B)   In layman's terms, the question is why doesn't insuring an individual change their probability of being under-nourished as much as the odds ratio indicates it does?  In my data, Prob(Ins) - Prob(Unins) = .04, where the exponentiated beta value is .8 (so why is the difference not .2?)


I've been dual booting Linux (Kubuntu) and Windows for a couple of months now, and I'm thinking of making a full switch, since I haven't booted Windows since I started dual booting.  However, I don't want to forsake Windows, in case I were to need it later for a specific application.  Is it possible to delete Windows, but keep the product key so that you can reinstall Windows later?

With the new Windows 10 coming out soon as a free upgrade, I'd like to know if and how I can install the upgrade on a new HDD. I assume the files needed for Windows 10 are only for upgrading an installed copy of Windows 7 or 8 and not a standalone installer to use on an empty hard drive. Or is this assumption wrong?  I have some issues booting (an older non-working version appears in the list of OS's to choose from) and I'd like to replace my current SSD, which is too small, with a new larger capacity one, while keeping my other drives intact. The old SSD will then be removed.  If more information is needed, please let me know.


Hello I have an input field on my site which people can enter search terms.  I am taking the value of the users input and spitting it out onto a url string.    jQuery("#searchButton").click(function(){     var simpleSearchTermLocal = jQuery('#searchField').val();     var urlString = "www.mysite.com/" + simpleSearchTermLocal;     alert(urlString); }); <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> <input type="text" id="searchField" /> <button id="searchButton">search</button>     So when someone inputs something like "ABC" into the search field, the value of variable urlString becomes www.mysite.com/ABC which is fine.  But when entering a space in the input field, like "ABC 123", urlString becomes www.mysite.com/ABC 123 which isnt fine. I would like it to turn into www.mysite.com/ABC%20123  Any suggestions?  Thanks

How do you safely encode a URL using JavaScript such that it can be put into a GET string?  var myUrl = "http://example.com/index.html?param=1&anotherParam=2"; var myOtherUrl = "http://example.com/index.html?url=" + myUrl;   I assume that you need to encode the myUrl variable on that second line?


This is a follow up question to my   Let $A,B,C$ be independent normally distribution variables $\mathcal{N}(0,\sigma^2)$ with unknown variance $\sigma^2$. Let $D = A + B + C$.  Given $n$ samples of $A$ and $D$ suggest an estimator $\hat{\sigma}_D^2$ the variance of $D$. Obviously a simple approach is to simple compute the sample variance of $D$. However can the extra information provided by the samples of $A$ be used to reduce the error of the estimate $\hat{\sigma}_D^2$? let the error be defined by the root-mean-square deviation:  \begin{equation} RMSD\left(\hat{\sigma}_D^2\right) = \sqrt{\mathbb{E}\left[\left(\hat{\sigma}_D^2-\sigma_D^2\right)^2\right]} \end{equation}  My approach:   $$D \sim \mathcal{N}(0,3\sigma^2)$$  Compute sample variance of $D$ notated $\text{Var}(D)$ and sample variance of $A$ notated $\text{Var}(A)$:  $$\hat{\sigma}_D^2 = 3\lambda_1\text{Var}(A) + \lambda_2\text{Var}(D)$$  Arbitrarily take $\lambda_1 = \lambda_2 = 0.5$. However there is no reason to think this is optimal. Please give your suggestions.

Let $A,B,C,D$ be independent normal random variables distributed according to $\mathcal{N}(0,\sigma^2)$ and $E = A+B+C+D$.  The goal is to provide an optimal estimate of $\sigma^2$ given samples of $A,B,E$ but not $C,D$.  In this case optimal refers to minimising the root-mean square deviation of the estimate $\hat{\sigma}^2$:  $$RMSD(\hat{\sigma}^2) = \sqrt{\mathbb{E}\left[\left(\hat{\sigma}^2-\sigma^2\right)^2\right]}$$  I can think of a simple approach to estimate $\sigma^2$ given samples of $A,B$ which is to simply compute the sample variance. Also I know that the variance of $E$ is $4\sigma^2$ so I could compute the sample variance of $E$ and divide it by 4 to get an estimate of $\sigma^2$. However it should be possible to combine the information from both $E$ and $A,B$ to improve estimation $\sigma^2$. Could you outline the approach to use both sets of information?


I would like eclipse to show me explanations for different methods, how do I do that?

Using Eclipse I want to view the source code for a core Java class (E.g. java.util.concurrent.ConcurrentHashMap) but when I navigate to the source using 'Open Declaration' it says 'Source not found' and gives me the option to attach the source.  My question is; how do i attach the source? Where do i get the source .jar from for the java.util.concurrent library?


I have a very simple request here to implement, if it doesn't already exist, a way to filter questions by number of answers. This would allow you to look for questions with no answers at all (not just questions that have no accepted or upvoted answers, like the unanswered questions tab).

I want to find questions within the C++ tag but with zero answers. How can I do that?


I've come across an exercise while preparing my OCA, i don't understand why the program print : abce 3 instead of abcde 3. Here the program :  'public static void main(String[] args) {         System.out.print("a");          try{             System.out.print("b");              throw new IllegalArgumentException();           }catch(IllegalArgumentException e){               System.out.print("c");               throw new RuntimeException("1");           }catch(RuntimeException e) {               System.out.print("d");               throw new RuntimeException("2");           }finally {             System.out.print("e");             throw new RuntimeException("3");           }         }'   Any explanations why it ignores the last catch block  will be really appreciated!

This may seem like a programming 101 question and I had thought I knew the answer but now find myself needing to double check. In this piece of code below, will the exception thrown in the first catch block then be caught by the general Exception catch block below?  try {   // Do something } catch(IOException e) {   throw new ApplicationException("Problem connecting to server"); } catch(Exception e) {   // Will the ApplicationException be caught here? }   I always thought the answer would be no, but now I have some odd behaviour that could be caused by this. The answer is probably the same for most languages but I'm working in Java.


When I'm trying to deploy my react app to github pages, I ran npm run deploy. It managed to build but has the following errors when deploying:  git-upload-pack '.': git-upload-pack: command not found fatal: Could not read from remote repository.  Please make sure you have the correct access rights and the repository exists.   My git remote -v returns:  origin  https://github.com/helplah/shopping-cart.git (fetch) origin  https://github.com/helplah/shopping-cart.git (push)

I have been using git to keep two copies of my project in sync, one is my local box, the other the test server. This is an issue which occurs when I log onto our remote development server using ssh;  git clone me@me.mydevbox.com:/home/chris/myproject Initialized empty Git repository in /tmp/myproject/.git/ Password: bash: git-upload-pack: command not found fatal: The remote end hung up unexpectedly fetch-pack from 'me@me.mydevbox.com:/home/chris/myproject' failed.   (the file-names have been changed to protect the guilty... !)   Both boxes run Solaris 10 AMD. I have done some digging,  if I add --upload-pack=$(which git-upload-pack) the command works, (and proves that $PATH contains the path to 'git-upload-pack' as per the RTFM solution)  but this is really annoying, plus 'git push' doesn't work, because I don't think there is a --unpack= option.    Incidentally, all the git commands work fine from my local box, it is the same version of the software (1.5.4.2), installed on the same NFS mount at /usr/local/bin.    Can anybody help?


Hey so I have this div and inside the div I have a button. I wanted to center the div horizontally and vertically. Also I wanted to center the button horizontally and vertically inside the div. Here is my code.    <div style='position: relative; left: calc(50% - 250px); top: calc(50% - 100px); border: 1px solid black; width: 500px; height: 200px;'>   <button style='position: absolute; width: 100px; height: 30px; left: calc(50% - 50px); top: calc(50% - 15px);'>     Submit   </button> </div>     The button positioning works fine inside the div. However I am curious why the div will center horizontally but not vertically? I am assuming it has something to do with the position: relative? But I am not sure.  Thanks for your help!

I want to center a div vertically with CSS. I don't want tables or JavaScript, but only pure CSS. I found some solutions, but all of them are missing Internet Explorer 6 support.
Div to be aligned vertically
   How can I center a div vertically in all major browsers, including Internet Explorer 6?


We are a family of 13 travelling from Mumbai to Istanbul via Frankfurt and return in the same direction. we have 4 hours layover each way, do we need a transit visa for Germany?

I found many related questions on this site but I am still not sure about the rules. How can I decide if I need a visa to transit? Schengen members as of May 2021 are as follows:  Austria Belgium Czech Republic Denmark (excluding Greenland and the Faroe Islands - but an open border with the Schengen Area is maintained) Estonia Finland France (excluding overseas departments and collectivities) Germany Greece Hungary Iceland Italy Latvia Liechtenstein Lithuania Luxembourg Malta Netherlands (excluding Aruba, Curaçao, Sint Maarten and the Caribbean Netherlands) Norway (excluding Svalbard) Poland Portugal Slovakia Slovenia Spain (except Ceuta and Melilla) Sweden Switzerland


I currently have a Windows partition installed on my Mac, for CptS reasons, and since that took up a majority of my storage space, I've been using an external hard drive to save documents and whatnot. I wanted to know if I can download applications from the App Store to my external hard drive. I've read on other forums that it's possible to change the location of the download folder on a Mac, but you have to delete the application if you were to want to update it. I'm not sure if it's possible to assign the download folder to an external hard drive.   Any input would be much appreciated.

I prefer to have all applications installed per-user, to ~/Applications/ rather than globally. The default location for apps installed from the Mac App Store is the global applications folder located at /Applications/.  Is there a defaults write com.apple.AppStore command I can run in the terminal, or perhaps a .plist file I can edit manually, to change this default preference?


I'd like to override one of the applications set in /usr/bin/. I have created an alternative with the same name in ~/bin/ which in in my PATH (as set both in .bashrc and in .profile).  When I start the application from the console, I get the expected result: my application is started instead of one from the distribution.  However, within KDE, when I do alt+F2 and type in the application name, the one in /usr/bin starts instead of the one in ~/bin/.   How do I set KDE so that ~/bin is recognized from everywhere in KDE.  I'll probably also have to edit the K-menu, although I am not sure how to do it with KDE4.

I need to set some environment variables such as the XDG spec ones, before KDE starts in such a way that kwin and any apps run from KDE will inherit them. Where could I do this, and how?


I have Ubuntu 16.10 with Windows 7. I installed Ubuntu ( first ) then I created a partition for Windows, then installed it on the partition so that deleted GRUB. So I restored GRUB , but now Windows 7 is not appearing in GRUB.  Any solutions on how to add Windows 7 to GRUB?

I have Ubuntu on my laptop. Now I want install Windows 7 in a dual-boot. How can I do this? I can't lose my Ubuntu files, and I'm afraid that I might break . Go  for UEFI only!


I have a very simple question that I really can't understand.  I have a method that takes a string and determines what the first character of the string is, and then returns it.  public String deterFirstChar(String value){     String keyValue;     char res;      res = value.charAt(0);     keyValue = Character.toString(res);     if (keyValue == "C"){         return keyValue;     } else if (keyValue == "G") {         return keyValue;     }     System.out.println("Error: Wrong keyParam");     return "F"; }   However, intstead of returning, for an example keyValue = C, it skipps the if statement and returns "F" when I know for sure that keyValue is "C".  Why is this occurring?

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


It is one of the companies that..  Removed background music from its stores.  Removed background music from their stores.

The company will issue (their, its) annual report next month.   In this case, should I use "its" or "their"?


If $|ax^2+bx+c|\le1$ for $|x|\le1$, then prove that $|cx^2+bx+a|\le2$ for $|x|\le1$. $a,b,c$ are real.  I discovered this to be a duplicate of   With reference to the answer there , is the information $|x|\le1$ redundant as the proof only uses the conditions at $x=1,0,-1$

I have an interesting problem, in which i would be utmost happy to receive some help:  $p$, $q$, $r$ are real numbers with the following property: $|px^2+qx+r|\le 1$ for all $x$ in $[-1; 1]$. Prove that $|rx^2+qx+p|\le2$ for all $x$ in $[-1; 1]$.  Substituting for $x=0$ yields $-1\le r\le1$. $x=1$ and $x=-1$ results $-1\le p+q+r\le1$ and $-1\le p-q+r\le 1$ respectively. From those: $-2\le p\le2$ and $-1\le q\le 1$.  I couldn't go anything further. Would be happy to receive some ideas. :)


I hate not being able to full screen the YouTube videos embedded on Stack Exchange sites.  What's the reason for blocking full screen?  Please enable it...

Currently, embedded YouTube videos don't allow you to fullscreen them. Clicking the button shows the frustrating message Fullscreen is unavailable.  An example answer with an embedded video (embedding isn't enabled on on this site):    It looks like this is really easy to fix, see for example . Could this be enabled?


I want to connect diodes in parallel to increase the current carrying capacity. If I connect two diodes in parallel having same rating(same forward voltage drop), does thermal runaway still come in picture? If forward voltage drop is not going to be same for each diode then why so when I'm using same diode?

I'm trying to repair an 800W power supply (see my previous question on this.) One thing that gets me is that the design has two schottky diode packages (in TO-220) in parallel. I was always told this was A Bad Idea, but since they are thermally coupled to the same heatsink, does it present a problem in this instance? I've also noticed the same for the input bridge rectifier, two are used in parallel.


A colleague has a dataset from a before and after study looking at a continuous outcome that was measured in individuals before and after an intervention. An unknown but not insubstantial proportion of the individuals were only measured before or after the intervention.  However, due to an oversight following changes to the study design due to ethics they have only now realised that there is no way to link the before and after measurements that were made to the same individuals, i.e. there is no person ID.  Consequently, the data consists of a mix of paired and independent samples, but can only be treated as independent samples.  Are there any reasonable ways to mitigate this problem or address it, e.g. via some kind of sensitivity analysis?

An investigator wishes to produce a combined analysis of several datasets.  In some datasets there are paired observations for treatment A and B.  In others there are unpaired A and/or B data.  I am looking for a reference for an adaptation of the t-test, or for a likelihood ratio test, for such partially paired data.  I am willing to (for now) to assume normality with equal variance and that the population means for A are the same for each study (and likewise for B).


Can we define the general term for the Fibonacci Sequence? I mean we can make a generating function for fibonacci sequence which equals $\dfrac1{1-x-x^2}$, but is there any way to find the general term of fibonacci sequence?

This formula provides the $n$th term in the Fibonacci Sequence, and is defined using the recurrence formula: $u_n = u_{n − 1} + u_{n − 2}$, for $n > 1$,  where $u_0 = 0$ and $u_1 = 1$.   Show that     $$u_n = \frac{(1 + \sqrt{5})^n - (1 - \sqrt{5})^n}{2^n \sqrt{5}}.$$    Please help me with its proof. Thank you.


I am running a VirtualBox with Ubuntu 18.04 Desktop, and I need access on this guest to a folder on the host; however, the access needs to be full so I can run Wordpress. I have added myself to the vboxsf group after using the built in mounting for Ubuntu desktop, no result. I've tried chown, no result. How can I mount the shared folder on my VM and have it not owned by root and have all permissions?

I am using a VM with Ubuntu 18.04 with GUI, and I am working on a Wordpress project with Nginx. I installed VBox guest additions, but I cannot change the owner of the shared folder, which I have set to auto mount in the /opt folder; the path to the shared folder is /opt/myfolder/THISFOLDER. I want to edit contents (files) inside THISFOLDER. I have tried the command sudo chmod -aG vboxsf myusername and rebooted to no avail. When I do sudo chown -R myusername /opt/myfolder, it also doesn't do anything. How can I fix this?


If $K$ is a field complete with respect to a non-archimedean absolute value, then the $n$th term test (checking whether the $n$th term of a series goes to zero) is sufficient to check convergence of a series in $K$.  I was wondering if we have any results that guarantee, under additional hypothesis, whether a series in $\mathbb{R}$ converges by just making sure that the $n$th term goes to zero. An example would be the alternating series test. Are there others?

This is just a general question. I know the opposite statement is always true. I'm just asking when the converse holds. I know that the converse is not true in some cases, such as for harmonic series. What additional restrictions are needed to make this statement true?


I'm the new to regular expressions in JavaScript. I see the expressions in C# have the label,such as"\p{f},\p{Zs},p{Lu},p{Lt},p{Lo}". But I add this in JavaScript , it doesn't work. So, how can I change these to JavaScript format that make it can work.

How can I use Unicode-aware regular expressions in JavaScript?  For example, there should be something akin to \w that can match any code-point in Letters or Marks category (not just the ASCII ones), and hopefully have filters like [[P*]] for punctuation, etc.


Does there exist a nontrivial abelian group $A$, such that $\mathrm{Aut}(A) \cong A$? Here $\mathrm{Aut}$ stands for the automorphism group.  What do I currently know:     If such $A$ exists, it has infinite exponent.   It follows from the first Prüfer theorem, that every bounded exponent noncyclic abelian group has non-abelian automorphism group. A cyclic group is isomorphic to its automorphism group iff it is trivial.     If such $A$ exists, it is infinitely generated.   It follows from the classification of finitely-generated abelian groups, that every finitely generated noncyclic abelian group has non-abelian automorphism group. A cyclic group is isomorphic to its automorphism group iff it is trivial.

It is well-known that the map $\operatorname{Aut}$ from the class of groups to itself has fixed points. For $n \neq 2$ or $6$, $\operatorname{Aut}(S_n) \cong S_n$, $\operatorname{Aut}(D_4) \cong D_4$ and if $G$ is a finite non-abelian simple group, then $\operatorname{Aut}(\operatorname{Aut}(G)) \cong \operatorname{Aut}(G)$. The question arises if there is a fixed point among the non-trivial abelian groups. It is relatively easy to see that finitely generated abelian groups do not qualify, so if such a group exists, it has to be infinitely generated. Note that for topological automorphisms of topological groups fixed points are known: for instance $\operatorname{Aut}(\mathbb{R} \times \mathbb{Z}/2\mathbb{Z}) \cong \mathbb{R} \times \mathbb{Z}/2\mathbb{Z}$. But we assume no additional structure imposed.


Looks like at least IBM AIX and HP-UX don't have the tac command by default.  Is there a way to do this using just basic posix standard shell utilities available on all UNIX systems?  Furthermore, is SMCcoreu package on Solaris (which provides tac on SunOS, installed by default?

I want to print lines from a file backwards without using tac command. Is there any other solution to do such thing with bash?


Suppose that $G$ is an infinite group and $H\le G$. The criterion for normal subgroups states that if $H^g\le H$ for all $g\in G$, then $H\trianglelefteq G$ (and thus $H^g=H$ for all $g\in G$).  I am looking for an example of an infinite group such that $H^g\le H$ for some individual $g\in G$, but $H^g\ne H$.  I know that abelian groups are excluded, since each subgroup of such a group is normal.   Thanks.

Let $G$ be a group, $H\subseteq G$ a subgroup and $a\in G$ an element of the group. Is it possible that $aHa^{-1} \subset H$, but $aHa^{-1} \neq H$?   If $H$ has finite index or finite order, this is not possible.


There are a few parts to this question? First, if the toughness of a monster is reduced during combat by some effect such as a spell or item (I know there is one that reduces monster toughness by 1), is the trophy toughness also valued one less? I have been playing this as 'no'.   Second, if some effect raises the toughness of all or some monsters, and then after defeating one, the effect goes away, is the toughness of the trophy the originally listed toughess on the token or the enhanced toughness? Similarly one could imagine where a situation alters the toughness of a monster type you've already defeated.   I am not totally sure these last two cases actually exist but don't want to spoil more cards looking for it. If one could clarify that'd be great.

There are several things that change a monster's Toughness. For instance:    gives +1 Toughness to all Maniacs for the duration of the game  gives +1 Toughness to all Fire Vampires while the environment is active  gives all monsters +1 Toughness for the duration of the game   When effects like these are in play, the monster's Toughness in combat is higher than printed on the monster token. Does this also increase the monster's trophy value?   If yes, what happens in the event of temporary changes to the monster's Toughness? For instance, if a Fire Vampire was killed before a Heat Wave, is the trophy worth one extra point if a Heat Wave strikes later? And if a Fire Vampire is killed during a Heat Wave and then the environment is replaced with something else, is the trophy back to the original value?


I was looking for a division in a ring of formal power series. Specifically, let be $A$ a commutative ring with unit. Take $A[[x]]$ and $f\in A[x]$ a monic polynomial not invertible in $A[[x]]$ is so defined a division in $A[[x]]$ for f? for each $h$ in $A[[x]]$ there $\exists!$ r in $A[x]$ and $q \in A[[x]]$ such that h=fg+r and $degr < degf$ for example is trivial is $f(t)=t^N$:

Denote by $F[[T]]$ the ring of formal power series over a field $F$ (i.e expressions of the form $\sum_{n=0}^{\infty}a_nT^n$, $a_i \in F$).  I need to show that this is a euclidean ring with respect to the norm $\mathrm{ord}(\sum a_iT^i) = \min\{n \mid a_n \neq 0\}$.     This just feels too trivial and I think I am missing something obvious, so I would like to get a feedback on my proof (if it is even correct).    Take $f,g$ in the ring. If $\mathrm{ord}(g) < \mathrm{ord}(f)$ we get $g=f \cdot 0 + g$, so we can divide $g$ by $f$ and get a remainder.  Now suppose $\mathrm{ord}(g)=n>\mathrm{ord}(f)=k$.  I claim $f\mid g$ and therefore $g=fq+0$ for some $q$.  First, if $f=T^k$ then obviously $f\mid g$. So take $q_1$ such that $g=T^kq_1$.  Now since $\mathrm{ord}(f) = k$ we can write $f=T^kf_1$ for some $f_1$ that is invertible (since the coefficient of $1=T^0$ in it is nonzero). Taking $q = f_1^{-1}q_1$ we get $g=fq$, so $f\mid g$ and we are done.    Is this true? Am I missing something? This is suspicious for me because it seems like I proved that whenever $\mathrm{ord}(g) > \mathrm{ord}(f)$ we have $f\mid g$ which seems like a much stronger result than what I was asked to prove.


After using absorb elements, will melee spell attacks grant the extra damage from absorb elements?

The  spell says:     The spell captures some of the incoming energy, lessening its effect on you and storing it for your next melee attack. You have resistance to the triggering damage type until the start of your next turn. Also, the fist time you hit with a melee attack on your next turn, the target takes an extra 1d6 damage of the triggering type, and the spell ends.   The  cantrip says:     Lightning springs from your hand to deliver a shock to a creature you try to touch. Make a melee spell attack against the target. You have advantage on the attack roll if the target is wearing armor made of metal. On a hit, the target takes 1d8 lightning damage, and it can’t take reactions until the start of its next turn.   If I absorb fire damage with absorb elements, would I be able to add an extra 1d6 fire damage to my next shocking grasp attack?


The reputation on the profile Activity tab (on child meta sites) has a gray square background that also extends all the way to the edge of the next div (text below the reputation). Using Stack Overflow as an example, compare how it looks on the  (light theme) vs :  The div has a bg-black-050 class which is responsible for this gray background.

The way reputation is displayed on a user's profile page on meta sites is a bit off. There's gray padding around it:  which is not visible on the main site:  The 'top x%' label being so close to it makes it even worse. This affects both  and .


Not sure how to add side braces and multiple over braces and underbrace for the matrix A  What I currently have is braces inside the row vector, not sure how to make outside of the row vector Not sure how to type up these matrices in latex

I created the following matrix with , and I would like to add at the bottom (respectively right) something like an underbrace (resp. "rightbrace") under each of the two blocks, together with a number specifying the number of columns (resp. rows) of the block. This amounts to two braces on the bottom and two on the right, and each brace should have a number below (resp. at the right) of it.  I did not find anything about that on the easybmat manual. I think I see how to do the braces with the  package, but then I am not able to create the block structure of the matrix in the first place.  \documentclass{article} \usepackage{easybmat} \begin{document} \[  M(z)= \left[ \begin{BMAT}[5pt]{c|c}{c} \begin{BMAT}[5pt]{c:c:c}{ccccccc} & & \\ & & \\ & & \\ v_1 & \dots & v_m \\ & & \\ & & \\ & & \end{BMAT} & \begin{BMAT}{c}{c|c} \begin{BMAT}[5pt]{c:c:c}{ccc} & & \\ w_1(a) & \dots & w_n(a) \\ & & \end{BMAT} \\ \begin{BMAT}[10pt]{c}{c} B(z) \end{BMAT} \end{BMAT} \end{BMAT}  \right] \] \end{document}     This is more or less what i wish:


I'm trying to write a program that can compute the average result given an integer N  #!/bin/sh          CTR=0     sum=0     read N          while [ $CTR -ne $N ]; do       read integer;       sum=$(( $integer + $sum ))       CTR=$(( $CTR + 1 ))     done           printf '%.3f\n' "$(( $sum * 1/ $N ))"  This was my input when compiling : 2 5 6  Expected output 5.500 Actual output 5.000 Why is that ?

Using echo "20+5" literally produces the text "20+5".  What command can I use to get the numeric sum, 25 in this case?  Also, what's the easiest way to do it just using bash for floating point? For example, echo $((3224/3807.0)) prints 0 :(.  I am looking for answers using either the basic command shell ('command line') itself or through using languages that are available from the command line.


So, I'm new to C++ and I have come across a weird behavior. This is my code #include <iostream> #include <iomanip>  using namespace std;   int main() {     float fValue = 123.12;     cout << fixed << "Value: " << fValue << endl;     return 0; }   Now the output is kind of weird. For different fValues the output is different e.g: fValue: 123.12   Output: 123.120003 fValue: 1234.12   Output: 1234.119995 fValue: 1234.1231   Output: 1234.123047 So, not sure what I'm doing wrong here or what the problem is.

Consider the following code:   0.1 + 0.2 == 0.3  ->  false   0.1 + 0.2         ->  0.30000000000000004   Why do these inaccuracies happen?


According to Wikipedia:     In the form of a screw jack it is commonly used to lift moderately   heavy weights, such as vehicles. More commonly it is used as an   adjustable support for heavy loads, such as the foundations of houses,   or large vehicles. These can support a heavy load, but not lift it.   Insights into its mechanism is greatly appreciated .

I am trying to learn physics by myself as I do not have a good teacher at school. I've been reading Feynman Lectures on Physics and I can't figure out how he found  out this number. Here is an excerpt of :      Let us now illustrate the energy principle with a more complicated problem, the screw jack shown in Fig. 4–5. A handle $20$ inches long is used to turn the screw, which has $10$ threads to the inch. We would like to know how much force would be needed at the handle to lift one ton ($2000$ pounds). If we want to lift the ton one inch, say, then we must turn the handle around ten times. When it goes around once it goes approximately $126$ inches. The handle must thus travel $1260$ inches, and if we used various pulleys, etc., we would be lifting our one ton with an unknown smaller weight $W$ applied to the end of the handle. So we find out that W is about $1.6$ pounds. This is a result of the conservation of energy.       If you divide $2000$ pounds by  $1260$ in you get $\frac{100}{63}$, which is $1.58$, a number close enough to $1.6$ pounds, which according to Feynman is the weight that we need to apply to the end of the handle. I believe, however, that this calculation is wrong given a dimensional analysis of such operation.  Here is my dimensional analysis:  $\frac{2000 pounds * 1 in}{ 1260 inches }$ = $\frac{[M] * [L] }{[L]}$ = ${[M]}$ And this is wrong, as we are suppose to get a force, not a mass.  I found this , where you can find what I think is an email from an student reporting the teacher that he believes he got the number diving  $\frac{5}{\pi}$ . Can you also explain me this?   Finally, in a thread in a Physics Forum question,they concluded that $1.6$ is just the force to keep the system at equilibrium, and you need $\text{a force} > 1.6$ to actually lift the ton. After, someone said that Feynman would have said this answer is wrong. Why is that?


$\frac{dM}{dt} = 0$ represents a constant of motion $M.$ Why not $\frac{\partial M}{\partial t}$ represent a constant of motion $M$?

What is the difference between implicit, explicit, and total time dependence, e.g. $\frac{\partial \rho}{\partial t}$ and $\frac{d \rho} {dt}$?  I know one is a partial derivative and the other is a total derivative. But physically I cannot distinguish between them. I have a clue that my doubt really might be understanding the difference between implicit, explicit and  total time dependence.


I found thoose examples in another thread but I dont get it.   0 == '0'            // true   0 to the left i converted to false(the only number that does that). The right is a non empty string wich converts to true.  So how can  false == true --> true  What have I missed?  Edit: a lot of complaining. I didn't understand my specific case. (And the link on the top is exactly where I have copy and pasted this case from)

I'm using  to go through JavaScript, and it's returning many suggestions to replace == (two equals signs) with === (three equals signs) when doing things like comparing idSele_UNVEHtype.value.length == 0 inside of an if statement.  Is there a performance benefit to replacing == with ===?   Any performance improvement would be welcomed as many comparison operators exist.  If no type conversion takes place, would there be a performance gain over ==?


Given a linear functional on $X$, Royden's book define the norm of a linear functional $T$ as $$\{ \|T\| = \inf \{ M \geq 0 \mid |T(f)| \leq M \|f\| \forall f \in X \}, $$ How is this definition equivalent to the sup definition, where $$ \|T\| = \sup \{ T(f) \mid f \in X, \|f\| \leq 1 \} $$

How do you prove that these four definitions of the operator norm are equivalent? $$\begin{align*} \lVert A\rVert_{\mathrm{op}} &= \inf\{ c\;\colon\; \lVert Av\rVert\leq c\lVert v\rVert \text{ for all }v\in V\}\\ &=\sup\{ \lVert Av\rVert\;\colon\; v\in V\text{ with }\lVert v\rVert\leq 1\}\\ &=\sup\{\lVert Av\rVert\;\colon\; v\in V\text{ with }\lVert v\rVert = 1 \}\\ &=\sup\left\{ \frac{\lVert Av\rVert}{\lVert v\rVert}\;\colon\; v\in V\text{ with }v\neq 0\right\}. \end{align*}$$


some one states that the earth would travel in it path for 8 min if the sun vanished.  The equations of gravity show the Moon would crash into the Earth and the Earth would head for Mars the instant the Sun is gone.  Can someone show how there is a delta Time and the relaxing of the bend in space-time fields is finite?

A thought experiment: Imagine the Sun is suddenly removed. We wouldn't notice a difference for 8 minutes, because that's how long light takes to get from the Sun's surface to Earth.   However, what about the Sun's gravitational effect? If gravity propagates at the speed of light, for 8 minutes the Earth will continue to follow an orbit around nothing. If however, gravity is due to a distortion of spacetime, this distortion will cease to exist as soon as the mass is removed, thus the Earth will leave through the orbit tangent, so we could observe the Sun's disappearance more quickly.  What is the state of the research around such a thought experiment? Can this be inferred from observation?


I found  (I was getting result of 9000+ from a blog that was wrong) and used the  combined with the PLE checker from  and got a Buffer cache hit ratio of 100% with PLE of 103, how is that possible? The buffer chache hit ratio of 100% is saying the 100% of pages needed are being found in memory, but the PLE is saying pages are only staying in memory for a couple of minutes. Maybe there is some PLE value, below which buffer chache hit ratio does not add value? SELECT (a.cntr_value * 1.0 / b.cntr_value) * 100.0 as BufferCacheHitRatio FROM sys.dm_os_performance_counters  a JOIN  (SELECT cntr_value, OBJECT_NAME      FROM sys.dm_os_performance_counters       WHERE counter_name = 'Buffer cache hit ratio base'         AND OBJECT_NAME = 'SQLServer:Buffer Manager') b ON  a.OBJECT_NAME = b.OBJECT_NAME WHERE a.counter_name = 'Buffer cache hit ratio' AND a.OBJECT_NAME = 'SQLServer:Buffer Manager'  SELECT * FROM sys.dm_os_performance_counters   WHERE counter_name = 'Page life expectancy' AND OBJECT_NAME = 'SQLServer:Buffer Manager'   Why I care: My instance is SQL 2017 CU13, heavy OLTP, with 4GB of RAM for the SQL instance (single instance, 6GB RAM on the server). I know that more than 1.5GB of RAM is devoted to the Plan Cache, according to  of the 4GB of RAM here, the Plan Cache should be able to use 3GB (found similar details several places, but all are old and none are Microsoft) Select ( SUM(size_in_bytes)) /1024 /1024 AS size_in_MB FROM sys.dm_exec_cached_plans  I have not used any  just trying to understand things.

Our production server (2012, VM + SAN) has 32 GB of RAM, the database size is ~80GB. The application uses TempDB heavily - disk is hit ~100 MBps both reads & writes.  Seeing tons of SQL compilations/sec .. 95% of all batch requests are compilations.  Ideally would like to increase the RAM to 64GB or 128GB, but need to 'prove' to team that it's required.  Buffer Cache Hit Ratio (BCHR) is 99.9%, but Page Life Expectancy (PLE) is only ~400. What's the explanation for this ? I though PLE & BCHR had a linear relationship (i.e. they increase or decrease together)  On other VMs with larger databases and lot more RAM, both BCHR & PLE are high.  Current wait stats and perf counters


I have an enumerated list, for which I'm using enumitem because I want to resume the enumeration, and one item is rendered in a faded color using xcolor  \usepakage{enumitem, xcolor} % ... \begin{enumerate} \item First. \end{enumerate} other stuff \begin{enumerate}[resume] \item Second. \item \textcolor{gray}{Third.} \item Fourth. \end{enumerate}   I'd like to have the label of "Third." rendered in the same faded color, and because I've seen  I defined  newcommand{\fadeditem}{\item[\stepcounter{enumi}\textcolor{gray}{\arabic{enumi}.}]}   and it works (it's not general, but it works) but now it's not enough... I realize that what I want is a command that takes care also of the item text  What I have now  \fadeditem \textcolor{gray}{Bla bla bla.}   What I would like  \itemcolor{gray} Bla bla bla.   Addendum #1  David Carlisle, in a comment, suggested   \newcommand\itemcolor[1]{\fadeditem{#1}\textcolor{#1}}    and this deals with my task of today, writing optional questions in a list of questions.  An open part of the question is then a generalization of the problem, defining an \itemcolor{somecolor} command that just works in any (in most?) lists...

I am trying to define an alternative \item command that would allow me to use a different color for some of the items. My code has the following form:  \documentclass{article} \usepackage{color}  \definecolor{gray}{rgb}{0.7,0.7,0.7} \newcommand{\grayitem}[1]{{\color{gray} \item #1}}  \begin{document}  \begin{enumerate} \item First item. \grayitem Second item. \item Third item. \end{enumerate}  \end{document}   I was hoping that  \grayitem Second item.   would produce the same result as  {\color{gray} \item Second item.}   but for some reason, these are not equivalent. They produce the following results, respectively:                       Why are these two lines of code not equivalent? What am I doing wrong and how can I change the definition of \grayitem to produce the second result?  I have also tried removing a pair of braces, like this  \newcommand{\grayitem}[1]{\color{gray} \item #1}   but then the third item becomes gray as well.  The solution should also work for multi-paragraph items.