body1
stringlengths
20
4.1k
body2
stringlengths
23
4.09k
I have Dell Studio 1555. I want to install Ubuntu. I have downloaded Ubuntu latest version(Ubuntu 14.04.1 LTS) with 32 bit. there was an option with 64 bit (recommended). First question, Which version should I use? second question, from where I can get the drivers for the same? Please help me out, Thanks, Jay
What is the difference between 32-bit and 64-bit Ubuntu? I've heard the 64-bit platform performs better and can detect more than 4GB of RAM. Also, while some apps haven't ported to 64-bit yet, ia32-libs lets a 64-bit machine run them. If so, why not promote 64-bit over 32-bit?
Is there anyway to get the height of a dynamic div using javascript?I have a dynamic div which is populated by contents dynamically.I want to know div's height each time. Can anybody help me to figure it out?
How do you get the rendered height of an element? Let's say you have a <div> element with some content inside. This content inside is going to stretch the height of the <div>. How do you get the "rendered" height when you haven't explicitly set the height. Obviously, I tried: var h = document.getElementById('someDiv').style.height; Is there a trick for doing this? I am using jQuery if that helps.
I don’t see that anything is broken it just doesn’t follow the main mirror i push it up manually and it stays up but when taking a picture it doesn’t go up with the main mirror it stays down making my pictures have a black band .. can I DIY it maybe ? do you know if this is worth the fix I don’t want it to cost more than the camera itself ..
My Canon 350D is no longer raising the AF mirror when it takes a photo. Instead, it looks like this when the mirror flips up. This results in a photo that is half black due to the sensor being obscured. This camera is 9 years old and has never been dropped, mishandled or subjected to harsh temperature or humidity. Is there any common maintenance I can do to get this thing swinging properly again?
Here (a,b) represents GCD of a and b [a,b] represents LCM of a and b I deduced the relation $(m,n,k)^2[m,n,k]=mnk$ But I am not able to proceed further. Any suggestions??
Let $(a,b)$ denote the GCD of $a$ and $b$, and let $[a,b]$ denote the LCM of $a$ and $b$. Prove $\frac{[a,b,c]^2}{[a,b][b,c][c,a]}=\frac{(a,b,c)^2}{(a,b)(b,c)(c,a)}$.
Is there a way to somehow shrink down sda4 and free up 10gb and then allocate that freed up space to sda3? without breaking anything on the system that might require me a full reset setup from scratch by doing a typo :) The following shows my partition layout and problem:
Previously, I have installed Windows 7 on my 320 GB laptop with three partitions 173, 84 and 63 GB each. The 63 GB partition was where the Windows was installed. The rest were for file containers. Now I changed my OS to Ubuntu 12.04 LTS. I installed Ubuntu by replacing the entire Windows 7 on the 63 GB partition. The rest of the partitions remain as an NTFS Windows partition and I can still access them both (the 173 and 84 GB partitions). Now I want to change the two partitions of Windows into an Ubuntu format partitions plus most importantly, I want to extend the 63 GB partition to more than a 100 GB because at the moment I am running out of disk space. Whenever I try to install any application, especially using wine, it always complains for a shortage of disk space. How do I do the extending activity before I entirely format my laptop again and lose all the important files on my partitions?
I just upgraded a workstation from 18.04 LTS to 20.04 LTS over the web. I use Mozilla Firefox production download tar.bz2, not a .deb from an Ubuntu repository. The upgrade automatically installed the Ubuntu version of Firefox. I manually removed this Ubuntu-automatically installed version with apt purge and the like, although before doing so I did, as root, mv /usr/lib/firefox /usr/lib/firefox-distro so that the Ubuntu version can be accessed. In the Mozilla production version, when I select within Mozilla Help -> About Firefox, the "check for updates" box appears, but cannot be activated, and the usual check with "Firefox up to date" (after an automatic checking by Firefox and unless an update is needed) does NOT appear. From Note: If you use your Linux distribution's packaged version of Firefox, you will need to wait for an updated package to be released to its package repository. This article only applies if you installed Firefox manually (without using your distribution's package manager). End excerpt. How to I get Firefox NOT to be under the update control of the "distribution's package manager"?
Because of I'd like to prevent apt-get upgrade and Update Manager from updating the "libgtk2.0-0" package. How can this be achieved?
My DM says I need a skill or feat to use my pact weapon and conjure weapon at the same time. Is this true? Because I want to dual wield warlock hexweapon but warlocks don't have anything that grants bonus actions? Edit: This is different from other dual wielding because my weapon changes to a CHA modifier. Also the post linked still gives me two answers that arent specific to Hexblade class.
During the latest gaming session our level 3 Rogue was Two-Weapon fighting with a Rapier in the main-hand and a scimitar in the off-hand. At the completion of our gaming session I contested the application of the Two-Weapon fighting rules as it seemed unbalanced. Once I got home I reviewed the PHB and various RPGStack and Reddit but couldn't find a concrete answer. My interpretation of the PHB Reference rules below is that although any class/character can technically wield a weapon in their off-hand, only those who have been granted a Bonus Action for which no explicit bonus action have been defined would be allowed to actually attack. So in the case of a Rogue the Bonus Actions granted under Cunning Action allow for specific actions (none of which are attack). The alternate interpretation would be the rules under Two-Weapon Fighting, perhaps it should be written you receive a bonus action to attack with a different light melee weapon that you’re holding in the other hand. This would, in my opinion, explicitly grant the Bonus Action to any character/class who is Two-Weapon Fighting. After thorough review does it boil down to application of the rules-as-written and determining a house-rule to apply in our campaign? References Page 189 of PHB : Bonus Actions Various class features, spells, and other abilities let you take an additional action on your turn called a bonus action. The Cunning Action feature, for example, allows a rogue to take a bonus action. You can take a bonus action only when a special ability, spell, or other feature of the game states that you can do something as a bonus action. You otherwise don’t have a bonus action to take. You can take only one bonus action on your turn, so you must choose which bonus action to use when you have more than one available. You choose when to take a bonus action during your turn, unless the bonus action’s timing is specified, and anything that deprives you of your ability to take actions also prevents you from taking a bonus action. Page 96 of PHB A Rogue receives cunning action at level 2, You can take a bonus action on each of your turns in combat. This action can be used only to take the Dash, Disengage, or Hide action. Page 195 of PHB Two-Weapon Fighting (Combat Rules) When you take the Attack action and attack with a light melee weapon that you’re holding in one hand, you can use a bonus action to attack with a different light melee weapon that you’re holding in the other hand. You don’t add your ability modifier to the damage of the bonus attack, unless that modifier is negative. If either weapon has the thrown property, you can throw the weapon, instead of making a melee attack with it. Page 165 of PHB Dual Wielder (Feat) You master fighting with two weapons, gaining the following benefits: You gain a +1 bonus to AC while you are wielding a separate melee weapon in each hand. You can use two-weapon fighting even when the one-handed melee weapons you are wielding aren't light. You can draw or stow two one-handed weapons when you would normally be able to draw or stow only one.
So I have several email addresses over the last 20 years based on the main character from a 3-4 part book series. I'd love to remember the title and re-read them so I can explain the meaning of my email address - it has become my persona. I read the series in around 1996-97. It was set in space and centred around a lone-ranger type character called Darek Jarrod (I think spelled correctly). He had a telepathic owl-like alien sidekick who flew with him in his little fighter starship thing. There was some sinister, somewhat ethereal council of overlords who needed to be defeated - I think there was a lead antagonist as well. Eventually, 4 books later, he manages to defeat them. It's not much to go on - I think it was aimed at young adults/adolescents as I was a teen at the time. Any help for this 20 year+ mystery would be appreciated. Thanks, Jarrod ( :S )
I remember that the main character is trying to find the group that destroyed his home planet while he was on a mission. His planet was very difficult to live on and the people became expert in martial arts and were the best soldiers in the galaxy. They were mercenaries and often helped against tyrants. There was a very memorable section in at least one book about an initiation task that the main character had to do in that he had to survive in their wilderness for days. He was at some point surrounded in a old building by thousands of poisonous worm/snake creatures that he managed to survive until rescued by the leaders.
After what feels like an embarrassing hour of scribbling I can't seem to find a direct solution to the following problem $Show \space that: a^2 + b^2 + c^2 \geq ab+bc+ca \space \space \forall [a,b,c] \in Z^{+}_0 $ I've tried placing each integer in an arbitrary order like so: $a\leq b \therefore ab \leq b^2$ $b \leq c \therefore bc \leq c^2 \implies$ $a \leq c \therefore$ $ac \leq c^2$ Naturally I tried to add up the inequalities but this clearly yielded no results, but by nature of the third inequality I run into issues; what have I missed? EDIT I've constructed newer perhaps more insightful inequalities from one of the Dr's answer below: $a-b \leq ab \leq b^2$ $b-c \leq bc \leq c^2$ $a-c \leq ac \leq c^2$ EDIT 2 While I've seen this flagged as a possible duplicate, this question appears towards the beginning of an intro book to mathematical proofs without any prior knowledge given, I feel aso though this should be provable using pure inequalities from first principals
How can the following inequation be proven? $$a^2 + b^2 + c^2 \ge ab + bc + ca$$
Is anybody able to tell me what this supernova looking icon in between the bluetooth and wifi icon is?
I just bought an galaxy s7 edge, and this weird icon is on my notifcation bar. I cannot seem to figure it out. Does anyone know what it does or means? Thanks.
Does anyone know if the following itinerary is valid for a visa-free stopover in Guangzhou? Brisbane, Australia -> Singapore -> Guangzhou -> Brisbane? If I buy the tickets multi-city will this work? Will it not work if I book it all on Singapore Airlines since technically I'm going through Singapore in order to arrive back home?
Assuming one wants to travel through China, what are the rules for visa-free access? To be more specific: How does the 24-hour visa free transit work? How does the 72-hour version work? What does a person ineligible for either of these programs have to do to transit China? Do the programs apply to flights only or do they also work for transit on land? Would a visitor save much hassle by using visa free transit instead of just getting a visa? NB: this is intended as a canonical question on transiting China
I am getting error with this code: \documentclass[12pt]{article} \usepackage{ucs} \usepackage[utf8x]{inputenc} \usepackage[ukrainian]{babel} \usepackage{fontenc} \usepackage{inputenc} \usepackage{calc} \usepackage{pstcol} \usepackage{pstricks,pst-plot} \usepackage{pst-text} \usepackage{pst-char} \psset{xunit=0.7cm,yunit=5cm} \begin{document} \begin{pspicture}(-7.5,-0.4)(7.5,1.2) \psaxes[Ox=0,Oy=0,Dx=1,Dy=0.2,linecolor=black]{->}(0,0)(-7,-0.3)(7,1.1) \end{pspicture} \end{document} Code error: ! Undefined control sequence. <recently read> \c@lor@to@ps l.17 \end {pspicture} Help me please. Whats wrong? P.S. Sorry for my bad english
I have a problem with this file tex: \begin{document} \begin{figure} \begin{center} \begin{pspicture}(0,0)(1,3.8) \psline{-<}(0,0)(0,.2) \psline{-}(0,.2)(0,.4) \psline{*->}(0,.4)(0,.9) \psline{-*}(0,.9)(0,1.4) \psline{-<}(0,1.4)(0,2.4) \psline{-}(0,2.4)(0,3.4) \psline{*-}(0,3.4)(0,3.6) \psline{>-}(0,3.6)(0,3.8) \rput(1,.4){$y=0$}%testo \rput(1,1.4){$y=1$} \rput(1,3.4){$y=3$} \end{pspicture} \end{center} \caption{} \end{figure} \end{document} but I don't understand where is the error.
I know I can do this: a = ['1', '2'] b = [] a.forEach(function(e) { b.push(parseInt(e)); }) b >> [1, 2] I want to learn what is wrong in this? ['1', '2'].map(parseInt) >> [1, NaN]
From the : [1,4,9].map(Math.sqrt) will yield: [1,2,3] Why then does this: ['1','2','3'].map(parseInt) yield this: [1, NaN, NaN] I have tested in Firefox 3.0.1 and Chrome 0.3 and just as a disclaimer, I know this is not cross-browser functionality (no IE). I found out that the following will accomplish the desired effect. However, it still doesn’t explain the errant behavior of parseInt. ['1','2','3'].map(function(i){return +i;}) // returns [1,2,3]
Probably my Title is not so informative. My problem is that I try to "draw" hyperedges on some vertices with the following code: \usepackage{tikz} \tikzstyle{vertex} = [fill, shape=circle, opacity=1, node distance=80pt] \tikzstyle{hyperedge} = [fill, opacity=1, cap=round, join=round, line width=60pt] \tikzstyle{elabel} = [fill, shape=circle, node distance=30pt] \pgfdeclarelayer{background} \pgfsetlayers{background,main} \begin{document} \begin{tikzpicture} \node[vertex,label=above left:$v_1$] (v1) {}; \node[vertex,right of=v1,label=above right:$v_2$] (v2) {}; \node[vertex,below of=v1,label=below left:$v_3$] (v3) {}; \node[vertex,right of=v3,label=below right:$v_4$] (v4) {}; \begin{pgfonlayer}{background} \draw[hyperedge, color=yellow] (v1.center)--(v2.center)--(v3.center)--cycle; \draw[hyperedge, color=pink, line width=45pt] (v2.center)--(v3.center)--(v4.center)--cycle; \end{pgfonlayer} \node[elabel,color=yellow,label=right:$C_1$] (e1) at (-3,0) {}; \node[elabel,below of=e1,color=pink,label=right:$C_2$] (e2) {}; \end{tikzpicture} \end{document} This produces the following: It is not bad, but the intersection is not so visible. If I set opacity of the hyperedges to 0.5: \tikzstyle{hyperedge} = [fill, opacity=0.5, cap=round, join=round, line width=60pt] I get: The intersection is more visible here, but since the "fill" and the "lines" of the cycles also intersect, the affected parts become more opaque(?). Is there a workaround for this situation? Maybe to draw the lines only on one side of the cycle avoiding intersection with the fill, but is it possible?
I have a few circles in a drawing, and want to highlight some of them. \begin{tikzpicture} \coordinate (A1) at (0,0); \coordinate (A2) at (1,0); \coordinate (A3) at (1,1); \coordinate (B) at (1,0); \draw (A1) -- (A2); \draw (A1) -- (A3); \draw (B) -- (A3); \foreach \point in {A1,A2,A3,B} { \fill [black,draw=white](\point) circle (3pt); } \pgfsetstrokeopacity{.3} \pgfsetfillopacity{.3} \fill [red,draw,rounded corners,line width=9pt] (A1) -- (A2) -- (A3) -- cycle; \pgfsetstrokeopacity{1} \pgfsetfillopacity{1} \end{tikzpicture} I would like the whole area surrounding the A points to be of the same color, but the strokeopaticy and the fillopacity interfere. Is there some ay I can prevent this? Note: in my actuall use scenario, there are too many coordinates for manual adjusting to be an option (otherwise I would just do with a fill with rounded corners, with points calculated manually).
I'm aware that the following works: test.h #pragma once #include <string> class testclass { private: std::string _data; public: template<class T> testclass(const T&); }; test.cpp #include "test.h" template testclass::testclass(const int&); template testclass::testclass(const long&); //function can be called only with `int` and `long` template<class T> testclass::testclass(const T &num) : _data(std::to_string(num)) {} So this is a successful way of splitting the declaration and implementation of a template function, but it has some downsides. One of them is having to hardcode all the types with which you want your function to be called and that's a drag. And if the function is quite small, you end up having written more code than you would have if you hadn't templated it... I was wondering if something like this is possible: test.cpp #include "test.h" template<class T2> //bogus syntax, but here the point of interest template testclass::testclass(const T2&); template<class T> testclass::testclass(const T &num) : _data(std::to_string(num)) {}
Quote from : The only portable way of using templates at the moment is to implement them in header files by using inline functions. Why is this? (Clarification: header files are not the only portable solution. But they are the most convenient portable solution.)
The situation is: I don‘t want to able to surf certain websites out of distraction of boredom, while I am in the University, studying. My idea is: Create a sudo-password which is to complex to memorize it, write in somewhere and leave it at home when I go to the University. Create a user-account with restrictions, on the websites, which can be visited. Study without distraction.
I bought my kids a PC and installed 12.04 (Unity) on it. The bottom line is, I want my children to use the computer unsupervised while I have confidence they cannot access anything inappropriate. What I have looked at: I was looking at Scrubit a tool which allows me configure my wifi router to block content and this solution would also protect my other PC and mobile devices. This may be overkill as I just want the solution to work on one PC. I also did some Google searches and came across the application called . My experience of OSS is that the best solutions frequently never appear first on a Google search list and in this case I need to trust the methods therefore my question is very specific. I want to leverage your knowledge and experience to understand What is the best way to restrict adult content on 12.04 LTS as this is important to me. It maybe a combination of things so please don't answer this question "try this or that", then give me some PPA unless you can share your experience of how good it is and of course if there are any constraints.
I'm making a calculator in python 3 and I'm wondering if there is an option that can tell if the input the user gave is not a float. For example if the user wrote a word instead of a float the code will recognize it and print out something like: if num1 != float: print("You Need To Enter A Number")
What is the best possible way to check if a string can be represented as a number in Python? The function I currently have right now is: def is_number(s): try: float(s) return True except ValueError: return False Which, not only is ugly and slow, seems clunky. However I haven't found a better method because calling float in the main function is even worse.
How can I use object inside if statement I tried 2 ways one like this: import java.util.Scanner; public class Species{ String kind; public void talk() { System.out.println(kind + " is talking");} public void walk() { System.out.println(kind + " is walking");} public void swim() { System.out.println(kind + " is swimming");} public void check() { if (kind == "woman") {talk(); walk();} else if (kind == "fish") {swim();} else System.out.println("Sorry not one of our option."); } public static void main(String [] args) { Scanner read = new Scanner (System.in); Species sp1 = new Species(); sp1.kind = null ; System.out.print("Enter a kind: "); sp1.kind = read.nextLine(); sp1.check(); }} And another one: import java.util.Scanner; public class Species{ String kind; public void talk() { System.out.println(kind + " is talking");} public void walk() { System.out.println(kind + " is walking");} public void swim() { System.out.println(kind + " is swimming");} public static void main(String [] args) { Scanner read = new Scanner (System.in); Species sp1 = new Species(); sp1.kind = null ; System.out.print("Enter a kind: "); sp1.kind = read.nextLine(); if (sp1.kind == "woman") {sp1.talk(); sp1.walk();} else if (sp1.kind == "fish") {sp1.swim();} else System.out.println("Sorry not one of our option."); }} Each time it shows the message Sorry not one of our option I know it's a simple program but it wouldn't work
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 have a problem to figure out, how to toggle buttons in aura/lightning component. I have two buttons with functions showMore and showLess. The thing is, i want to only see button show more, and when i click on it, i want to show more button disappear and show less appear. And same with when i click on show less, switch show more on and less off <span class="show-more-button"> <lightning:buttonIcon iconName="utility:macros" alternativeText="Show more columns" onclick="{!c.showMore}" aura:id="show_more"/> </span> <span class="show-less-button"> <lightning:buttonIcon iconName="utility:macros" alternativeText="Show less columns" onclick="{!c.showLess}" aura:id="show_less"/> </span>
How to show or hide particular block in the onclick events in the lightning component
Question: Find the value of the limit of the following expression such that $x$ approaches to zero $$\frac{\cos(\sin x)-\cos x}{x^4}.$$ My attempt:
To find limit of $\lim_{x\to 0}\frac {\cos(\sin x) - \cos x}{x^4} $. I differentiated it using L Hospital's rule. I got $$\frac{-\sin(\sin x)\cos x + \sin x}{4x^3}\text{.}$$ I divided and multiplied by $\sin x$. Since $\lim_{x\to 0}\frac{\sin x}{x} = 1$, thus I got $\frac{1-\cos x}{4x^2}$.On applying standard limits, I get answer $\frac18$. But correct answer is $\frac16$. Please help.
I was wondering how to write the possessive form of a proper noun that is already in a possessive form (confusing, I know...) My company's name is Tuc's Contracting. If I were to write the possessive form of that, it would be Tuc's Contracting's. My question is if I were to leave off the "Contracting's" part, how would I write the possessive form of Tuc's (which is a proper noun already in a possessive form...HELP!) The proper noun is not “Tuc” it is “Tuc’s” so that is where I am confused… Tuc's? Tucs'? Tuc's'? The proper noun is not “Tuc” it is “Tuc’s” so that is where I am confused… None of these seem right to me...And that is why I am seeking your expertise! Thank you :)
If the cricket ground Lord's is a possessive, what if you want to describe something belonging to Lord's? Would you say: I was very impressed by Lord's's customer services. It doesn't look right, so what is the correct way of writing it?
finished a test for an animatic but I don't know how to export it as a .mp4 instead of a .blend, I saw that you have to go in "ouput" but I can't find it can someone help me pls
Yesterday I was working on a simple animation, an animated logo. Here is an image of the progress: I already have the animation working and everything is okay with the project, but I can't figure out how I can render the animation and turn it into an AVI format video. How do I render an animation in Blender?
I am starting to learn java and going through the following issue While trying to update values(Hashset) of ConcurrentHashMap when iterating over it - ConcurrentModificationError is shown while debugging - although the code didn't crash This is the scenario: concurrentMap = Key -> A Value -> ["a","b","c","d"] Key -> B value -> ["a", "j", "k", "l", "m"] when i try to remove "a" while iterating over A it fails to update the hashset properly and fails to loop I saw the hashset update as follows [a, b, c, d] [b,c] How can I remove 'a' from key A while i am iterating over A and update the hashSet properly ? private ConcurrentMap<String, HashSet<String>> concurrentMap = new ConcurrentHashMap<>(); private void parseItems(Item testItem) throws Exception { Map<String, HashSet<String>> itemMap = ConcurrentHashMap <>(Myclass.getIdMap(testItem)); concurrentMap = new ConcurrentHashMap<>(itemMap); for (String type : concurrentMap.keySet()) { for (String id : concurrentMap.get(type)) { if (type.equals("MyType")) { myList = function1(MyType, id); } else { myList = function2(defaultType, id, "ID"); } removeParsedIdFromCurrentMap(type, id); for (Item item : myList) { ConcurrentMap<String, HashSet<String>> newItemConcurrentMap = new ConcurrentHashMap<>(Myclass.getIdMap(item)); addToConcurentMap(newItemConcurrentMap); } } } } private void removeParsedIdFromCurrentMap(String type, String id) { HashSet<String> currentIdSet = concurrentMap.get(type); //This removes the value 'a' if (currentIdSet != null) { Iterator<String> iter = currentIdSet.iterator(); while (iter.hasNext()) { String toRemoveId = iter.next(); if (toRemoveId.contains(id)) { iter.remove(); } } //How can I update the values of key A while iterating A? updateConcurrentMap(); } } private void addToConcurentMap(ConcurrentMap<IOMType, HashSet<String>> newItemConcurrentMap ) { for (String type : newItemConcurrentMap .keySet()) { for (String id : newItemConcurrentMap .get(type)) { if (!checkIdParsed(type, id)) { concurrentMap.putIfAbsent(type, new HashSet<>()); concurrentMap.get(type).add(id); } } } }
We all know you can't do the following because of ConcurrentModificationException: for (Object i : l) { if (condition(i)) { l.remove(i); } } But this apparently works sometimes, but not always. Here's some specific code: public static void main(String[] args) { Collection<Integer> l = new ArrayList<>(); for (int i = 0; i < 10; ++i) { l.add(4); l.add(5); l.add(6); } for (int i : l) { if (i == 5) { l.remove(i); } } System.out.println(l); } This, of course, results in: Exception in thread "main" java.util.ConcurrentModificationException Even though multiple threads aren't doing it. Anyway. What's the best solution to this problem? How can I remove an item from the collection in a loop without throwing this exception? I'm also using an arbitrary Collection here, not necessarily an ArrayList, so you can't rely on get.
I am a beginner at Python, can someone explain me what is the usage of __name__ == '__main__' in Python?
Given the following code, what does the if __name__ == "__main__": do? # Threading example import time, thread def myfunction(string, sleeptime, lock, *args): while True: lock.acquire() time.sleep(sleeptime) lock.release() time.sleep(sleeptime) if __name__ == "__main__": lock = thread.allocate_lock() thread.start_new_thread(myfunction, ("Thread #: 1", 2, lock)) thread.start_new_thread(myfunction, ("Thread #: 2", 2, lock))
Is there a way to fly on a cargo plane as a passenger? Any airlines offer such an experience? I know there are some seats at the front of cargo planes, perhaps these can be used?
Some time ago I heard someone telling about travelling in cargo planes. Apparently some of those planes have a limited amount of extra seats and companies would sell them for an extra profit. Does anyone have any information about this? Is that still possible?
I am using Oracle 12c Standard Edition. I accidentally drop the table and try to recover it, but the table does not appear in Recyclebin. I think the tablespace is due to SYSTEM. Create table test( aaa varchar2(20) .... ) TABLESPACE SYSTEM STORAGE ( NEXT 1024K ) / thank!
I tried dropping a table and then when i viewed the recycle bin nothing was there in it . Earlier too i dropped tables many a times but I was surprised to find no objects whatsover in it . What's the deal ? [update]: i had tried SHOW PARAMETER RECYCLEBIN; Its VALUE column shows it as ON . So fine here ! Then i droppped an existing table but still the command Select object_name from recyclebin; and any such retrieval of columns is showing NO ROWS SELECTED !! Also using flashback command confirms that recyclebin is not having any such dropped tables !! So where are dropped tables going ? And one more thing : This time i tried using ALTER SYSTEM SET RECYCLEBIN=ON; Instead of Alter session and sqlplus throws an error : Specified initialization parameter is not modifiable with this option So, is this because that i am working as a SYSTEM ?? i have not created any other USER as of now .
My biceps muscles are attached to my arms bone/bones through a tendon/tendons, if my biceps pulls my arms bone/bones with a force of 100N upwards then my arms bone/bones pushes back downwards with a force of -100N,therefore fnet should be 0 and there should be no movement, however in reality our arm moves upwards, why?
Given Newton's third law, why is there motion at all? Should not all forces even themselves out, so nothing moves at all? When I push a table using my finger, the table applies the same force onto my finger like my finger does on the table just with an opposing direction, nothing happens except that I feel the opposing force. But why can I push a box on a table by applying force ($F=ma$) on one side, obviously outbalancing the force the box has on my finger and at the same time outbalancing the friction the box has on the table? I obviously have the greater mass and acceleration as for example the matchbox on the table and thusly I can move it, but shouldn't the third law prevent that from even happening? Shouldn't the matchbox just accommodate to said force and applying the same force to me in opposing direction?
I am currently developing a game that involves a multitude of weapons, armors, etc. I am using UE4 currently as an engine because I found that easy to use. Currently in development I have found myself unable to figure out how to make it so my character has the ability to equip different items. Does anyone know of any way that I can get this to work?
I'm want to create avatar animations (sprites) for a browser-based MMORPG. The player is able to customize the character, and the content changes often (new weapons, armors, and so on). How can I structurally manage the creation and updating of all the sprite sheets? The amount of different combinations are big enough that simply generating all permutations won't work. This can be server- or client-based, but if it works entirely on the client, please keep it to just HTML5/CSS/Canvas/WebGL.
I have a list of dictionaries each of them describing a file (file format, filename, filesize, ... and a full path to the file [always unique]). The goal is to exclude all but one dictionaries describing copies of the same file (I just want a single dict (entry) per file, no matter how many copies there are. In other words: if 2 (or more) dicts differ only in a single key (i.e. path) - leave only one of them). For example, here is the source list: src_list = [{'filename': 'abc', 'filetype': '.txt', ... 'path': 'C:/'}, {'filename': 'abc', 'filetype': '.txt', ... 'path': 'C:/mydir'}, {'filename': 'def', 'filetype': '.zip', ... 'path': 'C:/'}, {'filename': 'def', 'filetype': '.zip', ... 'path': 'C:/mydir2'}] The result should look like this: dst_list = [{'filename': 'abc', 'filetype': '.txt', ... 'path': 'C:/'}, {'filename': 'def', 'filetype': '.zip', ... 'path': 'C:/mydir2'}]
Is there a built-in that removes duplicates from list in Python, whilst preserving order? I know that I can use a set to remove duplicates, but that destroys the original order. I also know that I can roll my own like this: def uniq(input): output = [] for x in input: if x not in output: output.append(x) return output (Thanks to for that .) But I'd like to avail myself of a built-in or a more Pythonic idiom if possible. Related question:
It basically says it all in the title. I tried solving the inequality using the bernoulli inequality somehow $$\dfrac{\displaystyle\sum_{k=0}^n\frac{1}{k!}}{(1+\frac{1}{n})^n}\geq 1,$$ but the factorial gets me everytime. Also I've tried induction without success: $\displaystyle\sum_{k=0}^{n+1}\frac{1}{k!}\stackrel{IV}\geq \left(1+\frac{1}{n}\right)^n+\frac{1}{(n+1)!}$
Prove that $$\left(1+\frac{1}{n}\right)^n<\frac{1}{0!}+\frac{1}{1!}+\frac{1}{2!}+...+\frac{1}{n!}$$ for $n>1 , n \in \mathbb{N}$.
Prove that for any integers $a, b, c, d$ number $(a^2 + b^2)(c^2 + d^2)$ is a sum of two squares of integer. In fact I have no idea how to do this and I'll appreciate any tips or the solution.
Prove that if n is the product of two numbers that can be written as the sum of two squares then n can be written as the sum of two squares.
In my Schengen VISA application, I have mentioned Germany as "member state of first entry" and provided the itinerary of a Lufthansa flight which goes from Delhi to Berlin via Frankfurt, but due to the cost factor, I want to book Finnair now which transits through Helsinki. My understanding is that since I am entering the Schengen area in Helsinki I will have to go through immigration there. Will it create a problem because I have mentioned Germany as "member state of first entry" or will it be fine? Can the immigration officer look at my VISA application?
In case, if I get a multiple-entry Schengen visa in one of the embassies in Ukraine, Kyiv - should my first trip be to the country which issued the visa? Any there any requirements of this sort? Does this condition vary depending on embassy which issued the visa? What are the possible consequences on not visiting that country first? Does it somehow depend on country where the embassy is (i.e. non-Schengen and not EU members)?
I have a string like this, as you can see it consists of property/value pairs separated by space. For example: GRID "GLOBAL" or COORD 0 GRID "GLOBAL" LABEL "A" DIR "X" COORD 0 GRIDTYPE " " The TEXT values are inside quotation marks but the NUMERICAL ones are not. What is the best and fastest method to split it into an array of strings like this: [GRID ,"GLOBAL", LABEL, "A", DIR, "X", COORD, 0, GRIDTYPE, " "] The below solution does not work, because there is also space between " " in the value after GRIDTYPE. var tokens = str.Split(new char[] { ' ' }, StringSplitOptions.RemoveEmptyEntries);
I would like to use the .Net Regex.Split method to split this input string into an array. It must split on whitespace unless it is enclosed in a quote. Input: Here is "my string"    it has "six  matches" Expected output: Here is my string it has six  matches What pattern do I need? Also do I need to specify any RegexOptions?
\begin{equation*} \begin{split} \mathbb{E}[X_t] & =\mathbb{E}[\alpha \circ X_{t-1} + \epsilon_t] \\ &=\mathbb{E}[\sum_{j=1}^{X_{t-1}}{Y_j + \epsilon_t}] \\ &=\sum_{n=0}^{\infty}{\mathbb{E}[\sum_{j=1}^{X_{t-1}}Y_j|X_{t-1}=n] \mathbb{P}[X_{t-1}=n]} +\mu_{\epsilon}\\ &= \sum_{n=0}^{\infty}{{\sum_{j=1}^{n}{\mathbb{E}[Y_j] \mathbb{P}[X_{t-1}=n]}}} +\mu_{\epsilon} \end{split} \end{equation*} \\ We can use recursion to express it in terms of $X_0$: \begin{equation*} \begin{split} \mathbb{E}[X_t] & =\mathbb{E}[X_{t-1}] + \mu_{\epsilon} \\ &= \alpha [\alpha \mathbb{E}[X_{t-2}+ \mu_{\epsilon}]+ \mu_{\epsilon}\\ &=\alpha^2 \mathbb{E}[X_{t-2}]+ \alpha \mu_{\epsilon}+\mu_{\epsilon} \\ &=....\\ &=\alpha^t\mathbb{E}[X_0]+\alpha^{t-1}\mu_{\epsilon}+...+\alpha\mu_{\epsilon}+\mu_{\epsilon}\\ &=\alpha^t\mathbb{E}[X_0]+\mu_{\epsilon}\sum_{j=0}^{\infty}{\alpha^j} \end{split} \end{equation*} \begin{equation*} \begin{split} Var[X_t] & = Var[\alpha \circ X_{t-1}+\epsilon_t] \\ & = Var[\sum_{j=1}^{X_{t-1}}Y_j]+Var[\epsilon_t] \\ & =\mathbb{E}[{[\sum_{j=1}^{X_{t-1}}Y_j}]^2]-{\mathbb{E}\big[\sum_{j=1}^{X_{t-1}}Y_j]}\big]^2+ \sigma_{\epsilon}^2 \\ & =\mathbb{E}[{[\sum_{j=1}^{X_{t-1}}Y_j}]^2]-\alpha^2\mathbb{E}[X_{t-1}]^2+\sigma_{\epsilon}^2 \end{split} \end{equation*} \\ \begin{equation*} \begin{split} \mathbb{E}[{[\sum_{j=1}^{X_{t-1}}Y_j}]^2] & =\mathbb{E}[\sum_{j=1}^{X_{t-1}}{Y_j}^2 + \sum_{i\neq j}^{X_{t-1}}Y_iY_j]\\ & =\mathbb{E}[\sum_{j=1}^{X_{t-1}}{Y_j}^2]+\mathbb{E}[\sum_{i\neq j}^{X_{t-1}}Y_iY_j] \end{split} \end{equation*}
\documentclass{article} \usepackage{mathtools,amssymb} \begin{document} \begin{gather} \begin{split} (1-\underset{(0.034)}{0.060}{\textit{B}}^{12}-\underset{(0.032)}{0.123}{\textit{B}}^{2(12)}){y}_t &=(1-\underset{(0.016)}{0.878}\textit{B}^{12})(1-\underset{(0.012)}{0.969}\textit{B}){e}_t\\ \end{split} \notag\\ Box-Ljung \quad test \quad for\quad residuals\quad {\chi}^2= 15.151 \quad df= 12 \quad p-value = 0.233 \notag\\ \CENTERLINE {(Standard\quad errors\quad in\quad parentheses)}\notag \end{gather} \end{document}
I have been issued Germany National Type D visa but it is never used (no port of entry). Can I travel to other Schengen areas without going to Germany at all on that Visa?
I have requested for a French long term (Type D) student visa from a consulate in India. It's a national Type D visa and not a Schengen visa. My question is that can we still go to other Schengen countries on this visa? If not then can we get a Schengen visa from a consulate in France?
I need to calculate $$\lim_{n\rightarrow \infty} \left(\frac{n!}{n^n}\right)^{\frac{1}{n}}$$ My try: When $n!$ is large we have $n!\approx(\frac{n}{e})^n\sqrt {2\pi n}$ (Stirling approximation) $$\lim_{n\rightarrow \infty} \left(\frac{n!}{n^n}\right)^{\frac{1}{n}}=\lim_{n\rightarrow \infty}\frac{\left((\frac{n}{e})^n\sqrt {2\pi n}\right)^{\frac{1}{n}}}{n}$$ Simplifying we get, $$\frac{1}{e}\lim_{n\rightarrow \infty} \left(\sqrt{2\pi n}\right)^{\frac{1}{n}}$$ I am stuck here. I don't know how to proceed further.
I'm trying to find $$\lim_{n\to\infty}\frac{n}{\sqrt[n]{n!}} .$$ I tried couple of methods: Stolz, Squeeze, D'Alambert Thanks! Edit: I can't use Stirling.
I have posted a question about advices on design and architecture and review on a framework I'm creating: Basically: I'm in the right direction and have I done some mistakes in the architecture. This required a bit of reading of the documentation and code can't be posted as such. All my questions were closed or voted down, telling me to go somewhere else. Very nice people gave me a : none of them seem to fit the topic (although other similar question get answered on Stack Overflow, software engineering stack... which is very frustrating). Simple question: Where do I post this kind of question now?
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 want to understand what exactly is curse of dimensionality and how does it effect the model performance. Does the the concept apply to all the models?. Is it equally bad for distance based models like KNN and tree based models like random forest? Curse of Dimensionality: "Consider applying a KNN classifier to data where the inputs are uniformly distributed in the D-dimensional unit cube. Suppose we estimate the density of class labels around a test point x by growing” a hyper-cube around x until it contains a desired fraction f of the data points. The expected edge length of this cube will be eD(f) = f1/D. If D = 10, and we want to base our estimate on 10% of the data, we have e10(0.1) = 0.8, so we need to extend the cube 80% along each dimension around x. Even if we only use 1% of the data, we find e10(0.01) = 0.63. Since the entire range of the data is only 1 along each dimension, we see that the method is no longer very local, despite the name “nearest neighbor”. The trouble with looking at neighbors that are so far away is that they may not be good predictors about the behavior of the input-output function at a given point." This is the explanation of curse of dimensionality in the Machine learning book by Kevin P. Murphy. However, I only partially understand the concept. Can someone explain it in detail? Thanks in advance!
I read that 'Euclidean distance is not a good distance in high dimensions'. I guess this statement has something to do with the curse of dimensionality, but what exactly? Besides, what is 'high dimensions'? I have been applying hierarchical clustering using Euclidean distance with 100 features. Up to how many features is it 'safe' to use this metric?
I am pretty sure I saw this already on travel SE, but can't find it now. What are my navigation options with Android phone in an area without data connection? (I am in Northumberland) EDIT: To clarify, I am looking for a turn-by-turn navigation system (mainly for driving). The suggested question is mainly about actual maps without this feature.
I don't need a recommendation or a list but my knowledge of GPS and "navi"s and the differences between them is an utter mystery to me. But often I'm lost in backstreets in random countries where access to something like a live Google Maps would be awesome. I absolutely cannot afford a smartphone with worldwide roaming though. Can GPS's do what I want or am I barking up the wrong tree? If they can is it only high end ones than can?
I just need a clarification. If I am to talk about the physiological function of the CFTR gene product? Then what should I do research and talk about? The only physiological function that I can think of is the control of the thickness of mucus. Is there any other ones? On top of that, if i am to search for research paper for this topic. Do I just search for comparative study that compare the gene product in normal individuals and CF individuals in terms of mucus thickness? Thanks
I am a senior in high school and I am studying cystic fibrosis. I don't quite get the function of the CFTR gene as this is my first time dealing with this type of heavy scientific info. I had searched up its function on a website like this: By reading the gene functions section, I learned that CFTR regulate the formation of a chloride channel, changes the regulation of other transport pathways (i.e increase sodium ion absorption in sodium ion absortion). At the same time it also regulate the chloride-coupled bicarbonate receptor. And that is about all I got from that section. I would greatly appreciate if someone can summarize all the functions of the CFTR gene listed in layman terms (i.e grandma language) and also explain to me why decreased chloride channel leads to thicken mucus or increase sodium ion absorption leads to CF Symptoms. In addition I would also appreciate it if someone can tell me does decreased CFTR gene function also lead to other diseases on top of Cystic fibrosis. Thanks
I noticed that the reputation shown for meta sites in the site list dropdown differs rather greatly from the main site reputation: For example, there's a gap of ~2k on AU and AU meta (~1.5%), ~600 on U&L (~1.7%), and so on - the gap decreasing with total rep. The differences are too large to be accounted for by recent changes in rep (~2k is my rep change on AU for this quarter so far), so simple caching is unlikely to be the cause. Oddly, in meta sites, the rep shown in the top bar is correct (the screenshot above is taken from AU Meta), as is the rep in the user profile page, or that shown in posts by the user. This screenshot was taken on Safari on macOS High Sierra, but the same thing was seen on Chrome on iOS and on Android.
While using the top bar to navigate across communities, I noticed that the reputation displayed on meta sites on that list does not match the one of their corresponding main sites: I have noticed on past situations that reputation gained takes a bit to "update" on the display on Meta sites (that is, if you gain rep on SO, for example, it will take some time for you to see your updated rep on MSO). However, I have never noticed this behavior here, on the Sites List of the top bar. Furthermore, the "delay" here seems to be more severe, as the "outdated" rep showed is of several days ago (for example, I turned 3k on SO almost exactly a week ago, but the rep shown on MSO is still <3k). Any idea what could be causing this behavior? Update: 2 months later this persists: my main site rep updates correctly but their corresponding meta rep remains the same as in the image above. Update: As per Catija's I removed the site (MSO) and put it back in, but it didn't update the rep. However, after removing one site (TWP Meta), waiting at least a day, and then adding it back I see that although the reputations still don't match, the number displayed did changed a bit (previously 29,924 but now 33,112):
According to : Note that the holes injected into Emitter are supplied from Base electrode (Base current), whereas the electrons injected into the Base are supplied from Emitter electrode (Emitter current). The ratio between these currents is what makes BJT a current amplifying device - small current at Base terminal can cause a much higher current at Emitter terminal. The conventional current amplification is defined as Collector-to-Base currents ratio, but it is the ratio between the above currents which makes any current amplification possible. First off, Why collector current increases as base current increase? Is the former causes the later, or the later causes the former, or something else (voltage on electrodes, maybe) causes both? And here is my question, Why collector current always increases more than the increment of base current? Say after something changes, a extra holes are "injected into" emitter region, and b extra electrons are injected into base region. Then why b is greater to a?
In fact, this question has been asked on the , but it's not well-answered. I suppose it might be more on-topic here. According to : Note that the holes injected into Emitter are supplied from Base electrode (Base current), whereas the electrons injected into the Base are supplied from Emitter electrode (Emitter current). The ratio between these currents is what makes BJT a current amplifying device - small current at Base terminal can cause a much higher current at Emitter terminal. The conventional current amplification is defined as Collector-to-Base currents ratio, but it is the ratio between the above currents which makes any current amplification possible. First off, Why collector current increases as base current increase? Is the former causes the later, or the later causes the former, or something else (voltage on electrodes, maybe) causes both? And here is my question, Why collector current always increases more than the increment of base current? Say after something changes, a extra holes are "injected into" emitter region, and b extra electrons are injected into base region. Then why b is greater to a?
After Lyanna Mormont gave her speech and everyone started hooting-and-hollering, I'm not sure if anybody from the Vale (House Arryn) was voicing their agreement that Jon was the new King of the North. Of course, the intentions of Lord Baelish are always unknown, but officially, is House Arryn: declared as recognizing Jon as the new King of the North and ready to leave the easily defendable Vale and follow him into major combat? declared as sympathetic to House Stark, but neutral? Going to war with any major army and risking major casualties will take convincing? after Battle of the Bastards (BoB), the only remaining forces in the North are in the Vale? How many lesser Houses sat-out the BoB? It'd seem Jon has no army to command... At end of season 6, does House Arryn 100% follow the King of the North? Or are they sympathetic but neutral?
Based on , my understanding is that there are 9 regions of Westeros subject to the rule of the Iron Throne, from Dorne joining up to Cersei killing Robert. With whom does [insert region] align in what appears to be Daenerys vs Cersei? Kingdom of the North -- Daenerys probably but currently busy with White Walkers Kingdom of the Mountain and the Vale -- Daenerys probably but currently busy with White Walkers (supposedly; depends on what Littlefinger has in mind) Kingdom of the Isles and Rivers (Iron Islands) -- Daenerys Kingdom of the Isles and Rivers (Riverlands) -- Cersei because the Freys are with the Lannisters? Kingdom of the Rock -- Cersei because she is a Lannister Kingdom of the Stormlands -- Cersei? Kingdom of the Reach -- Daenerys after invitation of Varys and Ellaria Principality of Dorne -- Daenerys after invitation of Varys presumably Crownlands -- Cersei since Cersei is currently occupying the Iron Throne Am I understanding this right? Anything wrong?
Prove that the positive integers $n$ that cannot be written as a sum of $r$ consecutive positive integers, with $r > 1$, are of the form n = $2^l$ for some $l ≥ 0$. I wrote just k+(k+1)+.....(k+r-1) as $2^l$ and then by applying AP formula, it gets me to something like $r/2 ( 2k + (r-1))$ = $2^l$ which leads to nowhere.. .I did to get a contradiction. I have shown my approach and this is not a homework problem.I need some help to move from here or a new way to solve the problem in a less cumbersome manner. Thank you.
I have been wondering about this question for a while (I am almost sure that I read it in some contest mathematics book a while ago) Determine which positive integers cannot be written as a sum of consecutive positive integers. All numbers will be considered positive integers in the following unless stated otherwise. I was thinking as follows: odd numbers will always work since if we take an odd $m$, we have $$ m=2\cdot k+1=k+(k+1). $$ Then I realised that all numbers having at least one odd prime factor will also work. Take $n$ as a number having an odd prime factor and let this odd prime factor be $m$ and let $n=m\cdot k$. Then $$ n=\underbrace{k+k+\ldots+k}_{m \ \text{times}} $$ and since $m$ is odd, say $m=2\cdot l+1$ we have $$ n=\underbrace{k+k+\ldots+k}_{l \ \text{times}}+k+\underbrace{k+k+\ldots+k}_{l \ \text{times}} $$ and we can start moving $1$s one by one from the left side of the middle "$k$" to the right side of it $$ n=\underbrace{k+k+\ldots+(k-1)}_{l \ \text{times}}+k+\underbrace{(k+1)+k+\ldots+k}_{l \ \text{times}} $$ $$ n=\underbrace{k+k+\ldots(k-2)+(k-1)}_{l \ \text{times}}+k+\underbrace{(k+1)+(k+2)+\ldots+k}_{l \ \text{times}} $$ this way we end up in a sum of consecutive integers. It may happen that some integers on the left will be negative which is undesired but since these numbers are consecutive integers we always be able to cancel out the negative ones without disturbing the structure of the uncancelled ones. To see this in action let us take $22=11\cdot 2$. This would give $$ 2+2+2+2+2+2+2+2+2+2+2 $$ so $$ 2+2+2+2+1+2+3+2+2+2+2 $$ the next step gives $$ 2+2+2+0+1+2+3+4+2+2+2 $$ it seems that now we are out of numbers but we just continue moving an increasing number of $1$s to the right $$ 2+2+(-1)+0+1+2+3+4+5+2+2 $$ $$ 2+(-2)+(-1)+0+1+2+3+4+5+6+2 $$ finally $$ \underbrace{(-3)+(-2)+(-1)+0+1+2+3}_{=0}+4+5+6+7 $$ so we get $$ 22=4+5+6+7. $$ Now we have a method to generate the desired expression for all odd numbers and all the ones having at least one odd prime factor. Which numbers are left? The ones having ONLY even primes in their prime factorisation. These are of the form $2^n$. I was thinking what do these have in common and I thought that they are separated by a factor of $2$. The first of these are $1$ for $n=0$ and $1$ cannot be expressed in the desired for so if I could show that $$ m \ \text{cannot be expressed}\Rightarrow 2m \ \text{cannot be expressed} $$ I am done. So I was trying to show the contrapositive $$ 2m \ \text{can be expressed}\Rightarrow m \ \text{can be expressed}. $$ So assume that $2m$ can be expressed. Now, eihter $m$ is odd in which case we are done since odds were easy to express or it is even, that is $m=2l$. From here the argument repeats. Eihter $l$ is odd in which case we are done or it is even, so $l=2k$ and so on. After a while we factored out all of the $2$'s and we end up with and odd number which we can express and we are done. So integers of the form $2^n$ cannot be expressed in this form. Is my reasoning correct? If not please point out where I made a mistake. If it turns out to be correct then we are all happy I can sleep well tonight but it would be nice to see a more rigorous proof of this so if someone can provide one I am more than happy to read it. Since this is a contest question I expect it to have a really elegant solution and I do not consider mine an elegant one.
This is a real beginner question (I'm still learning the Java basics). I can (sort of) understand why methods would return a List<String> rather than an ArrayList<String>, or why they would accept a List parameter rather than an ArrayList. If it makes no difference to the method (i.e., if no special methods from ArrayList are required), this would make the method more flexible, and easier to use for callers. The same thing goes for other collection types, like Set or Map. What I don't understand: it appears to be common practice to create local variables like this: List<String> list = new ArrayList<String>(); While this form is less frequent: ArrayList<String> list = new ArrayList<String>(); What's the advantage here? All I can see is a minor disadvantage: a separate "import" line for java.util.List has to be added. Technically, "import java.util.*" could be used, but I don't see that very often either, probably because the "import" lines are added automatically by some IDE.
I have seen this mentioned a few times and I am not clear on what it means. When and why would you do this? I know what interfaces do, but the fact I am not clear on this makes me think I am missing out on using them correctly. Is it just so if you were to do: IInterface classRef = new ObjectWhatever() You could use any class that implements IInterface? When would you need to do that? The only thing I can think of is if you have a method and you are unsure of what object will be passed except for it implementing IInterface. I cannot think how often you would need to do that. Also, how could you write a method that takes in an object that implements an interface? Is that possible?
I’m having trouble finding the answer to my exact question after extensive searching on here and other places. I am currently a Level 3 Wizard / Level 1 Fighter. I aim to focus on my wizard levels but I was thinking about taking Level 3 Fighter to gain access to the Eldritch Knight martial archetype. Basically what I want to know is will being an Eldritch Knight give me access to more spell slots outside of wizard spell slots alone? Also, will it enable me to learn more spells that I could not as a wizard only character. I hope this makes sense and thank you in advance for help. What I’m hoping to hear is something like wizard gives me 4 spell slots for level 1 and being Eldritch Knight gives me another 1/2 level 1 spell slots etc etc.
How do I determine how many spell slots I have if I multiclass into more than one spellcasting class? For example, I have a character that is a level 3 Wizard, a level 5 Eldritch Knight Fighter, a level 4 Arcane Trickster Rogue, a level 4 Paladin, and a 4 Warlock. How many spell slots do I have and how do I determine this?
I have a dataset that consists of only categorical variables and a target variable. I want to predict the (binary) target variable with the categorical variables. I am trying to do this in Python and sklearn. The categorical variables have many different values. I was thinking to create dummy variables for each value in all the categorical variables. However, in the end this results in a sparse data set with thousands of variables. How would you go about to reduce the number of dummy variables? Would you use Chi2 to select useful features? Or would you not make dummy variables at all?
What techniques are available for collapsing (or pooling) many categories to a few, for the purpose of using them as an input (predictor) in a statistical model? Consider a variable like (discipline chosen by an undergraduate student). It is unordered and categorical, but it can potentially have dozens of distinct levels. Let's say I want to use major as a predictor in a regression model. Using these levels as-is for modeling leads to all sorts of issues because there are just so many. A lot of statistical precision would be thrown away to use them, and the results are hard to interpret. We're rarely interested in specific majors -- we're much more likely to be interested in broad categories (subgroups) of majors. But it isn't always clear how to divide up the levels into such higher-level categories, or even how many higher-level categories to use. For typical data I would be happy to use factor analysis, matrix factorization, or a discrete latent modeling technique. But majors are mutually exclusive categories, so I'm hesitant to exploit their covariance for anything. Furthermore I don't care about the major categories on their own. I care about producing higher-level categories that are coherent with respect to my regression outcome. In the binary outcome case, that suggests to me something like linear discriminant analysis (LDA) to generate higher-level categories that maximize discriminative performance. But LDA is a limited technique and that feels like dirty data dredging to me. Moreover any continuous solution will be hard to interpret. Meanwhile something based on covariances, like multiple correspondence analysis (MCA), seems suspect to me in this case because of the inherent dependence among mutually exclusive dummy variables -- they're better suited for studying multiple categorical variables, rather than multiple categories of the same variable. edit: to be clear, this is about collapsing categories (not selecting them), and the categories are predictors or independent variables. In hindsight, this problem seems like an appropriate time to "regularize 'em all and let God sort 'em out". Glad to see this question is interesting to so many people!
My ltxtable is indentated on both sides and I don't want the indents. My MWE is: \documentclass{scrreprt} \usepackage[latin1]{inputenc} \usepackage[ngerman]{babel} \usepackage{ltxtable, filecontents} \begin{document} \begin{filecontents}{longtable.tex} \noindent \begin{longtable}{|X|m{20ex}|m{5ex}m{5ex}|} \hline \textbf{Verlaufstyp} & \parbox{16ex}{\textbf{ergänzende Beschreibung}} & \multicolumn{2}{c|}{\textbf{Probanden}} \\ \hline \hline \endhead 1.\,monophasisch zur Vollremission & 17,2 Monaten Dauer & 50 \newline 10 & 10,0\,\% \newline 2\,\% \\ \hline \end{longtable} \end{filecontents} Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium. Integer tincidunt. Cras dapibus. Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo \LTXtable{\textwidth}{longtable.tex} \end{document}
Possible Duplicate: I am trying to fit a longtable in a page with the following specifications: \documentclass{article} \usepackage[letterpaper]{geometry} \geometry{tmargin=2cm,bmargin=2.5cm,lmargin=2.5cm,rmargin=2.7cm} \usepackage{array} \usepackage{longtable} \begin{document} \begin{longtable}{|c|>{\raggedright}p{4.5in}|p{0.85in}|} \hline \textbf{Week} & \textbf{Content} & \textbf{Assessments}\tabularnewline \hline \endfirsthead \hline \hline \textbf{Week} & \textbf{Content} & \textbf{Assessments}\tabularnewline \hline \hline \endhead \hline Week 1 & Unit 1 &HW, Q, T\tabularnewline \hline Week 2 & Unit 2 &HW, Q, T\tabularnewline \hline \end{longtable} \end{document} Note that to the naked eye, the table seems to be perfect, but I know that one can make the long table to span through the entire text width. I am looking for improvements and how to achieve the above effect (use of the text width.) If a similar question has been asked please redirect me.
I have 15,000 address strings which I have written a piece of code which assigns them to broad geographic region e.g. American address assigned to North America. I would like to check the accuracy of my code. However I must manually check the strings. To do this I've taken a sample (SRS). I set a margin of error of 5%, a CI of 95% and a response distribution of 50%. Therefore, I assumed that I would assign the correct region half the time. The issue here is that I am much more accurate then I anticipated. Of my sample of 375,372 (99%) were assigned to the correct location. This means I am unable to calculate lower and upper confidence limits. Is there any other types of formula I could use when your response distribution is skewed to a highly positive outcome? Or is the only remedy to simply increase my sample size?
What is the best technique to calculate a confidence interval of a binomial experiment, if your estimate is that $p=0$ (or similarly $p=1$) and sample size is relatively small, for example $n=25$?
I use the following command to convert my input file contents to lowercase tr A-Z a-z < input > output This command works fine. But when I try to store the output in input file itself, it is not working. The input file is empty after executing the command. Why? tr A-Z a-z < input > input
Possible Duplicate: I frequently connect to amazon ec2 using their public DNS names (ec2-12-34-56-78.compute-1.amazonaws.com) and because of this my known_hosts file gets overwhelmed with a lot of ec2 entries I will never use again. I know I could probably use sed -i to edit in place but I wanted to use grep and so I did this: grep -v ec2 ~/.ssh/known_hosts > ~/.ssh/known_hosts That leaves known_hosts as an empty file. If I do: grep -v ec2 ~/.ssh/known_hosts > ~/.ssh/tmp mv ~/.ssh/tmp ~/.ssh/known_hosts then things are fine, but I am confused why reading and writing to the same file leaves it blank, and if there is any way around this when using grep, cat, etc.
Some days ago I heard a teacher saying the sentence: I want to talk to you who thinks differently from the crowd. It sounded unnatural, but if you consider that 'who' is the relative pronoun ruling the verb, he is right. Can you clear that out to/ for me? Thank you!
Possible Duplicate: This is a line spoken by the . I always wondered if this is grammatically correct. Luke says something like "You are mistaken ..." which the Emperor answers with No, it is you who are mistaken! Why wouldn't he say No, it is you who is mistaken! instead? I don't know what rules apply here but my stomach tells me the latter is (at least also) correct, although you would say "you are mistaken". It feels as if he should be referring to "you" in the third person. Could you please shed some light? Are both correct or – if not – which one is correct? And why?
Let $Y_1, \ldots, Y_n$ be a random sample from the pdf $$f(y\mid\theta) = \theta y^{\theta - 1}, 0 < y < 1, \theta > 0 .$$ show that $$E\left(\frac{1}{2\theta\sum_{i = 1}^n W_i}\right) = \frac{1}{2(n-1)}$$ I have showed that $\sum_{i = 1}^n -\ln(Y_i)$ is sufficient for $\theta$, and if $W_i = -\ln(Y_i)$, I have showed that $W_i$ has an exponential distribution with mean $1/\theta$. I have also showed that $2\theta \sum_{i=1}^n W_i $ has a $\chi^2$ distribution with $2n$ degrees of freedom. My first question can we treat $2\theta\sum_{i=1}^n W_i$ as just 1/y? If so, I got to the following step $$\int_0^\infty \frac{1}{y} f(y) dy = \frac{1}{\Gamma(n)} \frac{1}{2} \int _0^\infty u^{n-2} e^{-u} du$$... I am wondering how to solve $\int _0^\infty u^{n-2} e^{-u} du?$ I know it is going to be $\Gamma(n-1)$ but what is the process for finding it?
Let $Y_1, \ldots, Y_n$ be a random sample from the pdf $$f(y\mid\theta) = \theta y^{\theta - 1}, 0 < y < 1, \theta > 0 .$$ show that $$E\left(\frac{1}{2\theta\sum_{i = 1}^n W_i}\right) = \frac{1}{2(n-1)}$$ I have showed that $\sum_{i = 1}^n -\ln(Y_i)$ is sufficient for $\theta$, and if $W_i = -\ln(Y_i)$, I have showed that $W_i$ has an exponential distribution with mean $1/\theta$. I have also showed that $2\theta \sum_{i=1}^n W_i $ has a $\chi^2$ distribution with $2n$ degrees of freedom. I am wondering how to show it?
I wanted to register a Slack team, but the most obvious team name for my purpose is already taken and I can not imagine who in their right mind, apart from me, would want to use that name. So I thought that perhaps this is one of those accounts that someone registered but did not end up using and I was hoping to contact the team administrator and ask whether they would be willing to give up the slack domain. Unfortunately when I go to [1] it says This team's administrator has not enabled email signups. So my question is: is there a way to contact the administrator and is there any precedent of giving up team domains? [1] not the actual team name
I'd like to check who owns (or at least some kind of public profile page) some workspace based on its subdomain (e.g. xyz.slack.com). Is it possible?
For groups $G$, $H$, and $K$, assume there exists a left-split short exact sequence: $$ 1 \rightarrow K \xrightarrow{\varphi} G \xrightarrow{\psi} H \rightarrow 1$$ Then $\varphi$ is an injective homomorphsim, $\psi$ is a surjective homomorphism, and ${\rm Im}(\varphi) = \ker(\psi)$. Furthermore, there exists a homomorphism $\pi: G \rightarrow K$ such that $\pi \circ \varphi = id_K$. How can I show that these assumptions imply that $H \triangleleft G, K \triangleleft G, G = HK,$ and $H \cap K = \{ 1 \}$?
Here is the problem I am trying to prove: For groups $G,H,K,$ show that the following conditions are equivalent. $G \cong K \times H.$ There exists a split short exact sequence: $1 \rightarrow K \rightarrow G \rightarrow H \rightarrow 1.$ There exists a left-split short exact sequence: $1 \rightarrow K \rightarrow G \rightarrow H \rightarrow 1.$ $H \triangleleft G, K \triangleleft G, G = HK $ and $H \cap K = \{1\}.$ My questions are: Here is the proof of $1 \implies 2.$ Assume that $G \cong K \times H.$ We want to show that there exists a split short exact sequence: $1 \rightarrow K \rightarrow G \rightarrow H \rightarrow 1.$ But we know that a short exact sequence is split if it is both left- and right-split. Also, know that a short exact sequence $1 \rightarrow K \rightarrow G \rightarrow H \rightarrow 1$ is left-split if there is a retraction $r: G \rightarrow K$ s.t. $$r\circ i = id_K \quad \quad (1) $$ Where $i: K \rightarrow G$ and it is injective. And also, we know that a short exact sequence $1 \rightarrow K \rightarrow G \rightarrow H \rightarrow 1$ is a right-split if there is a section $s: H \rightarrow G$ s.t. $$p\circ s = id_H \quad \quad (2)$$ Where $p: G \rightarrow H$ and it is onto. So, we need to find the functions $i, p, r$ and $s$ that satisfies $1.$ and $2.$ above. So, since $G \cong K \times H,$ we can say that we have $1 \rightarrow K \rightarrow K \times H \rightarrow H \rightarrow 1,$ with $i: K \rightarrow K \times H$ the embedding $i(k) = (k,1)$ and $p: K \times H \rightarrow H$ the projection $p(k,h) = h.$ If we define $r: K \times H \rightarrow K $ with $r(k,h) = k$ then we have $(r\circ i) (k) = r((k,1)) = k$ as required. Also, if we define $s: H \rightarrow K \times H $ with $s(h) = (1,h)$ then we have $(p\circ s)(h) = p ((1,h)) = h $ as required. 1- Is it correct? and is the importance of $G \cong K \times H$ is just to create the split short exact sequence? 2- Is the statement of my problem completely correct? 3- How can I prove $1 \implies 4$? 4- Is the right sequence of implications for proving the problem is proving $1 \implies 2 \implies 3 \implies 1$ and then proving $1 \Leftrightarrow 4$? 5- Is $2 \implies 3 \implies 1$ in my problem means $2 \implies 1$? or $2 \implies 1$ is a different thing
In java i would like to create a method that can return multiple objects like a couple of int values, strings, float , double etc. what is the way to do this?
I want to return two objects from a Java method and was wondering what could be a good way of doing so? The possible ways I can think of are: return a HashMap (since the two Objects are related) or return an ArrayList of Object objects. To be more precise, the two objects I want to return are (a) List of objects and (b) comma separated names of the same. I want to return these two Objects from one method because I dont want to iterate through the list of objects to get the comma separated names (which I can do in the same loop in this method). Somehow, returning a HashMap does not look a very elegant way of doing so.
System is Acer Laptop, Windows 10 and Ubuntu 16.04 terminal Halfway through installing an application and I cant seem to access any of the USBs. LSUSB just completes and returns nothing. Typically I'm doing a project and this could stop it in its tracks. Any help you could give would be much appreciated Edit: using lower case lsusb:
I'm trying to connect adb to my Android device in the Windows 10 Ubuntu shell, but it doesn't seem to be working: adb does work normally on Windows, so it's not a problem with the phone or the connection. Do I have to do something like mount the port in the Ubuntu shell? How? (The goal is to pass logcat to grep, which would obviously work better in Ubuntu.)
Let $X\in L^2(\Omega, \mathcal{A}, P)$ and let $\mathcal{G}\subset\mathcal{A}$ be a sub $\sigma$-algebra. Assume that $X\stackrel{d}{=}E[X|\mathcal{G}].$ Prove that $X=E[X|\mathcal{G}]$ a.s. I have posted and solved a similar question but I cannot figure out how to make the necessary changes from the assumption that $E[X|\mathcal{G}]\le X$ a.s. to the assumption that $X\stackrel{d}{=}E[X|\mathcal{G}]$ in order to alter this proof to make it work. Any help with that or a full blown new proof would be greatly appreciated.
Suppose $(\Omega,\mathcal F,P)$ is a probability space and that $\mathcal G$ is a sub-sigma-algebra of $\mathcal F$. If $X$ is an integrable, non-negative random variable with the same distribution as $E[X\mid \mathcal G]$, how does one show that $X=E[X\mid \mathcal G]$ a.s.?
linux process with status 'D' mean TASK_UNINTERRUPTIBLE, so I write a programer to test it on Ubuntu 16.04 My code: #include <unistd.h> #include <iostream> using namespace std; int main(void) { pid_t pid = vfork(); if (pid == -1) { cout<<"for error"<<endl; } else if (pid == 0) { cout<<"this child is "<<getpid()<<endl; sleep(1000); } else { cout<<"this parent is "<<getpid()<<endl; } return 0; } after I run the programmer, the status of the parent process is 'D' When I use kill command to kill the parent process, the parent process was be killed successfully, so anything wrong in my code ? Thanks very much !!!
Sometimes whenever I write a program in Linux and it crashes due to a bug of some sort, it will become an uninterruptible process and continue running forever until I restart my computer (even if I log out). My questions are: What causes a process to become uninterruptible? How do I stop that from happening? This is probably a dumb question, but is there any way to interrupt it without restarting my computer?
when I run it display this error Exception in thread "main" java.lang.NullPointerException at Abstract2.main(Abstract2.java:70) pleae tell me how to resolve it my code is given below import java.util.*; abstract class plan { public double rate,bill; public abstract void getrate(); public void cbill(int unit) { double bill=rate*unit; System.out.println("bill is="+bill); } } class domestic extends plan { public void getrate() { rate=2.5; } } class commercial extends plan { public void getrate() { rate=5.5; } } class industrial extends plan { public void getrate() { rate=7.5; } } class bill { public plan getplan(String plantype) { if(plantype==("domestic")) { return new domestic(); } if(plantype==("commercial")) { return new commercial(); } if (plantype==("industrial")) { return new industrial(); } return null; } } class Abstract2 { public static void main(String aa[]) { plan p;//instance of class plan String plantype; int unit; double rate; bill b=new bill(); Scanner sc=new Scanner(System.in); System.out.println("enter the plan type="); System.out.println(" domestic"); System.out.println(" commercial"); System.out.println(" industrial"); plantype=sc.next(); System.out.println("enter the units"); unit=sc.nextInt(); p=b.getplan(plantype); p.getrate();//line 70 p.cbill(unit); } } please tell me how to resolve it
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 can set line-height to 85px and it will vertically align it, but I won't always know how tall the element is. I'm sure I'm missing something simple here... but what can I modify in the .content class to make the text vertically centered? .tile { position: relative; width: 100px; height: 85px; display: inline-block; border: 1px solid red; } #container1 { position: absolute; top: 0; left: 0; right: 0; bottom: 0; } #container2 { position: absolute; top: 0; left: 0; right: 0; bottom: 0; } .content { margin: auto; height: 100%; vertical-align: middle; text-align: center; } <div class="tile"></div> <div class="tile"></div> <div class="tile"></div> <div class="tile"></div> <div class="tile"></div> <div class="tile"></div> <div class="tile"></div> <div class="tile"></div> <div class="tile"> <div id="container1"> <div id="container2"> <div class="content">Test</div> </div> </div> </div>
I have a div with two images and an h1. All of them need to be vertically aligned within the div, next to each other. One of the images needs to be absolute positioned within the div. What is the CSS needed for this to work on all common browsers? <div id="header"> <img src=".." ></img> <h1>testing...</h1> <img src="..."></img> </div>
I want to install ubuntu on vmware, I have downloaded the OS file from ubuntu web site, how to go ahead. Like for RHEL 6 do I have to download an ISO image file so as to install it or is there some other unique technique?
Hi I was looking to install this with or under VMware on windows 7 64bit, is this possiable and where can I find instructions on how to do so? I have searched the site and can not find anything for help on installing this with VMware. Also I have VMware Workstation do I need VMware player?
$R$ is a commutative ring. We need to prove that $R[x]$ has a subring isomorphic to $R$. Let $S$ be that subring of $R[x]$ which has polynomials of even degree. Now I consider a mapping from $S$ to $R$ as : $f(x) \to f(0)$ where $f(x)$ is a polynomial of even degree and $f(0)$ is clearly in $R$. The mapping defined as above "seems" one-one and onto. But I couldn't prove it. I took the kernel of the mapping as $\ker \phi = ( f(x) \in S | \phi ( f(x)) = 0 )$ , Which only gives $a_0 = 0$ , $ f(x) = a_0 + a_1 x + a_2 x^{2} $ . . . ... $ a_n x^{n} $ We know if kernel only contains the " 0 " element then the mapping is one-one . But I'm unable to prove that here. Can anyone help me out here ?
Say $R$ is a commutative ring. Does there exists a subring of $R[x]$ that is isomorphic to $R$? My approach would be to define the subring of $R[x]$ that generates $R$. Any thoughts?
I am having an issue in Ubuntu 16.04 . When I open a window such as a terminal window or the attached file properties window, the window border including the close , minimize etc icons are obscured by colored noise. What could be causing this? I have lived with this for a while but it's becoming very frustrating. Thanks.
After some gorgeous updates I witness this:
How can I disable blender from restarting a scene when dropping a blender model onto it? I'm looking for a way to merge models into existing scenes without using the awkward append option.
I have created several designs for a particular project and they are related, but I don't want to have to keep recreating any similar elements, such as shared materials or textures. How can I use the existing data in a new Blender file?
I need nth term for the below sequence $1,2,(3/2),(5/3),(8/5),(13/8),(21/13),(34/21)........nth term$ I know [(present number)= sum of previous(numerator + denominator ) / previous numerator] Thanks before
$$\frac23,\frac35,\frac58,\frac8{13},\frac{13}{21},\frac{21}{34},\frac{34}{55},\ldots$$ You would be able to find here a pattern that the denominator of previous term gets new term numerator and new term denominator gets the sum of numerator and denominator of previous term
My teacher told me that not only do we have to use the erf function to approximate error, but that it is proved impossible to integrate in real analysis (at least not Riemann-integrable). Is there a name for this proof, and can I have it? I am not a mathematician, but such a simple function has been around and it irks me terribly and need a detailed proof for closure.
I was wondering what the antiderivative of $e^{-x^2}$ was, and when I wolfram alpha'd it I got $$\displaystyle \int e^{-x^2} \textrm{d}x = \dfrac{1}{2} \sqrt{\pi} \space \text{erf} (x) + C$$ So, I of course didn't know what this $\text{erf}$ was and I looked it up on wikipedia, where it was defined as: $$ \text{erf}(x) = \dfrac{2}{\sqrt{\pi}} \displaystyle \int_0^x e^{-t^2} \textrm{d}t $$ To my mathematically illiterate mind, this is a bit too circular to understand. Why can't we express $\int e^{-x^2} \textrm{d}x$ as a 'normal function'? Also, what is the use of the error function?
I am looking for a book which focuses on a child and his family. I think there was a big house and there were creatures around the house but the creatures weren't visible all the time. There was something that made them visible but I don't remember what it was. The child's family didn't believe him at first.
The kids moved into a house inherited from a family member. There was a journal one kid found in an attack. The journal detailed a bunch of fantasy, fey-type creatures. The kids had a evilish brownie living in their house. The book was presented as something true that was mailed in to the publisher. There were two series.
I wrote a command for a document with many figures and tables which belong to each other. Every figure/table has the same caption just one parameter changes and the labels are automatically created. The problem is now, that these labels are not in the label list of TexStudio which would be nice. \documentclass{article} \usepackage{hyperref} \DeclareRobustCommand{\captionf}[1]{Parameter of #1\label{fig:Parameter#1} % \global\def \captiont {Description of \autoref{fig:Parameter#1}} } \begin{document} \begin{figure}[ht] \centering lalala \caption{\captionf{lalala}} \end{figure} \begin{table}[ht] \centering \begin{tabular}{cc} la & lu \\ \end{tabular} \caption{\captiont} \end{table} \end{document} Does somebody knows a solution to this?
In TeXstudio editor one can easily choose which labels to reference as soon as you type the cross-referencing-macro you intended to use, for instance, \cref{} of the cleveref package (see image below). One problem, though, when you use ctable package to create a table, a user-friendly package indeed, you soon discover that you should label the table the way that ctable understands: ... label=tab:somelabel, ... Here comes the problem, since labels of tables were marked the way ctable understands, TeXstudio can no more recognize them as normal labels, and you won't find these labels in the drop down menu among other labels made by whatever else method. This can be of course tolerated when you have a couple of labels, but when you have a lot of them, it turns out to be a tedious task to recall or call out the labels exactly as they are. I would be grateful if someone would provide a workaround solution for this issue, without sacrificing the use of either ctable package or TeXstudio IDE. Note: TeXstudio version 2.6.4 ctable version June 14, 2013
Let a,b,c $\in\mathbb{Z}$ such that a|k, b|k and gcd (a,b)=1. Prove that ab|k. Any hints would be helpful.
Using divisibility theorems, prove that if $\gcd(a,b)=1$ and $a|c$ and $b|c$, then $ab|c$. This is pretty clear by UPF, but I'm having some trouble proving it using divisibility theorems. I was looking at , and if this could be proven, then the solution would follow immediately.
I am trying to enter data in MySQL table using PHP. Below is my code. What am I missing? The reason is, no data is inserted. Database connection. <?php class Dbh{ private $servername = "localhost"; private $username = "username"; private $password = "password"; private $dbname = "oop"; protected function connect(){ $conn = new mysqli($this->servername, $this->username, $this->password, $this->dbname); return $conn; } } ?> Insert class for inserting the data into MySql table <?php include_once 'Dbh.php'; class Insert{ public function insertData(){ $uid = $_POST['uid']; $pwd = $_POST['pwd']; $sql = "INSERT INTO user(uid, pwd) VALUES ('uid', 'pwd')"; mysqli_query($sql); header("Location: ../index.php?data=inserted"); } } ?> HTML form for inputting the data. <?php include_once('Insert.php'); $data = new Insert(); ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Insert data into database</title> </head> <body> <form action="classes/Insert.php" method="POST"> <input type="text" name="uid" placeholder="user name"> <br> <input type="password" name="pwd" placeholder="password"> <br> <button type="submit" name="submit">Insert data</button> </form> </body> </html>
If user input is inserted without modification into an SQL query, then the application becomes vulnerable to , like in the following example: $unsafe_variable = $_POST['user_input']; mysql_query("INSERT INTO `table` (`column`) VALUES ('$unsafe_variable')"); That's because the user can input something like value'); DROP TABLE table;--, and the query becomes: INSERT INTO `table` (`column`) VALUES('value'); DROP TABLE table;--') What can be done to prevent this from happening?
The fanatic badge is awarded if you visited the site for 100 consecutive days. Apart from , but I was wondering, what does a visit entail? Any of these? Visit for at least 1 second Visit for at least 86.400 seconds Visit and did something, incl. voting, tagging, commenting, time of visit not counted Visit and did some more thing, at least asked/answered/edited a question Visit site while John Skeet is present In short, is a visit a hit, or an active visit?
I'm pretty depressed that I'm finally one of the people posting this, since I'm usually telling those people "you're obviously wrong", but either I don't understand how consecutive day counting works or this seems impossible: The last activity count is right; I was on SO at about 18:30Z yesterday (Saturday). Is it possible for the consecutive count to be at 1 if my last activity was yesterday? It would seem like it has to be at least 2 then (although I was definitely active Friday; I suspect Saturday is the "missing" day since all I did was poke through the newest question list and check the current flags)
Let $p:X \rightarrow Y$ be a perfect map, that is, $p$ is closed, continuous, surjective, and $p^{-1}(y)$ is compact for every $y \in Y$. Show that if $X$ is locally compact, then so is $Y$. There are a couple of these perfect map problems on one of our old qualifying exams. They seem really difficult. I've been working on this one all night and can't figure it out.
Recall that a space $X$ is locally compact if for any point $x$ in $X$, and any neighborhood $U$ of $x$ in $X$,there is a neighborhood $V$ of $x$ in $X$,and a compact subspace $C$ of $X$ such that $x \in V \subset C \subset U.$ Let $X$ be a locally compact space, and let $f : X \rightarrow Y$ be a continuous, closed surjection. Suppose that $f^{-1}(y)$ is compact for each $y \in Y$ . Show that $Y$ is locally compact.
I am a dual citizen of Germany and USA and I will enter the USA soon with my US passport which is set to expire in 2 weeks. I plan on staying there for about 1 month before returning to my country of residence, the UK. Will the expiry of my US passport cause any problems? Can I use the German one to leave the USA and enter the UK?
My daughter has dual citizenship: US/German. We will be flying from Germany to the US in 6 weeks. Her US passport will expire during our stay in the US, but not on the day of our flight (4 days later). Do you think I should get ESTA for her? Just to make sure that the airline will let her board the plane? Will there be any problems with getting back to Germany without ESTA and with an expired US passport?
i have a list of names e.g.: List<String> names = ... names.add('charles'); ... and a statement: PreparedStatement stmt = conn.prepareStatement('select * from person where name in ( ? )'); how to do the following: stmt.setParameterList(1,names); Is there a workaround? can someone explain why this method is missing? using: java, postgresql, jdbc3
What are the best workarounds for using a SQL IN clause with instances of java.sql.PreparedStatement, which is not supported for multiple values due to SQL injection attack security issues: One ? placeholder represents one value, rather than a list of values. Consider the following SQL statement: SELECT my_column FROM my_table where search_column IN (?) Using preparedStatement.setString( 1, "'A', 'B', 'C'" ); is essentially a non-working attempt at a workaround of the reasons for using ? in the first place. What workarounds are available?
How can I eliminate whitespace before a landscape page? \afterpage does not work for me. Please find below an example. My code is like that : Text \afterpage{ \begin{landscape} Text1 \end{landscape} a } \Section {head text2 } Another text
I want to add a landscape page between 2 pages, But the problem is that latex make a space before landscape, how to remove the section (which circled on red ) to the page 1. the code is like that Text \afterpage{ \begin{landscape} a \end{landscape} } \Section Another text
my brother and I are working on a story in which a being's atoms vibrate back and forth so rapidly that it appears invisible, like a plucked guitar string or a plane's propellor. Is that theoretically possible? Thanks for any help!
In many anime, comics, movies, etc, we see a lot of super human beings moving and fighting at such high speeds that a regular human being cannot see that they are fighting or moving pass by. In particular, in the first battle between Goku and Piccolo, those two are able to fight in a confined environment (when Piccolo first appears in the comics, stage fight, if I remembered correctly), and regular audiences are unable to see them when they battle. Is it physically possible for a "human" (human size object) to move in a confined environment (let's say, $20~\text{m} \times 20~\text{m} \times 10~\text{m}$ ) so fast that a normal person would be unable to see it? If it is possible, how fast must this "person" be? Assume that this "human" cannot move faster than, or even close to the speed of light. Some clarifications: First, please ignore the strength/physicality of the object, and consider it an object that can can move "freely" in this confined space without causing any "side effects" (such as heat, sounds, etc) Second, please take in note that the object is moving in a confined, rather small 3D space as mentioned in the question, and the observer would be always able to see the entire space. And last, a blurred image would be considered as "able to see".
From Wikipedia article : Spectral lines are the result of interaction between a quantum system (usually atoms, but sometimes molecules or atomic nuclei) and a single photon. When a photon has about the right amount of energy (which is connected to its frequency) to allow a change in the energy state of the system (in the case of an atom this is usually an electron changing orbitals), the photon is absorbed. Then it will be spontaneously re-emitted, either in the same frequency as the original or in a cascade, where the sum of the energies of the photons emitted will be equal to the energy of the one absorbed (assuming the system returns to its original state). A spectral line extends over a range of frequencies, not a single frequency (i.e., it has a nonzero linewidth). The lifetime of excited states results in natural broadening, also known as lifetime broadening. The uncertainty principle relates the lifetime of an excited state (...) with the uncertainty of its energy. Can you provide proof for the last statement? (Maybe without using QED, if possible)
Consider the atomic spectrum (absorption) of hydrogen. The Bohr's model postulates that there are only certain fixed orbits allowed in the atom. An atom will only be excited to a higher orbit, if it is supplied with light that precisely matches the difference in energies between the two orbits. But how precise does 'precisely' mean. Of course, if we need energy $E$ to excite the electron to a higher energy level, and I supply a photon with just $E/2$ I would expect nothing to happen (since the electron cannot occupy an orbit between the allowed ones). But what if I supplied a photon with energy $0.99E$, or $1.0001E$ or some such number. What will happen then? I think that the electron should still undergo excitation precisely because the lines we observe in the line spectrum have some thickness. Which means that for a given transition, the atom absorbs frequencies in a certain range. Is my reasoning correct? If not, why? How does Bohr's model explain this? How about modern theory? If I'm right, what is the range of values that an atom can 'accept' for a given transition?
I am trying to understand the code in : import socket import sys import time def get_lock(process_name): # Without holding a reference to our socket somewhere it gets garbage # collected when the function exits get_lock._lock_socket = socket.socket(socket.AF_UNIX, socket.SOCK_DGRAM) try: get_lock._lock_socket.bind('\0' + process_name) print 'I got the lock' except socket.error: print 'lock exists' sys.exit() How do the two lines work which start with get_lock.? It's not like it's a class instance and you are using its methods..
Not many are aware of this feature, but Python's functions (and methods) can have . Behold: >>> def foo(x): ... pass ... >>> foo.score = 10 >>> dir(foo) ['__call__', '__class__', '__delattr__', '__dict__', '__doc__', '__get__', '__getattribute__', '__hash__', '__init__', '__module__', '__name__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__str__', 'func_closure', 'func_code', 'func_defaults', 'func_dict', 'func_doc', 'func_globals', 'func_name', 'score'] >>> foo.score 10 >>> foo.score += 1 >>> foo.score 11 What are the possible uses and abuses of this feature in Python ? One good use I'm aware of is 's usage of the docstring to associate a syntax rule with a method. But what about custom attributes ? Are there good reasons to use them ?
Our Lennar at Laurel Creek Quads in Rogers, MN has been completed and it's now 3 years old. How do we get the community listed on Google Maps? It shows up on Apple Maps, but not Google Maps.
When I search for my address on Google Maps it cannot be found which means I can't order takeaway etc. Is there a way of adding my address to Google Maps or even add a street address? I want the address to be publicly available so others can search it.
I've seen that there are different groups like $SU(2)$ and $SO(3)$ with isomorphic Lie algebra. I know that putting the elements of the linear algebra in the exponential function gives the group elements, in this case I don't understand how it's possible that two isomorphic linear algebras gives different groups Does it mean that when I put two isomorphic group in the exponential function I can obtain two non isomorphic groups?
I thought that groups with the same Lie Algebra are automatically equivalent, but there appear to be some exceptions to this? What sort of exceptions are there and why?
Let $(U_n)$ be a sequence such as $|u_{n+1}-u_n|<\frac{1}{n^2}$ show that (U_n) is a convergent sequence. I m stuck with this question, I showed that $\lim\limits_{n \to \inf} u_{n+1}-u_n =0$ Can you help me ?
Let ${x_n}$ be a sequence in $R$ such that $|x_{n+1} - x_n|< \frac{1}{n^2}$ for all $n \in N$. Show that the sequence is convergent. If it were $|x_{n+1} - x_n|= \frac{1}{n^2}$, could take help of the fact $\sum \frac{1}{n^2}$ is convergent and of triangular inequality. But what to do here? Please help. Thanks in advance.
I want a button that runs a callback function using the AJAX method included in Form API. The button I have still submits the whole node edit form. I don't want it to do that - just pass a couple variables to the callback function and display the results. How can I do that? This is my FAPI code for that button: $form['rid_import']['rid_get'] = array( '#type' => 'button', '#value' => t('Import'), '#attributes' => array( 'id' => array('fetch_rid'), 'class' => array('col-sm-3', 'col-xs-4') ), '#parents' => array('rid_import'), '#limit_validation_errors' => array(), '#executes_submit_callback' => false, "#submit" => array('sql_no_submit'), '#ajax' => array( "callback" => 'sql_fetch_restid', "wrapper" => 'rid_sql_query', "event" => 'click' ) ); EDIT You're right, I was being unclear. Basically what I wanted is something that works like your "Add More" or "Remove" buttons when you have multiple-value fields, but just to run my function without reloading the page – grab some data from the DB and show it there on the node edit form. I have a multivalue field collection that should be populated with those values and then saved together with the rest of the node. That's why I don't want it to go ahead and save the node. However, if it isn't possible I guess I will have to find another way to do what I need. And tried to add a submit function, still reloads the whole page.
I have a submit button in my form and I want to implement it using ajax: function myid_user_page_form(){ drupal_add_library('system', 'drupal.ajax'); $form = array(); $form['id'] = array( '#type' => 'fieldset', '#title' => t('ID Information'), '#prefix' => '<div id="myid_search_id_number_wrapper">', '#suffix' => '</div>' ); $form['submit'] = array( '#type' => 'button', '#value' => 'Save', '#ajax' => array( 'event' => 'click', 'callback' => 'myid_user_page_form_ajax_submit', 'wrapper' => 'myid_search_id_number_wrapper' ), '#attributes' => array( 'id' => 'myid_save', ), ); function myid_user_page_form_ajax_submit($form, &$form_state) { watchdog('Wow','Wow'); } After executing the code above, the page still has it's refresh after it's clickfunctionality. The ajax doesnt work and no Wow message log in my watchdog table from my database, which means the ajax callback function isn't called. Where am I missing?
I need to now how to give a player a named item with commands. I have tried it already on PC, and it works, but it does not work in PE.
I have put the following command into a command block, but it keeps saying invalid command syntax: give @p spawn_egg 1 17 {display:{Name:"help!}} What do I need to do to fix this?
We are building web applications and I'm a front-end developer. In my job, I often have questions about CSS architecture, what is the best way to organize CSS/HTML markup. Examples of these would be questions about SMACSS or other front-end architecture frameworks. Is this topic appropriate for Stack Overflow?
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.
I wrote this in rails console (3352.3744333333334==3352.3744333333335) #true and result was true Notes: I'm using ruby 2.4.0 and rails 5.0.1
Consider the following code: 0.1 + 0.2 == 0.3 -> false 0.1 + 0.2 -> 0.30000000000000004 Why do these inaccuracies happen?
I am new in ubuntu and i am trying to download ROS at the moment. the idea of repository keyrings are still new. However i am getting somewhere and making progress. this error seems to render my installation useless, please help me out of this. I have tried the ls/etc/apt/sources.list.d and rm files.. but nothing happened. the next message tells me to 'Manage keyring files in trusted.gpg.d instead' what to do please guide. thanks
Setting up keys for a local repository on a new ubuntu 20.10 virtual machine, I got a message that apt-key add was deprecated and I should read the apt-key(8) man page. The apt-key(8) man page is a collection of words strung together, but if it contains information I can't winkle it out. Can anyone tell me what, exactly, I should type on my terminal instead of: apt-key add name-of-file The command does apparently still work after honking at me, so I was able to proceed, but would like to know what I'll need to do in the future.
In Breaking Bad, right after Walt and Jessie agree to work together for Gus, and later find out that the 2 men who killed Combo were using a little boy. That lead to a confrontation, and we learn that Gus ordered his men and Jessie to shake hands and ordered his men not to use kids anymore. We then learn about the death of the little boy. Did Gus order his men to kill the boy (off screen)? If yes, what will he accomplish? If not, what will the men accomplish? In anyway, I see no logical reasoning for anyone to kill the boy. But judging by the no-reaction from Gus to the boy's death, I would say: he is OK with it.
In the episode "Half Measure" (S03E12) Jesse tries to kill the two dealers who killed Combo using Andrea's little brother Tomas. But as soon as Gus gets behind this he intervenes and apparently only by Walt's pleading lets Jesse live. He tries to arrange peace between Jesse and the dealers to avoid any further trouble. And as a compromise he tells the dealers No more kids. when Jesse tells him about Tomas (though, it's hard to imagine Gus didn't know about the usage of kids as subordinates, let alone care about it at all). And so far so good the peace seems settled. But then suddenly Tomas ends up killed and I can't wrap my head around why (other than to further the story by making things escalate). Sure, for the dealers it might be an easy way to dispose of him, now that they're told "no more kids", but I don't think they would hazard such an action without permission from Gus. And I can't see what Gus really gained from Tomas' death. Even as an act of defiance to show Jesse who's the boss it doesn't make so much sense, seeing that he was quite interested in the "peace treaty" to avoid further trouble and he knew Jesse's temper and that this was bound to cause trouble once Jesse learns about it. If he really wanted the situation to escalate and get rid of Walt and Jesse, he could have offed them a lot easier and more unexpectedly. Or did he just hope for Walt to ditch Jesse once he goes postal, underestimating their bond? Did I miss anything relevant that may help to understand who ultimately made the plan to kill Tomas and why?
I have a mesh ( with points and triangles that define it), and I will need to create a DEM model out of it ( in geotiff format if possible for space consideration, if not, then in ASCII grid format). I need the DEM for watershed and catchment delineation purpose. Instead of using existing software like ArcGIS, I want to write my code to do it ( in C++ or C#), so that I can later integrate them into my own GIS software. is there anything in GDAL or other open source source code libraries that do this well? Or do I have to write from scratch? PS: there are a lot of posts like on how to do it the other way round, ie: from DEM grid points to mesh, but they are not what I want. I have a similar question as on how to get DEM grid points from point clouds, but that is fundamentally different from this one. I don't need the mesh interpolation part for this question, as I already have the mesh. I can always create the bounding box for the mesh, loop through each grid points, get the z, and then construct the grid, but this is crude and can be slow. I'm unsure whether there is a faster way of doing it?
I have a list of surveyor points, and I will need to create a DEM model out of it ( in geotiff format if possible for space consideration, if not, then in ASCII grid format). I need the DEM for watershed and catchment delineation purpose. Instead of using existing software like ArcGIS, I want to write my code to do it ( in C++ or C#), so that I can later integrate them into my own GIS software. is there anything in GDAL or other open source tools that do this well? Or do I have to write from scratch?
According to general relativity, speed is relative, so for example if you are running at 20 km/h and a car passes you at 30 km/h, the runner is actually moving at 50 km/h relative to the car. Now imagine that 2 spaceships are traveling both at 99% the speed of light, and they pass each other in a linear fashion. Could it be argued that from 1 spaceships perspective, you are traveling at 198% the speed of light relative to the other spaceship, according to special relativity, yet violating the constant speed of light?.
Let's say I fire a bus through space at (almost) the speed of light in vacuum. If I'm inside the bus (sitting on the back seat) and I run up the aisle of the bus toward the front, does that mean I'm traveling faster than the speed of light? (Relative to Earth that I just took off from.)
I have a valid 600 Business Stream Visa (valid for one year with multiple entries) to travel to Australia. I travelled to Perth earlier in the year for business meetings. With this visa am I allowed to enter Australia for leisure? I don't intend to participate in any business activities on this trip. Thanks for your help.
I currently hold a multiple-entry business visitor (subclass 600) visa for Australia valid until January 2020, and I have traveled to Sydney multiple times before for business. I am planning to spend my next holiday (i.e., next month) in other parts of Australia (Queensland & Victoria). For this purpose, do I need to apply for a tourist visa or will my business visitor visa work? Note: I have already looked at a similar query raised here but there was no definite answer to it. Edit: My plan to visit Australia last year was canceled but in May 2018, I went there as a tourist on my business visa and didn't face any issue with immigration.
Each time I’m inserting a removable USB drive with a file system Windows 10 doesn’t understand, Windows asks me to re-format the drive: I’m positive I have autoplay turned off everywhere I was able to find, but this message still appears. Is there a way to disable the message? Update: I’m not using true crypt. I don’t have “the disk”, instead I have several different SD cards I reformat often, each containing multiple Linux partitions so the “Exact duplicate” solution doesn’t work for me. Update 2: The “Exact duplicate” solution doesn’t work at all. Linux partitions aren’t raw like TrueCrypt partitions, they are healthy. They don’t have any assigned letters. And the only thing I can do with them in Windows disk management — delete, the rest of the options are grayed out. Update 3: My question is different. Please read the updates above. The first update explains why it's not a duplicate. The second one explains why the solution to that other question doesn't work, I even includes a screenshot that shows there's no drive letter and therefore nothing to remove.
I've started using TrueCrypt to encrypt a partition on an external USB hard drive. I've opted for using a raw partition as opposed to a file container. But here's the annoyance. Whenever I connect this drive to a computer running Vista or Windows 7, I get the message popup "You need to format the disk in drive J: before you can use it". The default option is "Format disk", and I'm afraid one of these days I'll accidentally trigger it. Is there any way to disable this message?
Michael Swan in his book ( - page 3/ page 4) writes about above/over 1) "Higher than": Above or over Above and over can both mean "higher than Can you see a helicopter above/over a palace? Okay, I make a conclusion they are the same here. 2) "not directly over": above We prefer above when one thing is not directly over than another. We've got a little house above the lake The thing that is meant here, as I can guess, is the house is higher but it's not on the same vertical line with the lake. If there were "over" here We've got a little house over the lake then we would have to understand it like the house is hovering/levitating above the lake with no logical explanation. Am thinking right? This case I am feeling troubled because in the first way of usage the choice of above/over means the same thing while in the second one it's different. Having read the second usage, should I take Can you see a helicopter above a palace? like the helicopter is at a higher position than the palace but it is not directly over the building? And should I understand Can you see a helicopter over a palace? like it's right over the roof that if it goes down it will land exactly onto the top of the palace? I see it as a problem because the author firstly says they are equal but then gives an example with an explanation where they are different. How should I distinguish the first usage senteces where they are the same from the second usage sentences where they would mean a different thing?
I read in some good grammar book that "Above" and "over" can both mean "higher than": The example from the book Can you see the helicopter above/over the palace? Then below it was written that We prefer "above" when one thing is not directly over another The example from the book We've got a little house above the lake The question is is the helicopter in the first example directly over the palace or no if both "above" and "over" can be used?
I am creating some <div> elements for my chat box application. The following is the HTML part, in which on clicking a button the <div> elements are created. <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> <html> <head> <link rel="stylesheet" type="text/css" href="../chat/style.css"/> </head> <body> <h1>Jquery div example</h1> <button><i>click to create div</i></button> </body> </html> The creation of <div> elements seems OK. But I am unable to do anything on the created box. This is the JQuery code for creating the div: $(document).ready(function(){ var chat_box_title = 'jaya chandra'; $("button").click(function(){ $('<div/>') .attr({id:'chat_box_'+chat_box_title}) .addClass('chat_box') .html('<div class="chat_head">jaya chandra<span class="chat_close"><a class="chat_close" href="javascript:void(0)" onclick="javascript:closeChatBox(\''+chat_box_title+'\')">X</a></span></div><div class="chat_wrapper"><div class="chat_body"></div><div class="chat_footer"><textarea rows="4" placeholder="Your message here..." class="chat_input"></textarea></div></div>') .appendTo('body'); }); }); When the class .chat_head is clicked then the .chat_wrapper has to toggle. I am trying to bind the click function using the following code.. $('body').on('click','div.chat_head>div.chat_wrapper',function(){ //$('.chat_wrapper').slideToggle('slow'); console.log('clicked'); }); I have tried all of my ideas for it, but I am unable to solve the problem.
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.
This is problem 1.2.20 from Hatcher's algebraic topology. I am able to complete the first part. But I have trouble proving they are homotopy equivalent but not homeomorphic. Can someone please give some hints? Thanks.
Let $X$ be the subspace of $\mathbb{R}^2$ that is the union of the circles $C_n$ of radius $n$ and center $(n,0)$ for $n \in \mathbb{N}$. Show that $X$ and $\bigvee_\infty S^1$ are homotopy equivalent, but not homeomorphic. It is unclear to me why the "obvious" maps between the two spaces do not give a homeomorphism. It seems like the difference would have to be a result of the behavior of the map near the origin. Could I get a hint?
For some reason I need to print a big array of data (2D) retrieved from the DB. There is so many column that the array go over the screen width. So I wonder if there is any tricks to show this kind of big HTML array in a good way. Thanks for you help and advices!
I have a Twitter Bootstrap based table with responsive CSS. Everything looks good but, when I try to put more columns than the size of the table supports, I have a line breaking. I tried to change font size. But I think it would be strange or confusing for the user if I have different font sizes in each table. So I am in a dead end. Some restrictions Maximum width: The table must not exceed 940 pixels. Single Table: I can't divide the information in multiple tables. This is what I have: Is there a better way to display tabular data considering the restrictions?
The random variables $X_1, X_2, . . . , X_n, Y_1, Y_2, . . . , Y_n$ are iid $\mathcal{U}(0, a)$. Determine the distribution of $$Z_n = n \log\bigg(\frac{\max\{X(n), Y(n)\}}{\min\{X(n), Y(n)\}}\bigg)$$ Should I find the joint distribution of $\max$ and $\min$ and then find distribuation of $Z_n$, since we have a two different random variable I do not know how to do that!
The random variables $X_1,X_2,...X_n,Y_1,Y_2,...Y_n $ are independent and $U(0,a)$-distributed. Determine the distribution of $$Z_n=n\cdot \log\left(\frac{\max\left(X_{(n)},Y_{(n)}\right)}{\min\left(X_{(n)},Y_{(n)}\right)}\right)$$ where $X_{(n)},Y_{(n)}$ denotes $n$th order variable. This problem is giving me a headache. The answer is that $Z_n$ is $\text{Exp}(1)$-distributed. But i can't derive that conclusion. I'd like to show you my derivation, but its so long and contains so many integrals and fractions that it would take a while to write it here. But basically my approach was to derive the distribution of $M=\max(X_{(n)},Y_{(n)})$ and $L=\min(X_{(n)},Y_{(n)})$. I get the following cdf's: $F_M=(F_X\cdot F_Y)^n=(F_X)^{2n}$ and $F_L=1-(1-(F_X)^n)\cdot (1-(F_Y)^n)=1-(1-(F_X)^n)^2$ , correct? $F_X $ stands for the cdf of $X_i$ Then i define the random variable $T=\frac{M}{L}$ and compute its cdf to finally be able to derive the distribution of $Z_n=n\cdot \log(T)$. But thats where i think everything goes wrong. Any help appreciated, thanks.
My teacher says- The degree of the zero polynomial is undefined. My book says- The degree of the zero polynomial is defined to be zero. says- The degree of the zero polynomial is $-\infty$. I am totally confused and want to know which one is true or are all true?
I wonder why the degree of the zero polynomial is $-\infty$ ? I heard that, it is $-\infty$ to make the formula $\deg(fg)=\deg(f)+\deg(g)$ hold when one of these polynomials is zero. However, if that was the only reason we could have said that it is $\infty$ instead.
How could the following be? require "bigdecimal/util" 86.26.to_d == 86.26 # => false 86.25.to_d == 86.25 # => true
Consider the following code: 0.1 + 0.2 == 0.3 -> false 0.1 + 0.2 -> 0.30000000000000004 Why do these inaccuracies happen?
Is there any English word referring to a single-sex school (either all-male or all-female schools or colleges)?
A school where both boys and girls study is called co-ed (co-education) What is the name for the school where only males study? (Calling it a male school seems a bit awkward)
I found a USB cable with three male connectors from somewhere. I'm sorry I don't know what it's called. I've never seen any such cable before. Tried searching on the Internet and many people, couldn't find any answers. What may be the possible use(s) of this? A picture of the cable:
I was reorganizing my desks and found two different triple-ended USB cables. I don't know their origin or purpose. I have never seen triple-ended USB cables before. What are they used for?