body1
stringlengths
20
4.1k
body2
stringlengths
23
4.09k
Suppose $X1$ and $X2$ are iid Bernoulli random variable with parameter $p$ where it is known that $1/3<=p<=2/3$. Find the maximum likelihood estimator $p*$ of $p$ based on $X1$ and $X2$. I could find the MLE and it doesn't include the fact anywhere that the parameter $p$ lies in a certain range. How do I proceed?
Suppose $X_1, X_2, \dots, X_n$ are iid Bernoulli(p) random variables. How do you find the restricted maximum likelihood for p where $0<p<0.5$? My work so far: Write out the likelihood: $L=p^{\sum x} (1-p)^{n-\sum x}$ Take the log: $\ln(L) = \sum x\ln(p)+(n-\sum x)\ln(1-p)$ Take the derivative and set equal to zero: $\frac{\sum x-np}{p(1-p)}=0$. Now I'm stuck. I don't know how to incorporate the restrictions for $p$.
Suppose G is a group, with subgroups H and K. Prove that if H ∪ K is a subgroup of G implies that H ⊆ K or K ⊆ H. I'm not really sure how to start this, I can prove that H ∩ K is a subgroup but I don't know how to approach the union. Any help is appreciated.
Let $H$ and $K$ denote two subgroups of a group $G$. Prove that the union $H \cup K$ is a subgroup of $G$ if and only if $H \subset K$ or $K \subset H$.
So this is my class and I just learned a little bit about inheritance. I heard about overriding methods but how do I do it in this case? class Game { string consoleName; int gameID; public Game(string name, int id) { this.consoleName = name; this.gameID = id; } public string displayGame() { return consoleName + " is the console I am playing"; } Here is my child class. class RolePlayingGame : Game { int level; public RolePlayingGame(string name, int id, int lv) : base(string name, int id) { this.level = lv; } // override method for displaying. meant to display what the game class displayed and "I am level " + level }
Ok, bear with me guys and girls as I'm learning. Here's my question. I can't figure out why I can't override a method from a parent class. Here's the code from the base class (yes, I pilfered the java code from an OOP book and am trying to rewrite it in C#). using System; public class MoodyObject { protected String getMood() { return "moody"; } public void queryMood() { Console.WriteLine("I feel " + getMood() + " today!"); } } and here are my other 2 objects that inherit the base class (MoodyObject): using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 { public class SadObject: MoodyObject { protected String getMood() { return "sad"; } //specialization public void cry() { Console.WriteLine("wah...boohoo"); } } } And: using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 { public class HappyObject: MoodyObject { protected String getMood() { return "happy"; } public void laugh() { Console.WriteLine("hehehehehehe."); } } } and here is my main: using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 { class Program { static void Main(string[] args) { MoodyObject moodyObject = new MoodyObject(); SadObject sadObject = new SadObject(); HappyObject happyObject = new HappyObject(); Console.WriteLine("How does the moody object feel today?"); moodyObject.queryMood(); Console.WriteLine(""); Console.WriteLine("How does the sad object feel today?"); sadObject.queryMood(); sadObject.cry(); Console.WriteLine(""); Console.WriteLine("How does the happy object feel today?"); happyObject.queryMood(); happyObject.laugh(); } } } As you can see, pretty basic stuff, but here's the output: How does the moody object feel today? I feel moody today! How does the sad object feel today? I feel moody today! wah...boohoo How does the happy object feel today? I feel moody today! hehehehehehe. Press any key to continue . . . Not as I expected. I've tried to make the base method virtual and calling override when trying to override it and that just gets me this error "cannot override inherited member 'MoodyObject.getMood()' because it is not marked virtual, abstract, or override". I also tried it without the virtual and override and it thinks I'm trying to hide the base method. Again, I'm new to OOP and would appreciate any guidance. EDITED TO ADD: I found it! The MoodyObject.cs was only a "solution item" in the solution explorer as opposed to a "ConsoleApplication1" item. I dragged it down to where it belonged in the solution explorer and voila! It works now. I marked Luc's answer below as the answer because he offered the help I needed to get to where I have it resolved... I'm learning so much here. It's amazing and you guys and girls are crazy smart!
To reduce the loop area and noisepick up, the GND lead of the scope probe is very next to the tip in the below probe: I don’t have such probes and my scope probe GND leads are much longer alligator clips. Does the type of probe in the photo have a name or is it homemade? And when is it used?
Exactly what it says on the tin. How is this pictured accessory called? The obvious place to look for a name would be the probe manual, but it looks like they decided to add the accessory to the package after making the manual, since it's not on the component list.
Is there any way to reinstall Ubuntu 12.04 straight from the terminal? My terminal works but I literally almost purged my entire operating system by accident (bad advice from a community member). The terminal runs on a black screen now but it works. Any ideas?
I am trying to boot Ubuntu on my computer. When I boot Ubuntu, it boots to a black screen. How can I fix this? Table of Contents:
Anyone knows why the preview (left bottom) looks different than the render (bottom right)? What i tried to achieve is something like i dont know what is going on?!
I have a model of a building with a sidewalk around it. Both show up when I switch to rendering mode in both Blender Render and Cycles Render mode. But: when I hit F12 for a final proper render, the building shows up -- but the sidewalk doesn't. I've checked the normals and I thought the normals seemed pointed in the right direction. I've set the Clipping on the Camera to a high number. I removed all the materials from the sidewalk and added a new material-- the problem persists. I've exported the blend as an FBX file and the Sidewalk shows up fine in Unity. Just in final renders, it doesn't show up. Here is a blend file: . I tried to destroy everything unrelated to the issue and label things in a clear way. Thanks.
Let $S = (\pi(1), \pi(2),\cdots,\pi(n))$ be a permutation of $\{1,2,\cdots,n\}$ such that $S$ does not contain the pattern $\pi(i)<\pi(j)<\pi(k)$ for any $i<j<k$. For example, the permutation $(1,4,3,2,5)$ is not allowed since it contains $1,\cdots,2,5$ in that order. How do we count the number of such permutations (of $n$ numbers)? I know how to count permutations that forbid the pattern $\pi(k)<\pi(i)<\pi(j)$ for any $i<j<k$, namely they are counted by the Catalan Number $C_n$. But the $\pi(i)<\pi(j)<\pi(k)$ pattern doesn't seem to yield to such a method. Any help would be appreciated, Thanks!
There are $k$ penguins, $k\ge 3$. They are all different heights. How many ways are there to order the penguins in a line, left to right, so that we cannot find any three that are arranged tallest to shortest (in left to right order)? The penguin triples do not have have to be adjacent. This problem is courtesy of someone I know only as "DaMancha."
If we have a point charge $q$ then at any point around $q$ we have an electric field due to our source charge $q$. We have a certain value of voltage or potential at this point, which is nothing but the work done by $q$ in moving a charge of $+1C$ from my reference point to infinity. Is my understanding correct?
The english wikipedia page defines the electic potential in the following way: The electric potential at a point r in a static electric field E is given by the line integral $V_\mathbf{E} = - \int_C \mathbf{E} \cdot \mathrm{d} \boldsymbol{\ell}$ where $C$ is an arbitrary path connecting the point with zero potential to $r$. So if we take infinity to be a point with zero potential, the path we take is from the infinity to that point. However the other definition I know states that the electric potential at a given point is equal to the work that needs to be done to move charge $q$ from that point to infinity, divided by $q$. It seems to me that the definitions are not equivalent (both give the same result, but with opposite sign). Could anyone clarify this for me please?
I made a group called "group1" and I want to give it all sudo rights only except "chmod, chown" commands. How can I change below sentence to get through this? Before applying change: %group1 ALL=(ALL) NOPASSWD:ALL
I don't need an administrator to change my root password. I don't want any sudo user to execute this command: sudo passwd $root I have tried it in the sudoers file using the following command: %sudo ALL=(ALL) ALL, !/usr/bin/passwd $root How can I block it?
If you reference an instantiated object in different classes, do changes get updated to the actual object or just the reference .. public class First { List<String> numbers; public First(){ this.numbers.add("one"); this.numbers.add("two"); } } public class Second{ First InstanceOfFirst; public Second(First F){ this.InstanceOfFirst = F; } public void printList(){ for(String s : this.InstanceOfFirst.numbers){ System.out.print(i+", "); } } } public class Third { First Reference; public Third(First F){ this.Reference = F; } public void Update(){ this.Reference.numbers.add("three"); } } So let's say my main looks likes this: public static main(String args[]){ First F = new Frist(); Second sec = new Second(F); Third th = new Third(F); th.Update(); sec.printList(); } Would I get one, two or one, two, three as a result. I guess what I'm trying to ask is: Deos Java make different copies of objects when referenced like this or do they point to the same object?? Please excuse me if my question seems vague ..
I always thought Java uses pass-by-reference. However, I've seen a couple of blog posts (for example, ) that claim that it isn't (the blog post says that Java uses pass-by-value). I don't think I understand the distinction they're making. What is the explanation?
I am building up a CRTP interface and noticed some undefined behavior. So, I built up some sample code to narrow down the problem. #include <iostream> template <typename T> class Base { public: int a() const { return static_cast<T const&>(*this).a_IMPL(); } int b() const { return static_cast<T const&>(*this).b_IMPL(); } int c() const { return static_cast<T const&>(*this).c_IMPL(); } }; class A : public Base<A> { public: A(int a, int b, int c) : _a(a), _b(b), _c(c) {} int a_IMPL() const { return _a; } int b_IMPL() const { return _b; } int c_IMPL() const { return _c; } private: int _a; int _b; int _c; }; template <typename T> void foo(const T& v) { std::cout << "foo()" << std::endl; std::cout << "a() = " << static_cast<Base<T>>(v).a() << std::endl; std::cout << "b() = " << static_cast<Base<T>>(v).b() << std::endl; std::cout << "c() = " << static_cast<Base<T>>(v).c() << std::endl; } int main() { A v(10, 20, 30); std::cout << "a() = " << v.a() << std::endl; std::cout << "b() = " << v.b() << std::endl; std::cout << "c() = " << v.c() << std::endl; foo(v); return 0; } The output of this code is: a() = 10 b() = 20 c() = 30 foo() a() = 134217855 b() = 0 c() = -917692416 It appears that there is some problem when casting the child class, which implements the CRTP "interface", to the interface itself. This doesn't make sense to me because the class A plainly inherits from Base so, shouldn't I be able to cast an instance of A into Base? Thanks!
Someone mentioned it in the IRC as the slicing problem.
I have an object with a lot of fields, is there a method in apex which returns a list of the object's fields?
I am new to Apex, but it is apparent to me that most (if not all) standard objects probably have an ID field. However, this field does not appear in the reference for the standard objects in the Soap API Developer's Guide. Instead, it reads: To verify the complete list of fields for an object, you can use a describe call from the API, or inspect with an appropriate tool, for example, inspecting the WSDL or using a schema viewer. If I want to find out for sure whether an object has an ID field, or what the field is named (is it ID, Identifier, id, etc), it sounds like I need to use a "describe call" or "an appropriate tool" or inspect the "WSDL" using a "schema viewer". Now, I am an experienced software developer, but those solutions are so ambiguous I have no idea where to look next to figure out how to get an object's ID. Can anybody either refer me to more specific documentation, or explain how to find the complete field documentation via a "describe call", "appropriate tool", or "schema viewer"?
Edit Purpose of my study I have weather stations collecting data inside and outside low-tech greenhouses. Four of the weather stations are inside, and one is outside. They are collecting temperature, humidity, solar radiation, wind speed, etc. I am testing to see if the differences between the weather station data inside and outside is statistically significant. Because I have an unequal number of replicates inside and outside the greenhouses, I calculated the difference for each variable between each weather station inside each greenhouse and one weather station outside. This gives me a sample size of 4. Sometimes 3 because I lost a replicate for part of the study. I was hoping to test the significance of the differences from zero rather than the original weather station data. The shapiro wilk test in R finds that none of my data are from a normal distribution. I am debating whether or not to transform the data and use a t-test or use a non-parametric test. I am leaning towards the latter. Question Should I log-transform the data and run the t-test or should I find another non-parametric test to use? What are the pros and cons of each? I have done a bit of research, but I'm still unclear on the best approach. Or is there another approach I haven't thought of. *The post talks about transformations, but it doesn't compare and contrast them to not transforming your data and using a different test.
Say I have some historical data e.g., past stock prices, airline ticket price fluctuations, past financial data of the company... Now someone (or some formula) comes along and says "let's take/use the log of the distribution" and here's where I go WHY? Questions: WHY should one take the log of the distribution in the first place? WHAT does the log of the distribution 'give/simplify' that the original distribution couldn't/didn't? Is the log transformation 'lossless'? I.e., when transforming to log-space and analyzing the data, do the same conclusions hold for the original distribution? How come? And lastly WHEN to take the log of the distribution? Under what conditions does one decide to do this? I've really wanted to understand log-based distributions (for example lognormal) but I never understood the when/why aspects - i.e., the log of the distribution is a normal distribution, so what? What does that even tell and me and why bother? Hence the question! UPDATE: As per @whuber's comment I looked at the posts and for some reason I do understand the use of log transforms and their application in linear regression, since you can draw a relation between the independent variable and the log of the dependent variable. However, my question is generic in the sense of analyzing the distribution itself - there is no relation per se that I can conclude to help understand the reason of taking logs to analyze a distribution. I hope I'm making sense :-/ In regression analysis you do have constraints on the type/fit/distribution of the data and you can transform it and define a relation between the independent and (not transformed) dependent variable. But when/why would one do that for a distribution in isolation where constraints of type/fit/distribution are not necessarily applicable in a framework (like regression). I hope the clarification makes things more clear than confusing :) This question deserves a clear answer as to "WHY and WHEN"
Using Ubuntu 12.04 LTS, upgraded from 11.10. Had no idea while installing Ubuntu for the first time. So missed SWAP partition. Now, at times Ubuntu hangs and system monitor shows the memory usage full. Is there any method that I can create a partition from the current Ubuntu partition and assign it as SWAP partition ? If yes, kindly guide me to do the same. How much SWAP partition space is recommended ? Current specs - 6 GB RAM, 1 GB Radeon GPU.
I did not create a swap partition during Ubuntu installation. Later, I freed up some space and made a swap partition. Now after each boot up, I am manually opening gparted to right-click the swap partition to turn on the 'swapon' option. How can I automatically enable the swap partition at boot? Also, if I had not created the swap partition, what are my other options?
When indicating participants (as in a picture), which is correct; "This is Fred and me." or "This is Fred and I." ? (And, I know my punctuation is incorrect here.)
A question was asked in one of my friend's interview. The question was to determine the right form from the below sentences. Q. Correct form of English: Samuel was with Susan and I Samuel was with Susan and me Samuel was with I and Susan Samuel was with me and Susan None of these Now I vaguely remember a rule of thumb from my school days. That is "2-3-1" i.e. where all the persons are acting in a sentence, second person comes first, then third person and it is followed by first person. So according to this theory, 1 seems to be correct to me. Is this theory correct?
seems to be old-ish and have hard-coded values preventing it to cache large amount of data. $ buffer -m 1G max_shmem 1 too low // it doesn't even understand gigabytes $ buffer -m 1000M Cannot handle that many blocks, aborting! $ buffer -m 1000M -s 1m blocksize 1048576 out of range What do use instead?
Is there a utility that I can stick in a pipeline to decouple read and write speeds? $ producer | buf | consumer Basically, I want a utility buf that reads its input as fast as possible, storing it in memory so consumer can take its sweet time while producer runs as fast as possible.
What is the appropriate SE site for asking about oauth plugins for PHP?
I'm looking into developing an ordering app for a potential client. The main part that I'm concerned about in this question is the payment mechanism. I would assume that there are already multiple plugins or similar programs out there, but I'm not sure where (or if) I should be asking for recommendations.
For uniform charge and mass distribution for a rigid body rotating with a uniform angular velocity about its centre of mass, I want to know if it is just a mathematical artifact of integration which cancels out the factors of moment of inertia (angular momentum) and the magnetic dipole moment or if there is something much deeper. I realize the spin magnetic moment $g$-factor is 2 quantum mechanically, which is another reason why i want to know if there is some kind of emergent property which nicely cancels everything and brings the final result as $q/2m$ in classical physics
How do I prove the relation between the vectors of magnetic moment $\vec\mu$ and angular momentum $\vec L$, $$\vec\mu=\gamma\vec L$$ ? Many text books and lecture notes about the principles of magnetism show the relation of $\mu$ and $L$ as scalars only and then just state that the relation holds also for the vectors. An example: $$\mu=I\cdot A = \frac{q}{t}\pi r^2 = \frac{qv}{2\pi rm}m\pi r^2$$ ($I=q/t$: current, $A$: area of a loop, $q$ charge, $t=2\pi r/v$: time of 1 rotation, $v$: velocity of particle, $m$: mass ) The angular momentum is $\vec L = \vec r\times\vec p$ or $L=mrv$ and therefore $$\Rightarrow \mu = {\frac{q}{2m}} L = \gamma L.$$ Why is this also true for the vectors? Is there a general explication by classical physics without the need of quantum theory?
In the The Hobbit and The Lord of the Rings series, there are many descriptions of dwarves. But there isn't any mention of female dwarves. Are there any in-universe mentions of female dwarves? If there aren't, then how do they reproduce? Is there any explanation from Tolkien?
I may have missed it with the 3D, but I could have sworn I saw what I suspect was a lady Dwarf or two running from the Erebor in the beginning of the Hobbit, but they didn't seem bearded. If dwarf women aren't bearded, then was Aragorn just kidding in the Two Towers (movie) when he intimated that they all had beards? It's also stated by Tolkien in appendix A to The Lord of the Rings that female dwarves appear identical to males and we can assume they are also born with beards, just like their male counterparts.
Let $f$ be analytic in the disk $D(0,2)$ except for a pole of order $1$ at $z=1$, and let $$f(z)=\sum_{k=0}^\infty a_k z^k$$ be the series expansion for $f$ in the disk $D(0,1)$. Prove that $$\lim_{k \to \infty}\frac{a_{k+1}}{a_k}=1.$$ Intuitively, I want to say that the information given yields a Laurent series representation on $D(0,2)-\{1\}$:$$f(z)=\sum_{k=-1}^\infty b_k (z-1)^k$$ Expanding instead around $z=0$, we have an issue of a non-removable singularity at $z=1$ with analyticity everywhere else. Thus, the distance from $z=0$ to $z=1$ (the nearest singularity from the point of analyticity) is 1, so the result must follow by the Ratio Test as applied to the radius of convergence. My solution has a feel of lack of rigor, however, and I don't know how to improve on its statement (or whether my approach is even valid).
Let $f$ be a function holomorphic in an open set containing the closed unit disc $D(0,1)$, except at the point $z_0$ with $|z_0|=1$, where $f$ has an isolated singularity. If $a_n$ are the coefficients of the Taylor expansion of $f$ centered at the origin, show that $$\displaystyle\lim_{n \to\infty}\frac{a_n}{a_{n+1}}=z_0$$ I considered first the case: $z_0$=simple pole. Then i can write the Laurent series for $f$ at $z_0$ $$f(z)=\frac{c}{z-z_0}+c_0+c_1(z-z_0)+\ldots$$ I put $$g(z)=f(z)-\frac{c}{z-z_0}$$ Then $g$ is holomorphic in an open set containing the closed unit disc $\overline{D(0,1)}$ and we have $$g(z)=\sum a_n z^n+\frac{c}{z_0}\sum(\frac{z}{z_0})^n=\sum(a_n+\frac{c}{z_0^{n+1}})z^n$$ The power series of $g$ has radius of convergence $>1$, hence i can substitute 1 in RHS of last equation, and i get a numeric convergent series. The necessary condition for convergence says that its general term has to be infinitesimal $$\displaystyle\lim_{n\to\infty}(a_n+\frac{c}{z_0^{n+1}})=0$$ from which follows $\frac{a_n}{a_{n+1}}\rightarrow z_0$ the question is:how can i adapt this argument to deal with cases where z_0 is not a simple pole?
I am encountering a very weird error recently, that I cannot figure out to solve. I have an Asus S301L with Ubuntu 12.04 and an Italian keyboard; every time I log in, some key on my keyboard does not work properly: p produces * 0 produces / - produces + But also others, for example, it took quite some time for me to just write this message. The only way to have things again to work properly is to type from a terminal: setxkbmap it That command takes a keyboard layout configuration from the folder /usr/share/X11/xkb/symbols/ And it starts again to work, just for a (indefinite) duration of time , then, things, again, are wrong. The output of the locale command is: LANG=en_US.UTF-8 LANGUAGE=en_US:en LC_CTYPE="en_US.UTF-8" LC_NUMERIC=it_IT.UTF-8 LC_TIME=it_IT.UTF-8 LC_COLLATE="en_US.UTF-8" LC_MONETARY=it_IT.UTF-8 LC_MESSAGES="en_US.UTF-8" LC_PAPER=it_IT.UTF-8 LC_NAME=it_IT.UTF-8 LC_ADDRESS=it_IT.UTF-8 LC_TELEPHONE=it_IT.UTF-8 LC_MEASUREMENT=it_IT.UTF-8 LC_IDENTIFICATION=it_IT.UTF-8 LC_ALL=
I want to switch between English and another language. I have tried Lubuntu and it was easy, I figured it out from the friendly menus. But in Ubuntu everything is so cryptic.
I have a python script that run for few hours to process each record. Also, at the same time, I want to run the same script but with other arguments for other purpose. Sometime an exception is raised and cause the script stop. Sometime the OS got restart. So I would like to have something at the OS level to check. Such that if the script is stop, restart the script. What is the best approach to solve this problem?
I'm trying to ensure a script remains running on a development server. It collates stats and provides a web service so it's supposed to persist, yet a few times a day, it dies off for unknown reasons. When we notice we just launch it again, but it's a pain in the rear and some users don't have permission (or the knowhow) to launch it up. The programmer in me wants to spend a few hours getting to the bottom of the problem but the busy person in me thinks there must be an easy way to detect if an app is not running, and launch it again. I know I could cron-script ps through grep: ps -A | grep appname But again, that's another hour of my life wasted on doing something that must already exist... Is there not a pre-made app that I can pass an executable (optionally with arguments) and that will keep a process running indefinitely? In case it makes any difference, it's Ubuntu.
CAN YOU PLEASE EXPLAIN IN DETAIL. Why are we not checking both condition in "and" of if statement , and in checking both condition in "or" of If condition? Why in first question x= 11, y=20, is printed. While in second question x=11, y=21, is printed.
Does the ANSI standard mandate the logical operators to be short-circuited, in either C or C++? I'm confused for I recall the K&R book saying your code shouldn't depend on these operations being short circuited, for they may not. Could someone please point out where in the standard it's said logic ops are always short-circuited? I'm mostly interested on C++, an answer also for C would be great. I also remember reading (can't remember where) that evaluation order isn't strictly defined, so your code shouldn't depend or assume functions within an expression would be executed in a specific order: by the end of a statement all referenced functions will have been called, but the compiler has freedom in selecting the most efficient order. Does the standard indicate the evaluation order of this expression? if( functionA() && functionB() && functionC() ) cout<<"Hello world";
I am trying to split txt file line by line and want to add tab. for first level is 1 tab, second level is 2 tabs indented and so on.I know how to do this if user add input line by line but I want to split txt file contents. This is input file: <company><name>xyz</name><name>ABC PQR</name><address> <line1>G M Road</line1><line2>akurdi</line2><state>Maharashtra</state> <city>Pune</city></address><company> And I want output like this: <company> <name>xyz</name> <name>ABC PQR</name> <address> <line1>G M Road</line1> <line2>akurdi</line2> <state>Maharashtra</state> <city>Pune</city> </address> <company> This is what i tried but its not working: class lineSplit { public static void main(String[] args) throws Exception { BufferedReader br = new BufferedReader(new FileReader("input.txt")); List<String> list = new ArrayList<String>(); String line = null; String[] values; while ((line = br.readLine()) != null) { values = line.split(">"); for (String str : values) { list.add(str + ">"); } } Iterator itr = list.iterator(); while (itr.hasNext()) { System.out.println(itr.next()); } br.close(); } } How can i do this?
I have a Java String that contains XML, with no line feeds or indentations. I would like to turn it into a String with nicely formatted XML. How do I do this? String unformattedXml = "<tag><nested>hello</nested></tag>"; String formattedXml = new [UnknownClass]().format(unformattedXml); Note: My input is a String. My output is a String. (Basic) mock result: <?xml version="1.0" encoding="UTF-8"?> <root> <tag> <nested>hello</nested> </tag> </root>
For $c > 0,$ find the limit, lim$_{n \to \infty} n(\sqrt[n]{c} - 1)$ Ok, I am not exactly on sure how to do this. Though here are some of my thoughts: lim$_{n \to \infty} (nc^{1/n} - n) = nc^0 - n = 0,$ and I don't think this can be correct logically. Also, I think we can make it a $\log$ function by doing it like this: $(nc^{1/n} - n) = e^{\log(nc^{1/n} - n)}.$ But, then what? We can't distribute the log inside because that's not correct. I am lost. Any help? Update: please don't mark this as a duplicate of , since the other question was not required to use L'hopital's rule, but I need to use that in my question.
How to find the limit of: $$ \lim_{x\to \infty }x\left(\sqrt[x]{a}-1\right)$$ Without using L'hôspital rule. I've tried to bound the term and use the squeeze theorem but I couldn't find the right upper bound. I've also tried to convert $a^\frac{1}{x}$ to $e^{\frac{1}{x}\ln{a}}$ but it didn't help me. Whats the right way to evaluate that limit?
when I click input type text fields the address saved in browser shows. I do't want to show it. autocomplete="off" not working in input fields within the form in chrome Version 75.0.3770.142 (Official Build) (64-bit)
How do you disable autocomplete in the major browsers for a specific input (or form field)?
Is it proper to include a comma at the very end of an inline place address? Also, in case it is relevant, the sentence is the title of an article. For example: Examples of cross-gene fertilization within a sample from Bogota, Colombia 2009-2011. or Examples of cross-gene fertilization within a sample from Bogota, Colombia, 2009-2011.
Is it acceptable in BrE to omit the commas (as I've done below) after 2006, 1946, France, Texas and New York? To me, commas after each serve no purpose: they reduce the flow of the sentence. • The performance took place on February 2, 2006 at the State Theatre in Ithaca. • January 23, 1946 is Helen's date of birth. • Prague, Czechoslovakia is a great vacation spot. • Paris, France will host the Olympics. • Dallas, Texas is the home of this special event. • Syracuse, NY will play host to this year's Rock of Ages music festival.
The problem: recently the UI for the Stack Exchange chat switched to mobile even in my browser on the notebook. While the UI might work fine for tablets and phones, it has some serious drawbacks on conventional systems, namely on computer w/o touchscreen and conventional keyboard. Likewise, I was unable to find a configuration option to keep using the old style of the chat, which had tons of advantages on a traditional computer, like users, and favorite messages in the sidebar etc. The most annoying part is that the new UI forces me to use the mouse to click "send" on every message, because hitting "Enter" only adds a \n to the multiline input field. Is there any possibility to keep using the old chat (which I greatly preferred on the notebook) or at least a configuration option that enables "send on enter" in the mobile UI?
While having trouble getting Stack Exchange Chat to work on my travels in China, . (I'm using a netbook.) That actually worked but now I'm in a different hotel in a different city and most of the sites I had trouble with previously now work. But when I open SE chat in a new tab it automatically opens in mobile mode. It doesn't seem to have any button to switch to "non mobile mode". It seems nobody has asked this before since my searches reveal nothing.
I am using Ubuntu 12.04. I am new to Ubuntu. When I click on the internet icon in the upper-right-hand corner, it doesn't show any wireless networks under "wireless networks." I went to Additional Drivers and found out that 'Broadcom STA wireless driver' is activated and currently in use. I searched internet but all the answers would tell me to install wireless driver which I already have. What might be the issue here? How can I troubleshoot the issue? Any help is greatly appreciated.
I upgraded Ubuntu from 11.10 to 12.04, until which wireless was working just fine. After the upgrade and reboot, wireless is not even being detected (When I click the network manager icon in the top panel, it does not show the wireless networks. Neither the Enable wireless option is there). But my laptop's LED indicator shows wireless is on. This is a Dell Vostro 3450 laptop with: Broadcom Corporation BCM4313 802.11b/g/n Wireless LAN Controller (rev 01)** (from lspci). Is any other info needed? How do I get Wifi working?
Is this a correct way to prove that $$ \arctan(\mathrm{e}^{-v}) = \text{arccot}(\mathrm{e}^v) $$ $$\tan x = \frac{1}{\mathrm{e}^v} $$ Turn $\tan x$ into $\sin x$ and $\cos x$ $$\frac{\sin x}{\cos x} = \frac{1}{\mathrm{e}^v}$$ Multiply $\cos x$ $$ \sin x = \frac{\cos x}{\mathrm{e}^v} $$ $$ \mathrm{e}^v \sin x = \cos x$$ $$ \mathrm{e}^v = \frac{\cos x}{\sin x}$$ Multiply by $\mathrm{e}^v$ and divide by $\sin x$ $$ \mathrm{e}^v = \cot x$$ $$\text{arccot}(\mathrm{e}^v) = x$$
In my textbook it asks for me to: Prove that there is no constant $C$ such that $\text{arccot}(x) - \text{arctan}(\frac{1}{x}) = C $ for all $x \ne 0$. Explain why this does not violate the zero-derivative theorem. But I believe I have found such a $C$, i.e. $C =0$! I even asked WolframAlpha () which corroborates my answer. This question appears in Apostol's Calculus Volume I, Second Edition: Exersize 6.22-11b Edit: Mathematica's definition of arccot is different from the one in my textbook. Apostol's arccot maps a real number into $(0, \pi)$ while Mathematica's maps a real number into $(-\pi/2, \pi/2)$ Here they are super-imposed:
Consider the following example: A particle oscillates with simple harmonic motion in a straight line. In the first $t$ seconds, it travels a distance $a$. In the next $t$ seconds, it travels an additional $2a$ distance (in the same direction). Find the time period of oscillation. For this question, the correct answer only comes when assuming $x=A\cos \omega t$. When using $x=A\sin \omega t$, the answer does not exist. Why?
Usually every simple harmonic question starts with the line: The block at equilibrium shifted to a position $X_0$ and released. I found this from the website: This equation has a sine in it, and a sine graph starts at zero. Using this equation is like starting your mathematical stopwatch in the middle of a pendulum swing: t = 0 is in the center of the oscillation. If, on the other hand, you replace sine with a cosine, then the equation is still correct; you're just starting to measure time at the maximum displacement instead. Now if this holds true then most of my question in my textbook in which the mass is slightly displaced from an equilibrium point uses the sin equation instead of cos. Aren't we measuring motion from the Amplitude point at t=0... Why the discrepancy
As per the previous post (which was 5 years ago), I have a that has three forms of serial communication. One is an RS232, the other is USB A and finally a USB B. So I have three options to connect my PC to this device. The device sends the scanned RFID tags through this serial connection to my PC. I want to place the reader 60 meters away from my PC. Which type of serial communication should I use?
What is the maximum length of serial cable I can use, to connection work properly? Is length of serial cable in connection with baud rate? I am using about 5 meter cable at speed 38400 bauds and RS232 communication, is it too long?
There seems to be more than a few computer science/programming Stack Exchange networks (is that the correct term?). Stack Overflow, being the first, has by far the most users, questions, and answers. What is the reasoning for creating the others, and are there clear guidelines for which kinds of questions should be posted? I can see a large amount of potential overflow, many cases of people not getting a good answer to their question, because the person who has the answer isn't browsing that particular network at the moment. I understand that they were probably created for organizational purposes, but wouldn't it almost make more sense to just have them as categories under Stack Overflow, keep them separated but still connected, instead of making people have to create multiple 'account's, one for each network? I am sure there was a very good reason to break them up, but as someone that is new to SE, it can be somewhat intimidating to decide which one to post in to ensure you get a good answer. For example, if I am a computer science student, my first instinct might to be to post in the computer science network, until I see that it literally has 1% of the users as the Stack Overflow network, which still seems to be for programming/computer science related questions. So my second instinct would then to be to post it into the Stack Overflow site on the basis that I have a significantly higher chance of my question being seen and getting a good answer. Then I notice that there is also a 'programmers' network, and I don't even begin to know where that fits in. I, and I am assuming most people, will probably just post on Stack Overflow to be safe. My question is, other than the short little description blurb of each one, is there a clear cut set of guidelines which what each network is intended for, what kinds of questions should go to each one, and is anything being done to encourage people to post in these newer, smaller (more specialized?) networks as opposed to just posting in big daddy Stack Overflow? Now again, this is for computer science/programming/"why isn't this code doing what I want?" related questions, I am not saying that if I had a question about Linux or WordPress or something I would have the same confusion.
What is the right site on the Stack Exchange network for computer science questions? None of the answers I can think of are remotely satisfying: : Even if CS questions are acceptable (, which I think shows they're not getting the right audience), where is the expertise to answer them? It would be . Also a site about computer science would need LaTeX markup, which SO lacks. : Same problems as SO, only worse (and the bulk of CS questions would be there anyway). : That's for questions only, so what about the other 99%? : That's , but not the other 95%: e.g. are ok in the abstract but not more implementation-oriented questions (e.g., not data structures). : the proposal was closed as a duplicate (of what? My impression is that the closers mainly had TCS.SE in mind, but that would be based on a mistaken perception of what TCS.SE is about, as seen above). Many different SE sites for subfields of CS: , , , , , … But why not follow the SO and Math.SE model of one big site? , but that was before SE2.0 which has completely changed the scope. On a closely related note, I've searched for a number of keywords where I would expect some activity on a computer science Q&A site. (Note: there is definitely a bias in the keywords related to my background — suggestions for an objective keyword list would be welcome — but I wrote the keyword list before I did any searching.) These are topics that are typically taught in undergraduate or graduate courses (so basic questions about them are out of scope for ). I'm only considering hits in questions, since here I'm looking at the kinds of questions people ask, not what people might mention in passing in answers. strongly normalizing (0) lambda calculus (43) theorem provers (): coq: (13), agda/agda2: (5), twelf (0), isabelle (0) linear logic () abstract interpretation (16 hits total, few in questions, though most are good CS questions) model checking: (3, not particularly science-y; some questions without the tag are more science-y) bisimulation (0; 3 answers) basic block (71 hits, ranging all over the board; I haven't counted the questions) What this tells me is that a lot of subjects that I learnt about in CS courses don't receive any questions. There seems to be a gap between the first two undergraduate years or so (mainly introduction to programming and algorithms), which get reasonable coverage at SO, and graduate students' first research projects, which is where TCS.SE starts. Computer science has more applied topics that don't fit well on Stack Overflow either. For example, don't seem to fare well.
I am using sklearn library to train the default SVM classifier on a bunch of data. My data has roughly 30 features. But I realize some of these features are "more important" than others. For example, I want the change in features 1, 2, and 3 to greatly impact the learning process, whereas, features 4 through 25 are useful information, but not as critical. If I just multiply the numbers in features 1 to 3 by say, 100, it won't make much difference because I believe the algorithm normalizes the features anyway. So my question is, how can I give a weight to the features in an SVM classifier, so that some of them influence the learning and prediction more than others? Here's the very crude version of the code I'm using: clf = SVC(probability=True, gamma=0.1, C=1)) data = np.array([1, 4, 1, 6, 2, 5, 7, 2, ... ]) target = np.array([0, 1, 0, 0, 1, ... ]) clf.fit(data, target)
I'm building an object detector using HOG features and linear SVM. Some of the regions of the object are more "distinctive" so I would like to give more weight to the features extracted from those regions. (e.g. imagine we want to detect between mugs and glasses, then the most "distinctive" part is the mug's handle) How could I do this? For sure there should be a more intelligent way than just replicating the features of those "distinctive" regions.
I would like to know what is difference in writing in below 2 ways : Approach 1: var onCallback = function(result) { alert('way1'); }; function1(onCallback); Approach 2: function2(function(result) { alert('way2'); });
I've recently started maintaining someone else's JavaScript code. I'm fixing bugs, adding features and also trying to tidy up the code and make it more consistent. The previous developer used two ways of declaring functions and I can't work out if there is a reason behind it or not. The two ways are: var functionOne = function() { // Some code }; function functionTwo() { // Some code } What are the reasons for using these two different methods and what are the pros and cons of each? Is there anything that can be done with one method that can't be done with the other?
Emacs creates backup files (which I want it to do) but it puts them in my source tree (which I do not want it to do). Following instructions elsewhere, I've placed the following in my .emacs file: ;; Disable auto save (setq auto-save-default nil) ;; Save all tempfiles in $TMPDIR/emacs$UID/ (defconst emacs-tmp-dir (format "%s/%s%s/" temporary-file-directory "emacs" (user-uid))) (setq backup-directory-alist `((".*" . ,emacs-tmp-dir))) It seems to be ignoring these directives and merrily continues to create the autosave files in the source directories. Any ideas?
Emacs puts backup files named foo~ everywhere and I don't like having to remember to delete them. Also, if I edit a file that has a hard link somewhere else in the file system, the hard link points to the backup when I'm done editing, and that's confusing and awful. How can I either eliminate these backup files, or have them go somewhere other than the same directory?
I want to get all the data from a table in SQL.The following command can be used: select * from table_name But it seems that using * decreases effeciency, so is there any other way ?
I've heard that SELECT * is generally bad practice to use when writing SQL commands because it is more efficient to SELECT columns you specifically need. If I need to SELECT every column in a table, should I use SELECT * FROM TABLE or SELECT column1, colum2, column3, etc. FROM TABLE Does the efficiency really matter in this case? I'd think SELECT * would be more optimal internally if you really need all of the data, but I'm saying this with no real understanding of database. I'm curious to know what the best practice is in this case. UPDATE: I probably should specify that the only situation where I would really want to do a SELECT * is when I'm selecting data from one table where I know all columns will always need to be retrieved, even when new columns are added. Given the responses I've seen however, this still seems like a bad idea and SELECT * should never be used for a lot more technical reasons that I ever though about.
I answered the following question yesterday I've noticed that the syntax highlighting of the razor code is somewhat broken. Is there anything that can be done about this? I don't think that there's anything wrong with the syntax since it highlights nicely in visual studio and executes without error. I've checked the following post but can't see anything that mentions razor views
I noticed that sometimes my code gets highlighted in different colors when rendered. What is syntax highlighting? How does it work? Why isn't my code being highlighted correctly? How do I report a bug or request a new language? How do I use syntax highlighting? What languages are currently available on Stack Exchange?
I'm trying to reproduce the steps needed to aim this goal: Given a layer of polygons, I'm want to retrieve for each polygon which is at a distance less than 50m to a 2nd polygonal layer the only 5m band in the polygon facing the items of the second layer. A drawing may be a better way to explain myself. I want to build the red parts (the 5m band of the orange layer polygons facing the green ones, when they're at a distance less than 50m). How would you do that with QGIS?
I'm trying to reproduce the steps needed to aim this goal: Given a layer of polygons, I'm want to retrieve for each polygon which is at a distance less than 50m to a 2nd polygonal layer the only 5m band in the polygon facing the items of the second layer. Quite complicated explanations...I know....so, a drawing is a better way to explain myself. I want to build the red parts (the 5m band of the orange layer polygons facing the green ones, when they're at a distance less than 50m)....How would you do that with QGIS?
This is being done in the context of a Hilbert system in propositional logic. But let's assume we've already proven all the axioms are tautologies / will always be true. How then are we showing that modus ponens is also valid? (or is valid the wrong word to use here? Normally, "valid" for a statement means the logic holds IF the premises were true, but premises being true is what makes it actually sound... but when it comes to inference rules I don't know the terminology) $P, (P \to Q) \vdash Q$ Is this strictly an informal "look at the truth tables and reason it out" kind of thing? i.e. if we assume $P$ is true and $P \to Q$ is true because they are each reducible to either true axioms or true atomic propositions, then we know $P \to Q = \top$ becomes $\top \to Q = \top$. And in the truth tables for $\to$, this only has one solution, i.e. where $Q = \top$, therefore modus ponens holds? Or are we now showing that $P, (P \to Q) \vDash Q$? I mean is that it? Or is it a more formal approach? I get totally lost when it comes to understanding and manipulating / proving things with these metalogical symbols.
I have the following question: "Explain the concept of the soundness of a rule of a proof system with respect to the truth tables" Would it be correct to state the following: "A rule of a proof system is sound with respect to the truth tables iff the conditions of the rules (requirements of the rule) ensure that the final formula will behave according to it's intended truth table."? This is a question in a practice exam, and I can not find a specific mentioning so far, by scanning Google and Proof Wiki. What would the correct answer be? Thank you.
I am somewhat new to Stack Exchange, but one thing I have noticed is that the policy of not allowing discussion type questions is a very good idea. It helps keep Stack Exchange sites focused and to the point. At the same time however, many times I have questions come up that require discussion. Something like "Which programming language should I learn first" is not appropriate for Stack Overflow, but could get a reasonably helpful answer on other forums like DreamInCode.net, Programming Forums, or maybe even Reddit. It seems like it would be more efficient to create a list of forums that we can redirect users with these sorts of questions to. For example, instead of simply closing the example question above about a first programming language, could it be closed with something like "Stack Overflow is not a site for discussion based questions, but you can try asking about it on <'better-alternative-website'>"? As far as the idea suggested in , the idea would be similar, but instead of creating an alternative on Stack Exchange itself, questions closed as not constructive could include a "suggested place to ask" link, which would be specific to each Stack Exchange site (Raspberry Pi Stack Exchange redirects to the Raspberry Pi forums, Arduino to Arduino forums, etc.)
Stuff like polls, recommendations based on subjective constraints, puzzles, webcomics etc. do not belong on the serious main SE sites, where professionals should be considered at work and having just a few spare minutes ("code's compiling") to answer questions, so they should not be distracted by such things. However, I'd also like to have a home for these things still using the SE engine. For the reason I mentioned before, this needs to be a separate place though. Let's call it four.[sitename-here].com.
I am a UK national citizen and I am travelling for 5 months through Myanmar, India and finally Indonesia. I have 2 valid passports - an Irish and a UK passport. I have my Myanmar and India visa on my UK passport and my Indonesia visa on my Irish passport. I am at a loss of how I can exit India on my UK passport but enter Indonesia on my Irish passport and whether there is even a way of doing this?! I will have entered India on my UK passport so must exit on this. I then need to fly to a middle destination such as Kuala Lumpur, Malayasia before flying to Sulawesi in Indonesia. I will need to collect my bags at Kuala Lumpur and re check in so in that sense I will have to clear immigration both ways than just catching a connecting flight. On entering Malaysia, at this point can i show my Irish passport on entering to get an entry stamp or is this not allowed since I would have technically come into the country on my UK passport as registered by the plane ticket?! I would then exit Kuala Lumpur on my Irish passport and enter Sulawesi on my Irish one? I am a little confused on what is legal and allowed - please help!
I am a citizen of two different countries, and have two passports. How should I use my passports when traveling?
I can't remove the old data in iCloud or even in Game Center. I like to play games like Hay Day and Township. I have already uninstalled the games and chose to remove the data but when I reinstall the same game, my level still is the same and won't become level 1 and start all over. How can I fix this problem? iPad mini, iOS 7
I have one particular game that saves data through the game center. Somehow the saved game data got messed up which causes the game not to work properly when I a connected to the internet (I.e. When the game center is accessible). Is there some way to delete all the data belonging to that game only?
What is the meaning of axe in: "Axe me a question!" Thank you for your time.
I know the correct pronunciation (I think) of the words "ask" and "asked", but I quite often hear them pronounced as "ahks" and "ahksed" (almost like an "r" sound). I've heard it both in conversation and on television shows (both Australian and American). Are these pronunciations due to dialect, or are they alternative pronunciations or incorrect pronunciations? If they are the correct pronunciation, should I use them or the "normal" pronunciation?
Edit 2: At the bottom I have updated the question after incorporating the answer from here: I created a function to display a command in bold with optionally giving the man page section in parenthesis. \usepackage{xparse} \newcommand*{\man}[2][]{% \textbf{#2}\IfNoValueF{#1}{(#1)}% } Now I also want to be able to create an index entry for these commands. So I created a wrapper command: \newcommand*{\mani}[2][]{% \man[#1]{#2}% \index{#2@\man[#1]{#2}}% } However, sometimes I want to create an index entry using the same formatting, but not print the command in the running text. Here is a MWE: \documentclass{memoir} \usepackage{xparse} \newcommand*{\man}[2][]{% \textbf{#2}\IfNoValueF{#1}{(#1)}% } \newcommand*{\mani}[2][]{% \man[#1]{#2}% \index{#2@\man[#1]{#2}}% } \makeindex \begin{document} Only an index entry: \index{ssh-keygen@\man[1]{ssh-keygen}} Hello world Command and index entry: \mani[1]{ssh-keygen} \printindex \end{document} The file output.idx contains two lines, the second containing an additional space. The question thus is, why is there an additional space and how can I fix it so there is no additional space? \indexentry{ssh-keygen@\man[1]{ssh-keygen}}{1} \indexentry{ssh-keygen@\man [1]{ssh-keygen}}{1} Edit 1: I've added a screenshot of the result of this extra space: two identical index entries are printed. Update I have updated my code as per the provided solution but I now get an error message which I do not understand. \documentclass{memoir} \usepackage{xparse} \makeindex \NewDocumentCommand\man{om}{% \textbf{#2}\IfNoValueF{#1}{(#1)}% } \makeatletter \newcommand*{\mani}{% \@bsphack \begingroup \@sanitize \@mani } \newcommand*{\@mani}[2][]{% \man[#1]{#2}% \@wrindex{#2@\string\man[#1]{#2}}% } \makeatletter \begin{document} Two separate commands: \man[1]{ssh-keygen}\index{ssh-keygen@\man[1]{ssh-keygen}} Hello world One command: \mani[1]{ssh-keygen} \printindex \end{document} OverLeaf states: The compiler is having trouble understanding a command you have used. Check that the command is spelled correctly. If the command is part of a package, make sure you have included the package in your preamble using \usepackage{...}. The log file reports: ! Missing number, treated as zero. <to be read again> { l.25 One command: \mani[1]{ssh-keygen} A number should have been here; I inserted `0'. (If you can't figure out why I needed to see a number, look up `weird error' in the index to The TeXbook.)
I'm creating a technical document with lots of index entries. To reduce typing I defined an index command that typesets the word to be indexed using \emph{}: \newcommand{\ind}[1]{\index{#1@\emph{#1}}} I turns out the .ind file gets different entries when I use this command, compared to typing the \index{} command myself: the entries created with the \ind{} command get two spaces inserted before the { of the \emph command. Consequently, the index will contain two entries for the same word if I use both the \ind{} command and the \index{} command (e.g. when defining a region using \index{someword@\emph{someword}\(} to start a region for that word. Here is an MWE: \documentclass[a4paper]{article} \usepackage{makeidx} \makeindex \newcommand{\ind}[1]{\index{#1@\emph{#1}}} \begin{document} Testing our self-defined command\ind{italictext}. This is the normal way\index{italictext@\emph{italictext}}. \printindex \end{document} The contents of the .ind corresponding file is: \begin{theindex} \item \emph {italictext}, 1 \item \emph{italictext}, 1 \end{theindex} Note 1: my actual use case is not with \emph{}, but with \lstinline{} from the listings package, but this simplified example already shows the problem. I observed the same behaviour when using the imakeidx package. Note 2: using \DeclareRobustCommand instead of \newcommand doesn't change anything. Note 3: I am actually using a KOMA class documentclass, so the scrindex package would be an option since the spacing problem doesn't appear there (in fact, both entries end up as one index entry with a single space between the \emph and opening { in the .ind file. However, with that package I haven't managed to get the page numbers for the index entries hyperlinked when using the hyperref package.
In Python we can get the index of a value in an array by using .index(). But with a NumPy array, when I try to do: decoding.index(i) I get: AttributeError: 'numpy.ndarray' object has no attribute 'index' How could I do this on a NumPy array?
I know there is a method for a Python list to return the first index of something: >>> l = [1, 2, 3] >>> l.index(2) 1 Is there something like that for NumPy arrays?
I would like to access the in Scipy in the scripting window. I have looked at and and @polosson's answer in the first one suggests three possible ways to install a module in order to use it. EDIT: My question is - HOW to install scipy.special into either the Blender Python path (which I should be able to find) or how to instal into a separate folder (which I would point to with the menu indicated in the third option of that answer). Could someone take a moment to help me find a step-by-step way for me to start using scipy.special in the script window? Thank You! fyi I'm using Blender 2.70a on OSX 10.8. Currently I run Python 2.7.6 using IDLE elsewhere in the computer, using method (indicative of my current installation experience == clicking and dragging).
I'm currently developing a script for Blender to handle Mesh Frequency Decomposition. The script is nearly complete, but i need one more thing: The SciPy library to compute eigenvalues and eigenvectors. Following the installation instructions on , I'm able to install it as well as Numpy. Numpy works fine, but I can't even import SciPy: Traceback (most recent call last): File "/CAF_FD.py", line 4, in <module> ImportError: No module named 'scipy' Error: Python script fail, look in the console for now... By the way, I'm working on Linux 64 bit and I've installed SciPy and Numpy with my package manager. Edit: When I try to use SciPy with a terminal prompt, it works.
I recently installed Ubuntu 18.04. Previously in GNOME 3, the minimize, maximize, and close buttons never appeared on any of my applications, such as Chromium Browser and Emacs. These buttons annoy me because I am used to clicking Alt+Space. How do I remove these buttons from Ubuntu 18.04?
(Ubuntu 13.04 with GNOME Shell, upgraded, GNOME version 3.8) Recently, I upgraded Ubuntu to 13.04. the default desktop is gnome-shell. Except Nautilus, other software border doesn't disappear when I make them to be maximized. I checked the problem for these software: LibreOffice Firefox Rhythmbox thunderbird GNOME-Terminal On the other hand there are three bars on maximized mode: GNOME Shell panel Title-bar for software which contains - + x (minimise, maximise, close) buttons. Software menu-bar Number "2" is extra. Is a package missing?
Is there a way to follow a particular person (or List<Person>) easily? Some people answer the questions in a very educative way, and I don't want to miss them.
I've been looking around and I can't seem to find an automatic (i.e. buzz- or Twitter-like) way to follow users inside Stack Exchange. Why haven't the developers added such a feature? It could help beginner users follow other beginners with the same interests. We would be able to learn from each others' questions and pitfalls. Also, it would reduce double posting.
I have one activity one tab with fragment . But it keeps giving me the error "java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String android.os.Bundle.getString(java.lang.String)' on a null object reference". Send data to fragment: final DescriptionDetailFragment ddf = new DescriptionDetailFragment(); Bundle bundleddf =new Bundle(); bundleddf.putString("description", massageModel.getDescription()); ddf.setArguments(bundleddf); Called activity: desc = v.findViewById(R.id.description); Bundle b1 =getArguments(); String description = b1.getString("description"); desc.setText(description); Can someone help me out why this is happening?
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?
Let $f:\mathbb{R}^n\rightarrow ]-\infty,+\infty]$ be proper and strictly convex. Show that $f$ has at most one minimizer. I am hoping someone can give me some feedback on the proof for this. I feel that it may not be rigorous enough. proof: Let $\mu=\inf_{x\in\mathbb{R}^n} f(x)$ (i.e. $\mu$ is a global infimum) and choose a sequence $(x_n)_{n=1}^{\infty}$ in $\mathbb{R}^n$ such that $f(x_n)\rightarrow\mu.$ Then $(x_n)$ is a bounded sequence [otherwise $(x_n)\rightarrow+\infty$, so $f(x_n)\rightarrow+\infty$. Therefore, $\mu\rightarrow+\infty$, which means that $dom(f)=\emptyset$, which negates our assumption that $f$ is proper.] Moreover, by the Bolzano-Wierstrass theorem there exists a convergent subsequence $(x_{n_{k}})_{k=1}^{\infty}$, which means $(x_{n_{k}})\rightarrow x\in\mathbb{R}^{n}$. Thus, we see that \begin{align} \mu&\leq f(x)\;\;\;\;\;\;\;\;\;\;\;\;\;\qquad\text{as $f$ is lsc}\\ &\leq\liminf_{k \to \infty} \;(f(x_{n_k}))\\ &=\mu. \end{align} Thus, $\mu=f(x)$ is our minimizer, and since $f$ is strictly convex we get that $\mu$ is unique.$\qquad\;\;\;\;\Box$
Let $f\colon X \to [ -\infty, +\infty]$ be proper and strictly convex. Show that $f$ has at most one minimizer. Give examples where $f$ is strictly convex, and either (i) $f$ has one minimizer; or (ii) $f$ has no minimizer. For the strict convexity part, you may use the fact that f is strictly convex whenever its Hessian is positive definite. I am not sure how to show that f has at most one minimizer, could someone help get me started with the question?
What is the best way to know what should your method name be when developing a web app? I know this is an easy question, but seriously what considerations and practices should I be doing in order to derive the best names possible for my methods?
So I'm working on this class that's supposed to request help documentation from a vendor through a web service. I try to name it DocumentRetriever, VendorDocRequester, DocGetter, but they just don't sound right. I ended up browsing through for half an hour trying to come up with an adequate word. Start programming with bad names is like having a very bad hair day in the morning, the rest of the day goes downhill from there. Feel me?
Why does my "if" statement not fire? String something = ""; String category = json_data.getString("den"); Log.e("JSON", "category="+category); if (category == "1"){ something = "Random something"; } Even if in my logcat I can see JSON:"category=1", the "something" String does not take "Random something" value. This must be some convention in java? Please help.
I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug. Is == bad? When should it and should it not be used? What's the difference?
I want to calculate $$\lim_{n\to \infty} n\sin(2\pi n! e)$$ I have used the Stirling approximation and I think the answer is zero . But I think the limit maybe not exists. Can some one help? Thanks.
I tried and got this $$e=\sum_{k=0}^\infty\frac{1}{k!}=\lim_{n\to\infty}\sum_{k=0}^n\frac{1}{k!}$$ $$n!\sum_{k=0}^n\frac{1}{k!}=\frac{n!}{0!}+\frac{n!}{1!}+\cdots+\frac{n!}{n!}=m$$ where $m$ is an integer. $$\lim_{n\to\infty}n\sin(2\pi en!)=\lim_{n\to\infty}n\sin\left(2\pi n!\sum_{k=0}^n\frac{1}{k!}\right)=\lim_{n\to\infty}n\sin(2\pi m)=\lim_{n\to\infty}n\cdot0=0$$ Is it correct?
I've been working on this problem and got stuck. Assume that X and Y have joint normal distribution, that each $X, Y \sim N(0,1)$, and that their correlation is $\frac{1}{2}$. Calculate $Pr(X \ge 0, Y \ge 0)$. I know that I can rewrite (X,Y) in terms of independent normal variables (W,T) as follows $$ \begin{bmatrix} X\\ Y\\ \end{bmatrix} = \begin{bmatrix} 1 & 0\\ \rho & \sqrt{1-\rho^2}\\ \end{bmatrix} \begin{bmatrix} X\\ Z\\ \end{bmatrix} $$ where $\rho$ is the correlation. This has left me with $$ X=X\\ Y=\frac{1}{2}X + Z\sqrt{\frac{3}{4}} $$ And so I have $$ Pr(X \ge 0, Y \ge 0) = Pr(X \ge 0, \frac{1}{2}X + Z\sqrt{\frac{3}{4}} \ge 0) $$ So I just realized that the T variable I had before was superfluous, so I removed it. I am wondering from here if it would make sense to put this: $$ Pr(X \ge 0, \frac{1}{2}X + Z\sqrt{\frac{3}{4}} \ge 0)=Pr(X \ge 0, Z\sqrt{\frac{3}{4}} \ge -\frac{1}{2}X) $$ Still not sure how to proceed from here. Maybe simplify to $$ Pr(X \ge 0, \frac{1}{2}X + Z\sqrt{\frac{3}{4}} \ge 0)=Pr(X \ge 0, Z\sqrt{\frac{3}{4}} \ge 0) $$ Since we are looking for $Pr(X \ge 0)$ anyway?
$X$ and $Y$ have a bivariate normal distribution with $\rho$ as covariance. $X$ and $Y$ are standard normal variables. I showed that $X$ and $Z= \dfrac{Y-\rho X}{\sqrt{1-\rho^2}}$ are independent standard normal variables. Using this I need to show that $$P(X >0,Y>0) = \frac14 + \frac{1}{2\pi} \cdot\arcsin(\rho).$$
I am from India. I am attending a conference in USA. I have B1/B2 visa. Do I need transit visa if I am changing airport from EWR to LGA
In Europe usually you don't need to go through immigration to change planes (unless you are entering/exiting Schengen). Is it the case in the US as well? May I catch a connecting flight on one of the US airports if I don't have US visa?
Visually it seems that a strictly decreasing twice-differentiable map $f: [0, \infty) \to \mathbb{R}$ with $f''(x) < 0$ for all $x$ should be negative at some point, but I can't come up with a formal proof. Any help?
If $f(x) > 0$ over the reals is it possible to have $f'(x) < 0$ and $f''(x)< 0 $ over the reals? Assuming $f$ can be differentiated twice.
Could someone please help me correct my following proof? Prove that if $G$ is a cyclic group of order $n$, then $G$ is isomorphic to $\mathbb{Z}_{n}$. Proof: Let $G=\left \langle a \right \rangle$ with $|G|=n$. Define the relation $\phi:\mathbb{Z}_{n}\to G$ by $\phi(k)=a^{k}$ with $0\leq k<n$. Well-defined: For $0\leq k_{1}<n$ and $0\leq k_{2}<n$, if $k_{1}=k_{2}$, then $\phi(k_{1})=a^{k_{1}}=a^{k_{2}}=\phi(k_{2})$. Operation preserving: Since $\phi(k_{1}+k_{2})=a^{k_{1}+k_{2}}=a^{k_{1}}a^{k_{2}}=\phi(k_{1})\phi(k_{2})$, the operation is preserved. One-to-one: For $m,n\in \mathbb{Z}_{n}$, let $m>n$ and assume $\phi(m)=\phi(n)$. Then $a^{m}=a^{n}$ or $a^{m-n}=e$. Then $m-n>0$. I am not sure how to prove that $m-n<0$. Is it due to $G$ being abelian? Onto: $\phi$ is onto iff for all $a^{k}\in G$, there exists a $k\in \mathbb{Z}_{n}$ such that $\phi(k)=a^{k}$. By definition, $\phi$ is onto.
I want to prove that 2 cyclic groups of the same order are always isomorph. So, let $G,H$ be cyclic groups with $|G| = |H|$. Then: I suspect the isomorphism would be the one that maps a generator g to a generator h. Thus, consider this function: $f: G \rightarrow H$ defined by $f(g^k) = h^k$. I already showed that this mapping is surjective and a homomorphism, but I get stuck at the injectivity part. Can someone give a hint (my attempts: I tried to deduce whether the kernel is $e_G$ and I also used the definition of injectivity but I got stuck in both approaches)?
Prove that if $f$ is an odd function, then $f ′ (x) = f ′ (- x)$.
This is the question: "Show that the derivative of an even function is odd and that the derivative of an odd function is even. (Write the equation that says f is even, and differentiate both sides, using the chain rule.)" I already read numerous solutions online. was the official solution but I didn't quite understand it (particularly, I'm not convinced why exactly $dz/dx=-1$; even though $z=-x$). Thanks in advance =]
I am using postfix and need to send the mail using google apps smtp. I am getting errors after I thought I had set everything up correctly: May 11 09:50:57 zedsaid postfix/error[22214]: 00E009693FB: to=<[email protected]>, relay=none, delay=2466, delays=2462/3.4/0/0.06, dsn=4.7.0, status=deferred (delivery temporarily suspended: SASL authentication failed; cannot authenticate to server smtp.gmail.com[74.125.155.109]: no mechanism available) May 11 09:50:57 zedsaid postfix/error[22213]: 0ACB36D1B94: to=<[email protected]>, relay=none, delay=2486, delays=2482/3.4/0/0.06, dsn=4.7.0, status=deferred (delivery temporarily suspended: SASL authentication failed; cannot authenticate to server smtp.gmail.com[74.125.155.109]: no mechanism available) May 11 09:50:57 zedsaid postfix/error[22232]: 067379693D3: to=<[email protected]>, relay=none, delay=2421, delays=2417/3.4/0/0.06, dsn=4.7.0, status=deferred (delivery temporarily suspended: SASL authentication failed; cannot authenticate to server smtp.gmail.com[74.125.155.109]: no mechanism available) main.cf: # Debian specific: Specifying a file name will cause the first # line of that file to be used as the name. The Debian default # is /etc/mailname. #myorigin = /etc/mailname smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU) biff = no # appending .domain is the MUA's job. append_dot_mydomain = no # Uncomment the next line to generate "delayed mail" warnings #delay_warning_time = 4h readme_directory = no # TLS parameters #smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem #smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key smtpd_use_tls=yes smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache # See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for # information on enabling SSL in the smtp client. myhostname = zedsaid.com alias_maps = hash:/etc/aliases alias_database = hash:/etc/aliases myorigin = /etc/mailname mydestination = #relayhost = mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128 mailbox_command = procmail -a "$EXTENSION" mailbox_size_limit = 0 recipient_delimiter = + inet_interfaces = all delay_warning_time = 4h smtpd_recipient_limit = 16 # how many error before back off. smtpd_soft_error_limit = 3 # how many max errors before blocking it. smtpd_hard_error_limit = 12 ## Gmail Relay relayhost = [smtp.gmail.com]:587 smtp_use_tls = yes smtp_sasl_auth_enable = yes smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd smtp_sasl_security_options = noanonymous smtp_sasl_tls_security_options = noanonymous smtp_sasl_mechanism_filter = login smtp_tls_eccert_file = smtp_tls_eckey_file = smtp_use_tls = yes smtp_enforce_tls = no smtp_tls_CAfile = /etc/postfix/cacert.pem smtpd_tls_received_header = yes tls_random_source = dev:/dev/urandom transport_maps = hash:/etc/postfix/transport debug_peer_list = smtp.gmail.com debug_peer_level = 3 What am I doing wrong?
I've been trying to configure email to forward to Gmail, using Postfix to relay email to smtp.gmail.com. However, I'm failing to get it to authenticate with smtp.gmail.com, which is a rather vital prerequisite to getting anything working… The mail logs show only: Oct 29 15:50:14 gsnedders-1 postfix/master[6596]: daemon started -- version 2.7.1, configuration /etc/postfix Oct 29 15:50:19 gsnedders-1 postfix/pickup[6598]: EBA1F78750: uid=1000 from=<gsnedders> Oct 29 15:50:19 gsnedders-1 postfix/cleanup[6603]: EBA1F78750: message-id=<[email protected]> Oct 29 15:50:19 gsnedders-1 postfix/qmgr[6599]: EBA1F78750: from=<[email protected]>, size=324, nrcpt=1 (queue active) Oct 29 15:50:19 gsnedders-1 postfix/cleanup[6603]: F2D557874F: message-id=<[email protected]> Oct 29 15:50:19 gsnedders-1 postfix/local[6605]: EBA1F78750: to=<[email protected]>, orig_to=<me>, relay=local, delay=0.04, delays=0.03/0.02/0/0, dsn=2.0.0, status=sent (forwarded as F2D557874F) Oct 29 15:50:19 gsnedders-1 postfix/qmgr[6599]: F2D557874F: from=<[email protected]>, size=454, nrcpt=1 (queue active) Oct 29 15:50:19 gsnedders-1 postfix/qmgr[6599]: EBA1F78750: removed Oct 29 15:50:20 gsnedders-1 postfix/smtp[6606]: warning: SASL authentication failure: No worthy mechs found Oct 29 15:50:20 gsnedders-1 postfix/smtp[6606]: F2D557874F: SASL authentication failed; cannot authenticate to server smtp.gmail.com[74.125.157.108]: no mechanism available And the postfix config is: relayhost = [smtp.gmail.com]:587 smtp_use_tls = yes smtp_sasl_auth_enable = yes smtp_sasl_password_maps = hash:/etc/postfix/sasl/passwd smtp_sasl_security_options = noanonymous smtp_tls_eccert_file = smtp_tls_eckey_file = smtp_tls_security_level = may smtp_tls_CAfile = /etc/postfix/cacert.pem smtpd_tls_received_header = yes tls_random_source = dev:/dev/urandom smtpd_tls_security_level = may
Here's my basic issue: £ apt show cmake | grep -i version Version: 3.5.1-1ubuntu3 £ apt show debhelper | grep -i breaks Breaks: cmake (<< 3.9~), dh-systemd (<< 1.38), meson (<< 0.40.0~) £ cmake --version cmake version 3.11.20180516-gacb971 £ cmake was built and installed from source. I can't uninstall the apt version because many packages depend on it. The debhelper package is from a neovim ppa (16.04), and is honestly probably broken for 16.04 (breaking cmake<3.9 on a 16.04 system doesn't make sense), but...it's actually not an issue on my system. But of course apt refuses to install it. Is there a way to tell apt what my cmake version actually is? Of course, cmake 3.11 is not an apt package and could be missing things, so I doubt it. If not, what might be a good solution to this problem?
I installed program (call it, for example,progA) by building it from source code, and then finally calling sudo make install and sudo ldconfig. However, it seems apt-get hasn't gotten the memo, because when installing progB, which depends on progA, apt-get recommends I also install progA. Why is this, and what could I do?
Let $R$ be the ring of all real valued continuous functions on $[0,1]$ and $M$ be a maximal ideal of $R$. Then how to prove that $\exists c \in [0,1] $ such that $M:=\{f \in R:f(c)=0\}$ ?
Let $R$ be the ring of all continuous real valued functions on the unit interval $[0,1]$ (with pointwise operations), and let $I$ be a proper ideal of $R$. Show that there exists $λ\in [0,1]$ such that $$I\subseteq M_{λ}= \left\{f \in R\mid f(λ)=0\right\}.$$ Can't really get anywhere with this one. Appreciate the help.
I want to convert Unix timestamp (long value) to local tried to covert it. but its not showing local time (UTC +05.30). here local time is 29-12-2018 01:38:09 PM but Its showing 29-12-2018 05:51:09 AM My code is as below. please suggest what i am missing? var lastRecieved = DateTimeOffset.FromUnixTimeMilliseconds(1546062669090).DateTime.ToLocalTime(); string Timetest = lastRecieved.ToString("dd-MM-yyyy hh:mm:ss tt"); Console.WriteLine("Value in datetime format : " + Timetest);
There is this example code, but then it starts talking about millisecond / nanosecond problems. The same question is on MSDN, . This is what I've got so far: public Double CreatedEpoch { get { DateTime epoch = new DateTime(1970, 1, 1, 0, 0, 0, 0).ToLocalTime(); TimeSpan span = (this.Created.ToLocalTime() - epoch); return span.TotalSeconds; } set { DateTime epoch = new DateTime(1970, 1, 1, 0, 0, 0, 0).ToLocalTime(); this.Created = epoch.AddSeconds(value); } }
Is there a name for these kind of doubled words? For example: hanky-panky flim-flam hoity-toity boo-hoo zig-zag Note that some rhyme and others do not.
Some English words only differ in their vowels: crisscross, dillydally, riffraff, etc. Is there a name for them?
I think potential difference across disconnected diode should be zero but how? the last graph tells that there is a potential difference between the two ends of a diode. then how can be it zero?
This image from wikipedia, explains that there occurs a potential drop across a , and an electric field confined to the depletion region. I already know the reason for the existence of this drop and the calculation of the difference but I have two questions regarding this drop. 1) If the regions are externally connected using a perfectly conducting wire, why will not any current flow? Connecting the two regions should equalize their potentials (since wire is a resistance less) conductor, and therefore the gradient at the junction is destroyed resulting in a which is obviously against conservation of energy as the semiconductor has non-zero resistivity. Where will extra potential drops will be created so that Kirchoff's voltage rule holds without any current and the built-in potential difference $V_o$ of the juction persists? 2) (probably naive) If an external Bias is applied, of say $|V|<|V_o|$, then the pn potential difference across the junction will just reduce by that amount ($|V|$). Assuming that the external voltage source is ideal without any resistance, what will be the potential drops which would sum to zero in this case? Will drop due to the resistance of semiconductor play a par in it? If yes, then there cannot be any ideal resistance-less semiconductor junction, can there?
Suppose we have a weightless, rigid rod fixed at one end, but free to swing at the other, where there is a mass $m$ attached. If we want to determine the tangential acceleration of the mass using linear mechanics, we can use the formula, $F = ma$ Thus, $a = \frac{F}{m}$ Thus provided the force is always acting perpendicular to R, the mass will accelerate tangentially at $a$. Now if instead we analyse the problem using torque, we can arrive at the equation, $\frac{dL}{dt} = \tau =R\times F = RF$ Therefore, $\Delta L = RFt$ where t is the time the force is acting on the mass (again assuming the force is always applied in a direction perpendicular to R). Since $L = mRv$, where $v$ is the tangential velocity of the mass, we have, $mRv = RFt$ Therefore, $\frac{v}{t} = \frac{F}{m}$ $a = \frac{F}{m}$ which is exactly as predicted from the linear analysis. So in this very simplistic scenario, the acceleration of the body could be derived using either linear mechanics or utilising the concepts of torque and angular momentum. Given this, in general when does the application of linear momentum start to break down when describing rigid body physics problems, and the concepts of torque and angular momentum become necessary to arrive at a solution?
For a long time I have wondered if there is a way to show that the rotational analogs of Newton's Laws are a direct consequence of just those laws, or are we adding more to them? I understand mathematically that we take Newton's second law and do "r cross both sides," but that has always struck me as using more than just the 2nd law. Here it matters where forces on the body are applied, but I don't see where Newton's Laws talk about points where forces are applied to a body. For translational motion it doesn't matter. So are we adding a sort of "extra law" when we do this for rotation? The only thing I can think of would be to "disassemble" an extended body into differential point masses and work with internal constraint forces that make the body rigid. If every mass is just a point mass it would get around the issue I'm having. I've never seen any discussion along those lines, though.
I'm trying to type \digamma. In latex, this character is supported in \usepackage{amssymb}. In Matlab, I can set the interpreter to be Latex as follows Figure1=figure(1) set(Figure1,'defaulttextinterpreter','latex'); but the aforementioned character is not supported. Is there a solution for this problem?
When using LaTeX as the interpreter to typeset labels in MATLAB it would be great to be able to include packages to customize appearance. Is this possible? As of now I know no method to create non italic greek letters in the legends.
I was surprised to see "his husband" in the : He complained that his husband never paid him any compliments anymore. Isn't that a mistake? Or is Cambridge talking about something homosexual?
I know that non-married lovers address each other by saying “This is my girlfriend/boyfriend.” I know that married couples address each other by calling “my wife/husband”. I also know that gay lovers who are not married (yet?) address each other by saying "my boyfriend" (for gays) and "my girlfriend" (for lesbians). But if they are married, how do they address each other? And how do we describe them? I mean if they are gays, are they “husband and husband” or “husband and wife” (one of them acts like the wife)? And if they are lesbians, are they “wife and wife” or “husband and wife” (one of them acts as the husband)? I know they can be referred to as a gay couple or gay lovers from , but I couldn't find the answer to address each of the two.
When I watched "how I met your mother" season 5 ep15, Robin said: "Dibs on his wings" when she saw Barney was on TV, showed his phone number for any girl to call if that woman wanted to sleep with him. What does Robin mean when she said that? PS: Is there any mistake in my grammar?
The term "to have dibs on something" or "to call dibs on something" plays a recurring role in American film and television (e.g. ), so it gets exported a lot. describes "dibs" as [...] a common, "informal" convention to reserve or declare full or partial ownership of a community resource, such as a chair [...] From the usages in the media I have seen, this convention also seems to contain some moral concept which is not described in dictionaries. For me, it looks like by calling dibs (or ), the caller actually receives the (implicit, moral) right to that resource, and this typically goes undisputed by their rivals. Can you confirm the existence of this concept? Is this something that varies between groups of people (or maybe between regions), or is there a concensus on how to respond to this?
Using induction, prove $|\sin(nx)| \le n|\sin x|$ for $n\in \mathbb{N}$. How I can show that with induction? Normally , When I make a induction I know for $n$, and I prove for $n+1$. But I can't write $n+1$ in this question. If I write $n+1$, formula change like this: $|\sin((n+1)x)| \le (n+1)|\sin x|$ for $n+1$, This new formula doesn't include $n$. What should I do in such cases?
I have to show that for every $x \in \mathbb{R}$ and every $n \in \mathbb{N}$ $$|\sin(nx)| \le n|\sin(x)| $$ In the previous exercise, I have showed that $|\sin(x)|≤|x|$ with the use of the mean value theorem. I think that I cannot use this approach this time. I also tried to write $\sin(nx)$ as a series expansion but that doesn't work either. Does anyone know how I can solve this?
My Mac mini is currently is version 10.12.6. Xcode requires "version 10.14.4 or laterV. However, when I check for available updates for my OS, there are none
So I'm programming on a MacBook from mid-2010, and I have the most recent update (10.13.6) but when I try to install Xcode it says I need to update again, but it's not listed as an update in the AppStore.
I am facing the above problem on my handler which checks every time if your logged in but I am facing that problem how can I solve that? Guys I have tried several methods but I am still getting the same problem it's the splash screen which checks every time so, the app is getting crash. Here is my welcome screen ```public class WelcomeScreen extends AppCompatActivity { private ImageView logo; private FirebaseAuth firebaseAuth; private FirebaseDatabase firebaseDatabase; private static int SPLASH_TIME_OUT = 5000; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setFullscreen (); setContentView (R.layout.welcomescreen); firebaseAuth = FirebaseAuth.getInstance (); final String user_id = firebaseAuth.getCurrentUser ().getUid (); final FirebaseUser firebaseUser = firebaseAuth.getInstance ().getCurrentUser (); firebaseDatabase = FirebaseDatabase.getInstance (); final DatabaseReference databaseReference = firebaseDatabase.getReference ().child ("Users").child (user_id); logo= findViewById (R.id.logoocaap); Animation animation = AnimationUtils.loadAnimation (this,R.anim.splashscreen); logo.startAnimation (animation); new Handler ().postDelayed (new Runnable () { @Override public void run() { //check if there's internet connection checkConnection(); if(firebaseUser != null) { databaseReference.addValueEventListener (new ValueEventListener () { @Override public void onDataChange(@NonNull DataSnapshot dataSnapshot) {```
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 end up getting -0.944444444444444 when I want it to be -0.94 Assuming the entered temperature is 30.3 and clicking Fahrenheit to Celsius. using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; namespace TemperatureConverter { public partial class FrmTemperature : Form { public FrmTemperature() { InitializeComponent(); } private void btnCalcFahrenheit_Click(object sender, EventArgs e) { lblFahrenheit.Text = Convert.ToString(9.0/5.0 * Convert.ToDouble(txtTemperature.Text) + 32.0); } private void btnCalcCelsius_Click(object sender, EventArgs e) { lblCelsius.Text = Convert.ToString(5.0/9.0*(Convert.ToDouble(txtTemperature.Text) - 32.0)); } } }
I want to do this using the Math.Round function
I am specifically looking for UK local authorities, wards, postcodes in shp file format.
After learning about the datasets I've working with the following layers, from the USA data Country boundaries State boundaries County boundaries City boundaries ZipCode/Postcode boundaries What I am trying to find is the equivalent (where appropriate) of the same data for various countries. Is there any free administrative boundaries available as shapefiles for other countries?
I am trying to migrate a plugin. I have these two lines: QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), Configuration.accept) QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), Configuration.reject) I thought after looking into some examples that in PyQt5 the lines should read: self.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), Configuration.accept) self.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), Configuration.reject) but it just throws the error AttributeError: 'ConfigurationDialog' object has no attribute 'QObject' This is confusing because ConfigurationDialog is not found in this py script. ConfigurationDialog is a class in another script but nowhere in it does it make reference to QObject. Can I get some clarification on what where I am going wrong?
A while ago I made a plugin for QGIS for myself. This worked until version 2.18. Now I have version 3.0 and would like to use this plugin here too. But I get some error messages. I have been able to solve most of them fairly easily. Only I can not do this. Perhaps there is someone among you who can help me in this. This is the code that I used before. def initGui(self): """Create menu entries and toolbar icons inside the QGIS GUI.""" icon_path = ":/plugins/BFVWtools/" """Create the menu entrie Configuratie and toolbar icon inside the QGIS GUI.""" self.add_action(icon_path + "/icon.png", text=self.tr(u'Configuratie'), callback=self.run, parent=self.iface.mainWindow()) self.action = QAction( QIcon( os.path.dirname(os.path.realpath(__file__)) + "/icon.png" ), "Configuratie", self.iface.mainWindow() ) QObject.connect(self.action, SIGNAL("triggered()"), self.run) The error message I get is the following AttributeError: type object 'QObject' has no attribute 'connect' Traceback (most recent call last): File "C:/OSGEO4~1/apps/qgis/./python\qgis\utils.py", line 345, in startPlugin plugins[packageName].initGui() File "C:/Users/Automatisering/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\BFVWtools\bfvw_tools.py", line 212, in initGui QObject.connect(self.action, SIGNAL("triggered()"), self.run) AttributeError: type object 'QObject' has no attribute 'connect' Apparently there is no attribute 'Connect' in QObject After your explanation, I have converted everything to PyQt5 and changed the connect to slot. The strange thing is that I now get all the entrys from the menu one after the other.
I have an xml file of this structure <?xml version="1.0" encoding="iso-8859-1"?> <my_events> <event id="e20111129215359"> <title>the title</title> <channel id="1"> <name>A name</name> <onclick></onclick> </channel> <event_site> <name/> <url/> </event_site> <start_date>Thu Mar 08 2012</start_date> <start_time>11:00 AM</start_time> <end_date>null</end_date> <end_time>null</end_time> <notes>Notes for the event</notes> </event> </my_events> To delete an event, I have this php function. <?php include_once("phpshared.php"); function delete_event( $nodeid ) { $nodes = new SimpleXMLElement('my_events.xml', LIBXML_NOCDATA, true); $node = $nodes->xpath("/my_events/event[@id='$nodeid']"); $node->parentNode->removeChild($node); $formatted = formatXmlString($nodes->asXML()); $file = fopen ('my_events.xml', "w"); fwrite($file, $formatted); fclose ($file); } echo delete_event(trim($_REQUEST['nodeid'])); ?> That doesn't delete the node. Is there a different way to do this?
I have several identical elements with different attributes that I'm accessing with SimpleXML: <data> <seg id="A1"/> <seg id="A5"/> <seg id="A12"/> <seg id="A29"/> <seg id="A30"/> </data> I need to remove a specific seg element, with an id of "A12", how can I do this? I've tried looping through the seg elements and unsetting the specific one, but this doesn't work, the elements remain. foreach($doc->seg as $seg) { if($seg['id'] == 'A12') { unset($seg); } }
Regarding Potential Duplicates: I saw , which got closed as a duplicate of , which in turn has an "accepted" answer, but doesn't answer the question (or, the answer was revoked). So, there still seems to be no thread keeping this issue open for continued discussion or waiting for a viable resolution. There may be other potential duplicates I may have missed, however. Today wasn't the first time I failed an audit, wanting to learn more about why a question got VTC'ed. I've failed audits by accident before too, so I'm not too torn up about having failed(—although, as the person running the SO Close Votes Reviewers chat room, it'd be pretty ironic if I got banned from those reviews :-)—but I am uncomfortable that the current system fails an auditee who clicks a button which normally functions to display more information (not cast a vote). It's as if normally, it's a Close... button, and during an audit, it's a Close button—and that makes a difference. Preempting those who'd say that one shouldn't need information about what others are doing to make their own judgment, . But, between (1) the bias that the lightbox might cause (which, we're supposed to trust users about, as answered in the linked question) and (2) penalizing the thoughtful and the curious for wanting to know more, I feel the greater evil is the latter. (Besides, why not just show no votes, as if it were a freshly flagged question? Or, if these are pulled from real examples, just show one of the votes that was originally cast.) Precisely because I'm always skeptical of what I presently know, when I see something that doesn't make sense, I want to find out more. When I see a question that seems just fine, I instinctively click Close, hoping the subsequent lightbox might shed some light on things, or teach me something new: Is there a more specialized site for this question that I haven't heard of? Is there some other, subtle reason I'm not yet aware of that this question should be closed? Was a code sample missing previously, but filled in later? If yes, then I want to see how many off-topic votes this question received, because if it has, say, 3 such votes, and the question seems useful, I'd comment, "This question has been improved and should no longer be closed for its initial reason," to fend off its impending doom. (It only takes one more user—tired and on autopilot—or predisposed to bandwagoning—out of all exposed to the question until the votes expire.) I think this is one of those questions asking about objective differences (not opinion-based) between the internal workings of two comparable "software tools commonly used by programmers," which is a valid question. But with the popularity nowadays of closing such questions as being about "a tool, library, or favorite off-site resource," I want to leave a comment explaining the difference to future reviewers. So let's see, how many people voted to close for that reason? (Or, was this question voted to close for something else entirely that I've missed?) I think there might be valid grounds for closing this question. But with the advent of so many new, long-descript close vote reasons, I need to go over them again to know for sure whether I'm doing the right thing. And so on. tl;dr I use the lightbox to make many judgments about how to review a close vote, and especially whether to leave a comment and what if so. I think it's healthy that a user should attempt to investigate the context in which a question was VTC'ed. Alas the current system discourages that curiosity. I think it's inconsistent that the Close button should mean different things in practice, and during an audit.
Having just from any of the queues, it was reviewing close votes; however, this audit was flawed in that I didn't even cast a close vote. Often I press the Close button to preview greater detail and sentiment of the closure, spawning the Why should this question be closed dialog box: Especially for duplicates, where functionality is solely dependent on spawning this dialog. From Closing > Duplicate, I can search or view selected duplicates: Although, I realize general closure reasons are summarized on the page: This question had 6-upvotes, but seemed very localized referencing subjective query is "taking too long" and even had a sqlfiddle link. Maybe overly broad regarding performance tuning, the OP was posting like a forum with two answer posts to his own question and with one of those answers asking follow-up questions. Wanting to gauge community response, current closure totals struck my curiosity. So, I pressed the Close button and boom - oh, the humanity! I failed, and didn't even cast a close vote. Votes are not cast until a reason for closure is selected and Vote to Close is pressed. Taking any review very seriously on this site, it only seems fair that my review quality is tested through actionable steps instead of clicking for more detailed information, leveraging the functional design of the close vote user interface. Sure, it's complex to seed fake vote totals, and then there's controversy of mindless voting in the majority or people who simply cherry pick 4-vote questions. Still though, it seems unfair I should hesitate to review further information of vote totals and duplicates before skipping due to the implementation of this audit.
I'd like use awk to parse a file, and add a line, if and only if this line does not already exist. My file: cccc dddd aaaa mmm Example 1: I'm looking for "aaaa" "aaaa" exists so, nothing happens, the output file will be the same. Example 2: I'm looking for "bbbb" "bbbb" doesn't exist. My output file should be : cccc dddd aaaa mmm bbbb How can I obtain this result?
Using awk, how we can add text at the bottom, only if a certain pattern was not found in the file? This is not working: awk '{if ($0 !~ /pattern/) {print}; END {print "someText"}}' file The file is small, less than 1MB.
This is an update of a query that I had asked few months ago: In fact I have even adopted some of the suggestions given by @Magicsowon there. I was advised to make the question to the point, and not include any extra information. This is why I am posting it afresh here with only relevant information and also some new information as the situation has evolved since then. I have worked as a postdoc in a European university for 6 months. The topic of my research was suggested by my boss and his collaborator, Prof. M. That was their contribution. After that, I went through more than 50-60 papers to find the right paper to build my work on. I have developed the theory and I have finished the computational part. Now, I am writing the paper. A good analogy would be, it was like going to a conference and there one hears about an interesting problem that deserves serious investigation. While developing the theory, I sent many drafts containing my derived equations to my main collaborator (my boss), but he hardly commented on them, none useful feedback from him. I do not think he had even read them seriously. Considering that a postdoc is essentially an unsupervised position, and the potential of co-authorship dispute in the future, I sent him a couple of emails asking him to help me with certain aspect of the theory and computational aspect. But, he did not provided any help to me. He had a regular comment during every meeting we had, "I am aware, I should more actively contribute to the work, but as you can see I am busy with meetings. And I am sure, you can fix this problem." Also, he did not gave me sufficient freedom to collaborate with other researchers. So, having no help coming from anywhere, I resigned from the job. I had implicitly mentioned to him as well as to the head of the dept. in my resignation email that I had worked all by myself during the 6 months stay at their department, and also that I can do the remaining work by myself. No objection was raised on that from anyone. Now, I am writing the paper, and my plan is: 1) Write the paper as a single author under the affiliation of the former department where I had finished almost 40% of the work. I cannot gift co-authorship for my hard work of 6-months to anyone as I did not received any major/minor help from anyone. I have checked, this is consistent with the Vancouver recommendations. 2) I will acknowledge my boss and Prof. M in the acknowledgement section of the paper for suggesting me the topic of research. Note: I had just met Prof. M in a conference for 30 minutes or so, we had general discussion about the topic of research. No specific discussion regarding the work I did, no mail correspondence between him and me. However if I am not wrong, he is the actual brain behind the project, and I had tried to visit him and collaborate with him closely. But my boss did not facilitated that either. Also, note that my boss and Prof. M have worked together in most of their papers in the last 2-3 years. And my boss is the director of a research unit in which Prof. M is a member too. 3) I will also acknowledge the research unit of my boss for funding the research. Is it fair, honest and sufficient? If the paper is published, can he claim authorship by writing to the editor? I am pretty sure he can almost show nothing about the evidence of the contribution other than suggesting the topic of research, if asked. And the traces of this problem have off shoot to become another problem. See,
I am a postdoc at a European University. However, I am planning to quit my postdoc in a month or so since the research environment and the city life is not to me liking. Also, I work with a Professor who is very polite, but also very busy with meetings. My salary comes from the project he administers, so he is the boss of the organization and the project. For the past four months I have been working on a problem day and night including weekends as I found the problem very interesting and challenging. The theoretical part of the work is complete. It is a "complete" solution. He had NO contribution at all in this. Not even a single email exchange. He is too busy with meetings all the time. He is in the department twice a week for two to three hours at a time. I am also managing his master student as he has no time. He is definitely polite and nice though, but I have not received any input from him other than giving me printed research papers. But he always asked me to give him the PDFs of lengthy derivations which I did. But I am dealing with analytical/numerical Navier-Stokes equation and its variations, so you can imagine how much terse that is. He has the entire theory now with him from my work. He may have been a good researcher in the past but no contribution to this work. And he had no proper publication in the work that I am doing so I am not sure how much he can contribute in writing the paper. Now remains the numerical part which I believe I can do in next 2/3 weeks. And I have the ability to write the paper by myself when I have the numerical solution. I talked to him and asked if I can work for him based in another city. He said if it is a week visit, that is fine, but not otherwise. He said it clearly that "I will not pay you to work somewhere else." I still have a cordial relationship with him. No worries on that part. So, I am going to leave the place and the position in a month or two for sure. So, he gains co-authorship just because he has the authority to provide employment? What should I do? Please help. I could have continued to live in the city though it was little boring for me, provided I was able to get inputs from my collaborator, or if he had given me necessary freedom to collaborate with other researchers, which he hasn't. Update 10th June, I have resigned now. This problem has evolved into a new stage. Please post your replies there: and
The Sorcerer's metamagic features has the following general rules: At 3rd level, you gain the ability to twist your spells to suit your needs...You can use only one Metamagic option on a spell when you cast it, unless otherwise noted. The Empowered Spell metamagic states: When you roll damage for a spell, you can spend 1 sorcery point to reroll a number of the damage dice up to your Charisma modifier (minimum of one). You must use the new rolls. The Wand of Magic Missiles states: While holding it, you can use an action to expend 1 or more of its charges to cast the magic missile spell from it. My question is does the process of activating the Wand equate to the sorcerer casting the Magic Missile spell and thus it becomes a suitable target spell for enhancement using the Empower Spell metamagic? Or does the casting occur from the wand and not from the sorcerer, thereby rendering the spell invalid for metamagic enhancement?
This question is updated to request additional answers and details in light of information now available in the Dungeon Master's Guide. In the released DM basic rules, Lost Mine of Phandelver, Hoard of the Dragon Queen, and the DMG teaser there are wands, staves, and rings that you can use to cast spells. Do abilities that trigger from casting a spell activate when casting a spell from an item? Can the character modify the spell using class abilities when casting a spell from an item? Examples include: An abjurer Wizard's arcane ward recovering hit points from a Dispel Magic cast from a Ring of Spell Storing A sorcerer using Twinned Spell on a ray of enfeeblement from a Staff of Power An evocation wizard using Sculpt Spell on a fireball from a Wand of Fireballs. Now that the DMG is out we have some clearer rules on casting spells from items (DMG p. 141): Some magic items allow you to cast a spell from the item. The spell is cast at the lowest possible spell level, doesn't expend any spell slots, and requires no components, unless the item's description says otherwise The spell uses its normal casting time, range and duration, and the user of the item must concentrate if the spell requires concentration. A magic item, such as certain staffs, may require you to use your own spellcasting ability when you cast a spell from the item. Does whether or not you can apply class abilities to the casting of the spell depend whether the item uses the user's own spellcasting ability (such as the Staff of Fire) versus an item that comes with a fixed spellcasting ability built-in (such as the Wand of Fireballs)? Does it matter if it's something that triggers more or less automatically like Arcane Ward, versus something you have to control, like Careful Spell?
Today is 3/26/2016. I want to Print out how many days are until 4/05/2016 ex. The answer is 10 days. I want to do this with Javascript Code. With standard javascript or with the use of a Library or Framework. Just to calculate the Difference between two dates. Easy, no too complicated. InsertDateHere ------- 3/26/2016 InsertDateHere ------ 4/05/2016 ResultHere -------------- AnswerHere ("10" ex.) if anyone can help, please Do. Thanks a lot People!
How do I get the number of days between two dates in JavaScript? For example, given two dates in input boxes: <input id="first" value="1/1/2000"/> <input id="second" value="1/1/2001"/> <script> alert(datediff("day", first, second)); // what goes here? </script>
Do you guys know where the AOT location is? I tried using the map from a thread and my best possible solution was Australia or eastern Europe but I can say for sure. note the climate of Australia real doesn't suit the inside of the walls.
Is the setting of "Attack on Titan" (Shingeki no kyojin) supposed to be Earth in the distant future and Titans suddenly appeared out of nowhere and devolved society to medieval level of technology? Or is this just a completely fictional setting?
I am experiencing a issue in my 3d blender model. It seems as if hard shadows are appearing on my model, but it is not a lighting issue as when I add a sun lamp the black spots are still there as seen below. It is also not an overlapping issue as i can find no overlapping quads over my whole model. I will leave the blender model below so that you can look at it yourselves and hopefully fix this issue :)
I can't find the solution to this one; I don't know the correct name of the problem. The shading is different on parallel faces facing the same direction. I've tried: - Recalculating Normals - Removing doubles - Tried smooth and flat shading - Deleting and remaking faces - Adding Edge Split modifier Any ideas? Thanks Edit: Link to .blend:
Other similar questions I have found used integration by part of alternative complicated transformations that I do not understand. Using the $\cos(x) = \frac{1}{2} * (e^{ix} + e^{-ix})$ identity, is there a way to find the solution, which should be $a/(a^2 + s^2)$?
I need to find the Laplace transform of $\cos(at)$ I know that $L\{\cos(at)\}= \int_{0}^{\infty} e^{-st} \cos (at) dt$ but I am having trouble finding the integral Thank you
I have already asked a question about this but I didn't really get a clear answer. I need to delay a tp command but when I searched it up I found a answer on how to tp an armour stand. I would like to know how to convert the command below so that it teleports a person to -586.634 64 -430.697. This is the command I found /tp @e[type=ArmorStand,name=Bob,score_time_min=101] ~ ~1 ~ If anyone could change this command or tell me how to it would really help! (NOTE: Before anyone comments below I did already create the scoreboard)
I found 11 questions like this on gamingSE already, but none of them have proper and up-to-date answers. So I'm creating this Q&A: How do you either activate a command x seconds/minutes/hours/… in the future or every x seconds/minutes/… in a loop? Repeating command blocks and ticking functions execute 20 times per second, redstone is in many situations and most of the extremely fancy solutions, like falling blocks in cobwebs, have broken over time or are needlessly complicated.
It's been a question since long time. Everytime code goes for review there are different opinion from different senior developers/coders/QA. And every other person fights for its own opinion. Here are some of "Code review": There should be single HTML identifier.CSS Selector, id, name, xpath or whatever, but choose only one across the project It should be xpath only across the project Use name and id only, as they are fast and readable You can use whatever is easily available i.e. sometimes use xpath, and then sometimes use Css selector etc etc Which one is best practice in terms of speedy execution of Automation tests and managing Object repositories? Plus you can point in Code Review meetings that this is why I am using it. If it depends which tools you are using, as of now I am using WATIR (Ruby+cucumber) and previously I was using JAVA. This question was earlier posted by me on Code Review SE but there it got closed due to off-topic, not so sure where to post so posting here.
I'm pretty sure this isn't the right place to ask this. I'm not aware of a stack site out there where this question would fit. If someone could point me to the right place it would be awesome. The question I was going to ask is: I am incorporating a blogging feature into my car enthusiast site. I want each user to be able to have their own blog and be able to browse other people's blogs. What blog engine would be best for this scenario? I am using ASP MVC 4 and found to look promising; however, I am a bit confused at the setup. This seems to be a blog set up for a personal site and not a "Nest of blogs" type of system. I've never done a blog before so I'm fresh meat here.
For some languages, there are academies that decide topics such as grammar and spelling of things, for example, for the Spanish language, there are 22 academies in 22 different countries, all making decisions on spanish grammar in their country. I would like to know if there is something that serves the same purpose for the English language.
Some languages have a "regulatory body" issuing recommendations and guidelines regarding the use of that language. For example in the case of Spanish it's the whose status is recognised in all Spanish-speaking countries. The Academy, among other things, publishes a dictionary (""), in print and , which is usually given a lot of prestige (but is not without , of course). Are there any such authorative—or at least influential—institution(s) or publication(s) for the English language?
I have a company laptop (a Lenovo T540) running Windows 10. I am using a domain user to access the computer. That user has administrator privileges. A few days ago, Windows did a Windows Update, rebooted and then failed to start. After the Lenovo splash screen the screen stays black with no further progress. Holding Shift+F8 during boot shows the Windows 10 recovery menu. However, trying to do any action gives the following error: You need to sign in as an administrator to continue, but there aren't any administrator accounts on this PC. Using a recovery USB created from another Windows 10 machine does allow all of the actions from the recovery menu to start, but they all give an error. At best I would like to use the System Restore to go back to before the Windows Update was installed. I have some important files still on the drive of the laptop, and would rather not have to do a clean reset of the Windows 10. Is there a way to work around that error?
I accidentally disabled my admin account. After I login to another account I found I can not get admin rights, because all admin accounts on my computer are disabled. I clicked on 'run as administrator' but only see a smart card choice (all the admin accounts are disabled so no choice provided) I don't want to re-install my OS, help! Details: I have account A on my computer. I got a new computer so I want to give the old one to my mother. Creating a new user account B for her and disable account A. Logout and restart. Successfully login B, now I found I could not get admin rights because no account choice is provided. More informations about my machine: OS is Windows 10 and my admin account is a Microsoft Account. I have an arch-linux installed on my computer and dual-boot it using GRUB, so maybe I can not use safe mode.
I am unable to install mssql-tools sudo apt-get install mssql-tools It gives the error: E: unable to locate How can I fix this?
This post was created to try and be a 'catch all' canonical question/answer pair for 'How do I Install MSSQL Server' and 'How Do I Install MSSQL Server Tools' questions. I am looking to set up MS SQL Server for Linux, and quite possibly its tools (on the server itself or other systems) so I can interact with SQL Server. How can I go about doing this?
I am doing research more than 3 years. I was admitted in a 3 years program, now in the last months of the program. I fell I have a long way in the field to be an independent researcher. But most of the post-docs in my department and in my group don't seem to be in the direction of a independent research. Many of us PhD students and post-docs look like more high level technical staff.
I am in the last months of my MSc and I have done my thesis. I have published some conference papers but most of them were literature reviews. My MSc thesis is about solving wave equations by means of method of potentials and boundary elements. I am interested in pursuing research in another field (differential equations) but I have no idea how to start any topic that may lead to a journal publication. By asking this question, I want to understand how a research student, whether a recently graduated MSc student or a PhD student, can start searching for a new research topic and develop some researches based on his own interests. Specially, I would like to know: To what extent should a graduate student be dependent on faculty members? How can he be more independent and start his own research activities? Is it a good idea that the graduate work on another topic with the faculty member or work independently on a more recent research topic? If the person is in a research group or at the university, is it a good idea or is it ethical that he develop his own research interests, besides to the topics which are being developed in that institute? How should a graduate student manage this and make some progress in the research fields of his own interest? (In particular, sometimes the faculty members are not interested in the topics you are interested in and the person has to start his own research activity.) And also, if this research is part of his independent research, at the time of publishing what affiliation should be used in the publications. Should it be "Independent Scholar" as mentioned in or something else? This is important in academic publications, because sometimes, the person is in a research group, but he is publishing a paper as part of his own researches not the things he is doing in that institute; in this case, has he mention that institute's affiliation or use his own one? So please make it clear that how the affiliation would be when the person does research independently in the cases like when he is not working in a research group or he is working with a professor or research group but his publication is output of his own research activities? It is a little unclear.
I was trying to learn more about Linux and came across the command ls ????? and it displayed a few files in the directory but I am not really sure what it is specifically displaying. I tried to use the man to explain it further but I couldn't find anything. Could someone please explain?
If I have a number of directories, named, for example 10001 through 10025 is there any reason to use ls 1*/foo vs. ls 100??/foo? I have a lot more than 25 of them, so I mostly curious if there's any differences in speed. I know the difference in use between the two, that the asterisk will match longer file names, like 10001.backup. But let's say I don't have any files that don't follow my conventions. Is there any behind-the-scenes differences?
I observe a sample from a distribution that I expect to be the hitting time $$\tau = \inf\{t>0| X(t)>a\}$$ where $X(t)$ is a Lévy process with $X(0)=0$ and $a$ is some constant. $X$ is not a Brownian motion and the experimental fit to the is poor. However, I do not need to know the exact formula for the law of $\tau$. For my needs I only need to know that the expectation of $\tau$ is infinite (as in the case of tau for a Brownian motion). Is it possible to formulate and test this as a statistical hypothesis?
Is it possible to test for finiteness (or existence) of the variance of a random variable given a sample? As a null, either {the variance exists and is finite} or {the variance does not exist/is infinite} would be acceptable. Philosophically (and computationally), this seems very strange because there should be no difference between a population without finite variance, and one with a very very large variance (say > $10^{400}$), so I am not hopeful this problem can be solved. One approach that had been suggested to me was via the Central Limit Theorem: assuming the samples are i.i.d., and the population has finite mean, one could check, somehow, whether the sample mean has the right standard error with increasing sample size. I'm not sure I believe this method would work, though. (In particular, I don't see how to make it into a proper test.)
I am creating two structs in C that have the same number of variables: 3 integers and 3 chars. When i look at the size of an instance of each of the structs using the sizeof() operator i get two different values. I wonder Why is this happening, here is my code: I tried rearranging the variable with the same result. typedef struct a { int x; char a; int y; char b; int z; char c; }s1; typedef struct b { int x; int y; int z; char a; char b; char c; }s2; int main() { printf("%d %d\r\n", sizeof (s1), sizeof (s2)); return 0; }
Why does the sizeof operator return a size larger for a structure than the total sizes of the structure's members?
I'm currently learning how to write bash scripts. How do I stop while loop once I get a 200 response code on my curl request? aws --endpoint-url http://s3.sample.com/ s3 cp hello.php s3://bucket/ while [ true ] do curl http://sample.com/hello.php &> /dev/null done
I've script as below :- (edited) httpUrl="http://www.nnin.com" rep=$(curl -v -X POST -d "UID=username&PWD=pass" $httpUrl) status=$? if [ "$?" -eq 0 ]; then echo "Success" exit $status else echo "Failed" exit $status fi when I run the script the return code always $?=0 because in a way the script is successfully execute but I want the return code for cURL to apply in next function. I've try browsing around and use several method in this site particularly but doesn't help much, maybe because of the POST command and how to prevent the output from print when I run the script? Thanks
The following command from terminal works perfectly: sh /home/flux/Downloads/TeamSpeak3-Client-linux_amd64/ts3client_runscript.sh How would I go about adding this as a shortcut, so I can open teamspeak from my Unity Launcher panel on the left without using the terminal?
Will Unity allow making custom launcher icons from .desktop files or via menu editing system? (Right now the launcher doesn't give the option to "keep in launcher" on all programs. For some programs I use, I have to make custom launchers or .desktop files. For instance, daily blender builds are generally just folders with an executable. In basic Gnome or KDE, I can make a new menu entry with the menu editing system. Then, I can also add it to Docky either from the menu or by dragging a .desktop file to it. Unity launcher doesn't support drag and drop, so thats not a bug or anything, but when I open a .desktop file, it has unpredictable results. Most time it will not have "keep in launcher". Sometime it will have a pinnable item without the .desktop's icon, and if I pin the item to the launcher, it will not call upon the program again after closing it. I've also gotten it to just work with a .desktop file for celtx.
Why Ubuntu disconnects from Wi-Fi when turning on hotspot and how to solve this problem??
I know how to create a hotspot when connected to a wired network, but when I am using internet from a WiFi connection, this disconnects the wireless connection the moment I activate the hotspot. In Windows I can use , which enables me to share the internet connection from the same wireless adapter as I am creating an access point on. As you can read on the : Access Point mode allows you to create a hotspot using the same Wi-Fi card that you are using to access the Internet. How do I do this on Ubuntu?
I want to prove that if $a$ and $b$ are positive integers, the following equality is true: $$\left\lceil \frac{a}{b}\right\rceil = \left\lfloor\frac{a+b-1}{b}\right\rfloor$$ What have I thought about? Then $a$ = $qb + r$, where $q$ is the quotient and $r$ the remainder \begin{align} b-1 &\ge r \ge 0 \\ qb + (b-1) &\ge qb+r \ge qb \\ qb + (b-1) &\ge a\ge qb \\ \left\lfloor\frac{a}{b} \right\rfloor +1-\frac1{b} &\ge \frac{a}{b} \ge \left\lfloor\frac{a}{b}\right\rfloor \\ \left\lfloor \frac{a+b}{b} \right\rfloor -\frac1{b} &\ge \frac{a}{b} \ge \left\lfloor\frac{a}{b}\right\rfloor \end{align}
Mathematically, why is this true? $$\left\lceil\frac{a}{b}\right\rceil= \left\lfloor\frac{a+b-1}{b}\right\rfloor$$ Assume $a$ and $b$ are positive integers. Is this also true if $a$ and $b$ are real numbers?
I've been running a game for three sessions now, and each time I feel uncertain as to how to raise the curtains, so to speak, to let everyone know that we're entering the and it's time for me to be the dungeon master and them to be the players, as opposed to us being just friends sitting in a circle. I can of course do something like say "Okay guys we're starting now, time to get serious", but this feels to me a bit heavy-handed, and I'm not sure it would help us all get to the place we're aiming for. This is especially important as I'm going to be moving to a new place in a few days, and any players I find in the new game I want to run then might not be experienced players and have the presence of mind to consciously put themselves in that roleplaying state of mind. What techniques can I make use of to put everyone in the right mindset at the start of a session and to provide that rigid turning point beyond which everyone knows the game is really on?
We have a weekly game in the evenings; however, we often don't start playing for a few hours after we get together, if at all. This has been exacerbated recently by other events with the same people being scheduled for the few hours prior to the game; last week we barely managed to struggle through a five-minute scene over the course of 8 hours we'd scheduled for gaming! Since we rather enjoy our "social hour" just before the game, what can we do to signal a definite switch to "Game time is now!" (It's a World of Darkness game, if that helps; not settling down to play seriously takes away from the horror aspect significantly)
Let $R$ be a finite commutative ring. Does $R$ must be a direct product of local rings? The basic example is $\mathbb Z/n\mathbb Z$, but I can not find any counter example. If the answer is no, then in what conditions $R$ is a direct product of local rings?
Proposition. Let $R$ be commutative ring with $1_R$. We assume that $R$ is an Artinian ring and $M_1,\dots,M_n$ its maximal ideals. Then $R/\mathrm{Jac}(R)\cong (R/M_1)\times \dotsb \times (R/M_n)$. The ring $R$ is isomorphic to the direct product of a finite number of Artinian local rings. Proof. 1. It's obvious that $M_i+M_j=R,\ \forall 1\leq i \neq j \leq n$. So, from Chinese Remainder Theorem, we have $$R/\bigcap_{i=1}^{n}M_i = R/\mathrm{Jac}(R) \cong (R/M_1)\times \dotsb \times (R/M_n),$$ as we wanted. Since $R$ is an Artinian ring, we have $\mathrm{Jac}(R)^m=\{0_R\}$, for some $m\in \Bbb Z^+$. But, $$\{0_R\}\subseteq M_1^m\dotsb M_n^m=(M_1\dotsb M_n)^m\subseteq (\bigcap_{i=1}^{n}M_i=\mathrm{Jac}(R))^m=\{0_R\}.$$ So, if we apply CRT we will take $$R\cong R/\{0_R\}\cong R/M_1^m\dotsb M_n^m\cong (R/M_1^m)\times \dots \times (R/M_n^m).$$ Questions. 1) Are these thoughts complete and correct? 2) Why $R/M_i^m$ are artinian local rings? 3) Could you please elaborate some examples as an application?
Faced with a problem that jquery doesn't allow to select appended element. I've seen a lot of advices how to solve it. For example: var $li = $('<li><span>' + html + '</span></li>'); $('.top').append($li); But it can't help me in my way. I get from server list of records from database in json format and in my view and I loop by this list and generate some html structure. For example: $.getJSON( "/searchbytype", data, function( data ) { $.each( data, function( key, val ) { $('items').append('<li class="item">'+ val.name + '</li>'); }); }); And what I want to do next is click on some li item and to do some manipulation. Ul list may contain 100-200 li tags. Any ideas would be appreciated!
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.