Python merging dictionary of dictionaries into one dictionary by summing the value

I want to merge all the dictionaries in a dictionary, while ignoring the main dictionary keys, and summing the value of the other dictionaries by value.  Input:  {'first':{'a': 5}, 'second':{'a': 10}, 'third':{'b': 5, 'c': 1}}   Output:  {'a': 15, 'b': 5, 'c': 1}   I did:  def merge_dicts(large_dictionary):     result = {}     for name, dictionary in large_dictionary.items():         for key, value in dictionary.items():             if key not in result:                 result[key] = value             else:                 result[key] += value     return result   Which works, but I don't think it's such a good way (or less "pythonic").  By the way, I don't like the title I wrote. If anybody thinks of a better wording please edit.


Here is the preamble i used   \immediate\write18{makeindex \jobname.nlo -s nomencl.ist -o \jobname.nls} \documentclass[paper=letter, fontsize=12pt]{book} \usepackage[utf8]{inputenc} \usepackage[english]{babel} \usepackage{graphicx} \usepackage{subfigure} \usepackage{amsmath} \usepackage{amssymb} \usepackage{fancyhdr} \usepackage{geometry} \usepackage{textcomp} \usepackage{setspace} \usepackage[font=small]{caption} \usepackage{float} \usepackage{lineno} \usepackage{hyperref} \usepackage{pdflscape} \usepackage[Glenn]{fncychap} %Options: Sonny, Lenny, Glenn, Conny, Rejne, Bjarne, Bjornstrup %\textwidth=450pt\oddsidemargin=0pt %\geometry{verbose,a4paper,tmargin=25mm,bmargin=25mm,lmargin=25mm,rmargin=25mm} \setlength{\parindent}{0in} \onehalfspacing  \usepackage[numbers]{natbib}  \begin{document} and I want to put a picture in landscape mode. I did in this way which did not worked for me:  \begin{landscape} \begin{figure}[h!] \begin{center} \includegraphics[scale=0.5]{lhc_cross_section.jpg} \caption{Cross sectional view of proton-proton collision.} \end{center} \end{figure} \end{landscape}   Any suggestion will really be appreciated.


Is the US ESTA (Electronic System for Travel Authorization) a visa?

An ESTA is a prerequisite to (most) travel to the US if you are a holder a passport from a visa exempt country. The ESTA:   Is required in advance of travel (at least 72 hours) Requires a fee Is valid for 2 years   In practice then this just seems to be a multiple entry tourist visa, with the only difference being (according to some sites) that visas are approved electronically instead of by an actual person. Most other visa free schemes I know of literally just require you to show up with the correct type of passport.  Then why is this considered not to be a visa? It just seems to be a justification for the visa-waiver program to not really be visa-free.


Add CSS classes and repeating header to Visualforce PDF

I have a Visualforce page that renders as a PDF. It displays a table of data and an image on the header on each page:  <apex:page renderAs="pdf">

         test

 </apex:page>   My issue is that I want to apply CSS classes to my table elements; however the CSS is not applied (in this example the text should be bold but it doesn't). If I set the applyBodyTag or applyHtmlTag of apex:page to false, it does take effect the CSS classes for the table but the header breaks.  Any ideas?


What's the value of f1 score when true positives are zero?

f1 score is defined as F1 = 2 * (precision * recall) / (precision + recall) However if true positives are zero, this gives 0/0. How to deal with this scenario?


Why didn't the compass take me to where I last slept?

I have fun playing under my world and tried to run under my house but accidentally ran the wrong way and got lost.   I used a compass which I read will help me find my bed. The last place I slept was in the middle of nowhere yet it still took me back to my house.   Why did it take me back to my house and not to where I last slept?


One of the pages in our web app includes a table that typically has a few dozen rows for each user, and it takes most of the page's width (5-8 columns).   For each row, users can perform 3 possible actions.  What's the recommended way to let users perform these actions? We've considered a few options:   3 small action buttons on the left-hand side of each row  3 small action buttons on the right-hand side of each row Drop down with the three actions Other approaches?   I saw other questions with a great discussion on  , but in this case, I'm more interested in the right place to put them.   Thanks!  Option 1 Illustration


Why in Variational Auto Encoder (Gaussian variational family) we model $\log\sigma^2$ and not $\sigma^2$ (or $\sigma$) itself?

In theory the encoder in VAE (assuming that variational family is Gaussian) generates the $\mu$ and $\sigma$ (or $\sigma^2$). But, in practice, I have seen people assuming the output is $\log\sigma^2$. Why this is necessary or useful?


NullPointerException on FileInput/OutputStream on jar

I'm working on application that causes me many problems when working   file1 = "src\\sga\\facturation\\data.ser"; FileInputStream fis = new FileInputrStream(file1);//this works fine on NetBeans   I tried  file1 = "data.ser"; InputStream fis = ClassLoader.getSystemClassLoader().getResourceAsStream(file1);   But nothing; I tried also to change the repertory's path, it told me file not found, I tried even to force the repertory in C:\Folder; where I put my files but nothing works. I tried to delete those lines to see if FileOutputStream works, but it's not the case :( Here's which works on NetBeans   ObjectOutputStream oos = new ObjectOutputStream(new FileOutputStream(file2));   This is my repertory    Thanks for helping  RELATED POSTS NEVER TOLD ME A SOLUTION WHICH WORK, SO IF YOUR ATTENTION WAS TO PUT A -1 ON BEGINING, DO IT AND LEAVE !


I'm new to MAC OS.   Using MacOSX 10.9.1 (Mavericks).   My external HDD is formatted with NTFS.   I need some rock-solid, free solution for reading and writing to this HDD. Any suggestions?


I have wondered this on and off for years, and was prompted to find out the answer:  Any time I've seen capacitors, they're listed with milli- or pico-Farad ratings. I understand that, nowadays, we have special purpose supercapacitors that package "whole" Farads into single components.  But, why on earth did "they" use such a large base value that for "most" applications you'd need something in the milli- to pico- range? It just seems ... unnecessarily skewed.


Does a Schengen visa issued and then cancelled have any effect on H1B?

I am from India. I was supposed to go to Poland for business, but since the Polish consulate usually has a long waiting time for visa appointment, my company advised me to get a German Schengen visa, for which interviews/applications are processed the next business day after application, after which I could travel on to Poland for my business.  So, I did. But Lufthansa denied me boarding, as my country destination was Poland and I was carrying a Schengen visa for Germany. The next day, the German consulate called me over and canceled my visa for the following reasons:   Consulate was made aware Germany is not the primary destination. Unreliable information was supplied.    Now, how serious is this? I really need to be in Poland. Will the Polish consulate even entertain my visa application? Should I make one?  Will this have any impact on my H1B visa stamping, which is due shortly? In general, how much of a special treatment am I going to get around the world?  Also, will traveling to other countries for business/tourism 'dilute' the seriousness of this cancellation, so it does not look like a grave violation of rules, which it was no? It was a bit dodgy but done with no fraudulent intent.


I have tried to open nm-applet but it doesn't list my/any networks. I thus can't connect to the internet.   $ lspci | grep -i Network  network controller: Broadcom corporation BCM4321 802.lla/b/g/n  (rev 03)   I installed Lubuntu 14.04 on a "HP Pavilion Entertainment PC" laptop.  What do I need to do to connect to my network?


There seems to be an issue going around at the moment, where I've seen a number of edits to post that are complete vandalism. Presumably, these get filtered out by diligent users who notice that there is something wrong with the edit, but it would be nice to reduce the work load. What can we do to prevent this from happening?


How can I prevent Chrome from offsetting newly opened Window?

When I open a new Window in Chrome on Windows 7 (by pressing CTRL+N), the new window does not exactly overlap the existing window.   Instead it is offset to the right slightly.   So, immediately after opening a new window I have to manually move it to the left so that it uses the full screen real estate.   Is there a way to prevent this offset?


What decides, which sites will appear on Off-Topic list?

I was trying to migrate my own question (finally deleted it and reposted) to Programmers only to find out, that when I select Closing > Off-Topic > Migration there is no Programmers on the list and the list itself is limited to only five strange sites:   Strange (at least for me), because:   None of the selected pages seems to fit my question. There aren't many popular SE website on the list (maybe except second -- Super User). I haven't been ever using three (last) out of five suggested.   What decides, which sites will appear on this list? Why there is only five, not all of them. And finally -- how to migrate a question to a site, that is no listed there?


hii i am creating a live search like this  and i am having a small problem in code this  jQuery("#result").on("click",function(e){  var $clicked = $(e.target); var $name = $clicked.find(\'.name\').html(); var decoded = $("
").html($name).text(); $(\'#searchid\').val(decoded);    the codes are taken from here   Problem - The problem i am facing is that when i search something it shows results correctly but when i click on result then nothing happens i want that result in input box when i click it. thanks help needed  here is a complete code  index.php  <?php     $content ='


I’ve been having trouble getting WiFi to work reliably on my laptop with Ubuntu 16.04.3 and MATE 1.12.1. I can connect to the network, but Firefox and the terminal both time out whenever I try to do anything, despite System Moniter showing that I am transmitting and receiving (tiny) amounts of data. Occasionally itll suddenly start working again for a minute or two before stopping again. I don’t think it’s my router, as my phone works fine, but Ethernet works fine. Does anyone know what this is and how to fix it?


root@modsmy:~# add-apt-repository ppa:webupd8team/java -bash: add-apt-repository: command not found   I got this error when I type the following:   add-apt-repository ppa:webupd8team/java


Warlocks using spell slots with multiclassing

I'm playing a warlock/sorcerer. Can I cast a 1st level warlock spell with a 1st level slot instead of a 2nd level slot using my sorcerer spellcasting instead of pact magic?


In my biology class we got the question if saltwater fish need to drink. We need to use the term osmosis, but I cannot think of a valid answer and we were allowed to ask help.


If f is a continuous map from X to Y with X limit point compact, does it follow that f(X) is limit point compact?

I'm looking for proof verification/help for the title question. Here is what I have now: Let $f:X \rightarrow Y$ be continuous with $X$ limit point compact. Let $V$ be an infinite subset of $f(X)$. Then we also have that $f^{-1}(V)$ is also an infinite subset of $X$. Since $X$ is limit point compact there is $x \in X$ such that $x$ is a limit point of $f^{-1}(V)$. Then $x \in \overline{f^{-1}(V)}$ by definition of the closure. Hence since $f$ is continuous, $$ f(x) \in f(\overline{f^{-1}(V)}) \subseteq \overline{f(f^{-1}(V))} \subseteq \overline{V} $$ Then since $f(x) \in \overline{V}$, it is either a limit point of $V$ or an element of $V$. However since is infinite, any neighborhood of $f(x)$ will contain infinitely many points of $V$ in either case. Thus $V$ has a limit point and $f(X)$ is limit point compact.


What is the historical background for this term?   I cannot quite see what is integral about an integral, even if we go back to the viewing it as the area under a curve.  It seems to me a strange choice of word.


Making CreateProcess inherit the console of the calling process

When I call CreateProcess in Windows, the new process doesn't seem to inherit the console of the calling process.  I made a test program that runs "ruby xtest", xtest being a script that writes "hello" to standard output.  I ran this test program from Emacs, and get no output.  I also tried the following code calling GetStdHandle, but again, no output.  Then I tried passing CREATE_NEW_CONSOLE in dwCreationFlags to CreateProcess, which made a whole new window with the Ruby output.  Finally, I made a simple fork/exec test program and compiled it using Cygwin's GCC.  This program worked: the Ruby output showed up in Emacs as expected.  I tried to decipher the Cygwin source code in  but failed.  So, how do you make the new process inherit the console of the parent process such that the output from the child shows up as expected?  STARTUPINFO si; PROCESS_INFORMATION pi; memset(&si, 0, sizeof(si)); memset(&pi, 0, sizeof(pi)); si.dwFlags |= STARTF_USESTDHANDLES; si.hStdInput = GetStdHandle(STD_INPUT_HANDLE); si.hStdOutput = GetStdHandle(STD_OUTPUT_HANDLE); si.hStdError = GetStdHandle(STD_ERROR_HANDLE); if(!CreateProcess(0, "ruby xtest", 0, 0, 1, 0, 0, 0, &si, &pi)) die("CreateProcess");


I painted my object in vertex paint (cycles) and it looks great in rendered view, but on final picture render it has white spots on it. Did anyone had the same problem? Thank you  nodes: attribute - diffuse BSDF - material output


How can I prove that every word has unique representation?

Let $\Sigma = \{0,1,*\}$ be a finite alphabet and let $\mathcal{L}\subseteq \Sigma^*$ be a formal language defined as follows  $\{0,1\}\subseteq \mathcal{L}$. If $w_1,\dots,w_n\in\mathcal{L}$ then $*w_1w_2\dots w_n*\in\mathcal{L}$ Nothing more is a an element of $\mathcal{L}$.  I want to prove that  If $*w_1w_2\dots w_n*=*v_1v_2\dots v_m*$ where $w_i, v_j \in \mathcal{L}$ then $n=m$ and $w_i=v_i$ for all $i$.  I was trying to use the fact that every element of $\mathcal{L}$ has an even number of $*$ but maybe I am missing something.


Woocommerce Force the category choice before creating new product?

How can I force the user to first choose a category product before continuing to the editor when creating a new product?  I found a successful solution but it is working for posts not products.   What I did: I changed the following code :    $post_type = 'post';     if ( isset( $_REQUEST['post_type'] ) ) {         $post_type = $_REQUEST['post_type'];     }      // Only do this for posts     if ( 'post' != $post_type ) {         return;     }   To  $post_type = 'product'; if ( isset( $_REQUEST['post_type'] ) ) {     $post_type = $_REQUEST['post_type']; }  // Only do this for products if ( 'product' != $post_type ) {     return; }   It worked, But it Still listing post categories not product categories.


I want to add an image to the sidebar, where widgets are displayed. How can I do it?


I'd like to control a 20 amp, 240 volt AC resistive load with a heavy duty contactor.  The contactor I have is a Siemens 3TX7130-0DB03 rated for 30 amps, and DPDT.  I was originally going to switch both lines on this relay.  But I got to thinking...  Would it be easier on the contactor to use both poles in parallel to switch the same line, and leave the other line always powered? What theory or research would support that conclusion?  In short...       – Schematic created using   Which of the above relays will last longer, why, and what other pros and cons are there?


Add acknowledgments and self citations to paper only after the blind review?

I am writing a conference paper of the first time, and the conference I am targeting requires anonymized submissions for the peer review. But at the same time, we (as in, my research group) are required to acknowledge the grants and support of our funding agency in all our publications. Plus, I also need to refer to a previous work of our group.   Is it appropriate for me to leave out the acknowledgements section and the reference to my work while sending the paper for review, but add these details later on if and when the paper gets accepted?   Is appropriate to add details (the acknowledgments section, for instance) which were not a part of the paper when it went for review?  I could think of this as the only way to satisfy all concerns. Are there better suggestions from more experienced people in academia?


Using Java tools,  wscompile for RPC wsimport for Document etc..   I can use WSDL to generate the stub and Classes required to hit the SOAP Web Service.  But I have no idea how I can do the same in REST. How can I get the Java classes required for hitting the REST Web Service. What is the way to hit the service anyway?  Can anyone show me the way?


No way to login with stack exchange on askubuntu.com?

I just noticed that I'm not logged in on askubuntu.com and here's my login page:    What do I click to just use my connected StackExchange account?


Automatically filter the Close Votes review queue to active tags for newbies

I am a little puzzled over this subject. Why does the number of items in the  is always increasing?  Compared to "suggested edits" - there are fewer items in the close votes queue (less than a 1M  close items vs. over 2M  items in the suggested edits).  So why can't we handle the closed votes reviews?  My observation: While reviewing a suggested edit does not require specific understanding of the post itself (a good assesment can be made based on style and formating), this is not the case for close votes: these reviews require an understanding of the post's subject.  My proposal: It would be nice if when I go to review closed votes the system will automatically filter the posts for me based on my active tags. This way I will be more efficient in reviewing and more encouraged to review more.  EDIT: An after thought (after reading proposed answer and comments): It might be that filtering is not exactly what is required, but rather prioritizing the queue per reiviewer. Each reiviewer will be given posts to review that are "similar" to his active badges with higher probability.  Update: Following , I believe it is highly important to have no backlog at the close votes reviews: This backlog actually makes closing questions on SO quite a random event, leaving many low-quality questions open spamming SO. Is there an effective way to draw the attention of SE team/moderators to this burning issue?


SQL server DB status runnable, sleeping, suspended, running and background meanings

I am not able to get the meanings of DB Session  status. I searched it for some references, but not getting any help. Can anyone explain these status (runnable, sleeping, suspended, running and background) what actually means, that would be help me a lot. Thanks in advance.


Error msg "Name is not defined" when trying to populate a field with the shape file name

I am trying to populate a field with corresponding file name. For example, if the file name is Route1.shp then the field value will be Route1 as well. However my code is not working. Can you please suggest a code that works? The code I used is given below, along with the error message             import arcpy, os, sys     from arcpy import env     arcpy.env.overwriteOutput = True     env.workspace = r"C:\ABC\GIS"     fc_tables = arcpy.ListFeatureClasses ("R*")     for fc in fc_tables:         field = "RouteName"         arcpy.AddField_management (fc, field, "TEXT")     for fc in fc_tables:     arcpy.CalculateField_management (fc, field, str(fc), "PYTHON")   And this is the error message     Runtime error  Traceback (most recent call last):   File "",   line 2, in    File "c:\program   files\arcgis\desktop10.1\arcpy\arcpy\management.py", line 3128, in   CalculateField     raise e ExecuteError: ERROR 000539: Error running   expression: Route1.shp  Traceback (most recent call last):   File   "", line 1, in  NameError: name 'Route1' is not   defined  Failed to execute (CalculateField).


I have been trying to make a slide show on the front page but I am facing an issue on how to upload images of my choice in the slide show. I.e. the images that I have in my computers folder.  I have created a view and placed an image field in it, everything is set. I have also added the block to the main page content. All I can see on the front page is the slider title obviously since i have not been able to add any images. Can any body tell me how to set my own images to the slider? I don't want to use fixer slider.  I have used views slide show and some other js files for cycle.


How is an object - created from a constructor function - able to access variables in the constructor function that was used to create it?

function F (v) {     var v = v;     this.fun = function f () {             console.log(v);     }; };  var i = new F(1);   i.fun();    Just to clarify, I don't this my question is solved by a knowledge of closures. To my understanding, i is just: {fun: function f () {console.log(v)}}. So how is i.fun() able to access v - one of the variables in a constructor function that only helped to make i?


I am getting the below ERROR.  java.lang.NullPointerException     at java.util.Properties$LineReader.readLine(Properties.java:434)     at java.util.Properties.load0(Properties.java:353)     at java.util.Properties.load(Properties.java:341)     at org.apache.qpid.example.jmsexample.hello.Hello.runTest(Hello.java:29)     at org.apache.qpid.example.jmsexample.hello.Hello.main(Hello.java:16)   My code is :  Properties properties = new Properties(); properties.load(this.getClass().getResourceAsStream("C:/Users/xxx/Documents/workspace-sts-3.8.3.RELEASE/hello.properties"));   Now ititially it looks like the file is missing or something like that.   So I added a check.  File f = new File("C:/Users/xxx/Documents/workspace-sts-3.8.3.RELEASE/hello.properties");       if(f.exists()) {              System.out.println("File exists");         }       else {           System.out.println("File DOES NOT exists");       }   This yields are result of :  File exists   So Im all out of options as to what else is missing. The file definitely exists and is properly populated. What else could I be missing ?


Use of "the" before the first part of Of-phrases

There is a  with a similar title, however it then focused on two specific examples. The main question is when we should use "the" before an Of-phrase.   Is "the" used for the first part or the whole phrase?  for example, is it [the history ] of the internet. Or the [history of the internet ].  Some examples by searching google:        the International Day of the Girl Child   the study of Pattern Recognition    The Charter of the United Nations   More than 60 United Nations Member States have never been Members of the Security Council.   the Word of the Day   The history of the Internet   Transactions of the American Mathematical Society   Proceedings of the Royal Society    Types of problems and tasks      For example in     Machine learning is a subfield of computer science that evolved from the study of pattern recognition and computational learning theory in artificial intelligence.   Why "the study". Please note there is not much context for the "study" and I suspect the possessive construction has a role.   Apart from these examples, I feel in Of-phrases the domain of objects become limited, and it allows to use "the" for the noun before "of". For example you can't say "the mouse"! which mouse? but you can say "the mouse of a computer" because in the domain of a single computer, mouse is specific.    For another example we may say "The manager of a shop" (even without any context) but not "the customer of the shop" (again without any context). maybe "the customers of the shop" or maybe just "customers of the shop". "the door of the house" but not "the window of the house", because without any context we don't have one window but one door. Similarly, "the head of a human" but not "the hand of a human" (maybe the left hand of a human).  Does this analysis creditable?


I need help so I can get back to GUI: I just pressed Ctrl+Alt+F11 but it took me to a black screen! What do I do?


Example with :     That, I think, is the most likely circumstance for Putin's departure. It's not that he'll lose an election—it's that a bunch of men in gray suits are going to file into his office and say, "Vladimir Vladimirovich, it's time for you to do your last service to the state, and that's to retire."   Or he may be off at his dacha and see on the television that he's just stepped down for reasons of ill health. And he'll pick up his red phone, and find that the people answering it will no longer take orders from him.   What do you think the difference would be if we got rid of the article? Why not say on television instead? What's the nuance?


Is Dragonstone unoccupied after Stannis Baratheon's defeat?

Is anything known about Dragonstone after:      Stannis Baratheon is killed in his bid for the Iron Throne?   As the seat of the naval defense of King's Landing and the birthplace of Daenerys Targaryen, she has a vested interest in taking it.   At the conclusion of Season 6 Episode 10, is Dragonstone unoccupied?


Prove that there are no integers $x$ and $y$ such that $ (x/y)^2 = 2$

Prove that there are no $x$ and $y$ such that $(x/y)^2 = 2$  It says that I can assume that $x$ and $y$ are relatively prime so I started the proof as:   $x$ and $y$ relatively prime $\implies$ there are integer $m$ and $n$ s.t $mx + ny = 1$ $\implies (m/n)^2 = ((1-ny)/(xn))^2$   I don't know what to do after this. Thanks


How does one make vertices in line with the rest of the object's mesh?

Hello Blender community!  I'm working on a personal project in which I'm modelling a car.    Its mesh once had bezels, but I've decided to scrap them for now in order to lower the complexity of my mesh. In turn, this has caused the mesh to become a bit messy:    My goal is to make the top of the vehicle an even surface while still retaining its angle, and my loop cuts as straight as can be. I've highlighted my objectives in red.      In this situation I figured it would be incredibly useful to have vertex snapping while performing a vertex slide, but after doing some research I've found that this just isn't possible yet.  How should I go about cleaning this mesh up?  Also, how acceptable is it to have tris in my mesh? One of the reasons I got rid of the bezels was because they were creating tris and n-gons in my mesh. I aim to use only quads for the sake of managing loop cuts, and I frequently check this using the "Select faces by sides" feature.  Thank you so much for your help!


Pass an enum value from lightning controller to Apex

Is it possible to pass an enum value from lightning controller to Apex?  Here is what I tried  lightning component part      const action = component.get("methodC");     action.setParams({p: "VIEW"});     action.setCallback(component, function(){});     $A.getCallback(function(){$A.enqueueAction(action);})();   apex part  public enum Mode { CREATE, VIEW, EDIT }  @AuraEnabled public static void methodC(Mode p) {     System.debug('p:' + p); }   And here is the error I am getting:     16:35:58:002 FATAL_ERROR System.JSONException: Illegal value for primitive     Would be grateful for any relevant documentation on the topic.  is what I was able to find, but it is of no use for my question about lightning client-side and Apex enum.  Thank you.


Outdated name and broken logo in Data Explorer for Software Engineering (previously known as Programmers)

Programmers  to Software Engineering.  But this hasn't been reflected in the SEDE site switcher: it still shows the old name and the site logo is broken as shown on the screen shot:


In the national English language test (equivalent to A-levels), exam sitters were supposed to fill the spaces in the sentences with a word of some grammatical function.  One such sentence read: 'Some major junctions even have a special set of traffic lights for cyclists, allowing ___ a head start ahead of motorists.'  The key of the test says the correct answer is 'them'. However, what I did choose was 'for'. Is 'allow for something' a reasonable construction in this case?


How can I check which application opens a file by extension?

I am on a debian 9 system with unknown desktop environment (ssh access). How can I find out which program is used by default to view a file with a given extension (e.g. pdf)?  Edit: Since extension is not important to the decision, the mime type of the given file can be found by using file  file -i file.ext


I want to simulate mass distribution code for 10^10 particle of unit mass.   But this code works only if number of particle is 10^8.  long par = 85000000; float p[85000000][2];   and this shows error if size goes to 10^9 or 10^10   "Relocation truncated to fit"   that is  long par = 85000000; float p[85000000][2];   how to find the maximum possible indexing range of float array?  #include <stdio.h> #include <stdlib.h> #include <math.h> #include <sys/time.h>  long double net[4096][4096]; int max = 4000; long par = 85000000; float p[85000000][2];  int main(int argc, char *argv[]) {     int i;     for( i = 0; i < par/1000; i++) {         p[i][0]= ((long double)rand()/(long double)(RAND_MAX) * (long double)max);         p[i][1]= ((long double)rand()/(long double)(RAND_MAX) * (long double)max);     }      clock_t begin = clock();      for ( i = 0; i < par/1000; i++) {         double x = p[i][0];         double y = p[i][1];          int left = (int)floor(x);         int right = left + 1;          if ( left >= 4095)             printf("out of bound left is %d/n", left);          int bottom = (int)floor(y);         int top = bottom +1;          double fL = x - left;         double fR = 1 - fL;          double fB = y - bottom;         double fT = 1 - fB;          net[left][bottom]   =   net[left][bottom]   +( fT * fR ) ;         net[right][bottom]  =   net[right][bottom]  +( fT * fL ) ;         net[left][top]      =   net[left][top]      +( fB * fR ) ;         net[right][top]     =   net[right][top]     +( fB * fL ) ;     }      clock_t close = clock();      FILE *f = fopen("file.txt", "a");     if (!f) {             printf("Error opening file!\n");             exit(1);     }      fprintf (f,"Computation time for grid size %d X %d and %ld particle is "         "%4.6lf ,\n",max, max,par,(double)(close-begin) );      fclose(f); }


How do I make my neural network better at predicting sine waves?

Here, have a look:  You can see exactly where the training data ends. Training data goes from $-1$ to $1$.  I used Keras and a 1-100-100-2 dense network with tanh activation. I calculate the result from two values, p and q as p / q. This way I can achive any size of number using only smaller than 1 values.  Please note I am still a beginner in this field, so go easy on me.


Is an Abtec CE2 hb1003 (550W) enough to power an GTX 970?

Would an Abtec CE2 hb1003 () be enough to power a GTX 970 or 960 4gb? Thanks


Has anyone had any success connecting things like content builder or cloud pages to GitHub? I have been searching far and wide and have come across this amazing repository that almost does what I need (). The reason being as our organization grows and things become more complex we would love the ability to track changes and have reviewers before things are published. Most of my experience comes from GitHub and I am struggling to find any source of versioning within SFMC. Any recommendations would be helpful!


How does Find Familiar work with a Ring of Spell Storing?

Say a Wizard casts  for himself, and then casts it again into a Ring of Spell Storing. The Ring is then given to another person, let's say a Rogue, who uses the Ring to cast Find Familiar.   The description of Find Familiar says     If you cast this spell while you already have a familiar, you instead cause it to adopt a new form.   but the description of the Ring says      The spell has no effect, other than to be stored in the ring.   What happens? Does the Wizard's familiar change when the spell is cast into the Ring? Does it change when the spell is cast out of the Ring? Does the Rogue get a Familiar, since the Rogue is considered to be casting the spell?


is there a way to disable Windows from switching window focus when I am typing?

Sometimes when I am typing in a notepad, command prompt, webpage, or the file explorer address bar, or even any other place where typing is allowed, it happens that the currently active window loses focus and a confirmation dialog pops open.   For example, when I have started a long-running copy/move operation in File Explorer, and whilst waiting for it to complete I start working on some other task that requires typing. Immersed in typing sentences or commands, suddenly a popup-window jumps on screen! But I have already instructed my fingers to type in some sentences/commands, and I have no way to make my fingers stop at this high speed! The popup-confirmation dialog then receives some "random" keystrikes from my typing, and more often than not, some of these keystrikes correspond to a "Yes", "No", "Overwrite anyway" or similar option's hotkey. Thus, it happens so that my fingers are typing in a sentence, and my eyes see a flash of some random dialog, but my fingers have already typed in something that closes the dialog. Then I am left baffled, because I absolutely have no idea what I just "clicked" with a hotkey - did I agree to overwrite some important files? Did I perhaps agree to delete some file? Did I abort everything? I cannot know.  To prevent these kinds of horrible accidents, I'd like to disable Windows from "randomly" switching window focus. When I am typing in something, I'd like the focus to stay there and nowhere else. So the idea is that I am in control of the focused window, not Windows.   Is there some registry tweak or similar to prevent Windows from changing active window focus automatically?


How to set brightness level even lower than default minimum?

I am an ex-Windows user, I noticed that minimum level of screen brightness on ubuntu is way brighter than minimum level on windows when I was using it on the same hardware. I was wondering if I can set the brightness level on ubuntu at a level even lower than the minimum level it allows, because default minimum brightness on ubuntu is too brighter for me. Is there any tweak with system settings which I can employ to reduce my screen brightness even further than what default system settings allow?


Why does the Terminator look like Arnie?

Related to , in The Terminator we have this dialogue:     REESE: Pay attention. The 600 series had rubber skin. We spotted them easy. But these are new. They look human. Sweat, bad breath, everything. Very hard to spot. I had to wait 'til he moved on you before I could zero him.   From this and other dialogue, we are told that the Terminators are infiltration units, designed to look and appear human.  In this way they can get back to the human base and start shooting, thus wiping out large amounts of resistance members.  But when you look like Arnold Schwarzenegger, you don't exactly blend in.  The resistance was not made up of giant musclemen, but weary ordinary humans with a lot of courage.  We know that Skynet eventually learnt its lesson, making units like Cameron and the T-1000, but why make a giant muscle guy?  Wouldn't it just grab a resistance person and make a copy of them?  Looking for canonical answers please.  Also, that deleted scene from T3 doesn't count.  The T-800s had more than one face.


Assign null to Variables, That Are No Longer Needed in Java

I went through the following  on oracle official site regarding performance tuning, which states "Assigning null to unused variable ease garbage collector to reclaim the memory"  Do I need to adopt the following code practice?  Student student = new Student(100L, "Brian Lara", "II", "B"); public String getSomeValue() {     String val = "";     try {         // Perform some action to get value using student ref. variable         // val = some val, using student      }     finally {         this.student = null;     }     return val; }    There are 3 possibilities (or may be more) for the instance variable:    Global static instance variable Global non static instance variable Local non static instance variable    Please suggest the correct way for the better coding practice.


How to check if some program is already installed and its version?

I'm exploring working with the ubuntu terminal. For particular reason I need to check if I have installed Python interpreter, like cPython. How to do it? In general, how to check if some program is already installed and its version?


What is a repository? How does it differ from a PPA?

While installing something I often came across the term repository. Can anyone tell what it is? Also, what is different to a PPA?


How to make “less” exit with clearing the screen?

I have a question just opposite to : my less exits without clearing the screen, but I have never used -X.  The options I use is as follows:  $ echo $LESS  -N -g -i -M -R -w -z-4 $ echo $LESSOPEN $ $ echo $TERM ansi   I remember when my less started to change its behavior: when I was trying to type something to another application but my cursor was in the terminal with less opening. When I realized I'm typing into a wrong place and tried to quit less, the file contents start to remaining to my terminal. I'm using MacOS terminal (not iTerm2).  As @roaima suggested, my issue is to get the less's standard behavior without -X. However, -+X does not work; and -X is not in LESS.  I'm using OSX Terminal.app, not iTerm2.


If I remove Minecraft sound files from .minecraft/assets/objects, will Minecraft be unable to play them?

In Minecraft, there are a lot of cool sounds. I decided to find there location and move them to my desktop. I have Ubuntu, and if when I remove them from that folder will Minecraft be unable to play them or is it smart enough to figure out that they are gone and download them again. Before minecraft was installed, it had to download the files. I even moved my favorite song (creative 6) from the sounds. The sounds are not labeled and have seemingly random names like b0b12118a97ddd733a50e9382e91a21652568641 and how will I know what to call them that will be recognized without digging through the index if Minecraft fails to download them? Or do I not have to worry because it will download them again upon launch?  Note: Why does it not label them and call them random names?


It is in tikz possible to fill area inside a cycle, right?  I am having issues with it and I can't figure out what I am messing up:  \documentclass[center]{article} \usepackage{tikz}  \begin{document}  \centering \begin{tikzpicture}[>=latex] \node[circle, fill, inner sep = 0, minimum size = 2mm] (a) at (3,0,0) {}; \node[left of = a] {$a$}; \node[circle, fill, inner sep = 0, minimum size = 2mm] (b) at (5,0,4) {}; \node[left of = b] {$b$}; \node[circle, fill, inner sep = 0, minimum size = 2mm] (apb) at (8,0,1) {}; \node[right of = apb] {$a + b$};  \draw[->, very thin] (a) -- node[below] {$i_1$} (apb); \draw[->, very thin] (b) -- node[below] {$i_2$} (apb);  \node[circle, fill, inner sep = 0, minimum size = 2mm] (fa) at (3,3,0) {}; \node[right of = fa, circle, minimum size = 6cm] {}; \node[left of = fa] {$f(a)$}; \node[circle, fill, inner sep = 0, minimum size = 2mm] (fb) at (5,3,4) {}; \node[right of = fb, circle, minimum size = 3cm] {}; \node[left of = fb] {$f(b)$}; \node[circle, fill, inner sep = 0, minimum size = 2mm] (fapb) at (8,3,1) {}; \node[right of = fapb, circle, minimum size = 3cm] {}; \node[right of = fapb] {$f(a + b)$};  \draw[very thin, dashed, blue, ->] (a) -- (fa); \draw[very thin, dashed, blue, ->] (b) -- (fb); \draw[very thin, dashed, blue, ->] (apb) -- (fapb);   \draw[very thin, ->] (fa) -- node[below] {$j_1$} (fapb); \draw[very thin, ->] (fb) -- node[below] {$j_2$} (fapb);   \fill[red] (b) -- (apb) -- (a) -- cycle; \end{tikzpicture}  \end{document}     As you can see the bottom two arrows are red, but I want the triangle between the bottom three point to be red. The triangle is described by the path (b) -- (apb) -- (a) --cycle however. So... what is problem?


I wish I could trust the packages I am supposedly downloading from Ubuntu servers are exactly what I think they are. But ...  ... Hit:1 http://archive.ubuntu.com/ubuntu xenial InRelease Get:5 http://security.ubuntu.com/ubuntu xenial-security InRelease [94,5 kB] Hit:6 http://archive.ubuntu.com/ubuntu xenial-updates InRelease Hit:10 http://archive.ubuntu.com/ubuntu xenial-backports InRelease ...   It's all clear text and unauthenticated traffic.  Why isn't Ubuntu using HTTPS by default when accessing software repositories? Which reasons can there be to keep this situation?


How can I iterate over a databound value of an asp.net repeater? (C#)

I'd like to iterate over the value of each entry in a c# dictionary within my asp.net repeater. My IDictionary is nothing special - Just key-value pairs of data, and the values are arrays of strings. I'm trying to create a form select element with materializecss (, see "Optgroups"). Currently, what I have is this:  ...
     <asp:Repeater runat="server" ID="optgroupSelect">         <HeaderTemplate>             <select>         </HeaderTemplate>         <ItemTemplate>             <optgroup label="<%# Eval("Key") %>">                 <%-- Here comes the problem --%>                 <%# foreach (string s in Eval("Value")) { %>                     <option value="<%=s.toLower()%>"><%=s%></option>                 <%# } %>             </optgroup>         </ItemTemplate>         <FooterTemplate>             </select>             Please select something         </FooterTemplate>     </asp:Repeater>
 ...   I've worked with PHP for the last couple years and feel that I'm missing the mindset of an asp.net dev - Still, I have to do this for work. Obviously, the above code does not work, but it highlights what I'd like to achieve. I've gone through the whole  list to maybe find a component which could iterate over the databound value array, but most of them have their own style which I don't want (since everything should match with materializecss). I appreciate any help towards solving this, thanks for taking your time!    Note: My pages are .aspx Web Forms in the Asp.net Framework 4.8


I'm trying to get some words in bold and typewriter styles together but only typewriter is been applied. I saw in other question one not should use \bf while nesting, so I tried:  \texttt{\textbf{Mywords}} \textbf{\texttt{Other words}}   but both of them appear only with typewriter style. I'm in a document class scrreprt.


Packing all linked Files for Render Farm submission

So I want to submit a project to a renderfarm. I have multiple links to other .blend files in the project since this saves memory and speeds up the render a lot. The blend files are roughly 5 GB combined. it is a large scene. Is there a way to easily package all associated files for submission to the renderfarm? The pack all into blend function only works for textures for as far as I know. Thanks in advance.


Is the amount of energy in the universe a finite quantity Joules?

We know from the first law of thermodynamics that the amount of energy in the universe is conserved. However, doesn't this law presuppose that the amount of energy in the universe is a finite quantity of Joules?  As David Hume reasoned, all of science depends on inductive generalization. But wouldn't it be a fallacy of hasty generalization to conclude from models and experiments where the quantity of joules are finite and contained by an adiabatic wall that therefore the universe at large is like this?


Align text to the right, overflowing to the left

Note: This question is not answered in the above linked question, nor is it a duplicate. This question addresses the problem with the ordering of special characters when using text-direction: rtl, which it turns out can be solved with the unicode-bidi: bidi-override as pointed out by @Serlite below.  I have a div containing some text that I'd like to overflow to the left, not to the right.  For example, if the div contains all letters of the alphabet, the default behaviour is as follows:    I, however, want the contents of the div to be displayed like this:    Using direction: rtl in the styles for that div works fine, and achieves this effect perfectly for the above example, as well as if the contents contains just numbers (or a mix of alphanumeric characters) as shown below.  Standard behaviour:    Behaviour after setting direction: rtl:    The problem occurs when special characters are entered into the div, such as * and #.  Setting the string *#0123456789 as the div contents causes the following to be displayed:    Note the * moving from the start of the string to the end.  It's difficult to show the problem with just images, so  is a quick jsfiddle to better demonstrate it.  In general, it seems like weird things happen when setting the direction property, and so I'm guessing it's probably not the way to go.  Is there a way I can force the last characters to always be visible while the first characters overflow to the left?


Describe the prime elements of the ring $\mathbb Z[\sqrt{-2}]$

I have a ring $\mathbb Z[\sqrt{-2}]$ and I need to describe all the prime numbers of that ring. How I can do that? Thank you


Should one file 1040X to get extra $5 tax refund

After I finished my taxed in last week of March, I received a Updated 1099 with only one modification where 199a is modified from zero to $50 or so. Refund is about to come in a week.  Initial values  Box 1a = 500 Box 1b = 200 (all other boxes empty)  similar question is at   Updated values Box 1a = 500 Box 1b = 200 Box 5 = $50    The effect of this update is about $5 more tax refund. And to get this refund I will spend more in postage.  So my question is , is it ok to leave the money with IRS or by law I am required to get it fixed.  This question was asked on April 08, 2019 before the  ( asked on April 18) @joetaxpayer , The marking says      This question has been asked before and already has an answer.   I agree that this question has answer at the referenced location, the part that I disagree is "asked before"


How to get the diskdrive hardware id in c#

How can I get the disk-drive hardware ID in C# ?  I tried System.Management, but I think this is only for processor ID.  I need the hardware ID that we find in cmd by typing wmic diskdrive get serialnumber!


Validating International Phone Numbers in PHP

I've been searching for hours to find a regex that does this for me, all the ones I've found either require dashes or limit something else that I don't need.  Like this one:      ^(?([0-9]{3}))?[-. ]?([0-9]{3})[-. ]?([0-9]{4})$  Basically I want to allow these types of input for phone number, these are all valid:  +000 111111111  +00011111111111  0022 111111111111  0022111111111  +333-4444-5555-6666  000-7878787-0000-4587  Note that the number of digits is not limited, I only want the validation to filter out empty inputs and the alphabet. Also filter out all other characters except a maximum of 4 dashes, max. 4 spaces and an optional single plus sign.  Is this possible through preg_match or not?  Any help is appreciated, thanks!


Error copying file on xampp installing in ubuntu

I want to try install xampp on Ubuntu 14.04, I download  xampp-linux-x64-5.6.15-1-installer.run and try to run it with sudo ,but in between of unpacking it getting error .    I lookup at path /opt/lamp some files getting copy but installation not getting complete, I try to see log in install duration with tail -f /usr/log/syslog but nothing reported. where is the problem?  update according to comment I try df -h to see free space of my disk


how to write a trigger on account to prevent text filed entering name ending with 'text'

I need to write a trigger on Account which, while inserting a text value as 'someName' ended with 'text' ex: 'renuText' On Account Object it should throw an error. How can I achieve this requirement?


When Starting at 3rd Level as a Sorcerer, Can I Have Four 2nd Level Spells?

If I start play with three levels of Sorcerer (allowing me four spells), must I choose spells as if I began at level 1, or can I choose any four spells?  If I began at first level, I would have two level 1 spells. Per level up, I can forget one spell and learn a new one. Since level 3 is the first time the Sorc can get 2nd level spells, I can only have two level 1 spells and two level 2 spells.  But beginning with three Sorc levels right away, if allowed to choose any four spells, I would be able to choose four level 2 spells and no level 1 spells.  I realize this isn't optimal since there are only two level 2 slots at level 3, but this could be useful, if not without its drawbacks, in the case of a multiclassed Sorc. Anyway, any rules that can be quoted to support your answer would be great, but any reasoning to support either case would be good as well.


what does this shell command do? "${f// /_}"

somehow this identifies spaces in filenames and replaces them with underscore, how do I learn how to do this?


Error when upgraded operating system from Ubuntu 16.04 to 18.04> do-release-upgrade Current version: cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=16.04 DISTRIB_CODENAME=xenial DISTRIB_DESCRIPTION="Ubuntu 16.04.7 LTS"  Any body faced this issue ? Is there a solution to this ? **do-release-upgrade -f DistUpgradeViewNonInteractive**  Send problem report to the developers?  After the problem report has been sent, please fill out the form in the automatically opened web browser.  What would you like to do? Your options are:   S: Send report (302.5 KB)   V: View report   K: Keep report file for sending later or copying to somewhere else   I: Cancel and ignore future crashes of this program version   C: Cancel Please choose (S/V/K/I/C): Traceback (most recent call last):   File "/usr/bin/apport-cli", line 386, in <module>     if not app.run_argv():   File "/usr/lib/python3/dist-packages/apport/ui.py", line 673, in run_argv     return self.run_report_bug()   File "/usr/lib/python3/dist-packages/apport/ui.py", line 511, in run_report_bug     response = self.ui_present_report_details(allowed_to_report)   File "/usr/bin/apport-cli", line 213, in ui_present_report_details     response = dialog.run()   File "/usr/bin/apport-cli", line 101, in run     multi_char)   File "/usr/bin/apport-cli", line 49, in raw_input_char     saved_attributes = termios.tcgetattr(file) termios.error: (25, 'Inappropriate ioctl for device')  var log errors /var/log/dist-upgrade/main.log  2021-04-27 15:31:12,436 ERROR No 'ubuntu-minimal' available/downloadable after sources.list rewrite+update 2021-04-27 15:31:12,436 ERROR 'ubuntu-minimal' was not downloadable 2021-04-27 15:31:12,436 ERROR Invalid package information After updating your package information, the essential package 'ubuntu-minimal' could not be located. This may be because you have no official mirrors listed in your software sources, or because of excessive load on the mirror you are using. See /etc/apt/sources.list for the current list of configured software sources. In the case of an overloaded mirror, you may want to try the upgrade again later. (None) 2021-04-27 15:31:12,448 DEBUG abort called


If a cube is rigged on all it's edges. How can I animate it so it tumbles forward forever?

When I roll a rigged cube over its edge (for instance this example which has no bones on all its edges but anyway -> ), some bones stay behind outside my mesh. So I'm not able to animate a next turn/tumble. Does someone have a solution? It is possible to transfer the bones to a new position in one frame after the first rotation? How does this work?


Determine if local datetime is within a datetime window

I'm working on code to determine if the current local datetime falls within a datetime range, a start and end datetime. I start by getting the start and end datetime values as a serialized GMT string (this is what the source system is returning to me): let myStartDate = "2020-09-11T14:15:13.000Z"; let myEndDate = "2020-09-15T01:09:34.000Z";  I then convert the datetime to UTC format: let startDate = new Date(myStartDate).toUTCString(); let endDate = new Date(myEndDate).toUTCString(); let now = new Date().toUTCString();  Then I check to see if now is between the startDate and endDate: if (now > startDate && now < endDate) {   console.log("You're INSIDE the datetime window!"); } else {   console.log("You're OUTSIDE the datetime window!"); }  console.log("Now:   " + new Date(now)); console.log("Start: " + new Date(startDate)); console.log("End:   " + new Date(endDate));  When I run this, my code is telling me I'm outside the datetime window, even though the start and datetime values are a couple days before and after my current datetime. An alternative I see is using getTime(), which converts the datetime to a UTC milliseconds number. let startDate = new Date(myStartDate).getTime(); let endDate = new Date(myEndDate).getTime(); let now = new Date().getTime();  This seems to work, but I'm confused why toUTCString() can't be evaluated the same way.


Installing Ubuntu on a MSI GS65, freezes at login screen

Did anybody figure out how to successfully install Ubuntu 16.04 or 18.04 on a MSI GS65 8RF? After finally installing it (after following ), it freezes when I try to log in.   I've already disabled secure boot and set the BIOS to UEFI only.   Does anybody have a solution for this?  Edit: It is not a duplication, MSI GS65 still freezes even after BIOS update


Wi-Fi adaptor is not found after Ubuntu 18.04 is installed

I just installed Ubuntu 18.04. But the Wi-Fi adaptor is missing.  $lspci -knn | grep Net -A3; rfkill list 03:00.0 Network controller [0280]: Broadcom Limited BCM4352 802.11ac Wireless Network Adapter [14e4:43b1] (rev 03)     Subsystem: AzureWave BCM4352 802.11ac Wireless Network Adapter [1a3b:2123]     Kernel driver in use: bcma-pci-bridge     Kernel modules: bcma 0: hci0: Bluetooth     Soft blocked: no     Hard blocked: no   I also tried to use my cellphone to do the USB tethering and run   $ sudo apt-get update $ sudo apt-get install bcmwl-kernel-source   but I got   Need to get 0 B/28.4 MB of archives. After this operation, 125 MB of additional disk space will be used. Do you want to continue? [Y/n] Y Media change: please insert the disc labeled  'Ubuntu 18.04 LTS _Bionic Beaver_ - Release amd64 (20180426)' in the drive '/media/cdrom/' and press [Enter]   I was using a USB drive to boot and installed the Ubuntu not sure why the system is not able to found the file.  The last thing I tried is: to go to the 'Software & updates' -> 'additional Drivers' -> 'Broadcom Limited: BCM4352 802.11ac wireless driver source from bcmwl-kernel-source'.   I selected that option and applied the change. But after that, the progress bar for 'Applying changes...' is frozen, the operation can not be done.  Any suggestion about how to enable my Wi-Fi adaptor?


Nginx config: two applications under same domain

I have two applications: HTML+JS frontend and PHP backend. I would like to set Nginx up so that both are served from the same domain. Requests to the backend are made uing URLs starting with /api.  My attempt was this:  server {     root /path/to/frontend;     index index.html;     server_name example.com;      location / {         try_files $uri $uri/ /index.html;     }      location /api {         alias /path/to/backend;         index index.php;         try_files $uri $uri/ /index.php;     }      location ~ \.php$ {         fastcgi_pass 127.0.0.1:9000;         fastcgi_index index.php;         include fastcgi_params;     } }   However, for all requests to the backend, I end up with a 404: primary script unknown.  Is there a way to achieve what I'm trying to do here? How?


self guided electronics text recommendations

Can anyone recommend a good text or texts that they have experience with for someone learning electronics on their own. I have taken some very basic college courses, but I want to know more. There are so many books out there that claim to be geared toward this, but I'd love to hear from some of the more experienced people with higher knowledge levels about what they would personally recommend. I have done a lot of searching and was going to base my selection on online user reviews, but I thought some input from people on here would be valuable. I have a lot of experience with DC electrical systems, and some with AC electrical systems, but only a small bit with electronics.  As I work through some self learning and project using online resources, I am quickly deciding that I need some actual text reference material.  I apologize if this is an inappropriate place for this question.  Thank you for any info!


Extract several lines from large text file

I have a large text file.  I need to quickly pull a bunch of lines, say from #14600 to #14700, from this file, as a separate file.  How it could be done?


Will my 320W PSU handle a Asus GTX 750Ti

I've got a 320W PSU as far as I know and it's a Chinese PSU because I've seen the Chinese letters on it. I just had a question if I can upgrade my pc to Asus GTX 750Ti 2 GB OC.  My pc specs are:   4GB DDR3 RAM Intel Core 2 Duo E8400 3.0 GHZ 250GB HDD Onboard graphics card


How to remove top and bottom whitespace of longtable?

I am using longtable instead of tabular environment and noticed that it puts some additional whitespace at the top and at the bottom of the table. Is there some way to remove it (something less hacky than \vskip -\baselineskip before the table)?  Small piece of code for illustration:  \documentclass[12pt]{book} \usepackage{longtable}  \begin{document}  Linelineline  \begin{longtable}{l l} cell1 & cell2 \end{longtable}  Linelineline  \begin{tabular}{l l} cell1 & cell2 \end{tabular}  Linelineline  \end{document}   And that's what I am getting:    Common tabular environment does not have any additional margins, but longtable does.


I have an i7-3612QM@2.1GHz in a Dell Inspiron notebook and now running Windows 10 Technical Preview.  The experience described below was also seen in Windows 8.1 previously.  I have been monitoring the Speed in Task Manager (Performance tab).  It goes up and down on its own without apparent logic.  When it is above 2GHz for sustained periods of time, the notebook becomes unbearably hot, at above 80C.  Recently I took out the hard disk and it was charred black. I now have a very expensive 1TB SSD and the heat would definitely void the warranty if it's damaged.  I would like to slow down the CPU clock to no more than 1.5GHz (I am not in the business of Bitcoin mining or code cracking).  How do I do it?


Can my Korean wife visit me before we apply for her spousal visa later?

I am British and married a Korean girl while living in Korea for many years. I returned to the UK this year and I'm just now starting a job, so once I have been earning the required amount for 6 months, we will be applying for her spousal visa.  But she came to visit me for 1 week recently and has since decided she wants to spend the next 6 months with me here on a visiting visa, after which she will return to Korea so we can apply for her spousal visa.  I am wondering if her coming back on a visiting visa and living with me would affect our spousal visa application later on? We really don't want to spend the next 6 months apart but we are worried about causing troubles for the spousal visa later on. Any help would be appreciated. Thanks


How can I protect midori from poodle? I have found fixes for Firefox and Chrome but not for midori.


How can I add the Memtest86+ options back to the Grub menu?

After having installed the 64bit version of Ubuntu 12.04 on my Lenovo B570 I ran into the same problems I had when installing 11.10 with Grub not playing nicely with a uEFI system. I used the same technique as last time to solve the problem (using a Super Grub Disc LiveCD session to repair Grub) and my system happily dual boots between Ubuntu and Windows 7  However now when I boot up the Grub menu only displays   Ubuntu, with Linux 3.2.0-24-generic Ubuntu, with Linux 3.2.0-24-generic (recovery mode) Previous Linux versions Windows 7 (loader) (on /dev/sda1) Windows Recovery Environment (loader) (on /dev/sda4)   I no longer see the option to use Memtest86+ which was there previously, having checked in the Ubuntu Software Center I can see that the package is installed, but how to I make the option to run it once again appear in the Grub menu?  I've tried:  sudo update-grub    which doesn't make any difference.  sudo chmod +x /etc/grub.d/20_memtest86+    results in:   chmod: cannot access /etc/grub.d/20_memtest86+': No such file or directory   and entering  ls /etc/grub.d/   results in:  00_header        10_linux      30_os-prober  41_custom 05_debian_theme  20_linux_xen  40_custom     README


Is AC required to demonstrate that every collection of disjoint open intervals in R is countable?

I understand that to prove this, one considers that each open interval contains a rational number and since the open intervals are disjoint, there exists an injection from the collection of intervals to the rational numbers, which are countable, hence the collection of open intervals is countable. I noticed, however, that this requires arbitrarily many simultaneous, non-defined, choices from the intersection of the rational numbers with each interval in the collection. So, my question is, does this proof require AC?


Convergence of the Power Series for $xu''+\sin(x)u=0$

Consider the initial value problem   $$xu''+\sin(x)u=0 \ \ \ \ u(0)=0, u'(0)=2$$   What can be said about the radius of convergence of this series?   I have determined that the first four nonzero terms (about the point $x=0$) of the power series are $$2x,-x^2,\frac{1}{6}x^3,-\frac{1}{72}x^4$$ How can I test for convergence? Intuitively it looks not to converge, but how can I  show this?  edit  The solution will have the from $$u(x)=\sum_{k=0}^{\infty}A_kx^k.$$ Differentiating, \begin{align} \sum_{k=2}^{\infty} k(k-1)A_kx^{k-1}+\sin(x)\sum_{k=0}^{\infty}A_kx^k&=0 \\ \sum_{k=2}^{\infty} k(k-1)A_kx^{k-1}+\left(\sum_{k=0}^{\infty} \frac{(-1)^k x^{2k+1}}{(2k+1)!}\right)\sum_{k=0}^{\infty}A_kx^k&=0 \\ (2A_2x+6A_3x^2+12A_4x^3+20A_5x^4+30A_6x^5+42A_7x^6+..)+\left(2x^2+A_2x^3+\left(A_3-\frac{1}{3}\right)x^4+\left(A_4-\frac{A_2}{6!}\right)x^5+\left(A_5-\frac{A_3}{3!}+\frac{2}{5!}\right)x^6+..\right)=0 \end{align} Equating coefficients, $x^{2k}=0$ for $k\in\mathbb{Z^+}$. $$6A_3+2=0\implies A_3=-\frac{1}{3}$$ $$20A_5+A_3-\frac{1}{3}=0\implies A_5=\frac{1}{30}$$ $$42A_7+A_5-\frac{A_3}{3!}+\frac{2}{5!}=0\implies A_7=-\frac{19}{7560}$$ Hence $$u=2x-\frac{1}{3}x^3+\frac{1}{30}x^5-\frac{19}{7560}x^7+..$$


Is there an optimal loss function for dealing with imbalanced classes?

I'm aware that there are many ways of dealing with datasets where there is a strong class imbalance in the target variable: downsampling the more prevalent and less important class, over-weighting the valuable minority class, etc. Are there any loss functions that are ideally suited for these types of problems? I've heard of AUC, but AUC sounds like a means of evaluating a model once its training is complete (correct me if I'm wrong). Log loss and squared loss penalize a model's over confidence, but overconfidence and class imbalance seem unrelated. Is that true?


How to detach a tmux session that itself already in a tmux?

I've opened a tmux session on my local machine, and ssh to the remote machine. After this, I typed command "tmux attach" on the remote machine, then I got a remote tmux session on my local tmux session.  Now I want to detach the remote tmux sesstion, I've tried  C-b d   but it detached my local tmux session rather than the remote one.  How can I detach the remote tmux sesstion?


I have  a small population and it is possible to estimate  Population regression function from the data. The size of the population is very small. It is only eight. I think since the regression  relates to poulation, there is no need to conduct any testing. Am I correct?


How to measure a qubit Hamiltonian in qiskit

I am using qiskit to get some measurement results of observables similar to the Hamiltonian. Can someone provide the way how qiskit measures the Hamiltonian (Jordan-Wigner transformed) when using VQE? Or can they just provide the source code link.


The word hello seems to have become popular with the coming of the telephone. Did our ancestors greet each other with ahoy before that?


If matrix $A$ is unitary and $B^2=A$, is $B$ necessarily unitary?

If matrix $A$ is unitary and the matrix $B$ satisfies $B^2=A$, is $B$ necessarily unitary?


Xubuntu 12.04 + Tex Live 2012 no biblatex binary and no biber

I am getting really confused now. I installed Tex Live 2012 on my Xubuntu 12.04 with a backport and I installed TexMaker.  I could user PdfLatex right away and it generated everything I needed except my bibliography. I read that Tex Live 2012 comes with biblatex so I just changed the bibtex command in TexMaker from "bibtex" to "biblatex". However, that does not exist. So I did  sudo apt-get remove biblatex sudo apt-get install biblatex   The package is installed but I don't find the binary. Using bibtex the whole thing crashes. Which does not surprise me since I want to userbiber:  \usepackage[backend=biber]{biblatex}   Btw does biber come with biblatex? So far I couldn't get any clear explanation what biber and biblatex are to each other.  EDIT: I had to remove texlive completely and install it with the install script form . Apparently the newest version of biber does not work with the older version of biblatex I had.


Given the two green lines and the real distance between them (blue lines), is it possible to calculate where in the picture would be placed a point 4.5m away from a certain initial point (red line)?    I've been reading other posts about this and it is not clear to me if I need more data to compute this, but I think I do.    EDIT  As said in the comments, I know the line equation of the green lines and the angle they form between them. I also know the length of the blue lines (in the picture and the real one) and the distance between them in the picture, but I don't know their distance in real life.  The conclusions I've arrived so far are:    Since the four points aren't collinear and I don't have any real distances along lines converging to vanishing point, I can't use the .  Given that I don't have the real distance between the blue lines I can't scale along green lines.  The only thing I've found that might be helpful is , but since my lack of knowledge in the subject I don't know how to apply it to my problem.


Does deleting an account uncheck the accepted answers?

In my opinion the accepted answer should permanently stick as only the original question submitter has the ability to accept.


Is it possible to remove the 'cache' from the request headers with js?

Basically, I need to remove the 'cache' part of request headers when requesting a particular static resource (a pdf).  Is this possible to achieve?  A bit more context:  I'm comparing two calls to a file (calls as in assigning the path of pdf to a src attribute of an iframe). One works, one doesn't. Using fiddler2 I've had a look at the traffic and it appears that the only difference is that the request headers of the request that doesn't work includes If-Modified-Since in the 'cache' part of it's headers. If I can remove this I think it'll solve the issues I'm having as I understand caching and iframes displaying pdfs can be potentially problematic. If I'm wrong, and it doesn't solve it, I'll at least have ruled that out as a problem.  EDIT: This is a problem exclusive to IE 8 if that's any help:


Should I bin my continuous input variables for neural networks?

And what is the optimal method to do this? Is there a package for this in R?


Old sci-fi/thriller movie centered around a pistol that causes blackouts/temporary amnesia with bursts of light

Plot Details/Summary  I saw this one on HBO as a kid in the 1980s.  As best as I can remember, the plot was along these lines: There's a series of murders occurring, and the protagonist, I believe, is a suspect at one point.  IIRC, he's at or near the scene of one of the murders.  The protagonist can't remember what happened during the time of the murder - what he was doing, etc.   As he investigates, the protagonist discovers an experimental weapon has been developed.  It's a handgun that fires pulses of light. The pattern of the light causes the victim to go in to a sort of blackout.  Not really unconscious, but sort of stunned in place. When it wears off, the victim is left with a memory gap, with no recollection of what happened or what took place while he was stunned.  I recall the protagonist is able to acquire the weapon, and turns the table on the man who's been killing people with it.  I don't recall how the weapon was developed, or why the man was killing people in the first place.  I do remember the protagonist beats the killer up by using the weapon to stun him and then punching him out between bursts.  Timeframe  I saw the film in the early 80s, so I'd say 70's or 80s.  It was a color film, and I remember it being fairly "modern"-looking - i.e. not an old 60's film or the like.  That's all I can recall.


In R, How can I have a multi-line title in visNetwork? \n Doesn't seem a solution:  require(visNetwork, quietly = TRUE)  # minimal example  nodes <- data.frame(id = 1:3)  edges <- data.frame(from = c(1,2), to = c(1,3))  visNetwork(nodes, edges, main ="multi \n line \n title")


What happens if I blink a transformed double-faced planeswalker?

If I blink  with something like , does he come back and instantly die?


Access a JSTL variable from JSP expression tag

I need to add up the price of the products to display Grand Total for every order. I am traversing through a list of orders ${order.purchaseItems} and I need to access the price of the Purchased Items and add it up in the JSP itself but I can't figure out how to access it in the JSP Expression tag.

         Manufacturer	         Item	         Description	         Quantity	         Price
                                  <%! int grandTotal=0;%>                                  <c:forEach items="${order.purchaseItems}" var="item">
                 ${item.productJ.manufacturer}	                 ${item.productJ.item}	                 ${item.productJ.description}	                 ${item.quantity}	                 ${item.price}	                 <%= grandTotal += ${item.price}; %>
         </c:forEach>
                 	                 	                 	                 Grand Total: 	                 <%= grandTotal %>


I understand both sides of the "Lists questions" debate. Personally I find them very informative and end up on those threads often through google. But I also understand the desire to keep all the se sites "pure" with respects to the area.  So why couldn't there be a lists.se site that caters to these kinds of questions? The tags could designate the type of list it is for. Then all those nasty horrible list questions that the mods hate, but many find so useful, could be migrated to a single site.


Can I ask questions without the preview step?

The steps to publish used to be:   Write question Hit publish   Now the process is:   Write question Hit "Review" Get bounced back to the top of the page Scroll back down to the bottom of the page Hit the button again. Page gets published   Is there a way to skip the review step?  I'm not sure whether this is a feature-request or support question, as I don't know whether the option exists to remove this step.  Some proposals to improve the situation:   Make it clearer that you're on a different step. This could be as simple as drawing a border around the text or changing the background colour. I'm not a design person, but it wasn't until I started thinking about writing this post that I figured out there was a 2-step process, I just thought it kind of stuffed up the first time you press publish. CertainPerformance linked a similar question () that proposed a solution which would make it easier to avoid "Step 4" by putting the button into an area where the user gets bounced to when they hit publish. Remove it? We get plenty of feedback from the community when we post a bad question. Does a question need to be right the first time? And if it's not, will this feature help?


What is the current status or acceptance of  as it relates to Einstein's theory of relativity? Has quantum mechanics ruled it out or is it still the favored view of the world? Perhaps there can't be any consensus as we cannot link quantum mechanics with relativity?


How do I export a mesh then import it in to another blender file while keeping the original textures?

What sort of exporting format should I be using? Or will I have to re-assign all of the textures again? Thanks.


How to create an user with permission to do everything but drop databases?

If it is easier, the user can be denied only deletion of one specific database instead of any database.


I created a server where users can return a table as JSON representation.  What I wanted to do have the user create a python module that inherits from a Reader Base.  This isn't the issue.  The issue is how do I make it do my server can dynamically load each library to read each file type?  I hope I explained this well.  If not please ask questions.  Thank you, J  I do not believe this is a duplicate because the python modules may or may not exists and will be added to the system on run time.


How to sort elements in a list with numbers?

I am trying to sort this list:
     Thing 5     Thing 4     Thing 7     Thing 1     Thing 5     Thing 6     Thing 3
   I have tried:  $('#mainMenu').sort(function(){     $(this).children().sort(); });   I want it sorted in this order:  Thing 1 Thing 2 Thing 3 Thing 4 Thing 5 Thing 6 Thing 7


#!/bin/bash  for a in ./*.flac; do   ffmpeg -i "$a" -qscale:a 0 "${a[@]/%flac/mp3}" done   I found this script a few days ago to convert all FLAC files in the current directory into the MP3 format.  What I don't understand here is the "${a[@]/%flac/mp3}" part. I think it replaces the ending flac with mp3 for the current filename. But what eactly does the [@] part do? Is it a regular expression?


There is a prime between $n$ and $n^2$, without Bertrand

Consider the following statement:     For any integer $n>1$ there is a prime number strictly between $n$ and $n^2$.   This problem was given as an (extra) qualification problem for certain workshops (which I unfortunately couldn't attend). There was a requirement to not use Bertrand's postulate (with which the problem is nearly trivial), and I was told that there does exist a moderately short proof of this statement not using Bertrand. This is my question:     How can one prove the above statement without Bertrand postulate or any strong theorems?   Although I can only accept one answer, I would love to see any argument you can come up with.  I would also want to exclude arguments using a proof of Bertrand's postulate, unless it can be significantly simplified to prove weaker statement.  Thank you in advance.


How to derive this interesting identity for $\log(\sin(x))$

I saw on SE that:  $$\log(\sin x)=-\log(2)-\sum_{n=1}^{\infty}\frac{\cos(2nx)}{n} \phantom{a} (0<x<\pi)$$  This is an extremely useful identity, as it helps solve:   $$\int_{0}^{\pi} \log(\sin(x)) dx$$  But how is it derived? From Taylor series, power series? How do I get this?  Even if someone can start me off that would be great.


A subset of $\mathbb{R}$ that neither is an $F_\sigma$ set nor a $G_\delta$ set

Can anyone give me a simple example of a subset of $\mathbb{R}$ which is neither an $F_\sigma$ set nor a $G_\delta$.


Problem with new Marshmallow 6.1 on Samsung J5

the Facebook Messenger app & Whatsapp audio & video calling is not unavailable, it wants the access for camera & microphone, when the settings come I do it but it doesn't work, what to do?   After clicking audio or video call on messenger screen


after ubuntu installlation, space is missing on my harddisk

i started installing ubuntu and took out windows 10 completely during the installation.. but after the installation, when i checked my disk partitions  927gb on linux filesystem 3 gb on linux swap 512 mb on efi  but my hard disk size is 1tb (1024gb so now rest 94 gb is missing  can anyone help me out. i tried if the windows 10 is still existing on the disk, but i didnt get any method  and while booting the system i get a message on the top left corner  /dev/sda2: clean,223062/60760064 files, 5079494/243030464 blocks ... so does this mean.


How to install program locally without sudo privileges?

Assume I have ssh access to some Ubuntu server as user and I need some not system tools to be installed for convenience (mc, rtorrent, mcedit). I do not want to bother admins for these small programs.   Is there a way to install them (make them run) without using something like sudo apt-get install?


# Makefile  test :     while true; do         echo test     done  test2 :     while true; do echo test; done   make test throws the error while true; do /bin/sh: -c: line 1: syntax error: unexpected end of file make: *** [Makefile:2: test] Error 1  whereas make test2 works just fine. I can not figure out why.


Automating Creation of Network Dataset Using Polyline Input and ModelBuilder?

Is there a way to automate the creation of a Network Dataset in Model Builder using a line shapefile as an input? (ArcGIS 10.4)  The only documentation I have been able to find on creating a network dataset involves right clicking on a feature dataset > New > Network Dataset.   I have tried using the "Build Network" stand-alone tool, but it will not accept either a polyline or polylineM as an input. It seems like the "Build Network" tool simply re-builds any pre-existing network dataset.


How to define a bijection between $(0,1)$ and $(0,1]$?   Or any other open and closed intervals?   If the intervals are both open like $(-1,2)\text{ and }(-5,4)$ I do a cheap trick (don't know if that's how you're supposed to do it): I make a function $f : (-1, 2)\rightarrow (-5, 4)$ of the form $f(x)=mx+b$ by \begin{align*} -5 = f(-1) &= m(-1)+b \\ 4 = f(2) &= m(2) + b \end{align*} Solving for $m$ and $b$ I find $m=3\text{ and }b=-2$ so then $f(x)=3x-2.$  Then I show that $f$ is a bijection by showing that it is injective and surjective.


Routing sound from different cards to a single output

I have a setup where I am monitoring for silence on an incoming stream on 3 different audio cards.  When I detect silence on the master I switch to the secondary, and if I detect silence there I switch to the last card.  The way I have it set up I load/unload the loopback module for each card depending on who's the active card.  This has the inconvenience that I need a 3-to-1 minijack cable to be able to maintain the stream.  Can I load the loopback module and point the output to a single card (independently of the input card)?  How can I route the audio from any input to a single output?


In the recursion, if I have the following sample code  public class StringPractice {     public static void main(String[] args){              hello();     }     public static void hello(){          System.out.println("heloo world!");         hello();     } }   it will result in StackOverFlowError. However if I'm using while loop, for example while(true) and printout the function hello, it keeps looping with the output but doesn't give us StackOverFlowError. Can somebody explain why? Whats the different ?


Having many long tags on a question breaks question list layout

This only happens on .../questions pages, not on site home pages. Here's a screenshot from Aviation.SE:


Has anyone been able to install AceStreams? I had it , worked fine, but the same repository doesn't work and the attempt to install from them returns the error of unmet dependencies. Is there a workaround?


I am not using nor with neither is that fine or it is grammatically incorrect?

Sometimes I see that I can't fit "neither & nor" together or it looks like it won't sound correct.   So, would I be grammatically incorrect if I don't use nor with neither in the same sentence?  These posts couldnt help me:       Hey Perry,   I am not able to see payment box neither I can put the new one here.


vector of three RVs that are pairwise Gaussian is Gaussian

If $(X,Y)$, $(X,Z)$, and $(Y,Z)$ are all Gaussian, does it follow that $(X,Y,Z)$ is also Gaussian? I'm having trouble coming up with a counterexample...


Height in Object mode does not match the height in edit mode?

I wanted to simply create a cylinder with height of 1cm and a radius of 10cm. So I set the corresponding scales in the toolbar:   After that I went into edit mode, I enabled the edge length overlay and selected an edge from the bottom to the top:  I expected that it would be 1cm long (which is what I typed in object mode), but it is 20 cm. I also noticed the "Scale" entries in the toolbar in object mode. If you multiply 20cm by 0.005 you would arrive at 0.1cm which does not make any sense. What's going on? Is this a bug? I tried this in version 2.83.15 and 2.93.0 same behavior.


Best practise for change the IP address of web front end server

change the IP of existing sharepoint web front end server and best practise for change the iP of sharepoint server, is any issues to web applicatons and sharepont farm


Is Dark Matter called "Matter" only because of gravity?

As far as my understanding goes, dark matter is nothing but an amount of gravitational force, from yet unresolved/undiscovered source(s), needed to explain some observed attributes of our universe. Then, is it called "Matter" only because of gravity? Because other properties of matter like occupation of some space, mass etc is not found in this case. And, can it be some new kind of force other than gravity?


Why does $S^n$ satisfy the local $n$-slice condition? (From Lee's Smooth Manifolds)

Example $5.9$ on page $103$ of John Lee's Smooth Manifolds says the following:  The intersection of $S^n$ with the open subset $\{x:x^i>0\}$ is the graph of the smooth function $$ x^i=f(x^1,\dots,x^{i-1},x^{i+1},\dots,x^{n+1}) $$ where $f\colon B^n\to\mathbb{R}$ is $f(u)=\sqrt{1-|u|^2}$. The intersection of $S^n$ with $\{x:x^i<0\}$ is the graph of $-f$. Since every point in $S^n$ is in one of these sets, $S^n$ satisfies the local $n$-slice condition, this is an embedded submanifold.  The terminology is that if $M$ is a smooth manifold, and $S\subset M$ a subset, then $S$ satisfies the local $k$-slice condition if each point of $S$ is contained in the domain of a smooth chart $(U,\varphi)$ for $M$ such that $S\cap U$ is a single $k$-slice in $U$.   I don't see how this makes $S^n$ satisfy the local $n$-slice condition. Presumably the chart on $\mathbb{R}^{m+1}$ is $(U=\{x:x^i>0\},\mathrm{id})$, so that $S^n\cap\{x:x^i>0\}$ is an $n$-slice of $U$? But this doesn't seem right since $\mathrm{id}(S^n\cap U)$ is a hemisphere of $S^n$, but that's not a $n$-slice in the corresponding half-place $\mathrm{id}(U)$?


How does the new Ryanair luggage policy work?

The following might sound like a silly question, but I'm totally confused. I haven't flown with Ryanair in at least a year and apparently the luggage policy has changed since then. Previously it was allowed to carry two cabin bags (a small one and a medium one) and any other extra stuff was supposed to be checked-in and later held on by Ryanair.  I might be also wrong but it seems to me that the web portal is changed a bit as well.   I've booked a flight and if I've understood correctly I'm still allowed two bags, but one of them will be held on for free. I realized however that I need a third bag, but am I then supposed to purchase the "check-in bag" or is this only to allow me to carry the second bag in the cabin with me?  Ryanair staff (via chat) told me I need to buy an "extra seat", which doesn't make any sense to me unless they meant something else they did not explain.  Summary of the question:  I need to carry a third bag (not in the cabin with me... just extra stuff that doesn't fit in my luggage). Should I purchase the "check-in" bag?


Why bother looking at an omnibus ANOVA when I have a priori hypotheses about group differences?

I am examining three independent groups that were measured on a continuous outcome variable. I have a priori belief that the result should be Group 1 < Group 2 < Group 3. I've been told to do an ANOVA, and then to consider doing three t-tests to look at the specific differences between the groups.   Is there any reason to bother looking at the result of the ANOVA? It's been put to me that to keep the Type 1 error rate to 5% I should look at the ANOVA and if it's non-significant I should abandon the t-tests. However, someone else suggested to me that since t-tests could be statistically significant even when the omnibus ANOVA is not, and that I should therefore not bother looking at the ANOVA, and should do the individual t-tests come what may.  If the answer is "it depends", what does it depend on?


Can I do anything about a Nikon d750 taking 5 minutes to power on after taking saltwater damage?

I have had a Nikon d750 for a year or so, and 6 months ago it took on a bit of saltwater damage. It still works, but twice in the past it wouldn't power on, once for two weeks and once for two days.   Now it is at a point where it takes around 5 minutes to power on, and when i switch the camera to 'off' or standby, it completely powers off as if the battery drops out, then it takes another 5 mins or so for it to power back on, if it does at all. So I have switched the standby timer in the settings to 'infinity' so it just stays powered on.  I am taking it in to have it looked at, I just hope the damage isn't too fatal. I wonder if anyone has experienced anything similar to this, or can help me diagnose the actual problem. I have tried different batteries, and everything else possible really. Camera itself works fine, just power issues.  thanks in advance.


If $x\in\mathbb R$, solve $4x^2-40\lfloor x\rfloor+51=0$.

If $x\in\mathbb R$, solve $$4x^2-40\lfloor x\rfloor+51=0$$   where $\lfloor x\rfloor$ denotes the integer part of the number. $\lfloor x\rfloor\le x$ and $\lfloor x\rfloor=x-\{x\}$, where $\{x\}$ marks the fraction part of the number. $0\le\{x\}<1$.   Not sure if all these denotions are conventions that always mean what I've mentioned. Also, I'm not too sure if $x\in\mathbb R$, since the problem doesn't mention it, but it seems quite obvious that it most likely is that way.


PDOStatement->prepare and PDOStatement->bindParam() combination not working

I have some code that should loop through values and change entries in a table. The 5 values of the variables $change_val, $column, and $id all echo out correctly, so I assume there is something wrong with my usage of bindParam (but I am not sure what it is).  $connection = new PDO("mysql:host=localhost;dbname=logbook", $username, $password); $perform_edit = $connection->prepare("UPDATE contacts SET :column = :value WHERE name_id = :name_id");  [Definition of Arrays]  for ($i = 1; $i <= 5; $i++) {      if (!empty($_POST[ $change_array[$i]])) {         $change_val = $_POST[$change_array[$i]];         $column = $column_array[$i];         $id = $_POST["name_id_ref"];         $perform_edit->bindParam(":column", $column, PDO::PARAM_STR);         $perform_edit->bindParam(":value", $_POST[$change_array[$i]], PDO::PARAM_STR);         $perform_edit->bindParam(":name_id", $_POST["name_id_ref"], PDO::PARAM_INT);         $perform_edit->execute();         } }   The $_POST statement is there because the value I want is actually passed from another file. When I place appropriate echo statements within the loop, though, they all print out their correct value.  I've also tried bindValue, but that did not work either. I see no errors and things at least compile smoothly—just not as they should. Nothing in the table is changed.  What's wrong here?


Would anybody indicate me what is the grammatical structure applied in this sentence?     This is too vague a term   I have seen this structure sometimes and, although they sounded strange in the beginning, I'm starting to naturally use it on my essays.


I have been wanting to understand how to find the sum of this series.   $$1^p + 2^p + 3^p +{\dots} + n^p$$  I am familiar with Gauss' diagonalised adding trick for the sum of the first $n$ natural numbers.  I can prove the formulas for  $$\begin{align}   \sum_{1}^{n} k^2 &= \frac{n(n+1)(2n+1)}{6}\\  \sum_{1}^{n} k^3 &= \frac{n^2(n+1)^2}{4}\\ \sum_{1}^{n} k^4 &= \frac{n(n+1)(2n+1)(3n^2+3n-1)}{30} \\ \end{align}$$  With mathematical induction. But, beyond that even proofs with mathematical induction are difficult.  I'm interested in learning the theory and the proof behind Faulhaber's formula. What is the knowledge required to understand this proof ?


How to link back to the original site the user came from after he jumped to a subdomain with a "different" product?

lets say you have a site called "example.com", which is the homepage of a company that provides a login for its customers and different functions like a personal backoffice, learning material and company related stuff like news, about etc.  One of the things that site contains is a link to a sub-domain which basically is a media-area for the customers where they can watch videos from different topics that are related to their daily work, when the user clicks on that link, the sub-domain (lets call it videos.example.com) opens in a new tab.   What the project manager suggested  He wanted to add a home-icon next to the company logo on the left of the head-area, the company logo should act as a link to "example.com" the home icon should link back to "videos.example.com".  In my opinion thats to confusing for the user, since we are currently using a home-icon on "example.com" as a link back to the starting-page, users might expect that the home-icon will take them back to "example.com" instead of "videos.example.com", also most users click on the logo to jump back to the starting page, which makes it even more confusing.  I said we should not place them next to each other, we should only use the logo instead of a home-icon to take the user back to the starting page.  I still want to provide the users a way to get "back" to "example.com", and now i am looking for a good, understandable way how to do this.  Do you have any proposals on how to make that as transparent as possible?  Btw. the header will consist of Logo + 5 navigation points + search bar + login option


LiDAR Basics - How classes are determined at LiDAR data?

LiDAR data have classes as Medium vegetation, Buildings, Ground, Model Key and more. What determines these classes ? is it combination of intensity and scan angle rank ? how to reclassify these classes using ArcGIS ?


Minimum length required to connect 4 points in a square.

The original problem was: given 4 cities arranged as the vertices of a square of side length 8 km find a way to connect the cities together using 22km of road or less. The solution can be seen as follows:      Constructing the road in this manner is "less" symmetric than just making the road with the diagonals of the square yet it is shorter. This intrigued me and I decided to see how much we could optimise this approach of leaving a space of length x in the middle. With a bit of simple calculus I found the length of the road is minimised for $$x = 2 \times (4 - \sqrt{\frac{16}{3}})$$ The length of the road is minimised to approximately 21.856 for this value of x.  Given all this I have numerous questions: 1. Could I have an intuitive explanation for why a "less" symmetric solution is actually better than the "optimally" symmetric solution of two diagonals even though the problem relates to a square which is very symmetrical. 2. Is this value of 21.856 the best we can do? Is there a better solution? Is there an optimal solution? If there is an optimal solution can we prove it is optimal?


Why is it important to run a model with 1 standard error for lasso ml? I am unsure of the importance.


I have the following formula:    Is there an elegant way to make the matching brackets of one level a little bigger than the matching brackets of the previous one?  Normal -> () -> Bigger -> [] Bigger -> {}  \documentclass{article} \usepackage{parskip} \setlength{\parindent}{0cm} \usepackage{amsmath} \usepackage{unicode-math} \usepackage{fontspec} \usepackage[greek,english]{babel} \setmainfont [     Ligatures=TeX,     Extension=.otf,     UprightFont=*,     BoldFont=*Bold,     ItalicFont=*It,     BoldItalicFont=*BoldIt,     Mapping=tex-text ]{GFSArtemisia} \setsansfont[Mapping=tex-text]{GFSArtemisia.otf} \setmathfont{latinmodern-math.otf} \setmathfont[range=\varnothing]{Asana-Math.otf} \setmathfont[range=\int]{latinmodern-math.otf} \usepackage{lipsum}  \begin{document}  Formula: % \Eqs {   y_{n+1}=y_{n}+\frac{h}{2}\{f(x_{n},y_{n})+f[x_{n}+h,y_{n}+hf(x_{n},y_{n})]\} }  \end{document}


Why in evee does the emission shader not actually emit light? I turn it up to extreme levels and it does not work.


Why does everyone in Game Of Thrones have a British accent?

What is the reason for the British accents in Game Of Thrones?  Specifically in the North and South, not in what is considered foreign lands like Qarth and Meereen. Although George R. R. Martin is American and the show is directed towards American audiences, everyone in Game of Thrones speaks in some sort of British accent.   Going through some of the characters with accents:   Ned Stark has a northern accent (actually Sheffield). Robb Stark has a northern accent (actually Scottish). Jon Snow and Theon Greyjoy are non-northern actors with northern accents. Arya Stark has a slight West Country accent. Catelyn Stark speaks with a slight southern English accent. King Robert Baratheon has a northern accent. Some of the knights in the Vale speak with Welsh accents Jorah Mormont has a Northern accent (actually Scottish in real life) Davos Seaworth has a Northern accent (actually Irish) Tyrion Lannister umm, .   Anyway, you get the point that the English accent is the theme here. Obviously there are many more characters that speak with British accents, so what was the reason for the British accent?


what is the difference between >&2 and &>2

Just wondering if there is any difference between:    echo "running the npm patch" >&2;   and   echo "running the npm patch" &>2;   I have actually never really understand that syntax.


Click event for button created dynamically

In my AJAX success function, I've written:   rt = JSON.parse(responseText); for (i = 0; i < rt.length; i++) {   $("#inv").append("
" + rt[i][0] +     "	<input type='submit' value='Sync' " +     "class='syncnow' id='sync"+rt[i][6]+"' />
"); }   I've tried jQuery code:  $(".syncnow").on("click", function() {   alert("Hi"); });   Tried .click(), $(".tdclass").on("click", ".syncnow", function() {}) etc., but to no avail.  Can anyone help me with this?


How to wipe a hard disk completely so that no data recovery tools can retrieve anything?

How can I do a disk low level formatting in Ubuntu on an external hard disk so that any data recovery tools like test-disk or photorec cannot retrieve any data once formatted to ext4 or any file-system? As I was playing around with Test disk, I found that it can recover almost all old files even after formatting it many times and I want to use my external hard disk as new because it is only one year old and in warranty but without any old data.


How to debug "Cross-thread operation not valid" error in C#?

This is my first project on threading but i'm lost..  The problem is: I want to make a second counter, where every prime number turn color.   Thread thread1; private void Form1_Load(object sender, EventArgs e) {     thread1 = new Thread(new ThreadStart(voidPrime)); }  int sec=0;  void voidPrime() {      sec+= 1;     label1.Text = sec.ToString();     if (isprime(int.Parse(label1.Text)))     {         label1.ForeColor = Color.RED;     }     else      {         label1.ForeColor = Color.Black;     } }  private void PLAY_Click(object sender, EventArgs e) {     thread1.Start();      while (thread1.IsAlive)     {         Thread.Sleep(1000);     } }   When I start and press the PLAY button, throws me      Cross-thread operation not valid: Control 'label2' accessed from a thread other than the thread it was created on.


How to recover from a forgotten password for MacBook Pro?

I've forgotten the password for my MacBook Pro, which uses OS X 10.9.1. How can I reset my password?


I have a table in MYSQL. It is defined as character set - utf8, collation: utf8_general_ci. The ITEM_TITLE column defined as a varchar. I have this query: UPDATE  details SET ITEM_TITLE="★32GB VALUE PACK★ Sony Xperia miro ST23i 4GB Int     White with silver" WHERE TaskID=109 The result is that in the column ITEM_TITLE i have a title without the ★ and with "?" instead.   THE QUESTION: What should i do, in order to save "★" in the DB properly?  **I found a solution for SQL server - using Nvarchar and not varchar but there is no such type in MySQL.  Answer: I understood what was the problem and why the solution that worked for someone, didnt work for me. First off all, the default for my DB is charset latin. So i changed it to UTF-8 but it didnt solve the issue. The reason for that is that i had a charset latin for most of the rows. I didnt know that it is set automatically for varchar and doesnt change even when i set the table as UTF-8. So I changed everything to UTF-8 and it works fix.  Thanks for all the help!