Fetching a list of Objects and then checking it against a method then returning a new list

sM is an instance of the class, When running the method staffCanWork it is supposed to return a List of staff objects that can work on the given date and time, however when running the method it null pointer errors.  Testing the method within static void main;    Date date = Date.valueOf(LocalDate.now());         List<Staff> staff = sM.staffCanWork(date, Time.valueOf(LocalTime.now()));         for(int i = 0; i < staff.size(); i++){             System.out.println(staff.get(i).getId());         }   Method getStaff() using hibernate populates the List with staff objects using hibernate.       public List<Staff> getStaff(){         List staff =null;         Session session = factory.openSession();         Transaction tx = null;         try {             tx = session.beginTransaction();             TypedQuery query = session.getNamedQuery("getStaff");;             staff = query.getResultList();         }catch (HibernateException e){             e.printStackTrace();         }return staff;     }    staffCanWork method, Checks through the list to see if staff can work the given date and time.      public List<Staff> staffCanWork(Date date, Time time){         List<Staff> staff = getStaff();         List<Staff> staff1 = null;         for(int i = 0; i < staff.size(); i++){             if(staff.get(i).getDoctor() == null){                 if(staff.get(i).getNurse().canWork(date, time)) staff1.add(staff.get(i));             }             else {                 if(staff.get(i).getDoctor().canWork(date, time)) staff1.add(staff.get(i));             }         }         System.out.println(staff1.get(0).getId() + "test");         return staff1;     }   Method CanWork  public boolean canWork(Date date, Time time){         Boolean canWork =false;         Boolean aM = false;          if(time.getTime() < 12){ aM = true;}         SimpleDateFormat simpleDateFormat = new SimpleDateFormat("E");         simpleDateFormat.format(date);         if(aM = true) {             switch (simpleDateFormat.format(date)) {                 case "Mon": if (getMondayAM() == true) canWork = true;                     break;                 case "Tue" :if (getTuesdayAM() == true) canWork = true;                     break;                 case "Wed" :if (getWednesdayAM() == true) canWork = true;                     break;                 case "Thu" :if (getThursdayAM() == true) canWork = true;                     break;                 case "Fri" :if (getFridayAM() == true) canWork = true;                     break;                 case "Sat" :if (getSaturdayAM() == true) canWork = true;                     break;                 case "Sun" :if (getSundayAM() == true) canWork = true;                 default: return false;             }         }         switch (simpleDateFormat.format(date)) {             case "Mon": if (getMondayPM() == true) canWork = true;                 break;             case "Tue" :if (getTuesdayPM() == true) canWork = true;                 break;             case "Wed" :if (getWednesdayPM() == true) canWork = true;                 break;             case "Thu" :if (getThursdayPM() == true) canWork = true;                 break;             case "Fri" :if (getFridayPM() == true) canWork = true;                 break;             case "Sat" :if (getSaturdayPM() == true) canWork = true;                 break;             case "Sun" :if (getSundayPM() == true) canWork = true;             default: return false;         }         return canWork;     }


We are trying to determine logged-in status of our users as part of an automated lead-routing process (we only want to route to logged-in users), but we are seeing some inconsistencies.  We currently have a scheduled apex job running every 15 minutes executing this query: SELECT Id, UsersId FROM AuthSession WHERE SessionType = 'UI'  If a record exists we are assuming that the user is logged in.   However, it seems that some -but not all- AuthSession entries are never deleted, even when the user is no longer logged in, causing them to appear logged-in according to our process.  What could be causing this?  Could it be because some users are actively logging out using the logout button while others aren't? (In order to try and remedy this, we have now turned on the 'Force logout on session timeout' in the Session Settings).  We were wondering if we could use the isCurrent field on the AuthSession object, but it is false for all users at all times.   FYI, we are using SSO.


Could we allow suspended users to bookmark questions? I'm aware that  but I would like to have this feature changed.


I can't install gnome-shell on Ubuntu 17.04. What am I missing?  » sudo apt install gnome-shell                                                                                Reading package lists... Done Building dependency tree        Reading state information... Done Package gnome-shell is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source  E: Package 'gnome-shell' has no installation candidate


I don't how to promote a new Area51 site

I have created a new site () on Area51, how do I promote it?


Let A be the set of twice continuously differentiable functions on the interval $[0, 1]$,  and let $B = \{f\in A : f (0) = f (1) = 0, f ′ (0) = 2\}$. What is  min $\int_0^1 (f''(x))^2$.   There is one given hint consider $(1-x)f''(x)$.  Any idea how to start solving this problem?


Using CLT to calculate probability question

Suppose $53$ percent of the population prefer red socks to green. If $100$ random people are asked, what is the probability that most (at least $50$) will say prefer GREEN:  So I set \begin{align*} N & = 49.5\\   n & = 100\\   p & = 0.47 \end{align*}  Then.. \begin{align*}    P(N \geq 49.5) & = P\left(\frac{N - np}{\sqrt{npq}}\right)\\                & \geq \frac{49.5 - 47}{\sqrt{100*.47*.53}}\\                   & = \varphi(0.50)\\                   & = 0.3085   \end{align*} Except, that's not the right answer. What did I do wrong in my calculations?


Make div width same as its content width

I have attached a fiddle link to this question. I need the red dot to be closer to the text. For the first & last item, it works well..but if any item is multi line..it has extra whitespace at the right..i want the dot to be closer to the text for the second item also.I tried flex:0 but it makes the whole text area smaller.Please help!

    1
News Section

   2
Sample123 Organizational announcement

   3
Sample Text

 .container {   width:300px;   padding: .5em 1em;  } .item {   display: flex;  } .icon {   width: 18px;  float: left;  } .text {   display: inline-block;   background: yellow;  } .red {   margin: 0 0 0 0.5rem !important;   background: #FF0000;   padding: 0 !important;   width: .5rem;   height: .5rem;   border-radius: 50%;  }


Who Is To Find Research Ideas in Computer Science Research: PhD Student or Adviser?

Is a PhD student in Computer Science always expected to come up with new ideas or it is the responsibility of the adviser to provide some idea and guide the student to solve the problems in achieving that idea?  My PhD adviser wants me to give project ideas all by myself. He is not very good with new ideas and if he comes up with an idea he becomes the first author. So ideally to become a first author and complete my graduation, I've to find ideas all by myself and I don't get any useful suggestion from him either. I understand as a PhD student I should be able to find out problems but at the same time I expect some input from him. At least guide me to some specific direction or help me from a high level. Am I expecting too much or is my adviser's action appropriate? FYI, I'm at the end of my 2nd year and I've been working with him for 1 year. My major is Computer Science.


90'/00' movie about a man/boy on a quest

I think this movie is from the early 2000. A man goes on a quest to get something for his girlfriend/wife?               The quest start with him need to defeat an old man who is a martial arts master. After that I only know some vague details.  There are witches who 'fast travel' with candles. I also believe there is a assassin? who has killed his brothers and they follow him as ghosts.  And at some point the main protagonist runs in to pirates who capture him but after he finds out the captain is cross dressing they become his allies.  Somehow the movie title Starfall stuck with me but I can't find a movie with that name.


How to change system date on win7 to new requested date

I need to change the system date on Win 7 when the date does not match the requested date. For example:  If actual date  !=  requested date, then change the date to a specified value.  I'm looking for some kind of application, .exe program which can run in the background. Is there any idea on how to achieve this?


The meaning of $\rightsquigarrow$ in math?

In order to write a scientific paper, I would like to use the symbol     \rightsquigarrow or \leadsto   which look as: $\rightsquigarrow$ or $\leadsto$  I'm wondering about the usual meaning and use of this symbol.  Thanks in advance.


What is economics like for ordinary people in the Star Trek universe?

I realize that this is a very broad question, with the stories told in the Star Trek universe spanning hundreds of years.  I sometimes hear of economists talking about a theoretical "Star Trek economy" in the future.  The central feature of this is that in the future, the fundamental things we need for survival are no longer scarce.  Therefore, I would like to know what every day economics and commerce are like for ordinary people, as opposed to Starfleet and political elites.


TCL threads for run a script and update the GUI

I've a tcl script which runs another tcl script. When the script is called, it creates a log file which is supposed to be updated in the text box(TCL GUI). I tried and failed, below is the code  So I'm planning to run the script in a thread thread1 and access the log file created and update the results in GUI text box using another thread2. If this method is right, suggest how can i modify my existing code to run in threads. I'm open for any method, as I'm a noob in TCL.   #!/usr/bin/wish  set excel_path "" set types ""  proc receive {chan} {     .m.consoleText configure -state normal     .m.consoleText insert end [read $chan]     .m.consoleText configure -state disabled     .m.consoleText see end     if {[eof $chan]} {         close $chan     } } proc processLogLine {line} {     # Write this yourself...     .m.consoleText configure -state normal     .m.consoleText insert end $line\n     .m.consoleText configure -state disabled     .m.consoleText see end } proc Run_Button {} {     cd $folder_path    set cmd_err [catch {set command [eval exec ../Run/start.tcl]} err_msg]     if {$cmd_err == 1} {     foreach line [split $err_msg "\n"] {        processLogLine $line       } else {    fconfigure $chan -blocking 0    fileevent $chan readable "receive $chan" } }  frame .m  frame .m.f -borderwidth 5 -relief sunken -width 1800 -height 900  button .m.selectExcel -text "Choose Excel" -command {  set excel_path [tk_getOpenFile -initialdir "/Run" -defaultextension ".xls" ]  } -width 10 label .m.lab -text "No File choosen" button .m.myButton -background red -text "Run" -relief ridge -borderwidth 3 -command "Run_Button" -width 10 button .m.closeButton -background red -text "Close" -relief ridge -borderwidth 3 -command exit -width 10 text .m.consoleText -background white -borderwidth 2 -relief sunken -width 180 -height 50 -yscrollcommand {.m.scrl set} scrollbar .m.scrl -orient vertical -command {.m.consoleText yview}   entry .m.boardName -relief sunken -width 15 -bd 2 -textvariable ::board  grid .m -column 0 -row 0 grid .m.f -column 0 -row 0 -columnspan 18 -rowspan 36  grid .m.selectExcel -column 0 -row 0 -columnspan 2 grid .m.lab -column 2 -row 0 -columnspan 16 grid .m.myButton -column 0 -row 1 -columnspan 2 grid .m.closeButton -column 0 -row 35 -columnspan 2 grid .m.boardName -column 0 -row 2 -columnspan 2 grid .m.consoleText -column 2 -row 2 -columnspan 8 -rowspan 30  grid .m.scrl -column 17 -row 2 -rowspan 32


How to find all files with the same extension within a directory

I want to search for all .conf files in /etc/. I tried grep -r *.conf /etc, but the result isn't right. What am I doing wrong?


Is it possible to log your Steam account into two computers at once?

My gaming computer is currently downloading Napoleon: Total War and Supreme Commander 2 which I purchased on Steam, and which will take some time to complete. While this download is going on, I would like to play some of my other multiplayer games on my laptop, but I would rather not interrupt the download to do so.   Is it possible to have both computers logged in at once? I know if I was playing a single player game, I could set Steam into offline mode, then resume the download on the other computer, but this won't work for multi player games.


Applications crashing when they are closed from terminal

I've notice that when I open an application from terminal, for instance evince fileName.pdf  and I try to close using Ctrl+z, it actually does not close. Instead, it keeps open and when I try to close directly by "close button", it crashes and I receive a message like  "fileName.pdf" is not responding  Does someone knows why this is happening?


Finding nonnegative solutions to an underdetermined linear system

Here's the environment of my problem: I have a linear system of 4 equations in 8 unknowns (i.e. $Ax = b$, where $A$ is $4 \times 8$, $x$ is $8 \times 1$, and $b$ is $4 \times 1$, with $A$ given and $b$ varying with some exogenous parameters, i.e. essentially given). So, after reducing the system, the solution space can be described by a linear function $f \, : \, \mathbb{R}^4 \rightarrow \mathbb{R}^4$, which I can find explicitly.  Because of the nature of the problem, I am interested only in nonnegative values for each of the 8 unknowns. So, I can restrict the function $f$ to the domain $\mathbb{R}^4_{\geq 0}$ (i.e. examine only nonnegative values for each of the 4 free variables). What I'm interested in knowing (and classifying for different parameter values, which will change $b$) is whether solutions exist for which all 8 unknowns are nonnegative--or equivalently, whether the function $f$ takes nonnegative values in the nonnegative domain $\mathbb{R}^4_{\geq 0}$.   If there's a way to figure this out analytically, that would be great; alternatively, if there's a good way to do this numerically (I use MATLAB), that would be only slightly less great. Thanks in advance!    Thank you all so much for your answers--this has been a huge help. Working out the solution by hand using the LL Dines paper may prove to be too cumbersome, as it requires knowing the sign of the coefficients, and we examine thousands of different sets of coefficients (as we vary several parameters); however, if nothing else, it's really nice to know that there is an algorithm for (analytically) determining the existence of nonnegative solutions. Moreover, all of the software advice given has been extremely helpful. I've looked into all of your suggestions, and for now I think we'll try using lsqnonneg. Thanks again for your help!


Ps4 slim controler wont pair during intial setup or in safe mode

I factory reset my ps4 now the controller wont pair through the usb intial set up or in safe mode. My computer will still recognize it and I can pair it with my phone but not the ps4 system. When trying to pairnive used multiple cords and have used the reset button on the controller and a hard reset on the system. The controller just blinks white when trying to pair never connects to the system


What's the purpose of the CIL nop opcode?

I'm going through MSIL and noticing there are a lot of  instructions in the MSIL.  The MSDN article says they take no action and are used to fill space if the opcode is patched. They're used a lot more in debug builds than release builds.  I know that these kinds of statements are used in assembly languages to align later instructions, but why are MSIL nops needed in MSIL?  (Editor's note: the accepted answer is about machine-code NOPs, not MSIL/CIL NOPs which the question originally asked about.)


What is the difference between bool and Boolean types in C#?


arbitrarily long sequences without perfect powers

The fact that there are arbitrarily long sequences of consecutive numbers without prime number is well known, the proof is easy and goes like this:   let $n\ge 2$, then the number $n!+k$ is greater then $k$ and divisible by $k$ for $k=2,\dots,n$, so it is composite, so we have at least $n-1$ consecutive composite numbers.  I think that there are arbitrarily long sequences of consecutive numbers without prime numbers and without powers of primes, probably also without any perfect powers.  Examples:  $17,18,19,20,21,22,23,24$ -- 8 consecutive numbers without any perfect power,  $37,38,\dots,48$ -- 12 consecutive numbers without any perfect power,  $50,51,\dots,63$ -- 13 consecutive numbers without any perfect power,  $65,66,\dots,80$ -- 16 consecutive numbers without any perfect power,  $901,902,\dots,960$ -- 60 consecutive numbers without any perfect power,  $1601,1602,\dots,1680$ -- 80 consecutive numbers without any perfect power.  But I'm not able to prove my conjecture. Is it really true? Any proposals will be appreciated.


How can I contribute without using PayPal?

I'd like to contribute to Ubuntu development, but after  I'd like to avoid using them.  Are there other ways to share?  BitCoin? Check?


How to share Mac audio over Skype with the microphone?

System:  2011 iMac, built-in microphone, Mountain Lion.  This is a two part question.  First the more basic scenario, second the more-niche scenario that I hope to ultimately solve.  I want to share my Mac audio over Skype, while still being able to simultaneously talk to the person on the other end of the call.  As of yet, every combination of options I have tried (dozens) involving Soundflower, aggregated devices, and even LineIn.app has completely failed.    So firstly, what are the precise steps needed to get my Mac audio (say, youtube videos playing in a browser...) to transmit over Skype along WITH my voice from the built-in Mic?  Now for the ultimate solution I hope to achieve.  I want to be able to collaborate musically with other parties, using a program called Reason from Propellerhead Software.  Reason has its own audio interface setting - a single setting for both input and output.  I use the Propellerhead's own audio interface called "Balance" as my audio device for the software, providing my physical I/O as well as a headphone mix.  I want to be able to merge the audio output of Reason, along with my voice via the built-in mic of the Mac, and send them together over Skype so that the other person can hear what I'm doing in reasonable fidelity (subject to Skype's limitations, of course).  Can anyone provide the exact steps to share Reason's audio along with my mic, over Skype?  If 3rd party software beyond SoundFlower/LineIn is required, I'm OK with that... though this should work with just SoundFlower even.  I even had it working a couple months ago but can't seem to replicate the result again.


I upgraded my laptop to new Ubuntu distribution 17.10 this afternoon/evening and since then I cannot connect to the internet.  I have tried both wired and wireless connections, but the icon in the status bar shows a question mark over the connection icon whichever method I've tried. I originally thought it was a wireless problem (it's a Realtek RTL8833EE card) so tried to connect via Ethernet to download the latest driver but find I can't connect with wire either.  I had a similar problem last week with 17.04 which I resolved somehow but I can't find exactly what I did.  Please can I have some suggestions as to what I should try to troubleshoot.  EDIT: I have tried the question (and the answer) here:    both by adding a line  [main] dns=dnsmasq   under /etc/NetworkManager/NetworkManager.conf, and by checking the resolvconf.service via  $ systemctl status resolvconf   which is NOT showing an error like  resolvconf[623]: /etc/resolvconf/update.d/libc: Warning: /etc/resolv.conf is not a symbolic link to /run/resolvconf/resolv.conf   I have confirmed that /etc/resolv.conf is a symbolic link to /run/resolvconf/resolv.conf


How to transform column into row in SQL Server

I have a attendance table like this:  Student_id   attendance_date    status -----------  ----------------   ---------        1     1/8/2014          Present        2     1/8/2015          Absent        1     2/8/2014          Present        2     2/8/2015          Present        1     3/8/2014          Present        2     3/8/2015          Present   Expected output is this:    Student_ id   1/8/2014      2/8/2014     3/8/2014  -------------  ---------     ---------   ----------          1     present         present      present          2     absent          present      present   Please help me to get a expected output.....


Why doesn't max cross-correlation equal exactly 1 between two identical vectors with a designed-in lag? (R, ccf)

I have two vectors, a1 and a2. They're identical except for a certain lag:    I expected their cross-correlation to have a maximum of 1 at their lag. However that's not the case: their max cross-correlation is close to 1, but not quite (0.9998). (If I just remove the lag manually and correlate, I of course get a correlation of exactly 1.)  My intuitive understanding was that cross-correlation took two vectors, "slide one over" by a certain amount, and calculated a correlation. Clearly that's not the case, because I don't get a value of exactly 1. Why isn't the peak 1?  (This question is followup to , where the discrepancy is much bigger, so I take this is a general feature of ccf.)  Code  # make vectors a0 = runif(25) a1 = c(rep(0.5, 2), a0) a2 = c(a0, rep(0.5, 2))  # plot require(ggplot2) ggplot() + geom_line(aes(x=1:27, y=a1), color="red") + geom_line(aes(x=1:27, y=a2), color="blue")  # cross-correlate tmp = ccf(a1, a2, type="correlation", plot=F) print(paste("maximum correlation is", max(tmp$acf)))


This question only for users, who have knowledge about Idea object in salesforce For user who don't know about Idea object, I can't help .  how to get status and category value based on zone name in idea object salesforce    Requirement I have vf page. there I have three picklist   Zone Category Status   But I am not getting filtered value when I am selecting A zone name from Zone picklist. It gives us all category  and Status values.  But in standard sf page Idea detail page, It do these filtering. I want to do the same.  I have tried getting dependent field value using MetaData Api as well. but no luck because Zone(CommunityId-Apiname) is not dependent field of Status and Category field in Idea object, but behave in that manner(Magically).  ZoneId is label name and api name is CommunityId, is reference field in Idea obejct  Status and Category are picklist type of field and can have different-2 value depends upon Zone selection.  ZoneId is not controller field but behave like controller field for Status and Category field. This all are standard field(Category, Status, CommunityId(label as Zone)) and standard object(Idea)  In the end I would say,Zone is behaving as RecordType.       Zone Object detail page


Why does flag marking as helpful/declined not always correlate with moderator action?

I flagged a post and (choose one)   my flag was marked as helpful, yet nothing was done my flag was marked as declined, yet the post was deleted/edited/closed   Why?


Need advice, please. Trying to explain why not to use the "to infinitive"  I got the question after it was read in a textbook.  "The queen, what she does her entire life is lay eggs"   "lay" is used here as a bare infinitive because it used after the auxiliary verb "does", right?  Why would "to" be added if the sentence is changed to:   "The thing which she does her entire life is to lay eggs."   Does the rule still apply?  To simplify:  The thing which she does is to lay eggs.  What she does is lay eggs.   What am I missing here?  Any help would be appreciated.


Can not boot into windows 8 after cloning HDD to SSD

I have a problem about transition from HDD to SSD.  I have a Sony Vaio laptop (a third gen Intel) which came with a HDD. For higher speeds I bought a new OCZ vector SSD to replace it and a HDD box to make a portable HDD from the old one.  Then I removed the HDD, installed the SSD, cloned the HDD to the SSD with Norton ghost and rebooted.  After the reboot, the system report failed to boot (missing winload.efi) and need recovery. Is there anything goes wrong? I have no idea. The contents on the HDD and the SSD look quite the same.  I need your suggestion, if I must clean install the system at least hope you can show me how to backup the licence...  Of course the best thing is change something in the boot to minimize the work.


How to print data from one table, if it does not exist in another table (php mysql)

I have two tables comments and comments_liked. Users (viewer_id) can like comments written by (UID). Comments are stored in the comments table and comments that are liked are stored in the comments_liked table (as shown in the image attached).   **What Im trying to do:  When a user that has (viewer_id) as their id, found in the comments_liked table, is viewing their profile, they should see any comments that they have liked/given to a user (UID), Only when the comment does not exist in the comments table where uid = uid  Please don't get confused, as I am not trying to show all comments where uid=uid.  Below is my code in php  please note : if we can not say where comments_liked.uid != comments.uid as that would show all other values in the comments table.  $query = "     SELECT * FROM comments_liked      INNER JOIN comments ON uid = comments.uid      WHERE uid = ?      AND viewer_id = ?  ";   but my code only prints the records where commnets_liked.uid = comments.uid which is the opposite of what I want.   so if I am user 1, I need to see the record from comments_liked where viewer_id = 1, as it does not exist in comments table.  THANKS FOR YOUR HELP!


Can't delete my own questions in Android

If was pointed out to me that one of my questions was a duplicate, so I went to delete it. No such option available?


Minimum value of $S=\frac{3a}{b+c}+\frac{4b}{a+c}+\frac{5c}{a+b}$

Find Minimum value of Minimum value of $$S=\frac{3a}{b+c}+\frac{4b}{a+c}+\frac{5c}{a+b}$$  My Try:  we have $$S=3 \times \left (\frac{a}{b+c}+\frac{b}{a+c}+\frac{c}{a+b}\right)+\frac{b}{a+c}+\frac{2c}{a+b}$$  By Standard $AM$ $GM$ inequality we know that  $$\frac{a}{b+c}+\frac{b}{a+c}+\frac{c}{a+b} \ge \frac{3}{2}$$  Is it possible to proceed here?


I was on F1(OPT) visa in USA. My H1B got approved couple of months back and I will be going to India for stamping H1B visa. I am planning to stop in Switzerland for a week for vacation while going to India. Can I get the Schengen visa here in SF as I don’t have H1 stamped? I do have H1B approval notice. After staying in Switzerland, I will be going to India for stamping and then coming back to USA on H1B visa.


Add back link to activities somewhere in the new top bar

I find myself constantly going through my most recents comments, to see if people responded to them (but maybe didn't @mention me) or to see if there are any updates in general.  The previous bar had a dropdown with a link to my activities (taken from ):        Could we please integrate a link to activities somehow/somewhere in the bar or in one of the  dropdowns?  Having to go to my profile first, waiting for it to load and then click on the activity tab is really time consuming.    If we don't want to add such a link because most users don't actually use it, how about adding it for high rep users, to increase (or rather keep) their level of productivity?


QGIS Nautical Chart Symbols for sector lights

This is I know going to be of limited interest to many of you but I teach navigation and I am working on producing test questions and charts for assessing learners knowledge. My problem is solvable with post editing but as I am finding QGIS very versatile as I am learning it I think there may be another way to achieve this without needing post editing.  The effect I am looking for is this:    And in QGIS I have a layer with length of the vector lines and angle, and using the Vector Field marker symbol I get this:   This I am really impressed with and think I am probably asking to much to be able to either add colour bands as in image 1 or arrows between the lines labeled with the colour abbreviation.  One thought that I have is that perhaps there is some way to draw a radius and clip it to the sectors.  I am using Qgis Lyon and have a Mac so GIS alternatives are not easily possible.


How to justify some block of text in beamer?

I'm doing a presentation in beamer and would like to justify some text as one does in LibreOffice Writer or Word, cause I don't like how it looks aligned to the left. Is there a command that does the trick?


material not displaying on fresh install of 2.91 since upgrade

Blender was working fine for me a few weeks ago, recently had to replace my ssd, reinstalled blender2.91, and i cant get any materials to display, not in shading, not in uv edit, not in layout/edit mode. If i open up the default starter scene, select the cube, go to material menu select base colour change it, got to material preview/rendered view, i get a weird grey void where the object should be, if i render it renders as a transparent object amid a black background, same thing if i change the base colour to be an image texture. Tried 2.90, a few of the 2.8 builds, same issue, checked for updates to my graphics card, there were none. if i go in to texture paint mode, the image texture is visible, but only in solid viewport rendering short video of issue here


What is the main physical mechanism behind the generation of negative ions in air by a high negative voltage electrode ?


Suppose $\partial_j \partial_i f$ is continuous at $a$ and $\partial_j f$ exists. Then $\partial_i \partial_j f (a) = \partial_j \partial_i f (a)$

I usually encounter a version of Schwarz's theorem in which the continuity of all partial derivatives are required. I'm trying to prove Schwarz's theorem in a more general setting.  Could you please verify if my proof looks fine or contains logical gaps/errors? Thank you so much for your help!     Let $X$ be open in $\mathbb R^n$, $f:X \to F$, and $i, j \in\{1,\ldots,n\}$. Suppose that $\partial_j \partial_i f$ is continuous at $a$ and that $\partial_j f$ exists in a neighborhood of $a$. Then $\partial_i \partial_j f (a)$ exists and $$\partial_i \partial_j f (a) = \partial_j \partial_i f (a)$$     My attempt:  Let $\{e_1,\ldots, e_n\}$ be the standard basis of $\mathbb R^n$. Consider the maps $$\Psi: \mathbb R^{2} \to F, \quad (h, t) \mapsto f (a+ h e_i + t e_j) - f(a + h e_i) - f (a+t e_j) + f(a)$$ and $$\Phi: \mathbb R \to F, \quad s \mapsto f(a+s e_i + t e_j) - f (a + s e_i)$$  We have $\Psi(h,t) = \Phi(h) - \Phi(0)$. By Mean Value Theorem, we have $$\Phi(h) - \Phi(0) = \partial \Phi (\theta)h = (\partial_i f(a+ \theta e_i + t e_j) - \partial_i f (a +\theta e_i))h$$ for some $\theta$ between $0$ and $h$. Consider the map $$\Gamma:\mathbb R \to F,  \quad s \mapsto \partial_i f(a+ \theta e_i + s e_j)$$  By Mean Value Theorem again, we have $$\partial_i f(a+ \theta e_i + t e_j) - \partial_i f (a +\theta e_i) = \Gamma(t) - \Gamma(0) = \partial \Gamma(\lambda)t = \partial_j \partial_i f(a+ \theta e_i + \lambda e_j)t$$ for some $\lambda$ between $0$ and $t$. As such, $\Psi(h,t) = \partial_j \partial_i f(a+ \theta e_i + \lambda e_j) ht$. For $ht \neq 0$, we have $$\partial_j \partial_i f(a+ \theta e_i + \lambda e_j) =\frac{\Psi(h,t)}{ht} = \frac{ f (a+ h e_i + t e_j) - f(a + h e_i) - f (a+t e_j) + f(a) }{ht}$$ Hence $$\begin{aligned} & \partial_j \partial_i f(a+ \theta e_i + \lambda e_j) -\partial_j \partial_i f(a) \\ = \quad& \frac{ f (a+ h e_i + t e_j) - f(a + h e_i) - f (a+t e_j) + f(a) }{ht} - \partial_j \partial_i f(a) \end{aligned}$$  It follows from the continuity of $\partial_j \partial_i f$ at $a$ that $$\forall \delta >0, \exists\epsilon >0, \forall (|h|+|t|<\epsilon): \|\partial_j \partial_i f(a+ \theta e_i + \lambda e_j) -\partial_j \partial_i f(a)\| < \delta$$  As such, for all $h,t \in \mathbb R \setminus\{0\}$ such that $|h|+|t|<\epsilon$, we have $$\left \| \frac{ f (a+ h e_i + t e_j) - f(a + h e_i) - f (a+t e_j) + f(a) }{ht} - \partial_j \partial_i f(a) \right \|  <\ \delta$$  Taking the limit $t \to 0$, we obtain $$ \lim_{t \to 0}\left \| \frac{ f (a+ h e_i + t e_j) - f(a + h e_i) - f (a+t e_j) + f(a) }{ht} - \partial_j \partial_i f(a) \right \|  \le\ \delta$$ and consequently $$ \left \|\lim_{t \to 0} \frac{ f (a+ h e_i + t e_j) - f(a + h e_i) - f (a+t e_j) + f(a) }{ht} - \partial_j \partial_i f(a) \right \|  \le\ \delta$$ and consequently $$ \left \|\frac{1}{h}\lim_{t \to 0} \left( \frac{ f (a+ h e_i + t e_j) - f(a + h e_i) }{t} +\frac{ f (a+t e_j)- f(a)}{t} \right) - \partial_j \partial_i f(a) \right \|  \le\ \delta$$ and consequently $$ \left \|\frac{1}{h} \lim_{t \to 0} \frac{ f (a+ h e_i + t e_j) - f(a + h e_i) }{t} + \frac{1}{h} \lim_{t \to 0}\frac{ f (a+t e_j)- f(a)}{t}  - \partial_j \partial_i f(a) \right \|  \le\ \delta$$  It follows from the existence of $\partial_j f$ in a neighborhood of $a$ that $$\lim_{t \to 0} \frac{ f (a+ h e_i + t e_j) - f(a + h e_i) }{t} = \partial_j f (a+he_i)$$ and $$ \lim_{t \to 0} \frac{ f (a+t e_j)- f(a)}{t} = \partial_j f (a)$$  As such, $$\left \|\frac{\partial_j f (a+he_i) - \partial_j f (a)}{h}  - \partial_j \partial_i f(a) \right\| \le \delta$$  For all $\delta >0$, there is $\epsilon >0$ such that for all $|h| < \epsilon$, the last inequality holds. It follows that $$\lim_{h \to 0} \frac{\partial_j f (a+he_i) - \partial_j f (a)}{h} = \partial_j \partial_i f(a)$$  Hence $$\partial_i \partial_j f(a) = \partial_j \partial_i f(a)$$


$g(x+y)=g(x)g(y)$ for all $x,y \in\mathbb{R}$.   If $g$ is continuous at $0$, prove that $g$ is continuous on $\mathbb{R}$.


Is this a valid way to assign a random number to a variable?

I have seen a lot of different ways to generate random numbers in between a certain range.  Just today I came across the following piece of code. but upon doing research, I did not see anybody describe it this way.  Random ran = new Random(); int j = ran.nextInt(5+10);   My question is, does the code above assign a random integer to j between the numbers of 5 and 10?  If so, what if you wrote the second line of code like this int j = rgen.nextInt(10+5);


Can a surjective function $f: \mathbb N\to \mathbb N $ be not injective?  Hi; I've been breaking my head over this simple question since last night. It's actually a small sub problem (of a simple Analysis Question) to what I'm trying to solve but essential to me solving it.  At first I thought it can not be.  For example, say there is an infinite number of $ n \in \mathbb N $ that map to some x and an infinite number that doesn't.   But then, wouldn't the first have to be finite?   Because, for example if I were to arrange that first infinite subset on a line and say that all other terms that "hit" every other $n \in \mathbb N $ come afterwards then we'd never get to the other ones.  Are they there?  I apologize if this doesn't make a lot of sense.   I'm quite confused by all the scenarios that I can think of. It (the feeling of wonder) makes me excited and kind of happy, but also quite helpless.  I appreciate any tip to guide my thinking in the right direction. Cheers


How do I get the total size of everything in a directory in one line?

I know I can use du -h to output the total size of a directory. But when it contains other subdirectories, the output would be something like:  du -h /root/test  . . . . 24K   /root/test/1 64K   /root/test/2 876K  /root/test/3 1.1M  /root/test/4 15M   /root/test/5 17M   /root/test   I only want the last line because there are too many small directories in the /root/test directory. What can I do?


What is the difference between “home” and “house”?

Can you explain more?  I do not know when we can use them in the sentence.  Can we use them instead of each other?     They have a beautiful home.   They have a beautiful house.


This might sound silly but I come from a place where we would typically have to buy bottled water or boil tap water to drink, so now that I'm spending 5 weeks at a Yale dorm, is it safe to drink from the taps here (specifically in the dorms)? Also, I don't see any bottled water station with 20 litre bottles and dispensers to drink from, so I assume the college expects the students to drink from the taps (I've read various sources that it's safe to drink from most US taps) or go out and buy a bottled water.   One thing I noticed is that it does taste a little bleachy, but that might just be me.  EDIT: The dorm's sinks themselves don't look too clean and also it is a collection of pretty old buildings (at least on the outside, the inside does look more modern though). Pipes that are not behind walls in some areas have been covered in paint, so it's hard to tell whether it's prone to lead leaks or not. Doubt I could carry out a lead concentration level test either.


I'm trying to check a box using jQuery. I've looked at some of the answers on this site but none of them worked (or I'm doing it wrong).  Here is the DOM  <input type="checkbox" id="ckbx_81861252,uFT1" name="memberIds" class="memberIds" value="81861752,uGT2">   When I click the box on the page, I don't see anything being updated in the DOM. Can anyone explain why? Or maybe I'm just missing it?  I tried both using .prop & .attr but neither checked the box.   Any help would be appreciated!


How to add Contract History related list on visualforce page?   I have tried: History, Histories, ContractHistories, ContractHistory, ServiceContractHistories, ServiceContractHistory  What is the exact child relationship name for Contract History?


Invalid label on a non-favorited question's favorite button

The label on the favorite star is invalid if the question is not marked as favorite.


I have jQuery code which is never executed. When I'm trying the same code in the browser console it works, so I don't understand why my code is never executed.  HTML CODE :
      {$valeur}
          {foreach $reponse as $ligne}              <input type="radio" name="answers" id="answer_{$ligne@iteration}" value="{$ligne@iteration}"/>$ligne
          {/foreach}

   Update :   document.addEventListener("DOMContentLoaded", function() {   setTimeout(function(){     $.post(ajax_path+"bla.php", {} , function(response) {           $('#quest').html(response);           $('#quest').collapse("show");     })     .fail(function(jqXHR, textStatus, errorThrown) {         {/literal}         toastr.error(__['Error'], __['Error']);         {literal}     });   }, 50);    $('input[name=answers]').on('change', function () {       $(this).closest("form").submit();     }); });


Is it safe to write dynamic PDO scripts for SQL queries

I'm new to working with databases and am attempting to write my own handler for my databases. I have a PHP file containing a class with variables and functions to handle it. This file is then imported to the project needing to access the database in whatever way. In the project the data handler is created as an object then variables are set to tell the object the server name, user, password and database name. Once that data is defined then a function can be called with all the necessary data to build the query, including the table name and such.  I originally tried inserting all data as parameters IE:  $stm = $pdo->prepare("UPDATE ? SET ? = ? WHERE ? = ?");   However, this does not work so I end up with this:  $stm = $pdo->prepare("UPDATE $table SET $records = ? WHERE $compare = ?");   I process the $table, $records, and $compare variables so they only contain alpha-numerical characters, underscores and commas. Also I have set this file to where only the server can access it. I know that the whole purpose of the prepared statement is to prevent user input from entering the query string to fight injection, so is this considered safe practice? With the programming knowledge I already have this seems sound. The functions are inside a class so an attacker shouldn't be able to just call my include file and run their own input. The data is sent to this file from a server-side PHP script and is never touched by the user in any way.  Is this considered a safe practice? Or is there something else that I need to do in order to safe guard this, or just scrap this all together?  Clarification:  In this article: () it states the reasoning for whitelisting the tables and columns is to prevent users from being able to input their own data. To the best of my knowledge I have done that. The only way I see a user being able to do so is for them to either upload a script to my server to access it, or on theirs but their server will not have rights to the file. On top of that, the file that holds this coding has no server or database information on it (ie: no username, password or database name). The way I see it, if they are able to use this script, they already have full access to my server and I have bigger concerns.


Solve Euler Project #9 only mathematically - Pythagorean triplet

The "Euler Project" problem 9 () asks to solve:  $a^2$ + $b^2$ = $c^2$ a + b + c = 1000  I find answers solving it with brute-force and programmatically, but is there a way to solve the problem ONLY mathematically? Can someone help, please?  Problem as explained in Project Euler website:  A Pythagorean triplet is a set of three natural numbers, a < b < c, for which,  a^2 + b^2 = c^2 For example, 3^2 + 4^2 = 9 + 16 = 25 = 52.  There exists exactly one Pythagorean triplet for which a + b + c = 1000.  Find the product abc.


I have a Canon iP1600 connected wireless through Win system laptop, I just can't install the printer although I've googled and tried various ways recommended. I'm at my wit's end!


How should ambiguous tags be dealt with?

If tag "foo" refers to two or more different technologies or concepts is it better to retag the less common usages or is it better to add additional tags to disambiguate?  My particular issue is with the  tag which mostly refers to the  but could also refer to the  programming language & software platform. Is it better to retag the Curl language questions as  (any other suggestions?) or add some other tag such as "language"?


Consider:     This book provides a solid psychological understanding of these experiments, and adds a few expansions and conclusions of its own. It also provides …   My question regards the comma. I have been told that having the comma there is an error.  According to  this seems to be the case according to “some style guides”. The reason is that the stuff after the comma is not independent; it’s dependent on what comes before.  What do you think? It would seem to me the comma helps a lot, because those two “and”s without any comma make the sentence rather cluttered. That’s why I put the comma there. So I’m not sure.


It seems some long well thought out answers receive a very low vote count:     On the other hand, here   Jeff's witty, and grossly incorrect comment got him 66104 upvotes, for a response that probably took him 5 seconds to come up with.    Should I not bother answering complex questions which require lots of work to answer?   Why do long well thought out answers result in negative reputation while short snappy ones get all the rep?  EDIT:  So people do not think I am singling out Jeff, here is a bigger list:   Is it wrong to go to interviews while employed?    306 135 What's the difference between JavaScript and Java?     144 108 How do I move the turtle in LOGO?     196 102 How to check if a number is a power of 2   446 97 How do I calculate someone's age in C#?     480 89 I don't like this... Is this cheating the language?    370 81 Why do some websites add "Slugs" to the end of URLs?    372 70 Why do people have trouble learning recursion?     428 68 What's the difference between JavaScript and Java?     400 65 Why Windows 7 isn't written in C#?     162 65 Why does every man and his dog want to code a blogging engine?     140 63 What annoys you as a programmer?    124 56 Do you use "kibibyte" as a unit of measurement in your programs?   66  56 The Programmer's Bill of Rights    472 54 Big-O for Eight Year Olds?     452 54 Can you code while drunk?      254 52 Do you prefer "if (var)" or "if (var != 0)"?   368 50 What is the opposite of 'parse'?   94  49 Database-wide unique-yet-simple identifiers in SQL Server      486 48 How many lines of code is too many?     164 48   Query:  select top 20 ' - ' + q.Title ,'https://stackoverflow.com/questions/' + cast(q.Id as varchar(max)) , datalength(a.Body),     cast(a.Score as varchar) From Answers a  join Questions q on a.ParentId = q.Id and q.IsWiki = 0 where datalength(a.Body) < 500 order by a.Score desc   And for even more enjoyment, here is a list of Marc's longest 20 answers, the most votes he got from a long answer is 9 next up is 4, but the avg is probably around 2.    Deserialization Error: The XML element 'name' from namespace '' is already present in the current scope.   13466   2 Data binding dynamic data      11614   2 How do you implement Pipes and Filters pattern with LinqToSQL/Entity Framework/NHibernate?     11456   3 What's the way to implement Save / Load functionality?     10818   4 Wait for pooled threads to complete.   10754   1 How can I write a generic container class that implements a given interface in C#?     10570   9 TypeDescriptor.GetProperties(thisType) to return properties, which are write-only      9976    3 C#/winforms: how to best bind a propertygrid and a System.Data.DataRow     9878    1 How can I add my attributes to Code-Generated Linq2Sql classes properties?     9456    1 Why does WPF support binding to properties of an object, but not fields?   8552    1 Using the .NET collection editor without using a property grid control     8244    3 Expose a collection of enums (flags) in Visual Studio designer     7598    1 Delphi to .NET + C#    7526    3 MonthCalendar.SelectionRange databinding example   7516    1 .Net Property Grid. Is there a way to let the Grid manipulate object in different way      7372    2 In LINQ to SQL, how do you pass pass parts of a LINQ query into a function     7180    4 DataGridView Binding   6994    3 String.Join vs. StringBuilder: which is faster?    6834    4 LINQ to SQL query against a list of entities   6746    3 Better way to do this LINQ to XML query?   6728    1   Query:  select top 20 ' - ' + q.Title ,'https://stackoverflow.com/questions/' + cast(q.Id as varchar(max)) , datalength(a.Body),     cast(a.Score as varchar) From Answers a  join Questions q on a.ParentId = q.Id and q.IsWiki = 0 where a.OwnerUserId = 23354 order by datalength(a.Body) desc


Cannot connect to repository Ubuntu 20.04

Freshly installed ubuntu. Did the normal installation and unchecked the third party apps. Now when I try to install apps using the repository or update it I get this error. sudo apt-get update Hit:1 http://security.ubuntu.com/ubuntu focal-security InRelease                Err:2 http://in.archive.ubuntu.com/ubuntu focal InRelease                         Cannot initiate the connection to in.archive.ubuntu.com:80 (2403:8940:ffff::f). - connect (101: Network is unreachable) Could not connect to in.archive.ubuntu.com:80 (103.97.84.254), connection timed out Err:3 http://in.archive.ubuntu.com/ubuntu focal-updates InRelease   Cannot initiate the connection to in.archive.ubuntu.com:80 (2403:8940:ffff::f). - connect (101: Network is unreachable) Err:4 http://in.archive.ubuntu.com/ubuntu focal-backports InRelease   Cannot initiate the connection to in.archive.ubuntu.com:80 (2403:8940:ffff::f). - connect (101: Network is unreachable) Reading package lists... Done W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/focal/InRelease  Cannot initiate the connection to in.archive.ubuntu.com:80 (2403:8940:ffff::f). - connect (101: Network is unreachable) Could not connect to in.archive.ubuntu.com:80 (103.97.84.254), connection timed out W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/focal-updates/InRelease  Cannot initiate the connection to in.archive.ubuntu.com:80 (2403:8940:ffff::f). - connect (101: Network is unreachable) W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/focal-backports/InRelease  Cannot initiate the connection to in.archive.ubuntu.com:80 (2403:8940:ffff::f). - connect (101: Network is unreachable) W: Some index files failed to download. They have been ignored, or old ones used instead.  I also have only these in the Software and Update setting. Please help!


What is the Right Way™ to run a minecraft server?

I want to run a minecraft server on Ubuntu 12.04 server in a maintainable and secure way. I know about creating an own user for minecraft to avoid running as root. I know about using screen to be able to detach from the session without the server stopping.  Still, this all seems like patchwork, as opposed by say... a mysql server that will automatically update when there are security fixes, that will automatically start on boot etc etc.  So, since there are a bunch of servers out there and probably some smart people wanting the same thing, are there any cleaner/more beautiful/more elegant ways of packaging/running a minecraft server on let's say a 12.04 VRoot Server?  I have seen this question:      This seems very unmaintainable, and if my server reboot for whatever reasons I have to manually start it again. That's why I would prefer something cleaner.  If not, why not? ( <-- this is obviously just to satisfy my curiosity)


I am using Ubuntu 13.04. The browsers I am using are Firefox and Google Chrome.  Now I want to download videos from . Accordingly I've tried some extensions in Firefox and Chrome. But no luck, the connection is being disrupted before the completion of the downloads.  Any suggestions of best downloader of videos from various sites including Youtube?  Thanks


I purposely changed my display name, but now I want to change it back to what it was.  I tried to change it back myself, but I got this error message:     Display name may only be changed once every 30 days   NOOOOOOOOOOOOOOOOOO! Fine, prevent people from changing their name every day, but at least let them change it back!  Also, I think you should warn users before they perform an irreversible action!


What is the use of percent signs (%) at the end of lines? (Why is my macro creating extra space?)

I see that the code in many packages and examples contains percent signs % at the end of (many) lines. What are they used for? Do they affect the parsing of those lines?


Identify the graph that shows the region $x\ge 5$ and $y\ge 5$

I draw the equation in  wolframalpha.com but I don't know how can determine correct answer please I really need help to understand the difference:


I am currently studying for the GRE math subject test, which heavily tests calculus. I've reviewed most of the basic calculus techniques (integration by parts, trig substitutions, etc.) I am now looking for a list or reference for some lesser-known tricks or clever substitutions that are useful in integration. For example, I learned of this trick   $$\int_a^b f(x) \, dx = \int_a^b f(a + b -x) \, dx$$  in the question    I am especially interested in tricks that can be used without an excessive amount of computation, as I believe (or hope?) that these will be what  is useful for the GRE.


Why is there no Stack Exchange community about law?


How do I reverse my cake-like brownies to chewy?

I'm making brownies for the first time, so I went with cake-like but everyone wants chewy. I agreed but realized it was too late. They're already in the oven, how do I fix it to chewy?


In Dead 7, Carrie and other movies, there have been some scenes where an artery has been severed and an open wound is visible causing an artierial spray coming from inside the wound.  I am sure this may be CGI or whatever, and for the wound, I have no idea, but there doesn't seem to be any fake blood tubes coming from the area of the spray.  The blood just squirts and squirts. In Dead y, Apocalypta slits a mans throat when he wants to join her and it results in arterial spray.   Also in an episode of The walking dead where the cannibals have got hold of some survivors, they slit the survivors throats over a trough, resulting in arterial spray.  How is this filmed?


Let  $f:[0,1]\to \mathbb{R}$, $f(x)=0$ if $x\not\in \mathbb{Q}$ and $f(x)=\frac{1}{q}$ if $x=\frac{p}{q}$, $p,q$ coprime. $p$ integer, $q$ natural.  I want prove that $f$ is Riemann integrable.  I have a doubt. Let $P=\left\{\frac{1}{n},\frac{2}{n},\ldots, \frac{n-1}{n},1\right\}$ a partition.  Now, $U(f,P)=\frac{1}{n}\sum_{i=1}^n M_i=\frac{1}{n} \sum_{i=1}^n\sup\left\{f(x): x\in [\frac{i-1}{n},\frac{i}{n}]\right\}=\frac{1}{n} \sum_{i=1}^{n} \frac{1}{n}=\frac{1}{n} n\frac{1}{n}=\frac{1}{n}\leq \epsilon$ with $n\to \infty$. Therefore $\inf_{P} U(f,P)=0.$  It is correct?...


What is and how do you visit the community wiki

I have never used the community wiki and just want to know what it is and how I get onto it.


Notifications for edits by others of my own questions and answers?

I'd like to be more aware of when other SOpedians edit my own questions and answers, which is sure to happen because my innate spelling and grammar skills are  overloaded by my vocabulary and lackadaisical proofreading habits.  That said, I would like to review edits to my posts to ensure the basic content has not changed.    What do folks think of this?  EDIT:  So, apparently there is the revisions tab, which I had not seen.  But revisions are not in the summary page, which I'd like to see.


I want to print this text :  make -j 5 KDEB_PKGVERSION=1.yourcustomname deb-pkg  But I feel because of the underscore , LaTeX generates an error missing $ inserted and it doesn't print it as well.  Secondly, In the \fbox{} , I wanted to print the two texts on the next line(i.e) one text per line , so I used \ and even \par but it doesn't seem to work and I would like to align the (or) as well.   \fbox{\texttt{uname -a}\\(or) \texttt{cat /proc/version}}   Here is my full source code:  \documentclass[12pt]{article} \author{Subham Soni S.} \date{\today} \title{Compiling and Installing a Kernel 3.13.3 On Ubuntu, Debian and its Derivatives} \begin{document} \maketitle To replace the existing \textsl{kernel} with a new one, do the following: \begin{enumerate} \item Create a folder named \emph{kernel} in the home directory. \item Download the latest kernel to the folder from  \texttt{www.kernel.org}. \item Extract the file. \item In the terminal, type the following command to \textbf{install the neccesary tools to compile the kernel}:   \begin{center}     \fbox{\texttt{sudo apt-get install gcc libncurses5-dev dpkg-dev}}   \end{center} \item Enter the directory of the extracted kernel source   \begin{center}     \fbox{\texttt{cd kernel} \par \texttt{cd linux-3.13.3}}   \end{center} \item Configure the kernel   \begin{center}     \fbox{\texttt{make menuconfig}}   \end{center}   In this menu you can customize your kernel \item Save and exit \item Compile the kernel   \begin{center}     \fbox{\texttt{make -j 5 KDEB_PKGVERSION=1.yourcustomname deb-pkg}}   \end{center}   \emph{This process might take a while...} \item Install the kernel   \begin{center}     \fbox{\texttt{sudo dpkg -i ../linux*.deb}}   \end{center} \item Reboot   \begin{center}     \fbox{\texttt{sudo reboot}}   \end{center} \item Run the following commands to check the kernel version   \begin{center}     \fbox{\texttt{uname -a}\\(or) \texttt{cat /proc/version}}   \end{center} \item You can easily uninstall the kernel with the command:   \begin{center}     \fbox{\texttt{sudo apt-get purge linux-image-3.13.3 linux-image-3.13.3-dbg}}   \end{center} \end{enumerate} \end{document}


breadth first search java.lang.NullPointerException

i was coding a puzzle program. When i compiled my Java program, it was successful. But when i run it, it shows   Solution to problem using breadth first : Exception in thread "main" java.lang.NullPointerException  at SolvingProblem.isGoal(SolvingProblem.java:24) at AbstractTreeSearch.solve(AbstractTreeSearch.java:31) at EightP.main(EightP.java:15)   I spent several hours and fixing the code but unsuccessful. Ideally, it is supposed to show 3x3 array configuration. Could anyone help me here and point out what is the problem?  State initialState = new State(State.arrayA); State GoalState = new State(State.arrayG);  @Override public Object getInitialState() {     return initialState; }  @Override public boolean isGoal(Object state) {     return state.equals(GoalState); }   Another class below    public Node solve(Problem problem) {      //initialize the search tree using the initial state of problem     frontier = initFrontier();     frontier.addAll(expand(new Node(problem.getInitialState()), problem));     //Starting frontier     boolean done = false;     Node solution = null;     while (!done) {         if (frontier.isEmpty()) {             System.out.println("Blank frontier");             done = true;         } else {             Node node = chooseLeafNode(frontier, problem);             //inspecting node             if (problem.isGoal(node.getState())) {                 System.out.println("Solution found");                 System.out.println();                 solution = node;                 done = true;             } else {                 //Expanding node, frontier is..                 frontier.addAll(expand(node, problem));              }         }     }


Is the word "film" considered an umbrella term for movies, tv-series etc. or is it only used when referring to movies?


Values aren't correctly being assigned to array, (basic)

public class Main { public static void main(String[]args) {      int[] array = new int[10];      for (int i= 0; i < array.length; i++) {         array[i] = i;      }     System.out.println(array); } }   Why is the output "[I@677327b6"? I am just trying to assign values to an array. I know this is a very basic question, however, I've been struggling to find the answer. Thanks for the help!


Sometimes when I google something, I notice that some websites are shown with some several pages as results. Like in the picture here :    Does anyone know how to get such results on google search please ? What should I add to my web site to get it appear like this ?  I have been looking on rich snippets but I'm not sure it's this.  Thanks


Group of order 40 with 5 subgroups of order 8

Would $Z_{40}$ be an example, or the dihedral group $D_{2n}=D_{40}$ work? And how do we obtain the subgroups of $D_{40}$?


sed Argument List Too Long While Updating JSON

I've a JSON property which needs to be updated with base64.  The flow is:  prop_val=`base64 --wrap=0 < $prop_txt` sed -i 's@"property_specific": ""@"property_specific": "'"${prop_val}"'"@g' $final_json   It errors out with: line 22: /bin/sed: Argument list too long  The base64 string (single line) is very long. How else can I update the property w/o sed?  Note: the double quotes in format.  Update:   Created place holder unique string, to remove double quotes complexity. Tried sed -f; didn't work.   Tried:       sed -i -f - $final_json << EOF; 's@placeHolder123456@'"${prop_val}"'@g'; EOF   Error:  line 27: warning: here-document at line 23 delimited by end-of-file (wanted `EOF') line 28: syntax error: unexpected end of file   Tried placing it in a function to avoid EOF error, but it didnt work. Function:  update_prop_specific() {     sed -i -f - $1 << EOF     s@placeHolder123456@$2@g     EOF }   Suggestions?


How do I open the user folder of a hard drive that I transfered?

My Windows 10 notebook died but fortunately I was able to rescue the hard drive and put it into another PC.   Unfortunately, the other PC can't open the C/Users/Joe folder. What do I have to do to open the folder?


Background :  I used ffmpeg to merge two videos side by side. First I install ffmpeg by following command as it suggest by Ubuntu itself.  sudo apt-get install libav-tools   or   sudo apt-get install ffmpeg   But then I realize it is not the correct version since it doesn't support for -filter_complex and few other functions.   After a few hours researcher I found  and I succeed with video conversion as well. As per that article, it is suggesting we need to build it our own.        Question :  What is easiest way to install that ffmpeg version (which is support for -filter_complex ) without following all those steps ?


Material are not being applied to the model

I'm new to blender and hit a bug probably.  I checked the material/texture/rendered view but the material is not being applied. I also created a new project and tested with a simple cube and tried the voronoi texture. The texture doesn't seem to work while I successfully applied bevel. I have checked the documentation and saw some tutorials and the followed the same steps as the videos but the material won't work.  EDIT:  OS is Ubuntu 16.04 LTS.  Using cycles render, it didn't work in blender render either. I was using 2.76 when I posted the question upgraded to 2.79 and the issue persists.  I assume material will be applied when I left click or press enter by selecting a certain material. Here's a screenshot


Using Minim library in Java. Couldn't get the helper class working

I'm using the Minim 2.2.0 library with JAVA.  The library requires us to define a helper class defining two methods and pass an object of this class to the Minim constructor. I wrote the MinimHelper class as follows.  public class MinimHelper {     String sketchPath( String fileName ) {         return "C:\\Users\\Martin\\Downloads\\"+fileName;     }      InputStream createInput(String fileName) {         InputStream is = null;         try{             is = new FileInputStream(sketchPath(fileName));         }         catch(Exception e){             System.out.println(e.toString());         }         return is;     } }   And I wrote my main as follows  public class Main {     public static void main(String[] args) {         // TODO Auto-generated method stub         AudioPlayer player;         Minim minim = new Minim (new MinimHelper());         player = minim.loadFile("Butterfly.mp3");         player.play();     } }   However, I'm getting the following error in the console.  ==== JavaSound Minim Error ==== ==== Couldn't find a sketchPath method on the file loading object provided! ==== File recording will be disabled.  ==== JavaSound Minim Error ==== ==== Couldn't find a createInput method in the file loading object provided! ==== File loading will be disabled.  ==== JavaSound Minim Error ==== ==== Error invoking createInput on the file loader object: null  Exception in thread "main" java.lang.NullPointerException     at ddf.minim.javasound.JSMinim.getAudioRecordingStream(Unknown Source)     at ddf.minim.Minim.loadFile(Unknown Source)     at ddf.minim.Minim.loadFile(Unknown Source)     at Main.main(Main.java:9)   Please tell me where I'm doing wrong.


Should I use singular or plural after one or more?  Example:      One or more [signal/signals]


how to find the installing path of some install application?

I install (using the terminal setup command) Visual Studio Code.  I can run it (by clicking on the icon on the 'all programs')  but I can't find the installation path of it.    I want to run it using sudo and I need to navigate to the installation path to use the terminal and call sudo visualStudioCode and I can't find it. (Try to use the 'find', but I can't find it.)   How can I create a shortcut of this sudo visualStudioCode on the Ubuntu desktop?


Can light be launched outwards from an event horizon?

There's something which I don't quite get about black holes and event horizons (feel free to tell me if I got something completely backwards at any step along the way):  Say we have a singularity and we launch a particle from the singularity's Schwarzchild radius R at the speed of light directed outwards from the black hole - wouldn't that particle be able to escape beyond R, slowly decelerating in a parabolic path to a halt somewhere outside it (at a radius of, say, R1)?  If so - wouldn't an observer A between R and R1 be able to see that particle as it decelerates? And if so, we couldn't define the event horizon to be at R, because light from R can affect A who's outside it. We couldn't define the event horizon to be at R1 either, because light from the observer could escape R1 entirely.  So where would we define the event horizon in the case presented above? How can there be an event horizon if light can be launched slightly below it and take an parabolic path outside it, even if only for a moment?


Limit of product with cubes $\lim\limits_{n \to \infty}\frac{2^3-1}{2^3+1}\frac{3^3-1}{3^3+1}\dots\frac{n^3-1}{n^3+1}$

I am trying to evaluate $$\lim\limits_{n \to \infty}{2^3-1 \over 2^3+1}{3^3-1 \over 3^3+1}\dots{n^3-1 \over n^3+1}$$ It seems to be the perfect candidate for a factoring formula, however, I get stuck rewriting the fractions. Do you have any suggestions?


Trouble with complex fractions and parentheses

I'm having trouble finding a way to express this fraction with the amsmath package.    The result I'm getting isn't quite nice. Are there alternative ways to write this fraction?     \documentclass[10pt,norsk, fleqn]{extarticle}  \usepackage[a4paper, margin=1.2cm,includeheadfoot]{geometry}  \usepackage{amsmath}   \begin{document}   $\displaystyle\frac{a}{\displaystyle\frac{b}{\displaystyle\frac{c}{\displaystyle\frac{d}{e}}}}\to\left(\displaystyle\frac{\left(\displaystyle\frac{\left(\displaystyle\frac{\left(\displaystyle\frac{a}{b}\right)}{c}\right)}{d}\right)}{e}\right)$   \end{document}


You will take in a 5 digit lottery number and compare it to a winning lottery number.   If the input lottery number has a certain numbers correct you will tell the user how much they have won.   You should follow these steps:  1.Declare 2 5 element integer arrays. (a) One should be for the winning lottery number (hard code this as 12, 35, 34, 2, 5). (b) The other should be for the user’s lottery number input.  2.Declare an integer to count the number of matching lottery numbers.  2.Declare an integer to count the number of matching lottery numbers.  3.Prompt the user to enter their 5 digit lottery number using a for loop and put their numbers in the user’s lottery number array.  4.Compare the elements of the two arrays using a for loop and increment the counter variable declared above when there is a match.  Using the value held in the counter variable, display how much the user has won.  (a) 0 matching numbers: $0  (b) 1 matching number: $1  (c) 2 matching numbers: $50  (d) 3 matching numbers: $1,000  (e) 4 matching numbers: $50,000  (f) 5 matching numbers: $90,000,000  I have the code below so far:  public static void main(String[]args){      final int [] HardCoded = {12, 35, 34, 2, 5};     int UserInput [] = new int[5];      Scanner input = new Scanner(System.in);      System.out.println("Please enter 5 Numbers. ");      System.out.print("Numbers [0]: ");     UserInput [0] = input.nextInt();      System.out.print("Numbers [1]: ");     UserInput [1] = input.nextInt();      System.out.print("Numbers [2]: ");     UserInput [2] = input.nextInt();      System.out.print("Numbers [3]: ");     UserInput [3] = input.nextInt();      System.out.print("Numbers [4]: ");     UserInput [4] = input.nextInt();      System.out.println("Lottery Numbers are: " + HardCoded);      }  }   However, the issue is that the hardcoded value will not print and int UserInput [] = new int[5]; has to be 4 but i get an error so i have to put in 5?


When taking landscape photos, I often struggle with dynamic range. I have either a burned out skies or landscapes are too dark.  Now I'm reading  that some cameras can take 3 pictures with different exposures, and combine them automatically to one image with higher dynamic range.   So my question is, which cameras have this feature?


Given the complete source code below, please explain why every execution of this program in Eclipse results in time in do1() greater than time in do2() by 2~3 milliseconds.  Does the JVM need to "warm up"?  import java.util.concurrent.atomic.AtomicInteger; import java.util.stream.IntStream;  public class Question {     public static void main(String[] args) {         do1();         do2();     }      public static void do1() {         O obj = new O();         Thread t = new Thread(() -> IntStream.range(0, 100000)                     .forEach(e -> obj.incrementN()));          long start = System.currentTimeMillis();          t.start();          try {             t.join();         } catch (InterruptedException e1) {          }          float time = (System.currentTimeMillis()-start)/1000F;          System.out.println(time);         System.out.println(obj);         System.out.println();     }      public static void do2() {         O obj = new O();         Thread t = new Thread(() -> IntStream.range(0, 100000)                     .forEach(e -> obj.incrementN()));          long start = System.currentTimeMillis();          t.start();          try {             t.join();         } catch (InterruptedException e1) {          }          float time = (System.currentTimeMillis()-start)/1000F;          System.out.println(time);         System.out.println(obj);     } }  class O {     private AtomicInteger n = new AtomicInteger(0);      public void incrementN() {         n.getAndIncrement();     }      @Override     public String toString() {         return ""+n.get();     } }   Sample output:  0.003 100000  0.001 100000


Does a hole have a spin? If yes, how to determine its direction?

It is easy to understand that a hole is opposite to an electron in semiconductors. However electrons have spins, up and down, does hole have a spin? Furthermore, if a hole has its spin, how to determine the direction of spin?


Since we noticed that some user on our internal network use FTP client like FileZilla or WinSCP that store password as plain text, we wonder, is there any FTP client (windows) that store passwords in a "secure" way? Edit Also, we know that could use cerificate and SSH methods, but question is only about password storage.


Find center of mass and moment applied on beam structure.

I have a simple mathematical problem to solve but it is giving me a slightly difficult time to figure out. The problem:  I have a beam structure with same cross section. It consists of three beam. First in vertical with length 1meter. Second beam joined on top with a angle of 20degrees to the right with lenth 1.1meter and on top of the second beam, a third beam parallel to the ground with 1meter length.   I need to find the center of gravity and how much moment i have on the base of the structure so I would add a mass that would be sufficient to avoid the structure to fall over.   any ideas how?  thanks


Looking for the title of a story with a shoplifter gathering items for beings in another universe via a portal hidden in a bag

I'm looking for the title/author of a science fiction short story I read in an anthology many years ago. From what I remember the story involved a small portal to another universe being discovered inside the lip of a bag, perhaps a purse, when a shoplifter is caught putting items into the bag. The shoplifter seems to be unaware of what they're doing. The story involves scientists investigating the portal, believing that items are being taken in order to collect information about our world, and culminates in a tug of war of an iron bar or some such passing through the portal. The implication that the side winning the tug of war eventually puts stress on the loser's universe in some catastrophic way.


Why do I get "Required key not available" when install 3rd party kernel modules or after a kernel upgrade?

This issue happens only on UEFI systems with enabled Secure Boot.  When I try to install DKMS modules like VirtualBox, Nvidia, or Broadcom drivers, they do not install and I get Required key not available when I try to modprobe them.  VirtualBox complains that vboxdrv is not loaded.  Broadcom wl driver is shown in lspci -k as a kernel module but is not in use. sudo modprobe wl throws Required key not available.  Also this issue may happen when I install some kernel modules from git sources.  This issue may appear after a kernel update as disabled wireless adapter, black screen after a reboot, etc.   How can I fix it?


RegEx for matching a number greater than 9?

How to put a number greater than 9 to regexp character set?  For example, I can do ^[01236]$, but what if I want to put 100 as an option to the set?   How do I solve this problem?


How to derive this version of variance formula

A probably very easy computational question, but I don't really understand how it's done:  I try to compute the point estimates of a normal distribution as $N \sim (\beta, \sigma)$. Using the method of moments, we get:  $$\frac{1}{n} \sum_{i=1}^{n} X_{i} = \hat{\beta}$$  $$\frac{1}{n} \sum_{i=1}^{n} X_{i}^{2} = \hat{\sigma}^2 + \hat{\beta}^2$$  Solving the two equations for the two parameters, we get:  $$\hat{\beta} = \overline{X} $$   and   $$\hat{\sigma}^2 = \frac{1}{n} \sum_{i=1}^{n} (X_{i} - \overline{X}_n)^2 $$  My question is: How do we get to the term of $\hat{\sigma}^2$? If I try to compute it, I get:  $$\hat{\sigma}^2 = \frac{1}{n} \sum_{i=1}^{n} X_{i}^2 - (\frac{1}{n} \sum_{i=1}^{n} X_{i} )^2 $$  Can someone show me how to simplify the last term to what is stated above and what "rule" or law" is used there? Since it is used so often, I really wanna understand this.


Ubuntu shows no wifi adapter , Archer T3U

I have this TP-Link Archer T3U AC1300 Mini Wireless MU-MIMO USB Adapter on my PC and I have it on dual boot , Wndows and Ubuntu 20.04, on Windows it works fine, but since last night Ubuntu shows no wifi adapter found. It was working fine earlier. I tried a few things I found on the web, but nothing worked for me. The command lsusb gives the following output: Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 001 Device 007: ID 2357:012d TP-Link 802.11ac NIC Bus 001 Device 003: ID 0489:c022 Foxconn / Hon Hai Nokia 7.1 Bus 001 Device 006: ID 04d9:1203 Holtek Semiconductor, Inc. Keyboard Bus 001 Device 005: ID 046d:c24c Logitech, Inc. G400s Optical Mouse Bus 001 Device 002: ID 1b1c:0c09 Corsair H100i v2 Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub


I've modeled some interiors and lighted them with a simple area light. I'm currently trying to bake the lighting to a lightmap that I can then import into Unity3D Free Version (which doesn't have very good lighting for interiors, and that's why I'm making the lightmaps on blender). However, the baked lightmap seems to be poor in quality even though I made the texture 2048x2048. It's kinda hard to explain, but basically the gradients are choppy, as if the image was compressed. This is very subtle if I look at the lightmap itself on paint (albeit still visible), but the effect is magnified once the lightmap is applied to a colored material on unity3d:   My baking settings:


Can anybody help me how to export Repeater data to PDF file without using iTextSharp. I am generating PDF files from Repeater control using iTextSharp, it works properly but are there any other suggestions on how to export repeater data to a PDF document?


What movie was the first to feature onscreen zombie children?

The first zombie children I remember seeing in a movie were in Resident Evil. I may be wrong, but it seems unlikely to me that it was the first zombie flick to include them. What film was the first to feature onscreen zombified children?


We have learned that for universal set $U$ and  for set $A$ belonging to $U$, $A^c=U-A$ but what about for the empty set?


DVD won't play but CD'S will in my disc drive all drivers are installed still not working not sure on the problem is it is a new disc drive and worked fine on windows xp any and all help would be appreciated


what is the limit as $x$ approaches infinity of $x-\sqrt{x^2-x+2}$

$$ \lim_{x \to \infty} \left( x - \sqrt{x^2 - x +2 } \right) $$  I've tried rationalizing the expression but after repeated applications of L'Hospital's rule, it doesn't feel like I'm getting anywhere.


In the sentence, "I want an air-freshener because I can't stand bad smells", why is the because-clause a subordinate clause?

I want an air-freshener because I can't stand bad smells.  Here, isn't 'I can't stand bad smells' a coordinate clause? It is complete in itself, right? It's only after adding 'because' that the sentence becomes subordinate. But 'because' is a conjunction. So, if we want to check if a clause is coordinate or subordinate, shouldn't we exclude the conjunction ('because') here? Edit: Thanks to the people who have answered this question! Below, I am writing what I have inferred/concluded from all the answers. I request everyone, to inform if what I understood is correct or not.  subordinate clauses are necessary in the sentence to convey its full meaning, and that coordinate clauses are of greater value/importance than subordinate ones.  Coordinate and subordinate clauses can exist without the help of each other, and will make complete sense, but in order to convey the whole meaning of the original sentence, it is important to use them both.  Let's say in this sentence, both are making complete sense on its own, but coordinate clauses are more important. "I want a freshener" is more important than telling its reason. "I can't stand bad smells", which is the subordinate clause in this sentence, can stand alone, but it is of lesser importance in the original sentence.


Add one day to date string in javascript

I am setting the min of checkOut as the value of checkIn. My problem comes that i need to add one day to firstdate. (Should not be able to check out on or before the check in day.)  <script> function updatedate() { var firstdate = document.getElementById("checkIn").value; document.getElementById("checkOut").value = ""; document.getElementById("checkOut").setAttribute("min",firstdate); }   </script>  Check In <input type="date" id="checkIn" onchange="updatedate();" name="checkin">  Check out <input type="date" id="checkOut" min="" name="checkout">


Can I attack with two weapons in a single attack action with Extra Attack (not including any bonus action)?

Say my character is a 5th level monk with the Extra Attack feature and I am holding a dagger in one hand and a short sword in the other: Can I use the Attack action to swing the Short Sword with my first attack, throw the dagger with the second, and then use Martial Arts to make an Unarmed Attack with my bonus action?


I've to do some big works to my website, so I've to put it offline for some hours, but I don't want to lose my rank in google. I've read this tutorial:  This is the correct procedure, right?  I've also another question. Where should I put this code?  <?php header("HTTP/1.1 503 Service Temporarily Unavailable"); header("Status: 503 Service Temporarily Unavailable"); header("Retry-After: 3600"); php?>   In the index.php, ora in a new page named errorpage.php in the root? Google will find this automatically?  Thanks!


Can a holder of carta soggiorno travel to U.K. Without a visa With his spouse holding an Italian passport

please I'm confuse. I need your help. I want to find out if a carta soggiorno holder can travel to U.K. Without a visa whiles going with her spouse who holds Italian passport.


I now have a PCB with 64 UV LEDs on it and I use this to expose other PCBs. I have a serial resistor for each LED which produces a lot of heat and consumes about 1.3 A at 12 V.  I am now considering to make a bigger UV unit with twice the size of my current UV unit. I have searched on the internet how to drive this amount of LEDs but the only things I came across where ways to drive each LED individually.  I was thinking to make groups of LEDs (5 by example) and use one resister for each group of LEDs.  Are any other efficient ways to drive 128 LEDs without grouping the LEDs?


I want to install metasploit and armitage on my ubuntu 16.04 LTS laptop running kernel 4.6  I've read blogs and posts on how to install it but the problem is is that they are outdated. The packages are not there anymore and or the commands dont work.  If anyone can give me an updated tutorial on how to install it that would be great. I also think other users that see this post and want to install it will also be thankful. Thanks.


Minimize absolute values of errors instead of squares

Calculating absolute values is much more efficient than calculating squares. Is there any advantage, then, to using the latter as a cost function over the former? Squares are easier to treat analytically, but in practice that doesn't matter.


What does it mean to use a normalizing factor to "sum to unity"?

Would you also be able to provide an example? I have very little mathematical/statistical knowledge and have never understood normalization.


Can someone explain why the hint is useful? If $\mathcal{N}_{0}$ is the Skolem hull of $M$ and a countably infinite set of indiscernibles $\mathcal{I}$, my idea is to remove one element of $\mathcal{I}$ each time to create a new Skolem hull $\mathcal{N}_{i+1}$ generated by one less indiscernible element. The problem is that there may be a non-indiscernible element in every $\mathcal{N}_{i}$ that doesn't exist in $\mathcal{M}$ so the equality doesn't hold.  A hint or solution would be appreciated.


My question is a follow-up to one in which I identified stealing and killing in a particular sentence as gerunds. Bill J commented to the effect that if objects followed these gerunds, the latter became verbs.   My questions are why and what form of the verb? For me the grammatical distinction between “I dislike killing” and “I dislike killing sheep” is simply that the gerund complement in the first becomes a gerund phrase complement in the second.


Show that the equation has a natural solution

let $n$ be a natural number and $r$ , $s$ be rational such that   $n=s^2+r^2$  show that there are natural numbers a,b such that   $n=a^2+b^2$


when I use apt-get install on kubuntu-desktop ,I get an error like this:     E: Could not get lock /var/cache/apt/archives/lock - open (11 Resource   temporarily unavailable) E: Unable to lock the download directory   Why did this happene and how can I solve it? Thank you!


Reputation Activity in User Dropdown Incorrect/Inconsistent?

I hope this isn't a duplicate.  Similar questions that I found are over a year old.  I have seen cases where shortly after an upvote (perhaps on an old answer?), the summary in my user activity dropdown shows inconsistent counts:    Particularly, the Slid a div offscreen using jQuery answer shows +40, when it was only updated once yesterday.  Now, if this is a monthly total for this question, then it is correct, but when I refreshed later I got:    Now it shows +10, and other entries completely disappear.  So, what is this supposed to show me?  At the very least I am confused about what I am supposed to see here.  Here is another example:    This shows +20 for the same question as before, after I received a single upvote last night.  What gives?  You can see from my reputation that there was only a sinle upvote recently:


Idiom for the phrase "getting a good result from a bad situation or with a bad condition"?

Is there an idiom which expresses the idea of "getting a good result from a bad situation or with a bad condition"? Thanks!


Huge drop [50%] in traffic after HTTPS move

Currently look after 3 websites. I changed one of them to be HTTPS as it's ecommerce, however have seen a huge drop in organic traffic since this was implemented. Went from around 800 impressions to 400.   Any ideas as to why?   Very concerning as I expected it to improve if anything!  I set up 301 redirects to carry through to old pages to http://www.example.com/product1 would go to https://www.example.com/product1  I also set up a separate webmaster account for the HTTPs version as our integration wasn't working well with Google Merchant Centre, and data is flowing correctly but unsure why/if this would cause conflict.  Very confused!


How to manually install latest Pepper Flash onto Chromium?

I'm on 32 bit Lubuntu 16.04 and Chromium has the usual Flash version 11.2.9. A bunch of things won't play correctly so I've been trying to find a way to install Pepper Flash for a while and I'm not sure how to proceed.   I have the canonical repo enabled and I've tried installing PPAs in multiple ways--the package is always missing or there's no release file. Almost every online thread about this is from 2014 and I'm very new to Linux and very confused. And now the terminal is also on a loop when I use sudo apt-get update--it keeps trying to update & install ppa:skunk/pepper-flash which has no release file.  I have the latest tarball from Adobe. Could I extract it and manually install the Pepper Flash plugin as root? If so how would I do this? (I found a guide for this for Firefox but it didn't work out because it was majorly outdated.)  Forgive me if I'm missing something obvious, I have a headache. Thanks a bunch for any input.  EDIT: This got flagged as a duplicate but it's not--I was asking how to/if I could install via a tarball as root while the other question did not specify that this method was exactly what they needed info about. It is similar but not a duplicate.


Is insecure to give users permissions to apps in /opt?

I'm working with some apps (the best example i can give is Firefox Developer Edition) that i put in the /opt folder. These apps work perfectly until they need to apply and update, and that's because /opt is owned by root, and to write those apps in the /opt folder i use the sudo command when i unpack the apps. To "fix" this, my best solution was to chmod, chown and chgrp the apps (each app folder, no de /opt folder) to my user, and give permissions to users to write inside the apps folders:  [user@localhost /opt] $ ls -lah total 76K drwxr-xr-x. 19 root        root        4,0K dic 28 22:32 . dr-xr-xr-x. 20 root        root        4,0K nov 13 02:00 .. drwxrwxr-x   7 MyUser      MyGroup     4,0K nov 24 21:46 android-studio drwxr-xr-x  10 MyUser      MyGroup     4,0K dic 17 21:45 firefox-dev drwxrwxr-x   2 MyUser      MyGroup     4,0K dic 28 22:34 linux-wbfs-manager drwxr-xr-x.  5 MyUser      MyGroup     4,0K mar 25  2015 sublime_text_2 drwx------.  3 MyUser      MyGroup     4,0K dic  2 14:53 tor-browser_en-US drwxrwxr-x   4 MyUser      MyGroup     4,0K dic 17 19:28 WordPress.com   Now, i'm wondering if this a good practice or is insecure. Until now, i didn't have any problem, but i'm using browsers and other apps with network access.


What are the generators of $(\mathbb{R},+)$?

The real numbers as a group under addition are an infinitely-generated group. I'm not sure what those generators are though (or if it even makes sense to ask the question).  For example, could we say that the generators are $1, 0.1,0.01,\dots$ as a real number can be defined as a limit $\sum_i^n w_i 10^{-i}$ for some $w$?


I was told to use the iron dagger technique to level up my smithing fast  but I don't know what it is


Homology of quotient space of $S^2$ under the identifications $x \sim -x$ for $X$ in the equator $S^1$.

Apparently this question has been asked many times on here, but my question is more specific.  Let $X$ be the quotient space of $S^2$ under the identifications $x \sim -x$ for $x$ in the equator $S^1$. We are asked to compute the homology groups $H_i(X)$.  The method I chose is to use cellular homology. Give $X$ the following cell structure: one 0-cell $e^0$, one 1-cell $e^1$, and two 2-cells $e_1^2$ and $e_2^2$. The 2-cells are attached via the quotient projection of the boundary $x \sim -x$. In particular, the 0 and 1 skeletons are $\mathbb{R}P^0$ and $\mathbb{R}P^1$ respectively and the 2-cells are attached in the same way as in Hatcher's computation of the homology of $\mathbb{R}P^n$ using cellular homology.  The nontrivial part of cellular chain complex is  $0 \rightarrow \mathbb{Z}^2 \xrightarrow[]{d_2} \mathbb{Z} \xrightarrow[]{0} \mathbb{Z} \rightarrow 0$.     I don't understand why $d_2$ is not multiplication by $2$ here since they are attached in the same way as in Hatcher's Example 2.42. According to another answer $d_2(e_1^2)=2e^1$ and $d_2(e_2^2)=-2e^1$ "by the cellular boundary formula". I do not see why this is the case since $e_1^2$ and $e_2^2$ have the same attaching map.


Questions locked for moderation shouldn't appear on hot questions list

appeared on the hot network question list for me, even though it was locked 7 hours ago due to off-topic comments.  Questions that have a problem severe enough to warrant a moderation lock shouldn't appear on the hot question list - that'd only add fuel to the fire once they are unlocked. Instead, show it to people for the first time once it's been fixed up.  This is different from  in that that question had a historical question lock, not an off-topic-comments moderation lock.  This is still happening in February 2017, with  appearing on HNQ.


What are the reasons for and against wearing a bicycle helmet?

This is a tricky question to ask correctly.  has already been closed as subjective and argumentative. There is no one correct answer, for sure. However, there are interesting reasons that I believe are worth recording here.   Ideally include supporting documentation/research. I will vote up for quality of answer, not based on whether I agree with the answer.


How I can know what things that cause NPE?

I want to create a controller that passed a parameter search as an input to findDuelIdOrEmail method: @RequestMapping(value = "/app/friend_search", method = RequestMethod.GET) public ResponseEntity<List<FriendResponse>> getAll(         @RequestHeader("Authorization") String authToken,         @RequestParam(value = "search", required = false) Object search) throws Exception {      TokenPayload tokenPayload = tokenProvider.verifyAndDecode(authToken);       List<FriendResponse> friendResponseList = new ArrayList<>();     boolean isNull = search == null;     boolean isEmpty = search != null && search.toString().equals("");      if (isNull || isEmpty) return ResponseEntity.ok(friendResponseList);      friendResponseList.add(this.friendService.findByDuelIdOrEmail(search));     return ResponseEntity.ok(friendResponseList); }  I have a findDuelIdOrEmail method which contains a variable profile that initialized with null value. The code is shown below: public FriendResponse findByDuelIdOrEmail(Object duelIdOrEmail) throws Exception {     Profile profile = null;     final String duelIdOrEmailString = duelIdOrEmail.toString();     final User userEmail = this.userRepository.findByEmail(duelIdOrEmailString);       if (userEmail == null) {         final int userId = this.generateUserId(new Long(duelIdOrEmailString));         profile = this.profileRepository.findByUserId(userId);     } else {         profile = this.profileRepository.findByUserId(userEmail.getId());     }      if (profile == null) {         throw new ResourceNotFoundException();     } else {         FriendResponse response = this.generateFriendResponse(profile, 1, null);         checkResponse(response);          return response;     }  My guess is the profile variable caused NPE. I tried to handle the null value by validating it with if(profile == null). But, I still got the NullPointerException. What is the best practice to handle this problem? Any tips will be appreciated.


Can I use the Revised Ranger in Adventurers League?

I am planning to build an archer for my next D&D character for Adventurers League. I will be going three levels in fighter to pick up the Battle Master Archetype and from there I am considering multiclassing as a ranger. I have been away from D&D for the better part of 2 years and am unfamiliar with the ruling regarding the revised ranger from Unearthed Arcana in league play. My question is thus: can I use the revised ranger in Adventurers League and if not, is their any point in going ranger otherwise? I remember that the ranger was really underpowered and I know Unearthed Arcana addressed this issue. Also just to note, I am not planning on going beast master.


Perl script debugging through the command line gives error

While I am executing my perl script, I am getting following error: Can't locate Text/Unidecode.pm in @INC (you may need to install the Text::Unidecode module)


Sharing partition folder not working after reboot

I’m using Ubuntu 18.04 LTS with 3 hard drive partitions.  I installed Samba and shared a folder in the network from the second partition, worked fine but after reboot, I cannot access that folder from the network. I have to mount and share every time I reboot.  I first installed Samba and gave all the necessary permissions by following the installation steps.


Can you use a bonus action between the separate attacks of a spell?

Similar to  I am curious about whether RAW you can use a bonus action between a spells attacks.   Unlike in the case of movement, bonus actions do not have a section specifying that they can occur in between parts of a particular type of action. The rules section on  reads (PHB, 189):     You choose when to take a bonus action during your turn, unless the bonus action’s timing is specified, [...]   The answer to this question is very relevant to Warlocks who might use Eldritch Blast against the target of their Hex but slay the target before every blast of Eldritch Blast has been used. The Warlock would then want to target a new creature with the remaining blasts (see  on changing targets during a spell) but first use their Bonus Action to move Hex to the new target.  If the particular bonus action is relevant to your answer, you can use the moving of Hex to a new target as the use-case - but I would also appreciate a general understanding of when, if ever, bonus actions can split up a spell's attack.    Related:


Wifi not working after migrating hard drive

I migrated my hard drive to a different laptop and I am having trouble getting my WiFi to work. lshw shows that the drivers are installed but ifconfig  only display ethernet and loopback. I've been looking for solutions for over a week now.  Can anyone suggest something I can do? Thanks


I came across a reference to it recently on  and (as of now) it is not explained.  I suspect  might be it, but I don't know for sure.


A word for "somebody who is sponsored"? Sponsee?

Is there a word that means "somebody who is sponsored"?   E.g. if I sponsor somebody, that person is my ______?  Google results for  have scattered definitions in unreliable sources, so it does not appear that is a real word. I'm looking for something similar, a single word, preferably American English.  The specific context is a social group membership application where new members must be sponsored (as in  - "one who assumes responsibility for some other person or thing") by existing members. I am looking for a single word to describe the target of such a sponsorship.


Give an example of a metric space $(X,d)$ and two closed sets    $A,B$ with $A\cap B=\varnothing$ and $d(A,B)=0$.


Copy object, not being able to change the texture on one?

I have a Villager, rigged and everything, and when I copied him, the two were, exactly alike. Like expected. But when I tried to change the texture on one, the texture on both changed. I tried adding another texture to the object, but whatever I do, they stay the same. Its like they are the same object, just separated. How can I change this? I tried to make a "share the blend" file but it says it was too big.


Is there an easy way to convert a number to a word in PHP?

In PHP, is there an easy way to convert a number to a word? For instance, 27 to twenty-seven.


Dynamically create instance of class from string name and re use it

My requirement is I have to read data from one service and push this data into different tables(t1,t2,t3 or many more)  For this I created one table to map data field from service to table name and field name.  Eg: fname belongs to user table first name field   Now I am looping through this and creating objects before hand and assigning values from data returned from service by using switch case  T1 objt1; T2 objT2; T3 objT3; For loop mapping data     Switch(mapping data field)     Case "T1":       var obj1 =          entity.GetType().GetProperty(propertyName);     Obj1.SetValue(entity, data.Substring(1, data.Length - 2) == "Y", null);      break;       Case "T2":       // code             break;  Now how do we do this without creating instance of T1, T2 before hand and by not using switch case for every table type  We cannot use System.activator.createinstance because of performance issues with it  I want some solution using dictionary, so that we need not create instances of every class created


Why is Homebrew finding phantom directories?

I'm running Homebrew on macOS High Sierra 10.13.6. I use a bash alias brewup to periodically check on my installation.  brewup is defined as below:  alias brewup= 'brew update; brew upgrade; brew prune; brew cleanup; brew doctor'   Recently, when running brewup, the output from the brew prune portion of the command has been:  Pruned 0 symbolic links and 2 directories from /usr/local.  Every single time I run the brewupcommand, even after restarting, hand checking /usr/local for excess directories, recreating the brewup alias, and completely reinstalling Homebrew and all my packages, I  always get the output Pruned 0 symbolic links and 2 directories from /usr/local.    The mystery deepenes even further, because when I run just brew prune, I get, as expected, no pruned results whatsoever. Something in the order of the commands contained in brewup is causing phantom excess directories to appear, over, and over, and over again.  Can someone help me exorcise these phantom directories?