Let $\mathbb{Q}(\sqrt{d}) = \{a + b \sqrt{d}: a,b \in \mathbb{Q} \}.$ Show that $\mathbb{Q}(\sqrt{d})$ is a field.    Everything seems obvious except for existence of inverses in the multiplicative group of $\mathbb{Q}(\sqrt{d}).$  Suppose $\alpha \in \mathbb{Q}(\sqrt{d}) \Longrightarrow \alpha = a + b \sqrt{d}.$ To prove that $\mathbb{Q}(\sqrt{d})$ contains multiplicative inverses, observe that for a non-square $d$ and $a - b\sqrt{d} \ne 0$  one has $$\frac{1}{\alpha} = \frac{1}{a+b\sqrt{d}} \cdot \frac{a - b \sqrt{d}}{a - b \sqrt{d}} = \frac{a}{a^2-b^2d}- \frac{b}{a^2-b^2d} \sqrt{d}.$$  If $a,b \in \mathbb{Q} \Longrightarrow a^2,b^2 \in \mathbb{Q} \Longrightarrow b^2 d \in \mathbb{Q}$ (since $d \in \mathbb{Z}$) $\Longrightarrow a^2-b^2d \in \mathbb{Q} \Longrightarrow \frac{a}{a^2-b^2d}, \frac{b}{a^2-b^2d} \in \mathbb{Q}.$ Hence $\frac{1}{\alpha} \in \mathbb{Q}(\sqrt{d}).$   Is this correct?

For which $c$ will the set $K(c) = \{a + b\sqrt{c} : a, b \in \mathbb{Q}\}$ be a field? I know for example, that $K(\frac{2}{3})$ will be one, I am just wondering what the most general result of this type is.


How exactly does k-means clustering for categorical data work? I have a dataset which has several categorical features that can have 2,3,4,..,n values. I could one hot encode them, but I'm not sure if it even makes sense because k-means uses a distance metric. I looked into k-prototype clustering, but tried it on my dataset, but plotting it does not make sense when the y-axis and y-axis are just integer values that are small.

My data set contains a number of numeric attributes and one categorical. Say, NumericAttr1, NumericAttr2, ..., NumericAttrN, CategoricalAttr, where CategoricalAttr takes one of three possible values: CategoricalAttrValue1, CategoricalAttrValue2 or CategoricalAttrValue3. I'm using default . It works with numeric data only. So my question: is it correct to split the categorical attribute CategoricalAttr into three numeric (binary) variables, like IsCategoricalAttrValue1, IsCategoricalAttrValue2, IsCategoricalAttrValue3 ?


Say a wizard has a major bloodline. Is their maximum level wizard-17/bloodline-3(in which case they only have 17 HDs), or wizard-20/bloodline-3 (in which case their total caster level is 23)?  This isn't so much about if bloodline increases ECL for the purpose of XP requirements (that's been answered) as it is if bloodline-granted ECL results in fewer class levels.

, in all their weird but flavorful glory. For those who don't know, bloodlines are kind of like a racial template that gives you more abilities as you level up. Instead of having a level adjustment, you have to take pseudo-levels (1-3 of them) in the bloodline by certain points in your career. I'd always assumed those increased your ECL (effective character level, important for things like XP) like a regular level, but a guidebook I just read claimed otherwise. Sure enough:     Class levels of "bloodline" do not increase a character's character level the way a normal class level does, but they do provide certain benefits (see below).   So, do bloodlines not increase your ECL?


Sorry as this is a rather soft question, but I'm really struggling to get to grips with some packages for this (espcially since I really don't care about learning all the in's and out's). I literally just want the Petersen graph, $C_3$ and $C_6$. The problem with finding the pictures online is that the graphs will look inconsistent (different sizes of nodes etc from different webpages).

I need to draw simple graph (for example ) in LaTeX. I am using Kile in Ubuntu. I exactly don't know that which package should I use. Any suggestion with example is highly expected.


list1 = [1, 2, 3, 4]   element = list1[1:][1]    print(element)   Why does it print 3?   How is this evaluated? Does it first take the elements of list1 that are from index 1: then it takes the 1 index of that?

I need a good explanation (references are a plus) on Python's slice notation.   To me, this notation needs a bit of picking up.   It looks extremely powerful, but I haven't quite got my head around it.


How can I put my name in the lower corner of my pictures using Photoshop? Specifically, how can I put my name in mass numbers of my pictures using Photoshop? I have 1500 photos from a recent biology trip that need my name in them so people know that the works are mine. I can do it one by one, but is there a faster way to do it?

I have around 15,000 JPG files that need to be watermarked. Is there any way to process these images en masse and add a watermark?  The images may be different sizes, I want the watermark placed in the center of the images.


I am trying to install a vagrant instance while I am sitting in a group on a congress. Since we don't have such a big bandwidth here, I would like to limit the bandwidth of the initial download of the vagrant box.  Is there a simple way how to limit the throughput of my wireless card right now?

I am getting complaints that I consume lots of internet bandwidth.  Is there any software that can limit internet bandwidth on my computer from my own computer? I use Firefox as browser and use bittorrent and download software from software center.  (Is there also a way to monitor it?)


I'm trying to connect to a FTP to upload a file from a cent os box. I can access to the server, but the connection times out whenever I try to upload with 'put' command.  I can upload a file without a single problem on my local machine. It sounds like a port issue.  I've already opened outbound port 21. Are there any other ports that I need to open for uploading?  logs  ftp> put localFile remote 227 Entering Passive Mode. ftp: connect: Connection timed out

Whenever I install vsftpd on centos, I only setup the jail environment for the users and rest is default configuration of vsftpd. I create user and try to connect with filezila ftp client, but I could not connect with passive mode. I always change the transfer settings to active mode to successfully connect to the ftp server otherwise I get        Error: Failed to retrieve directory listing   So is there a way to change any directive in vsftp.conf file and we can connect with passive mode to the server?


I have some bibliography entries with points in the title field like "org.apache.lucene.analysis" or "java.util.Date". As there is no linebreak after ".", the text runs over the page margin in some cases. Is there a way to change this behaviour?

I have an BibLaTeX entry which causes in \printbibliography command a overful hbox. How can I tell BibLaTex that a line break is allowed without a minus symbol?  In my case I have a text like ABC.learning. I want to allow BibLaTex to break the line after the dot.


I watched a documentary on monkey flying into black hole and what it would perceive. Entire history of the universe redshifted in all directions, but without any way of knowing it's passed event horizon. Isn't it what we are seeing? In addition, universe is accelerating towards all directions, which would be perfectly explicable if we were inside the black hole which, as I understand, would be in all directions, because our entire future cone would be pointing there.  EDIT:  is NOT a duplicate as I am discussing a perceived differences, not only plausibility of this actually being true.

I was surprised to only recently notice that      An object of any density can be large enough to fall within its own   Schwarzschild radius.   Of course! It turns out that supermassive black holes at galactic centers can have an average density of less than water's.  Somehow I always operated under the assumption that black holes of any size had to be superdense objects by everyday standards.  Compare the Earth to collapsing into a mere 9mm marble retaining the same mass, in order for the escape velocity at the surface to finally reach that of light.  Or Mt. Everest packed into one nanometer.  Reading on about this , it increases proportionally with total mass.  Assuming matter is accumulated at a steady density into a spherical volume, the volume's radius will only "grow" at a cube root of the total volume and be quickly outpaced by its own gravitational radius.  Question: For an object the , what would have to be its diameter for it to qualify as a black hole (from an external point of view)?  Would this not imply by definition that:   The Earth, Solar system and Milky Way are conceivably inside this black hole? Black holes can be nested/be contained within larger ones? Whether something is a black hole or not is actually a matter of perspective/where the observer is, inside or outside?


This is a question about biasing 0V-referenced AC input signals to a positive single-ended signal. Even if the best solution for my question would be something else (and I'd like to hear about that, too,) I'd still mainly like to learn about the biasing question.  I have searched all the "biasing analog video signal" posts in here, as well as googled datasheets, and I haven't actually found one that answers the questions I ask here. Just searching the titles of other posts is misleading, because they have other requirements (using other devices, different power supplies, etc.) The suggested duplicate question "AC-Coupling on Composite video" talks about re-processing the signal, which I explicitly do NOT want to do.  Question Background  I have a remote operated robot with a video camera generating a composite video signal going into a transmitter.  I'd now like to switch the transmitter between two separate cameras. I don't need genlock (synchronized pictures); I'm OK with the "glitch" that happens when switching between unsynchronized signals.  Weight is important, and sticking to the current design of the control systems of the robot is important.  I have looked at dedicated "video switching" ICs. The older ones, like MAX4566 and NJM2595, are generally bipolar, and require dual power supplies (+/- 3-12V.) I only have a single end power supply (5V) and ground easily available. (The video signal, generated by the camera(s), is referenced the the ground I have available.) The newer "video switching" ICs (like the TS3V330) are all for digital video differential signals (HDMI etc.) They do not work with input signals less than 0V.  A simple SPDT switching IC like the SN74LVC1G3157 is readily available, but it has protection diodes from input signal to ground and to VCC. This means that the negative half of the input signal swing will be clamped by the diode to ground. (once the diode voltage drop of 0.3V or so has been overcome)  Actual Question  The AC signal centered around 0V is generated by an output stage in the camera (or other video equipment) like this:    The input to the transmitter, and other video processing devices, looks something like this:    (Illustrations shamelessly "borrowed" from the MinimOSD open source project schematics.)  I would like to take two of these video signals in, and switch between them (without any specific sync requirements) into one output signal, which is forwarded to the transmitter input.  I would like to not re-buffer and re-amplify the video signal. I could do that with an opamp with sufficient bandwidth, but that adds more parts and complexity. Call me lazy if you want!  So, my question is: Can I switch this signal by biasing it using a simple resistor ladder, then switching it, then adding an output capacitor? If so, what should the values for that ladder be? What will happen to the 75 Ohm output impedance seen by the original transmitter, and the eventual receiver?  Example:    (If the output from the camera doesn't actually use an isolating capacitor, I'm in trouble, though.)  Am I missing something else here, or would this "work" with reasonable signal quality?

Many sources say that composite video input should be AC-coupled. Voltage levels for blank, black and white signal are also specified. How is it possible to detect these voltage levels after AC coupling (aka dc-blocking capacitor)?  Doesn't the DC-component (average) of the signal vary wildly depending if the content is all black (0V-0.3V) or all white (0V-1V)?


I’m traveling from India to USA in which i got a 15 hour layover at London airport. My flight will land at London at 6 p.m. and other flight will take off at 9 a.m. next day. So an overnight stay. So will I be needing a transit visa? I don't want to get out of the airport.

Is there a website or some other way to find out if I need a transit visa for a short stop in the UK on my way somewhere else? Ideally this should give me the answer for all nationalities, and take into account any other visas I may have.


I am new to python. It might seem little obvious but would like to know if there is any easier way in python to do this.  I am trying to count number entries to a function. Requirement is as below:   Every 5 sec a timer event is triggered through which callback (ev_5ms()) is inturn triggered Wait until 20 secods and then clear the counter and start again   I am using the following code  counter = 0  "Callback" def ev_5s(): if counter < 4:     counter += 1 else     counter = 0     print('Send Message')  t = EventGenerator.TimerEventGenerator(1, ev_1s()) t.start()   Error Traceback:  Traceback (most recent call last): File "C:/Users/i8479/Desktop/Python/HPP_SM.py", line 28, in <module> t = EventGenerator.TimerEventGenerator(1, ev_1s()) File "C:/Users/i8479/Desktop/Python/HPP_SM.py", line 21, in ev_1s if counter < 4: UnboundLocalError: local variable 'counter' referenced before assignment   I am coding as I would do in c or cpp. How can I do this in python?

What is the idiomatic Python equivalent of this C/C++ code?  void foo() {     static int counter = 0;     counter++;     printf("counter is %d\n", counter); }   specifically, how does one implement the static member at the function level, as opposed to the class level? And does placing the function into a class change anything?


I just got an upvote on a question here on meta to push my daily total reputation to +15. This is shown correctly on the reputation tab on my profile page…        …as well as the reputation list…        However, the achievements dropdown does not show this, preserving the +10 that I received (before the recent scheduled read-only time—possible cause?). It's also not showing the green +[rep] badge on the button.        Also, I've got 66 reputation today on Ask Different, but it still shows 70 in the achievements dropdown, shown above. The actual list of reputation received/lost in the achievements dropdown has not updated either.

This was asked before too. .  Currently I am facing the issue of appearance of reputation notification in above toolbar.  I can see the reputation notification, for every page refresh even after clicking and viewing the notification.  current browser: Chrome Version 36.0.1985.143 m


So one day I opened my MacBook Pro, only to find that none of the keys were registering. A few seconds later, it gave me a popup that there was no bluetooth keyboard detected. My trackpad was also not registering. The only button that seemed to be working was the power button. When I pressed the power button, it brought up the usual popup dialog about whether I wanted to sleep, restart, or shut down. I had no way to click on any of the options, so I just held down the power button to force shut down. (Opening and closing the laptop didn't do anything).  When the computer booted back up, everything was working fine. I used my computer like normal, until a few days later, it happened again. o I did the same thing. This was maybe 5 days ago. And today, it happened again.  So it's not happening every time I use my computer, not even close, but it's still annoying, and I'd rather it didn't happen.  I didn't do anything to my keyboard before this happened, so I have no idea what could be causing it.  Anyone have any ideas?  EDIT: This question is not a duplicate of the linked question because in that question, the asker is having issues with specific buttons being stuck down. This seems like a physical issue with the hardware. In my issue, my computer is not registering my keyboard, and it telling me there is no keyboard attached. I haven't spilled anything on my keyboard or done anything else to it, so it seems like a software issue. I would share screenshots, but when this happens, I have no way to take screenshots.

This is an attempt to write a canonical QA for this issue, as per the Meta post:   I expect it to be periodically edited with the goal of becoming a comprehensive information resource.  I have a MacBook Pro that has a key(Shift, Return,   Command, P, etc.) that doesn’t respond when pressed or is stuck in the down position.    It's possible that my favorite beverage was spilled (or some other liquid damage).  It's also possible that I have no idea what happened.  It was working yesterday and suddenly today it's no longer working.  Is there any way to bypass or remap the key?  Can I  have the system ignore it completely?  (This question can also apply to external USB keyboards or the Bluetooth keyboards)


I'm on italian keyboard, accessing ` and ~ is so frustrating (I have to enter alt 96 and alt 126), but I have also a useless § key (shift + ù). What I'd like to do is to "add a layer" to \ key so pressing altgr + \ will produce ~  and altgr + ' will make `  Another nice thing to add is support for "dead key", what I'd like is to have single pressure to behaving as usual and (altgr + shift) + pressure let it behave as dead key.   So to put e' I just enter e + ', to enter é I enter altgr + shift + '  then e.  Can someone please suggest me a solution?  NOTE: switching to IT-104 is not an option as it remaps ~ to ] so I'll gain the gliphs but at cost of losing another that was well memorized.

Here is what the layout of an Italian keyboard looks like:  As you can see, the curly braces, which are absolutely necessary to write code in any of C, C++, JavaScript, Java, Objective-C, and others, appear in purple in this picture. This is because while the other characters can be seen visually as printed characters on most Italian keyboards, these purple characters are actually usually not printed on the keyboard's keys. These characters, found in the upper right corners of the given keys, can usually be generated with the following key combinations: (RIGHT SHIFT or LEFT SHIFT) + (RIGHT CTRL or LEFT CTRL) + (Alt or AltGR) + ([ or ]) (Actually as the MSKLC application shows, SHIFT + AltGr + [ and SHIFT + AltGr + ] are enough to generate the curly braces.) Characters such as the at (@) sign (called 'chiocciola' in Italian) and the hash (#) key (called 'cancelletto' in Italian) found in the lower right hand corner of the keyboard can be generated easily as follows (AltGr + @) or (AltGr + #). Such characters are also fundamental to programming as they can, for instance, be found in CSS, namely with media queries and with selectors referring to the id html attribute. Upon further inspection, we can see that all of the US ASCII keyboard / programmer's keyboard are covered by the keys of the Italian keyboard, except for the following, which are the tilde, which is especially useful on the Linux command line and is used to refer to a user's home directory on such system, as well as the back-tick (`), also known as the back-quote, which is also very useful on the Linux shell when we want to turn the output of a command into a command-line input. So, here comes the question: With all those empty upper-right hand corners of keys, why isn't there a better way of generating these characters, perhaps through a CTRL-ALT-SHIFT modifier key combination? All I've been able to find regarding generation of these characters are the following ALT-codes:  ALT code 96  corresponds to ` ALT code 123 corresponds to { ALT code 125 corresponds to } ALT code 126 corresponds to ~  and to generate a character via an ALT code, you make sure that the NumLock key on your keypad is toggled on, hold down the ALT key, enter the keycode, and release the ALT key. ALT code are documented at:  If someone knows of a better way of inserting these characters from an Italian keyboard without switching the keyboard layout in the Control Panel, then please let me know. Thanks.


I've attached some   and  here.      It shows the window as soon as I boot up. There also appears a (-) red minus sign which tells me that a problem occured while checking updates, and when I click "Show updates" it tells me that the Software Updater has crashed unexpectedly.  I am unable to update it (I wish to upgrade to 16.04 LTS), nor solve the problem. Any solutions?

This red icon.... It showed up after I upgraded to Ubuntu 12.04LTS; I can't figure out how to ditch it. It seems to be a notification thing.  I am at a loss.  The icon is this one:      I clicked it and read this:     An error occurred, please run Package Manager from the right-click menu or apt-get in a terminal to see what is wrong. The error message was:  'Error: BrokenCount>0'.        This usually means that your installed packages have unmet dependencies.


If $H$ is a ring and it has a finite non-zero characteristic $p$ then ring is finite.  I couldn’t any counter example for this claim. Can anyone help me please?

For curiosity: can a ring of positive characteristic ever have infinite number of distinct elements? (For example, in $\mathbb{Z}/7\mathbb{Z}$, there are really only seven elements.) We know that any field/ring of characterisitc zero must have infinite elements, but I am not sure what happens above.


Can an Android phone make phone calls in order to send fax? I mean, is it technically possible  with Android? Without using 3rd party servers.

Is there a way to send or receive faxes directly to/from the phone without routing through a web-based service?    There are times when I've needed to send or receive a document image without going through e-mail or a third-party service.  It may be a recipient without an e-mail option for a document I need to submit (e.g., a particular government agency) or it may contain sensitive information that I do not want going through other hands.  When I checked the app store, everything I found seemed to involve a web-based service (I could've missed one, though).  With a device that can take images and make phone calls, it seems like a natural extension of the capabilities to be able to communicate with a fax machine directly.


from datetime import datetime datetime(2018,01,01,10,08,00)   The above code produces an error  >>> datetime(2018,01,01,10,08,0) SyntaxError: invalid token   If i change 08 to any value between 01 and 07 then the error will not show and also the error will unshown if i change 08 to 8.  What is the reason behind it?

Some of you may recognize this as Project Euler's problem number 11. The one with the grid.  I'm trying to replicate the grid in a large multidimensional array, But it's giving me a syntax error and i'm not sure why  grid = [  [ 08, 02, 22, 97, 38, 15, 00, 40, 00, 75, 04, 05, 07, 78, 52, 12, 50, 77, 91, 08 ], [ 49, 49, 99, 40, 17, 81, 18, 57, 60, 87, 17, 40, 98, 43, 69, 48, 04, 56, 62, 00 ], [ 81, 49, 31, 73, 55, 79, 14, 29, 93, 71, 40, 67, 53, 88, 30, 03, 49, 13, 36, 65 ], ...   And I get this error:     File "D:\development\Python\ProjectEuler\p11.py", line 3     [ 08, 02, 22, 97, 38, 15, 00, 40, 00, 75, 04, 05, 07, 78, 52, 12, 50, 77, 91 , 08 ],        ^ SyntaxError: invalid token   Why is it throwing an error before the comma?


In the final episode of Game of Thrones, a pivoting moment resides in       A gathering where all greatest remaining Lords & Ladies of Westeros are presented Tyrion and Jon Snow by Grey Worm, in order for them to be judged.   I don't understand how the Council made up by the remaining Lords & Ladies was so merciful with Tyrion and so harsh for Jon Snow.  First, it seems that Grey Worm and the Unsullied (which for some reason have not executed the two prisoners the moment they found out they successfully conspired to kill their queen, and waited for a trial gathering Lords of the kingdom to be assembled) hold a lot of authority on the prospects of the prisoners, and almost hold as hostages the Lords & Ladies.   However, as the scene unfolds, it seems they decide to fall in with the Council's authority on its own lands.   As such, they accept to see Tyrion go from allegedly sentenced to death for treason to choosing the future of Westeros and becoming the Hand of the new king, as it's what the new king and the rest of the Council wants.  However, Jon Snow is most severely punished by a life-long exile in the Night's Watch (taking the black being often represented in the series as an ultimate choice with death). But most of the Lords & Ladies at the table are in fact on Jon's side, or, if not exactly, are at least expected to have been horrified by Daenerys's slaughter and wishful for her cruel reign to end. In fact, we're very much in the same situation as with the Mad King prior to Robert's Rebellion. When Jaime Lannister killed this king, judged by most as a tyrant, he was pardoned by the new king and remained a King's Guard knight.  At the gathering, except for Grey Worm which seems to respect the Council's decisions, only Yara Greyjoy seems to be unhappy about Daenarys's death. Though, her opinion is of light importance as, as opposed to a lot of others present in the Council and particularly Jon's allies, she has played a very little role in the Long Night and the attack against Cersei.  How come Jon was punished for killing a queen almost everybody judged as a tyran deserving to die, and not honoured for having accomplished the only move leading to potential peace in Westeros? All the more so when the two persons that can truly decide his fate – the King and his Hand – are his brother and the man that convinced him to kill the queen to save the Realm?  Finally, as discussed in comments for this , Jon is at this moment the true heir to the throne, and an important part of the Council is aware of it. In fact, the plot insists heavily on that Daenerys decided to reign by fear because she was afraid that the people of Westeros would turn to Jon, who they like better and who has a better claim to the throne. But when she is ruled out, this much advertised turn of events strangely doesn't take place.   Edit: I don't believe it's a duplicate of , as my question asks why the judgement for Jon is so harsh, while the other one asks why Tyrion judgement ends up freeing him. Those are two different characters, and I can't see the answer to the other question that would apply to this one.

In the season 8 episode finale of Game of Thrones the highest important lords met with Grey Worm to free      Tyrion and Jon. While it was pretty clear why they wanted to free Jon it was unclear to me why they also asked for Tyrion.   To make things even more strange, they asked about his opinion of a potential solution which becomes the actual final one in the end      (choose king and nominate someone).   I thought they (besides Sansa and Bran) don't like him and wanted to judge him? Or am I missing something?


I have been testing Ubuntu 17.10. I like it, but when I turn on my PC (with Ubuntu 17.10), the login screen uses Wayland, and my GPU doesn’t support it. After login, it automatically change to Xorg and it works normally.  How can I change from using Wayland to Xorg on the login screen permanently?

Some of my applications don't work on Ubuntu 17.10 Wayland. How can I switch back to Xorg?


I have a VPS with Ubuntu 14.04. I need to login as root to my server over SSH.  I set a password for root: sudo passwd root then enabled it: sudo passwd -u root then rebooted my vps: sudo reboot  But I still can't connect with the root user. How can i enable ssh login as root?

I'm using the default installation of openssh-server for my Ubuntu 14.04 server. I can connect through the console as root like normal, with my username and password. When I try to SSH with the same username/password, however, I repeatedly get Access Denied errors. /var/log/auth.log reports Failed password for root from <ip address> port <port> ssh2, but I'm entering the correct password.  Why can't I connect to the server via SSH, even though the username and password ARE correct?


I am having trouble proving that for all integers $n,\ 3$ does not divide $n^2-5$ using modular arithmetic. I know that $3\not\mid n^2-5$ means $n^2\not\equiv 5\pmod 3$. But I'm not sure how to start the proof.

Prove or disprove: For every integer a, if a is not congruent to 0 (mod 3), the a^2 is congruent to 1 (mod 3)  SO this is for abstract algebra and I am really struggling with this. Here are some of the definitions and theorems I think would apply.  -an integer a divides and integer b if there is an integer q such that b=aq -Let a and b be integers, with a>0. Then there exist unique integers q and r such that b= aq+r and 0<=r  The question says hint: use 2 cases but I'm not really sure what that means. I'm guessing it wants me to look at it when a is congruent to 0 and when it's not? so i tried to do that but just ended up stuck. below is as far as i got with that attempt  Proof: Case 1 There should be some information about letting variables exist in certain number sets here  assume a is not congruent to 0 mod 3, then 3 does not divide a-0, therefore a-0 does not equal 3q for some q in the integers  I was trying to get this to wind down to thus 3 divides a^2-1 but even tho it seems true (I couldn't find a counter example) I couldn't figure out how to prove it with what I have.  Next i tried reversing it thinking I could contradict it or something.  I think this would be case 2? assume a is congruent to 0 mod 3, then 3 divides a-0 and a-0=3q for some q in the integers, then 3q=a since 0 is the additive identity, therefore 3 divides a,  and again stuck and my brain hurts a little..  Can anyone help me figure out how to work this.


Define $u_n$ as :  $$u_n=\displaystyle\sum_{k=1}^n \dfrac{1}{\sqrt{n^2+k}}$$  From first values, $(u_n)$ seems to be increasing.  From squeezing, its limit is $1$.  $$ \dfrac{1}{\sqrt{n^2+n}} \le \dfrac{1}{\sqrt{n^2+k}} \le \dfrac{1}{\sqrt{n^2+1}}$$   (summing from $k=1$ to $k=n$)  How can one show that it's indeed increasing (if it is) because no terms cancel out when setting $u_{n+1}-u_n$.  thanks.

Let $ \{s_m\}_{m=1}^\infty$ be the sequence defined:  $s_m = \sum_{k=1}^{m} \frac{1}{\sqrt{m^2 + k}}$   I have already proven that $s_m\to 1$ as $m\to \infty $ but i'm having trouble to show that $s_m$ is a monotonic sequence.  Would appreciate any help or advice, thanks in advance.


I made a method to click on the calendar field and then choose the date, but when I move the parameters, is returning error.  My method  def select_current_date(self, *locator1, *locator2):      self.driver.find_element(*locator1).click()     WebDriverWait(self.driver, AUTOCOMPLETE_TIMEOUT).until(         EC.visibility_of_element_located((By.CSS_SELECTOR, ".ui-icon.ui-icon-circle-triangle-w")))     self.driver.find_element(*locator2).click()     WebDriverWait(self.driver, AUTOCOMPLETE_TIMEOUT).until(         EC.invisibility_of_element_located((By.CSS_SELECTOR, ".ui-datepicker-title")))   Passing the parameters  self.select_current_date(*EventsLocators.RECEIVED, *EventsLocators.CURRENT_DATE)   My error  E     File "/Users/rafael/Desktop/projects/automated_tests/base.py", line 23 E       def select_current_date(self, *locator1, *locator2): E                                                ^ E   SyntaxError: invalid syntax   Any idea?  Cheers!

In the following method definitions, what does the * and ** do for param2?  def foo(param1, *param2): def bar(param1, **param2):


Is there any way to remove the italic from the words bits in the code below? That is, change the \text output to represent the normal font when an align is used inside a theorem-like environment.  \begin{proposition}  The memory requirements for the keys are \begin{align}   m_{\text{pk}}&= 2r \,\,\,\text{bits}\\   m_{\text{sk}}&= r \end{align} \end{proposition}

\documentclass[11pt,a4paper]{article} \title{Title} \author{Author} \begin{document} \maketitle $\{ n \mid n\ \mbox{is\ even} \}$  \end{document}   Since it is a relatively rare occasion for me to display upright letters in math mode, I kind of ignored this problem for a long time. But recently, when I prepared my tutoring notes, I found manually creating space is annoying. I thus wonder if there is any way out?   I would also like to know if it is possible to display upright letters without commands such as "\mbox" or "\textup" in math mode?


I am applying for a job that my friend has told me about. He spoke with the employer about me and then told me I should send that employer an email. Because this will be is my first contact with the owner, I thought of composing a formal letter.  As the title says, I want to put the subject of my letter as:     Michael’s Referee(?): Job Application   What is the correct word instead of referee?

When a referrer (noun) gives a referral (noun) to another person, what is the term (noun) used for the recipient of the referral? "The referred" may work, but am I missing another term? "Referred" indicates past-tense, but I intend to use the term in future and present tense as well.


I've lost my follower I told her to wait and forgot about her it said "Follower tired from waiting and left" I've checked the shrine of Azura where I found her, both my homes, the bannered mare, winking Skeever, and where I left her I still cant find her

I had parked my follower at an inn with a bunch of valuable items that I didn't want to carry. I guess I have been out a bit too long as this message appears:      Your follower tires of waiting and leaves.    There have been other situations where my follower has mysteriously disappeared as well.  How can I find my follower when they get up and leave or disappear into thin air?


I can check for OR condition in regex like so: import re string = "abc ank won xyz" print(re.findall("ank|won", string))  But how do I check for AND condition? I couldn't find anything for python regex. EDIT: I want to check if both ank and won (in any order) exists in the string or not.

Obviously, you can use the | (pipe?) to represent OR, but is there a way to represent AND as well?  Specifically, I'd like to match paragraphs of text that contain ALL of a certain phrase, but in no particular order.


I have some abstracted code, which at the end of some process will create a homogeneous list of SObjects.    It could be a list of Accounts, it could be a list of contacts, it could be a list of some custom SObject.  It doesn't matter, every record in the list will be an instance of the same type of SObject.  upsert resultSObjectList   I can't simply do an because it results in:     System.TypeException: DML on generic List only allowed for insert, update or delete   If I send the list back to whatever method called my abstraction and then try to cast it back into whatever type it should be, e.g.:  List<Account> accountList = (List<Account>) resultSObjectList; upsert accountList;   It still results in:     System.TypeException: DML on generic List only allowed for insert, update or delete   I can make this work with:  List<Account> accountList = new List<Account>(); for (SObject sObj : resultSObjectList) {     accountList.add((Account) sObj); } upsert accountList;   But that is ugly and I will need to make a similar implementation for every consumer of my process.  Likewise, I'd prefer not to create two separate lists (for insert and for update) and then do two separate DML operations.  Any ideas?

The upsert() DML operation requires a specific List based on a specific sObject type, for instance:List<Account> lstAccount = new List<Account>();   However, we are trying to generate a generic method which allows us to pass by an sObject list containing all data records to be upserted for a specific sObject. An insert() operation allows us to use a List<sObject> to be inserted but the upsert() function is rejecting it:  List<sObject> listWRecords = new List<sObject>(); listWRecords.add(new Foo__c(Name="Record1")); listWRecords.add(new Foo__c(Name="Record2"));  upsert(listWRecords, 'ExternalIdFieldFrom_Foo__c', false);   Which will result in an error saying that the upsert must be performed on a concrete entity type.   Dynamically casting an sObject list is also not possible; I've seen solutions to 'hard code' or create Wrapper classes for each sObject on your org. But we would like to create a generic option here.  Another possibility would be to create some logic mimicking an upsert by splitting it into an update() and an insert() operation. Keeping in mind Salesforce limits, I do not see an option to go this way.


Edited the pdf in PDFelement & when you try to view a document in Adobe Reader or Acrobat, you receive the error, "There was a problem reading this document (131)." Why is this happening?

I'm generating a PDF document with pdflatex (more precisely, latexmk invoked from TexMaker 3.4. My LaTeX install is TeXLive 20120719). I can read the document fine in Okular and Gmail's attachment preview, but a colleague that runs Acrobat Reader on Windows reports: "There was a problem reading this document (131)".  EDIT: The error disappears when using \usepackage[demo]{graphicx}, which puts black boxes instead of the real images. They are all PDFs, PNGs and JPGs. Instead of using demo, I added the code for a \demoincludegraphics command, which makes the file work in Reader when using it to replace the logo in the headers, as shown below. But enabling it (using \includegraphics instead of \demoincludegraphics) and removing everything else also works in Reader! There is some strange global interaction that makes the file appear broken to Reader when enabling all the graphics...  My code compiles fine, reason why I only attach the preamble and a simple text for a Minimal Working Example:  \documentclass[12pt,lettersize,twoside]{article}  \usepackage[utf8]{inputenc} \usepackage[spanish,es-tabla]{babel}   \usepackage[fixlanguage]{babelbib} \usepackage{amssymb,amsmath} \usepackage{graphicx}    \usepackage{array}    \usepackage{caption} \usepackage{subfig} \usepackage{rotating} \usepackage{booktabs} \usepackage{multirow} \usepackage{calc} \usepackage{stfloats} \usepackage{fixltx2e} \usepackage{url} \usepackage[colorlinks=true,linkcolor=blue,citecolor=red]{hyperref} \usepackage[all]{hypcap}  % Margins \usepackage[top=2cm, bottom=2cm, left=3cm, right=2cm]{geometry}  % Make header show up in the first page \makeatletter \renewcommand\maketitle{\par \begingroup     \renewcommand\thefootnote{\@fnsymbol\c@footnote}%     \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}%     \long\def\@makefntext##1{\parindent 1em\noindent             \hb@xt@1.8em{%                 \hss\@textsuperscript{\normalfont\@thefnmark}}##1}%     \if@twocolumn     \ifnum \col@number=\@ne         \@maketitle     \else         \twocolumn[\@maketitle]%     \fi     \else     \newpage     \global\@topnum\z@   % Prevents figures from going at top of page.     \@maketitle     \fi     \thispagestyle{fancy}\@thanks % was {empty} \endgroup \setcounter{footnote}{0}% \global\let\thanks\relax \global\let\maketitle\relax \global\let\@maketitle\relax \global\let\@thanks\@empty \global\let\@author\@empty \global\let\@date\@empty \global\let\@title\@empty \global\let\title\relax \global\let\author\relax \global\let\date\relax \global\let\and\relax } \makeatother  % Remove date field in title; Remove preceding vertical space \makeatletter \renewcommand{\@maketitle}{ \vspace{-3cm} \begin{center}% {\LARGE \@title}\\ \vspace{2mm}% {\@author} \end{center}% \par} \makeatother \makeatletter  % Demo includegraphic boxes \newcommand{\demoincludegraphics}[2][]{%   \setlength{\fboxsep}{-\fboxrule}% Remove frame separator/gap   \framebox{\rule{0pt}{100pt}\rule{150pt}{0pt}}% Framed box of 150pt x 100pt }  % Headers Config  \usepackage{fancyhdr} \pagestyle{fancy} \fancyhead{} \renewcommand{\headrulewidth}{0.4pt} \setlength{\headheight}{2.2cm}  \addtolength{\textheight}{-1.62cm} \fancyhead[LO,RE]{\demoincludegraphics[height=1.6cm]{logo-slogan}} \fancyhead[LE,RO]{}  % Footers Config \fancyfoot{} \renewcommand{\footrulewidth}{0pt} \fancyfoot[C]{\thepage}  % Notas al pie etiquetadas por simbolos   \renewcommand{\thefootnote}{\fnsymbol{footnote}}  \title{Doc Title} \author{My name}  \begin{document}  \maketitle  This is a test. It includes graphics and other floats.   \end{document}   EDIT: I found a workaround: Processing the generated pdf file through Ghostscript, as follows:   gs -dSAFER -dBATCH -dNOPAUSE  -sDEVICE=pdfwrite -sOutputFile=output.pdf input.pdf   where input.pdf is the file generated by pdfLaTeX, and output.pdf the one that will be readable by Adobe Reader and the rest of the PDF readers.


I'm trying to calculate a risk ratio with the following 2x2 contingency table, where the rows are exposure groups and the columns are disease status. The first row of the matrix shows that 1/38 exposed participants developed the disease.                Disease +   Disease -   Total    ----------- ----------- ----------- -------    Exposed             1          37      38     Unexposed          26         120     146     (Example code using R)  library(epitools) study_results <- matrix(c(120, 37, 26, 1), ncol = 2) epitools::riskratio(study_results)   This gives a risk ratio of 0.15 (95% CI 0.02-1.05).   The p-value (null hypothesis is risk ratio = 1) is about 0.01, depending on the method. Why is the p-value clearly lower than 0.05, when the 95% confidence interval crosses 1?

I have run proc freq to test association between two binary variables using the Fisher's exact test. However, the outputs seem contradict to each other as Two-sided Pr <= P 0.0355 whereas the OR and the 95% Confidence Limits 0.1097 [0.0022, 1.1380] includes 1.  This means that p-value shows that they are significantly associated while the 95% CI does not indicate that.  My question is that based on the output from SAS, what should I use: p-value or CI?


So I have been trying to figure out the problem of when to call for a Perception check vs. an Investigation check. I have read over  extensively, but there is no accepted answer, and the most upvoted answer states that both perception or investigation could be used.  I am looking for a simple RAW way to decide whether the player is rolling Perception of Investigation, i.e., exactly when does the perception apply and when does the investigation apply?  An example of the kind of answer I'm looking for is: "Investigation is only used when the PC has a clue about whatever they are looking for. Perception is used when the PCs don't know what they're looking for."   The goal of this answer is to allow me, the DM, to quickly decide whether Perception or Investigation is being used AND to be able to explain my reasoning to my players.  Bonus points if the uses of Investigation don't paint it into an obscure corner or rely on first making a perception check.

This actually a number of questions that conform to the title question, and which all stem from a bit of rules confusion.  Let's start with the rules confusion.  On pg 178, under the skill Investigation the rules says the following;     You might deduce the location of a hidden object,...   On the same page, directly to the right of the investigation skill, is a green box titled Finding a hidden object. In the box the rules says the following;     When your character searches for an hidden object such as a secret door or trap, the DM typically ask you to make a Wisdom (Perception) check.   Now here we have two skills that clearly does the same thing.  So my first question is: Are the skills interchangeable or mutually exclusive?  That is: can you use either skill to search for traps in any situation, or do you use Investigation only in specific situations you can't use Perception in, and Perception only in specific situations you can't use Investigation in?  My second question is: What do you use to make passive checks to spot a trap?  Do you only use Perception, as you would if a character did not have proficiency in either skill? Or, if a character is proficient in Investigation but not Perception, would you then use Investigation instead?  Which leads me to my last question: What if a character is alert to the possibility of hidden objects like traps, but isn't actively searching for them?  In other words, what happens if a player utters the oh so familiar words: "I'm prepared for the possibility that there might be traps in here." He/she isn't actively searching, but it isn't exactly passive either. If the character has proficiency in Investigation, do you then use that skill, or do you stay with Perception checks?  In other words: when do you use what skill?


Note: This  has been posted as  to the .    Earlier when I used to cast a close vote, the dialog would look like this:    That is, the radio buttons used to disappear. But now since the redesign of the close vote dialog, the radio buttons don't disappear:    Or at least make test distinguishable like that of flags:

This week we rolled out a series of changes to  of the question close workflow.  You can read more about the details of these changes .    For context, the overall effort to improve the question close experience will be optimized for Stack Overflow. Given Stack Overflow’s scale, many of the pain points we hear about with question closing and reopening are unique to Stack Overflow and won’t make sense for other network sites. However some  changes are general improvements that should improve usability and guidance overall. Wherever possible, we plan to roll these changes out network wide as well. Any time we roll out a change network wide, we’ll make sure to cross-post here. This first phase is being rolled out to the network and is why I’m posting today.  Let us know if you run into any issues or have questions regarding the network here.


In the beginning of each section in the moderncv package there is a horizontal line. I cannot figure out where to find the code to modify/ get rid of it. e.g.

I want to write my cv with moderncv-Classic style. Can you tell me, how I can remove the horizontal line in the left of each section?


So I have two flash drives in, one is running Ubuntu as a live cd and I'm using that to install Ubuntu on the other. I've gone through the download process, clicked on "something else" and now I have to partition my flash drive. I don't know how to do this. What exactly do I do now?    Thank you guys so much! That link helped a lot, I'm just not sure if I have quite the right amount of space partitioned to each thing(I'm using a 14gig flashdrive) but I think I'm close enough. Does it matter if the colors that show how much space is is used are swapped with the ones in the link?

I'd like to see the full How-To on how to use manual partitioning during Ubuntu installation. The existing guides (at least those I found here) cover only automatic part and leave untouched the manual part (or extremely short and contain no pictures).  I'd like to cover such situations:     If your disk contains other systems:


I have a stored procedure which returns a weekly result from input parameters start date and end date. I am getting multiple rows in the result.  Requirement: I want to add the results of columns in a single column. Below is my final query. From this I want to concatenate the result:  SET @sqlText =      N'SELECT ['+REPLACE(@columns,',','],[') + ']' +     '      FROM dbo.timesheet      WHERE         month ='''+ @strMonth+'''          AND [Task ID] IN         (             SELECT TaskID              FROM ManageTasks              WHERE                 TeamMemberUserID ='+  Cast(@UserID AS VARCHAR(max)) +         ')'  --Here I want to add the columns result and need to show as single column  PRINT @sqlText EXEC (@sqlText)

I have this code:  DECLARE @MyTable AS TABLE (    [Month] INT,    Salary INT );  INSERT INTO @MyTable VALUES (1,2000), (1,3100);  SELECT [Month], Salary FROM @MyTable;   Output:    I want to concat the Salary (grouping by month) so that it will be NVARCHAR like this: '2000,3100'  How would I do this efficiently?


As I understand it, a file has 3 sets of permissions: owner permissions, group permissions, and everybody else permissions. Moreover, the file has is assigned to a owner, and a group.  How linux combines all this information, to actually determine the permissions a given user has over the file?  For example, say a file is:  --- rw- --x  That is, the owner has no permissions, the group can read/write, and everybody else can only execute.  Now user "Joe" comes to this file. Depending on which groups Joe belongs to, and whether Joe is or not the owner of this file, what can he do with it? He could execute the file, because x is set for everybody. But if "Joe" is the owner, x is forbidden for the owner. What takes precedence?

I just ran into something unexpected (for me) regarding file permissions on Linux (Arch Linux). Basically I have:   userX in groupX fileX userX:groupX ---rwx----   What puzzles me: I cannot perform any action (rwx) on fileX. Is this right? Can someone please confirm this is indeed the expected behaviour?  The only actions I can perform are mv and rm because I have write permissions on the parent directory.  The thing is, I always thought these permissions collapse on each other, starting with the most general one (other -> group -> user). In other words, if o=rwx who cares what the persmissions for group and user are? Apparently this is not the case but it doesn't make much sense to me; it seems counterintuitive. The only thing this approach seems to be useful at, is to easily exclude a very specific person / group, which doesn't seem like a smart way to go at it (imho). Besides, the owner (and group?) should be able to chmod anyway right? Any thoughts on this matter?


I'm new to AJAX, jQuery, and JavaScript, so I'm sure I'm missing something simple here.  This is a hard problem for me to describe, but I'll do my best.   I have two html files, index.html and news.html.  I'm using AJAX to update a div that I have declared in the index.html file (its name is contentDiv).  I'm using the class attribute on several tags to pass information into my jQuery script.    When I click the link on the index.html page to load news.html into the contentDiv, it loads properly.  I then click a link to a .pdf file that is on the news.html file and nothing happens.  I'm trying to replace news.html with the .pdf requested.    I have the following in index.html         Here is an  tag in index.html that is working properly:  Terms and Conditions   Here is the news.html link that also works (this link is also located on index.html):  Current News/Announcements   The problem is when I click this link that is located in the news.html file, nothing happens:     I've tried this both with and without importing the same .js files that I do in the index.html file and both with and without the same document.ready script that is in index.html.  I would think that the . js imports and document.ready code would not be necessary in news.html because I'm using ajax to load news.html into index.html, but that's just a guess.   Does anyone have any ideas on where I'm going wrong?   Thanks

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


I have recently compiled a .CPP file with Geany. The result file is a .o file. How can I run this .o program?

I wrote a simple program to print "hello world". The compiler shows a message "Compilation finished successfully". But the out put of the program, I can't see anywhere.    As using codeblocks a new terminal comes out with the program output. How can I see the program output using geany compiler.


Well, I do know that one of the consequences of the Special Theory of Relativity is increase in relativistic mass. But physically, why does it happen? Do more fundamental particles get added, or do their own masses increase? (that sounds strange,I know ,but that was only to explain the kind of answer I am looking for) Thanks in advance, and sorry if the question was stupid. My curiosity sometimes forces me to ask such foolish questions.

Some people say that mass increases with speed, some people say that the mass of an object is independent of its speed.  I understand how some (though not many) things in physics are a matter of interpretation based on one's definitions. But I can't get my head around how both can be 'true' is any sense of the word.  Either mass increases or it doesn't, right?  Can't we just measure it, and find out which 'interpretation' is right? e.g.: (in some sophisticated way) heat up some particles in a box and measure their weight?  ------------------------------  UPDATE  Right, so I've got two identical containers, each with identical amounts of water, each on identical weighing scales, and each in the same g field. If one container has hotter water, will the reading on its scale be larger than the other? If the answer is yes, and g is constant, does this mean that the m in w=mg has got bigger?


I've tried many ways, but it seems that it didn't work: $$    \int_1^{+\infty}\frac{\mathrm dx}{x(x+1)(x+2)\cdots(x+n)}      = \int_0^1\frac{x^{n-1}}{(x+1)(2x+1)\cdots(nx+1)}\mathrm dx      = \cdots $$ Any help would be appreciated!

I would like to compute: $$\int_0^\infty\frac1{(x+1)(x+2)\cdots(x+n)}\mathrm dx $$ $$ n\geq 2$$ So my question is how can I find the partial fraction expansion of $$\frac1{(x+1)(x+2)\cdots(x+n)}\ ?$$


Let $E = \mathbb{Q}(\sqrt{4+\sqrt{7}})$. Prove that $E$ is a normal extension of $\mathbb{Q}$ and find the Galois group $Gal(E/\mathbb{Q})$.  My attempt:  Let $\alpha = \sqrt{4+\sqrt{7}}$. $\alpha$ is a root of the polynomial $(x^2 - 4)^2 - 7$.   1) How can I show $f(x) = (x^2 - 4)^2 - 7 = x^4 - 8x^2 + 9$ is irreducible over $\mathbb{Q}$ because I can't apply Eisenstein condition?  If $f(x)$ is irreducible, $[E:\mathbb{Q}] = 4 = |Gal(E/\mathbb{Q})|$ and I have shown that all roots of $f(x)$, say $\alpha_{1} = \sqrt{4+\sqrt{7}}, \alpha_{2} = -\sqrt{4+\sqrt{7}}, \alpha_{3} = \sqrt{4-\sqrt{7}}, \alpha_{4} = -\sqrt{4-\sqrt{7}}$  are in $E$ and hence $E$ is a normal extension of $\mathbb{Q}$. Let $Gal(E/\mathbb{Q}) = \{ e,\sigma,\tau,\sigma\tau \}$  2) How can I find the order of $\sigma,\tau$ to find $Gal(E/\mathbb{Q})$? Thanks.

Let $\alpha =\sqrt{4+\sqrt 7}$ and $\beta =\sqrt{4-\sqrt 7 }$. I have to compute $Gal(\mathbb Q(\alpha )/\mathbb Q)$. So, I found that $Gal(\mathbb Q(\alpha )/\mathbb Q)=\mathbb Z/2\mathbb Z\times \mathbb Z/2\mathbb Z$, that $\mathbb Q(\beta^2)= \mathbb Q(\alpha^2)$. I show that the roots of the minimal polynomial of $\alpha $ are $\{\alpha ,-\alpha ,\beta ,-\beta \}$. But now that ask me to enumerate the element of the galois group. I did it's $\{id, \sigma ,\tau,\sigma \tau\}$ where   \begin{align*} \sigma : \alpha &\longmapsto -\alpha \\ \beta &\longmapsto -\beta  \end{align*} and  \begin{align*} \tau : \alpha &\longmapsto \beta  \\ \beta &\longmapsto \alpha  \end{align*}  But in my correction they wrote   \begin{align*} \sigma : \alpha &\longmapsto -\alpha \\ \beta &\longmapsto \beta  \end{align*}  Question : Who is right ? me or the correction ?  The problem it's that this group is abelian, so if they are right, $$\sigma \tau(\alpha )=\beta \neq -\beta =\tau\sigma (\alpha )$$ so I think I'm right, but in the doubt I prefer to ask you.


I've made a static model of a mannequin to do some tests. My problem is that whenever I scale a part of the model, or the entire mesh, then every time I move the time-line a bit (or Alt middle mouse. I'm used to zooming that way from maya) the scaled meshes return to previous scale, along individual centers.    Here's a image sample of the problem: 1 Before the scale     2 After the scale (note the time-line)  3 After moving the time-line*     This effect would also happen if I'd scale the mesh, and then export it as a FBX (without moving the time-line).  I've tried to apply the scale onto the model. In effect the elements of the model get incredibly small, when the time-line moves/I export it.  I would be very grateful for any help with this issue.  *I know it wasn't exactly by 5. My mistake. But it's visible that the current time has changed.

On my current .blend file, when I edit a particular object's origin point and save it, opening the file again resets the origin back to where it was before. I'm unable to save the object with a new origin location. I tried doing CtrlA to set to apply location, rotation, and scale, and then saving it, but upon reopening the object was scaled strangely and the origin once again not in the right location.


I have the output from a command in gnome-terminal, but there is too much text currently so it is wrapping, but the wrapping means that it is much harder for me to read the output because of the nature of it. So I was wondering if there is any way to make the output, or perhaps even all the text, not wrap in gnome-terminal?  I am running Ubuntu GNOME 16.04 with GNOME 3.20.

Is there a way to tell the terminal not to wrap long lines. I wish to see a line in the same space without wrapping to the next one. I do not care if I can not see the end of the line just as long as the line stays in one. A horizontal scroll would be good for this also but for the moment the removal of the wrapping is what I need.


While reading a paper, I encountered the symbol $\gtrless$, which I had not seen before:    Please point me to a reference or tell me what the symbol and associated symbols above and below means.

I'm reading Papadimitriou & Steiglitz's Combinatorial Optimization and came across notation I'd never seen before and don't know what it means. The $\LaTeX$ markup for it is \gtrless ($\gtrless$), which took me quite a while to find.  It arises in the formulation of general linear programs in terms of the constraints on the variables:  $$ x_j \geq 0 \;\; j \in N\\ x_j \gtrless 0 \;\; j \in \bar{N} $$  It's not "not equals" because there's places in the text where the authors say $x$ can be zero.


Suppose I push a book with my hand. I am applying force on it in the process. My question is: What is the carrier of the force I am applying?

If you've ever been annoyingly poked by a geek, you might be familiar with the semi-nerdy obnoxious response of      "I'm not actually touching you! The electrons in the atoms of my   skin are just getting really close to yours!"   Expanding on this a little bit, it seems the obnoxious geek is right. After all, consider Zeno's paradox. Every time you try to touch two objects together, you have to get them halfway there, then quarter-way, etc. In other words, there's always a infinitesimal distance in between the two objects.   Atoms don't "touch" each other; even the protons and neutrons in the nucleus of an atom aren't "touching" each other.  So what does it mean for two objects to touch each other?   Are atoms that join to form a molecule "touching"? I suppose the atoms are touching, because their is some overlap, but the subatomic particles are just whizzing around avoiding each other. If this is the case, should "touching" just be defined relative to some context? I.e, if I touch your hand, our hands are touching, but unless you pick up some of my DNA, the molecules in our hands aren't touching? And since the molecules aren't changing, the atoms aren't touching either?  Is there really no such thing as "touching"?


This question is number 6 of 3.1 of wayne patty topology.  Let  T be finite complement topology on $\mathbb{R}$. Is ($\mathbb{R} , T)$ connected?  Attempt: I took $\mathbb{R}=U \bigcup V$ , U ,V both open. Now I have to see if $\bar U \bigcap {V } = \bar {V} \bigcap U = \phi $ . But I am not able to undestand what closure of U will be in Finite complement topology. Can you please help in that?

what i had done :let X be a infinite set and there be open sets $A,B$ on it. such that $A\cap B =\varnothing$ or $A\cap B\ne\varnothing$then  $X-A\cap X-B \ne  \varnothing $ .which means there doesn't exist   $X-A\cap X-B = \varnothing $ ,which implies that there is no separation of X in finite complement topology. is this proof correct.


Let us consider the following scenario.  This is the partial code in the main.tex file and which includes code from other tex files like certificate.tex, abstract.tex etc.,   .................... \include{certificate} \include{abstract} \include{introduction} ...................   Now I want to incorporate separate font size and font style to each one of the above. For example let us say I want certificate to be of font size 12pt with font family Arial, abstract to be of font size 11pt with font family Courier. And finally the abstract should follow font size and font family, which I declare globally for whole document.  Is it possible to change for particular chapters without changing remaining document.   I am expecting some code like this  .................... \font{12pt}{Arial}{\include{certificate}} \font{11pt}{Courier}{\include{abstract}} \include{introduction} ...................

The standard font packages make global changes to the fonts in my document. What if I want to use a particular font for just a portion of my text?   How do I find the right name of the font? How do I select the font? How do I restrict the scope of the font change?     There are separate answers for different flavors of TeX (quick links):


The claim is that, for a regression task, the conditional regression function $f(x) = \mathbb{E}[\mathbf{Y}|\mathbf{X}=x]$ minimizes the L2 loss $\arg\min(\mathbb{E}[\mathbf{Y} - f(\mathbf{X})]^2)$. I can see why it's true for a normal distribution. But why is it true in general?

I want to understand the importance of optimizing the correct loss function. Say that I am building a linear regression model $p$ for predicting some values $y_1,\ldots,y_n$.  I choose to fit my linear model such that it minimizes the mean squared errors. Now I send my model off to a statistical prediction competition, where they instead of using MSE as an error metric uses mean absolute error (so no squares). How will this affect my models predictive power? In general, what can be said about the importance of optimizing the "correct" loss function?  Edit: If one should put the question in a more specific context, then that context would be predictive modelling competitions like those featured on . I want to understand the importance of choosing models and loss functions which correspond to the evaluation metric for the competition. One reason for this is .


Suppose $f:\left[0,1\right]\rightarrow R$ is continuous on $\left(0,1\right)$. Prove there is a sequence of step functions $\left\{f_{n}\right\}$ which converge pointwise to $f$ on $\left[0,1\right]$.  John Franks - A (Terse) Introduction to Lebesgue Integration 2009 - 1.5.6 (7), page 13. But, consider $f=\sin\frac{1}{x}$, with $f=a$ when $x=0$, is continuous on $\left(0,1\right)$. Suppose that, a step function $f_{n}$, is constant on $\left[0,k\right]$, $k<1$. Since, $-1\leq\sin\frac{1}{x}\leq1$ on $\left(0,k\right)$, so $\lim_{n\rightarrow\infty}f_{n}\neq f$ I can't believe this book is wrong. Is my example correct? If it's not, how to prove this problem? Thanks.

Question: Suppose $f: [0,1] \rightarrow \mathbb{R}$ is continuous on $(0,1)$. Prove there is a sequence of step functions $\left\{f_{n}\right\}$ which converges pointwise to $f$ on $[0,1]$.    I saw the same question was asked  but I was still confused regarding the solution to the question.   I had attempted a solution but I now realize this solution is wrong:  Proof: Since $f$ is continuous on $(0,1)$, then for every $x \in (0,1)$ and for every $\epsilon>0$, there exists a $\delta(x)$ such that $|f(x)-f(y)|<\epsilon$ whenever $y \in (0,1)$ and $|y-x|<\delta(x)$. In particular, let $\epsilon_{n} = 1/2^{n}$ and let $\delta_{n}(x)$ be the corresponding $\delta$ which is guaranteed by the continuity of $f$. Fix a value of $n$ and choose a partition $x_{0}=0 < x_{1} < x_{2} < \ldots < x_{m} = 1$ such that $x_{i}-x_{i-1} < \delta_{n}(x)$. Let $f_{n}(x):= f(x_{i-1})$ for all $x \in (x_{i-1}, x_{i})$. Clearly $f_{n}(x)$ is a step function and hence $\left\{f_{n}\right\}$ is a sequence of step functions. Observe that $f_{n}(x)=f_{n}(x_{i-1})=f(x_{i-1})$. Finally, by the continuity of $f$ and by the fact that $x_{i}-x_{i-1} < \delta_{n}(x)$, we may conclude that \begin{align*} |f(x)-f_{n}(x)| \leq |f(x)-f(x_{i-1})| < \epsilon_{n}  \end{align*} and so the sequence converges pointwise to $f$.  End of proof.  I was hoping someone can shed some light on the correct solution to this problem. Any hints would be appreciated. Thanks!


Can someone find $x$ in the figure? I tried to solve it, but failed.

The following is a geometry puzzle from a math school book. Even though it has been a long time since I finished school, I remember this puzzle quite well, and I don't have a nice solution to it.  So here is the puzzle:    The triangle $ABC$ is known to be isosceles, that is, $AC=BC$. The labelled angles are known to be $\alpha=\gamma=20°$, $\beta=30°$. The task is to find the angle labelled "?".  The only solution that I know of is to use the sine formula and cosine formula several times. From this one can obtain a numerical solution. Moreover this number can be algebraically shown to be correct (all sines and cosines are contained in the real subfield of the 36th cyclotomic field). So in this sense I solved the problem, but the solution is kind of a brute force attack (for example, some of the polynomials that show up in the computation have coefficients > 1000000). Since the puzzle originates from a book that deals only with elemetary geometry (and not even trigonometry if I remember correctly) there has to be a more elegant solution.


I know that we use protons in the LHC. So my question is, how is the proton separated from the electron in the hydrogen?

I heard that the LHC smashes two protons together to research the universe.  But how does it create the protons for collision? If we strip off the electrons won't there be neutrons along with protons?  A  is used by the LHC, it ionises atoms into negative or positive ions but how is the proton separated from that?


Did it ever really make a difference? I haven't restarted after an install in nearly 15 years if I'm honest. What have I been missing out on? Keep in mind I mean simple software, not huge drivers, operating system updates, or major downloads like that.

Even the smallest update of one package or security patch makes Windows need to restart. Why? If an anti-virus application doesn't need it after patch update, why Windows need it after updating Security Essentials' virus-signature files? On the other hand, Linux mostly doesn't need it except when it upgrades its kernel. Note: I am talking especially about Windows 7. I don't know much about Windows 8, or the Server editions.


I need to use the host to build a URL with a different port.  For example, if the host is example.com, I need to generate a URL like   I need it to be portable, so when I'm in my local enviroment it shows  instead.  Any ideas?

I'm in the process of maintaining a Ruby on Rails app and am looking for an easy way to find the hostname or IP address of the box I'm on (since it's a VM and new instances may have different hostnames or IP addresses). Is there a quick and easy way to do this in Ruby on Rails?  Edit: The answer below is correct but the clarification Craig provided is useful (see also provided link in answer):     The [below] code does NOT make a   connection or send any packets (to   64.233.187.99 which is google). Since UDP is a stateless protocol connect()   merely makes a system call which   figures out how to route the packets   based on the address and what   interface (and therefore IP address)   it should bind to. addr() returns an   array containing the family (AF_INET),   local port, and local address (which   is what we want) of the socket.


Is the usage of 2 consecutive 'that' in the following sentence correct, because it looks a bit odd? Should these be separated by comma perhaps?  "While I agree that strength and size definitely gives an advantage but I don't believe that that advantage holds up against a highly skilled fighter!"

Have you ever had a case where you felt compelled to include strange things like a double that in a sentence? If so, then what did you do to resolve this?  For me, I never knew whether it was acceptable grammar. However, what I did learn was that it was a logic distractor, could lead to confusion, and therefore should be reworded to avoid this.


I am reading Roger Scruton's Kant, A Very Short Introduction. The following sentence, in the first page, makes me pretty confused (I include the context to make it clearer):     (The greatest modern philosopher was moved by nothing more than by duty. His life, in consequence, was unremarkable.)      For Kant, the virtuous man is so much the master of his passions as scarcely to be prompted by them, and so far indifferent to power and reputation as to regard their significance as nothing beside that of duty itself.      (Having confined his life so that he could act without strain according to this ideal, Kant devoted himself to scholarship, entirely governed by congenial routines.)   I need an analysis for this sentence. I don't understand the phrase "so much ... as (scarcely) to do ...". I wonder the meaning and the usage of this kind of construction, explained in the context, not merely a translation, and I don't understand "so far ... as to do ...".  Incidentally, what's the meaning of "itself" here in the phrase "beside that of duty itself".  I need your help to understand this sentence well.  EDIT: Related:

First of all, this is not a duplicate... E.g., have a look at these posts:      Anytime people on those posts talked about the use of 'so...as...', they said either that it can be used 'only in negative context' or that it can be used 'only with negative comparatives'.   Well, it is not clear to me at all what is meant by 'negative context/comparatives'... I am quite sure there was something significant omitted in the explanations. E.g., look at the following sentences:     Like the coordinating conjunctions, it is perfectly fine to begin sentences with because, so long as you keep in mind that the goal is to avoid fragments.   (Source: ).  This sentence does not seem to contain any 'negative context/comparatives'.     So foolish, unreasonable, or out of place as to be amusing.   (Source: ).  This sentence does not seem to contain any 'negative context/comparatives' either.    And this post was not meant to be derogative in any way... I am sorry if anyone got offended.  I have also left the exact URLs of most of the websites I have linked to (without having used the hyperlink function) so as to let the users see some information about the links given before having them clicked on the link.   (additionally, is 'before having them clicked on the link' grammatical? I am not a native English speaker and I'm trying to get a hang of some more advanced kind of structures).  Some justifications of the uses of 'so...as...' in the two given sentences would be appreciated (as well as some other grammar corrections present in this post, if possible). Thanks!


Why this python code  print 888888803. == 8888888.03*100. prints False?

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


I am looking to calculate the distance from a main point to multiple points WITHIN shapefile.  In other words: I have a main point at the mouth of a creek. I have about 1,200 points at various distances upstream from the mouth. I would like to calculate the distance from the mouth to each individual point. (aka, mouth to point 1, mouth to point 2, mouth to point 3, etc.) So, in the end, I would end up with 1,200 measurements, all starting at the mouth of the creek.  I can only find tools that measure Euclidean distance or measure distance BETWEEN two consecutive points along a line, which will not work. I am looking for something that measures distance ALONG the route of the creek from one main point to multiple other points. Any tips?  Screenshot image: want to find individual measurements from mouth point (red) to each blue point.   I'm using ArcGIS 10.3.1. I have no experience with Python.

I'm using ArcGIS 10.3 (Desktop), and I'm trying to measure the distance between points following a path determined by a set of polylines.  Hand measurement is not a viable option-- there are ~7500 points, and my polyline set is the global coastline.  The ultimate goal is to get the spacing of these points along the polylines, so that I can analyze this with respect to a few other variables.   I can read python-- with a bit of effort-- but not write or edit it, so code-based solutions will not be particularly useful to me.  I have tried using the linear referencing tools-- I snapped the points to the lines, then transformed the polylines to routes and used 'locate features'-- but because my points are not (entirely) ordered along the path, using the difference between  linear reference locations of subsequent points yields some fairly unlikely answers.  In addition, spot checks of (hand-measured, using the built-in path length measuring tool) point-to-point along-polyline distance yield different answers than given by the corresponding linear references for the point pair. (Some of the answers were close enough that they could very well be measurement error on my part, but others were nearly 20%, despite my having zoomed in and snapped the measurement cursor to the polyline, proceeding vertex-to-vertex.)  Sorting first by linear distance seems to fix the first problem, but in light of the second one, I remain skeptical of this process.   I then tried simply splitting the polylines into segments ('split line at point') using the (snapped) points as the dividers, with the eventual goal of finding the segment length with the calculate geometry feature.  This produced gibberish. I'm not sure what criteria ArcGIS used to split the lines, but it wasn't the point set I provided.  Segments in the resulting shapefile ran right through tens of points, only to terminate at a place with no point. (Also, there were segments utterly empty of points...you get the gist.) I reiterate that the pointset was specifically snapped to the polylines, so this problem shouldn't be caused by excessive distance between the point and the polyline.  I'm at a bit of a loss, here: could someone point out where I might have gone astray and/or suggest a solution?  Or, failing that, a new method that I could try?  It seems like a fairly basic (not necessarily simple, but fundamental) analysis to do with geographic data, and I don't understand why it has presented so many difficulties.


Please help me...  I saw a news titile like this:  INDONESIA TO REVIEW CHINA’S BELT AND ROAD PROJECTS IF PRABOWO BEATS WIDODO IN PRESIDENTIAL ELECTION  Here where i saw it   Is the meaning of "to review" is the same as "will review"?

What does to mean in a newspaper headline, for example:     Airline XY to cut cost of pilots' wages   Is it a shorter form of "Is going to" or "Is planning to"?


I'm writing an app that has different functionality depending on the model of iPhone. Is there a way to distinguish between iPhone 5, and 5c 5s? I can not do a check on the display because it is identical. Thanks in advance.

Is there a way to determine the device running an application. I want to distinguish between iPhone and iPod Touch, if possible.


My main site is . I'm not sure how many tag wikis I've edited, but probably not many more than it took to get the shiny silver  badge for editing 50 tag wikis that's also been earned by twelve other users on our site.  Good tag wikis are important and I know I should be writing them, but inevitably I put it off in favour of some other work... a badge would make the difference between getting round to it and not getting round to it.  I know writing and improving tag wikis is a slog and most people won't do it even though there are badges, but that's ok. A site only needs a few badge-pursuers enthusiastic wiki-makers to make a big difference.  So I think there should be a gold badge for making, say, 200 tag wiki edits. It could be called Doctorate (because of the research required), for example.

Citing  from when "Research Assistant" badge was created     Looking through the data, it seemed to me that excerpts are handled fairly well by the community. I wanted to add a push to wiki editing, not excerpt editing (which is forced anyway). So... the badge counts distinct tag wikis you edit excluding excerpts."   17 months after its creation, the "Research Assistant" badge has certainly helped to improve Stack Overflow's tag wikis (103 badges awarded * 50 tag wiki edits = at least 5150 improvements made).    Yet, many tags there still do not have tag wiki or wiki excerpt. Examples of the latter:  models - 1150 questions, show - 1148 questions, alertdialog, 1070 questions, reload - 997 questions, send - 958 questions.  New examples (28-Nov-14):    - 1162 questions.  - 1047 questions.  - 985 questions.  - 938 questions.   BTW, it's odd that the "learn more" page doesn't show the wiki when it exist, but the excerpt. E.g.: see tags layer and matching. Reported this .   There are some broad tags where it is useful to have excerpt with:     the tag meaning  information about when to use the tag, and when not to use it   Tag wiki excerpts are very helpful to keep SE websites organized and new users well-informed. If SO's situation is still not perfect (comfortable, though) smaller SE sites struggle a lot to get certain resilience, with respect to this matter.  Thesis statement  Although "Research Assistant" creation was a leap of improvement to the completion of SO's tag wikis, many SO tags still don't have tag excerpts/wikis, and much less smaller SE sites (which could greatly benefit from this proposal too).  Proposal  Improve the current incentive for creation/edition of tag wikis and tag excerpts.  Note that this is a rough draft.    Make tag excerpts count for "Research Assistant" (silver) badge.     Research Assistant (silver): 50 edits on tag wiki and/or tag excerpts.    Create a new gold badge for tag wikis     Librarian (gold): 100 tag wikis edited (not valid for tag excerpts).  These (new/modified) badges should be awarded retroactively.   Tag Editor (bronze) can stay as it is.    These suggestions would further incentivize the completion and improvement of tag wiki and tag excerpts beyond what the original "Research Assistant" already does.  I am fine with the +2 reputation gain for tag edits – not suggesting any changes to that.


How to install and configure ansible on Ubuntu 16.04?

I'm following this document to install ansible:    I'm try to add ansible to my ubuntu repositories list but this is what happens:   me@mydev:~/Documents$ sudo apt-add-repository ppa:ansible/ansible Cannot add PPA: 'ppa:~ansible/ubuntu/ansible'. ERROR: '~ansible' user or team does not exist. me@mydev:~/Documents$    I've also tried to just clone the repo (following these instructions: ) But that fails with the following:   me@mydev:~/Documents/ansible$ git clone git://github.com/ansible/ansible.git --recursive Cloning into 'ansible'... fatal: unable to connect to github.com: github.com[0: 192.30.252.131]: errno=Connection timed out  me@mydev:~/Documents/ansible$ ping 192.30.252.131 PING 192.30.252.131 (192.30.252.131) 56(84) bytes of data. 64 bytes from 192.30.252.131: icmp_seq=1 ttl=56 time=23.4 ms 64 bytes from 192.30.252.131: icmp_seq=2 ttl=56 time=23.5 ms ^C --- 192.30.252.131 ping statistics --- 2 packets transmitted, 2 received, 0% packet loss, time 1000ms rtt min/avg/max/mdev = 23.466/23.511/23.557/0.159 ms me@mydev:~/Documents/ansible$    As you can see, I'm getting a connection timeout error.  I tried pinging the server and it seems to be able to communicate with my box. Not sure what else I could try.   thanks.  EDIT 1  I am behind a proxy.  I ran this command to identify my proxy server:   me@mydev:~/Documents/ansible$ export http_proxy=http://10.20.30.40:8080   and then to test, I ran:   sudo apt-get update   and it ran fine.


I'm interested to find out the options and best practices for allowing the client-side to identify an object in the server-side database, without the client being aware of the true primary key of that object.   For example, a form that updates the person #3 record:  <form method="POST" action="/people/3/update">     <input type="text" name="first_name"/>     <input type="text" name="last_name"/>     <input type="submit"/> </form>   What I'd like to avoid is the client side becoming aware of the number 3 specifically, as it points directly to a database record for this user, and I figure it's better if there is not glimpse of server-side data on the client-side.  I'm already aware of a few options:  1) Encrypt all primary keys before they are sent to the client, decrypt them when they come back. I'd imagine this has non-negligible overhead. 2) Perform some sort of non-cryptographic modification of every key before sending it to the client, and perform the reverse on the server-side (like adding 11 and then later subtracting 11 again). While this doesn't truly hide values, it barely has any overhead.  Da Questions  1) Should I worry about this in the first place?  2) What are considered to be effective ways of doing this?  3) Are there any good sources I can consult for further reading?  Thanks in advance for any help!

I've heard that exposing database IDs (in URLs, for example) is a security risk, but I'm having trouble understanding why.  Any opinions or links on why it's a risk, or why it isn't?  EDIT: of course the access is scoped, e.g. if you can't see resource foo?id=123 you'll get an error page. Otherwise the URL itself should be secret.  EDIT: if the URL is secret, it will probably contain a generated token that has a limited lifetime, e.g. valid for 1 hour and can only be used once.  EDIT (months later): my current preferred practice for this is to use UUIDS for IDs and expose them. If I'm using sequential numbers (usually for performance on some DBs) as IDs I like generating a UUID token for each entry as an alternate key, and expose that.


I went to review some close questions.  The first question I was given for my filter was    I clicked on the title to view the full question and edit it ( I wanted to remove one of the tags), but the link went to a page not found page    Why am I being asked to review a question that seems to have already been removed?

I was reviewing some stuff today, and I came across a rather ridiculous answer (see screenshot). I wanted to see the question and other answers, so I clicked on the link, and found that the answer I was reviewing was in fact deleted. Could someone take a look at it?


I want to access the url that is printed on the command line. For example, if I see the man pages for dropbox, there are some url links with underlines (i.e. https://www.dropbox.com/)--     The only way to access this url is to do right click and copy the link.  Is there anyway I can access it using a single click?

I'm using irssi hosted on a remote computer for IRC, and it'd be super helpful not to have to hold Control or right-click every single link (so I can avoid multiple clicks or multiple hands).  At this point I'm willing to download gnome-terminal's source and manually patch it and rebuild the package.


C++ / Win32. As shown in the popup menu pic, there's a large space at the right side of the menu. This is common to all popup menu's I've seen, probably there as a placeholder for a shortcut key combination. I was asked to clip the width to the menu text, but couldn't find any way to do it using the standard menu API or window repositioning API.  Is there any simple method to do it without going into owner-drawn?

I'm creating a custom control in wxWidgets that displays a menu as part of it, and currently working on the Windows side of things.  wxWidgets doesn't have a way of setting the width of a menu.  It just makes the window as wide as the longest string plus a few pixels on either side.  In the API, there is a way to get the actual Windows API menu handle.  Does the Windows API have a method of setting the width of a menu other than just calculating it on its own based on the width of the string?


I tried to install RStudio after installing R in Ubuntu. When I clicked to install via Ubuntu software, clicking the install button does nothing. But sometimes when I click it, it starts loading and after a while it says rstudio installed. But it's not really installed.   So I installed it via terminal using:  $ sudo dpkg -i rstudio-0.99.902-i386.deb  Selecting previously unselected package rstudio. (Reading database ... 175645 files and directories currently installed.) Preparing to unpack rstudio-0.99.902-i386.deb ... Unpacking rstudio (0.99.902) ... dpkg: dependency problems prevent configuration of rstudio:  rstudio depends on libjpeg62; however:   Package libjpeg62 is not installed.  rstudio depends on libgstreamer0.10-0; however:   Package libgstreamer0.10-0 is not installed.  rstudio depends on libgstreamer-plugins-base0.10-0; however:   Package libgstreamer-plugins-base0.10-0 is not installed.  dpkg: error processing package rstudio (--install):  dependency problems - leaving unconfigured Processing triggers for shared-mime-info (1.5-2) ... Processing triggers for gnome-menus (3.13.3-6ubuntu3) ... Processing triggers for desktop-file-utils (0.22-1ubuntu5) ... Processing triggers for bamfdaemon (0.5.3~bzr0+16.04.20160415-0ubuntu1) ... Rebuilding /usr/share/applications/bamf-2.index... Processing triggers for mime-support (3.59ubuntu1) ... Processing triggers for hicolor-icon-theme (0.15-0ubuntu1) ... Errors were encountered while processing:  rstudio   What are the steps to rectify this error?

I'm trying to install  on my Ubuntu box (11.04). The website has a Ubuntu .deb available for download (for 10.10 and 10.04 so I chose 10.10).   However,   sudo dpkg -i mysql-workbench-gpl-5.2.34-1ubu1010-amd64.deb   yields:  (Reading database ... 194069 files and directories currently installed.) Preparing to replace mysql-workbench-gpl 5.2.34-1ubu1010 (using mysql-workbench-gpl-5.2.34-1ubu1010-amd64.deb) ... Unpacking replacement mysql-workbench-gpl ... dpkg: dependency problems prevent configuration of mysql-workbench-gpl:  mysql-workbench-gpl depends on libctemplate0; however:   Package libctemplate0 is not installed.  mysql-workbench-gpl depends on libpython2.6 (>= 2.6); however:   Package libpython2.6 is not installed.  mysql-workbench-gpl depends on libzip1 (>= 0.8); however:   Package libzip1 is not installed.  mysql-workbench-gpl depends on python-paramiko; however:   Package python-paramiko is not installed.  mysql-workbench-gpl depends on python-pysqlite2; however:   Package python-pysqlite2 is not installed. dpkg: error processing mysql-workbench-gpl (--install):  dependency problems - leaving unconfigured Processing triggers for bamfdaemon ... Rebuilding /usr/share/applications/bamf.index... Processing triggers for desktop-file-utils ... Processing triggers for python-gmenu ... Rebuilding /usr/share/applications/desktop.en_US.utf8.cache... Processing triggers for python-support ... Errors were encountered while processing:  mysql-workbench-gpl   My question is, is there a way to tell dpkg to automatically fetch missing dependencies, or do I need to manually apt-get install missing packages like libctemplate0 and  libpython2.6?   (Or alternatively, is there some other way to get MySQL Workbench easily up & running?)


I made a huge base from bottom to the top I also made walls it almost finished I need water to protect it from TNT but how do I stop it from freezing the water?  Someone did there's duplicate of this question IT'S NOT there's nothing about on faction bases like on walls

In one of my worlds I built a house on the top of a mountain. When starting to build a wheat farm, I found out that the water keeps freezing, and I have to break the ice blocks:    Does wheat grow even if it is near ice instead of water? If not, how can I prevent the water from freezing?


I am using bibtex, with the bibliography style ieeetr to create my references. I have read the IEEE style manual, and I know that I should leave citations in separate sets of brackets, e.g., [3], [4].   However, I know that they should be hyphenated when consecutive, in groups of 3 or more, e.g., [5]-[10] but the ieetr style doesn't seem to do this automatically. Any ideas? I have already tried using the cite package.  MWE:  \documentclass{article}  \usepackage{cite}  \begin{document}  This is my text, and here are some citations \cite{article1}, \cite{article2}, \cite{article3}. \bibliography{examplebib}  \bibliographystyle{ieeetr}  \end{document}   And the bib file "examplebib.bib"  @article{article1,   author    = {Doe, John},   title     = {Title of article},   journal   = {journal of article},   year      = {2017},   volume    = {11},   number    = {1},   pages     = {11--13},   publisher = {Journal Publisher}, } @article{article2,   author    = {Doe, John},   title     = {Title of article},   journal   = {journal of article},   year      = {2017},   volume    = {11},   number    = {1},   pages     = {11--13},   publisher = {Journal Publisher}, } @article{article3,   author    = {Doe, John},   title     = {Title of article},   journal   = {journal of article},   year      = {2017},   volume    = {11},   number    = {1},   pages     = {11--13},   publisher = {Journal Publisher}, }

I have been trying to display the in-text citations in the following format:  [1-3], or [1, 6-8]  which looks like it is the default one inside the cite package, but what I get is:  [1]-[3]  Specifically, I'm using the IEEEtran template (bare_jrnl to be more precise) and the bibliography is built in the following way:  \bibliographystyle{IEEEtran} \bibliography{IEEEabrv,mybib}   The cite package is obviously loaded. I have looked the documentation of both IEEEtran and cite, but I have not been able to find a solution.


I want to create object like this:    How can I achieve this?

I'm trying to figure out the best way to model the sphere-spiral here:    Is it possible to make this shape directly? Or do you have to make it as a cylinder and wrap it to a sphere?


I am trying to remove all of the older computers that AD stores that have not been active for 60 days. I just started working with AD recently and noticed that the AD has not had a proper cleanup in a long time. I only have about 120 computers/servers but ad has over 300 registered. Does anyone have any advice or solutions for this?   Thanks in advanced!

The Windows Domain I manage has hundreds of computer names which I don't recognise and I'd like to remove old ones which aren't in use before trying to track down the misnamed ones.  Is there someway to see when the last time a machine logged onto the network? Either via dhcpd or a user login event or something else.


I want to delete var/log files due to low disk space, but I cannot find out how.

( deals with a similar issue, but it talks about a rotated log file.)  Today I got a system message regarding very low /var space.   As usual I executed the commands in the line of sudo apt-get clean which improved the scenario only slightly. Then I deleted the rotated log files which again provided very little improvement.  Upon examination I find that some log files in the /var/log has grown up to be very huge ones. To be specific, ls -lSh /var/log gives,   total 28G -rw-r----- 1 syslog            adm      14G Aug 23 21:56 kern.log -rw-r----- 1 syslog            adm      14G Aug 23 21:56 syslog -rw-rw-r-- 1 root              utmp    390K Aug 23 21:47 wtmp -rw-r--r-- 1 root              root    287K Aug 23 21:42 dpkg.log -rw-rw-r-- 1 root              utmp    287K Aug 23 20:43 lastlog    As we can see, the first two are the offending ones. I am mildly surprised why such large files have not been rotated.  So, what should I do? Simply delete these files and then reboot? Or go for some more prudent steps?  I am using Ubuntu 14.04.  UPDATE 1  To begin with, the system is only several months old. I had to install the system from scratch couple of months back after a hard disk crash.  Now, as advised in ,  I first checked the offending log files using tail, no surprise there. Then, for deeper inspection, I executed this script from the .  for log in /var/log/{syslog,kern.log}; do    echo "${log} :"   sed -e 's/\[[^]]\+\]//' -e 's/.*[0-9]\{2\}:[0-9]\{2\}:[0-9]\{2\}//' ${log} \   | sort | uniq -c | sort -hr | head -10 done   The process took several hours.  The output was in the line of,   /var/log/syslog : 71209229  Rafid-Hamiz-Dell kernel:  sda3: rw=1, want=7638104968240336200, limit=1681522688 53929977  Rafid-Hamiz-Dell kernel:  attempt to access beyond end of device 17280298  Rafid-Hamiz-Dell kernel:  attempt to access beyond end of device    1639  Rafid-Hamiz-Dell kernel:  EXT4-fs warning (device sda3): ext4_end_bio:317: I/O error -5 writing to inode 6819258 (offset 0 size 4096 starting block 54763121030042024)        <snipped>  /var/log/kern.log.1 : 71210257  Rafid-Hamiz-Dell kernel:  attempt to access beyond end of device 71209212  Rafid-Hamiz-Dell kernel:  sda3: rw=1, want=7638104968240336200, limit=1681522688    1639  Rafid-Hamiz-Dell kernel:  EXT4-fs warning (device sda3): ext4_end_bio:317: I/O error -5 writing to inode 6819258 (offset 0 size 4096 starting block 954763121030042024)    (/dev/sda3 is  my home directory. As we can find,   lsblk /dev/sda NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT sda      8:0    0 931.5G  0 disk  ├─sda1   8:1    0 122.1G  0 part / ├─sda2   8:2    0   7.6G  0 part [SWAP] └─sda3   8:3    0 801.8G  0 part /home    Why a process will want to write beyond the limit is actually outside the scope of my comprehension. Perhaps I will want to ask a different question in this forum if this continues even after a system update.)  Then, from  (you may want to check  for a deeper understanding), I executed,   sudo su - > kern.log > syslog   Now, these files have zero sizes. The system is running fine before and after a reboot.   I will watch these files (along with others) in the next few days and report back should they behave out-of-line.  As a final note, both  the offending files (kern.log and syslog), are set to be rotated, as inspection of the files (grep helped) inside  /etc/logrotate.d/ shows.  UPDATE 2  The log files are actually rotated. Looks like the large sizes were attained on a single day.


i have made an Qr-Scanner now the activity has button. if i click the button it opens the scanner so i'm doing good with it, but if i go back to the previous activity without clicking the button i get the NullPointerException from the onPause() .  @Override public void onPause() {     super.onPause();      mScannerView.stopCamera();  }   if i go to previous activity without opening the camera then it is giving the error. someone help me

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


I'm trying to insert data into a Webmin MySQL Database, but every time I hit submit on my form, It doesn't put the information in the MySQL database. I ran a test and it's running all the way to the INSERT part but it still didn't put anything in the DB. I can read from it just fine, but I can't write to it. I have all the permissions, but it still doesn't work. It also get all of the variables ($tblusername, $tblemail, $tblpassword). Here's my PHP (I'm using PDO.) Please help! <?php     if(isset($_POST['submit'])) {         try {         $tblusername = $_POST['Username'];         $tblemail = $_POST['Email'];         $tblpassword = $_POST['Password'];          $conn = new PDO("mysql:host=$servername;dbname=mealplan", $username, $password);         $conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);         $stmt = $conn->prepare("SELECT UserName FROM tblUsers");         $stmt->bindParam(1, $tblusername, PDO::PARAM_STR);         $stmt->execute();          if($stmt->rowCount() > 0){         die("Username already in use!");         }else{           $sql = "INSERT INTO `tblUsers` (`UserName`, `Email`, `UserPassword`) VALUES ($tblusername, $tblemail, $tblpassword)";           $stmt = $conn->prepare($sql);           $stmt->execute();         }       } catch(PDOException $e) {       echo "<style>.hidden { visibility: visible; } .shown { visibility: hidden; font-size: 0px }</style>";       }     } ?>

If user input is inserted without modification into an SQL query, then the application becomes vulnerable to , like in the following example:  $unsafe_variable = $_POST['user_input'];   mysql_query("INSERT INTO `table` (`column`) VALUES ('$unsafe_variable')");   That's because the user can input something like value'); DROP TABLE table;--, and the query becomes:  INSERT INTO `table` (`column`) VALUES('value'); DROP TABLE table;--')   What can be done to prevent this from happening?


I have 3 classes, 2 service layer classes are calling a utility class. Is it possible to find the name of the class that is calling my static method from within the method or is it too late at that point?   I don't want to pass the class when I call it because I feel like I should be able to infer that and want to ensure that there is no room for error. Like if the wrong class is passed or if null is passed instead.   Is this possible?  // ClassA.java public void doSomething(){     // Logic ...     ClassC.invoke(); }  // ClassB.java public void doSomethingElse(){     ClassC.invoke();     // Logic ... }  // ClassC.java private static final Logger LOGGER = LoggerFactory.getLogger(ClassC.class);  public static void invoke(){     String callingClass = // findClassingClassName      LOGGER.info("ClassC::invoke was called by: {} @ {}", callingClass, LocalDateTime.now()); }

I need to find the caller of a method. Is it possible using stacktrace or reflection?