body1
stringlengths
20
4.1k
body2
stringlengths
23
4.09k
I just started reading Lie Algebras in Particle Physics by Howard Georgi and I'm finding it frustratingly fuzzy. What I mean is that he often makes non-trivial statements without proof, is imprecise with definitions, and so on. However, what other books I can find seem to swing a bit too far the other way, and I simply don't have time for the most comprehensive and rigorous treatments. The ideal book would be somewhere in the middle. It should be a quick read, but prove or sufficiently motivate important statements. And it should cover the essentials needed in introductory theoretical particle physics; i.e. basic representation theory, basic Lie theory, and something about $SU(2)$ and $SU(3)$. Are there any good alternatives?
I am looking for a good source on group theory aimed at physicists. I'd prefer one with a good general introduction to group theory, not just focusing on Lie groups or crystal groups but one that covers "all" the basics, and then, in addition, talks about the specific subjects of group theory relevant to physicists, i.e. also some stuff on representations etc. Is Wigner's text a good way to start? I guess it's a "classic", but I fear that its notation might be a bit outdated?
I am trying to construct a proof and would like to know if I have started it correctly. The proof is as follows. "Prove that for every odd integer n, there is a group with exactly n elements of order 2." Written more compactly I have it as: "$\forall n \in \mathbb{Z^{+odd}}, \exists$ a group G with exactly n elements of order 2." To prove this universal statement, I figure I should disprove the negation. Thus I have: Assume: "$\exists n \in \mathbb{Z^{+odd}} , \nexists$ a group G with exactly n elements of order 2." I am new to proofs and would like to know if the beginnings of this proof are sound. Thanks in advance.
Prove that for every odd integer n, there is a group with exactly n elements of order 2. I am new to abstract algebra and proofs in general. Proving existence is difficult for me, but I will show what I have. $$n = 2k + 1$$ $$k \in \mathbb{Z^+}$$ $$\exists G \supset H = (a_1 , a_2 , ..., a_n, e)$$ $$s.t. |a_1| = |a_2| = ... = |a_n| = 2$$ My instinct is to use Lagrange's Theorem, although I would like to try another method to prove this as we have not gone over cosets in class yet. If someone could just give me a hint of how to start, it would be very beneficial. Thank you.
I need some help in order to understand the type of visa required to travel through Germany airports. My itinerary to india is Boston-Munich-Mumbai and my return flight is Mumbai-Munich-Frankfurt-Boston. I hold indian passport and have US visa in the form of approved I797 but passport is not stamped while going from US to India. The plan is to get passport stamped and take the return flight as mentioned above. While going from US to India, I just have one layover in Munich but while coming back I have two lay overs- one in Munich and other in Frankfurt (both in the same country). Do I need a German visa for my returning flight to US? I am really confused- Do I need a airport transit visa? or Do I need a visitor visa? Basically what type of visa I need to get for my round trip- US to india, and India to US. The more I read, the more I get confused. I tried calling German embassy in boston and also Lufthansa airline but I don't have any response yet. The whole terminology is confusing to me- Schengen vs transit or if they are same? Can anyone please provide me the response based on my case and if someone in the same situation or have traveled in the past.
I found many related questions on this site but I am still not sure about the rules. How can I decide if I need a visa to transit? Schengen members as of May 2021 are as follows: Austria Belgium Czech Republic Denmark (excluding Greenland and the Faroe Islands - but an open border with the Schengen Area is maintained) Estonia Finland France (excluding overseas departments and collectivities) Germany Greece Hungary Iceland Italy Latvia Liechtenstein Lithuania Luxembourg Malta Netherlands (excluding Aruba, Curaçao, Sint Maarten and the Caribbean Netherlands) Norway (excluding Svalbard) Poland Portugal Slovakia Slovenia Spain (except Ceuta and Melilla) Sweden Switzerland
When i put the command \pause on my beamer, the subsections are "white completely" (before appearing) while i want that they are "shaded" ! Do you have a solution for that ? Thanks in advance and sorry for my english
I tried all overlay options like hide, uncover, visible but didn't get solution. I don't know how to partially hide the content that will display in next slide. Here is the example what I really want to do. In which the bullet 2 content will display in next slide but partially hide or a shadow in current slide.
One of the ways replacing a string with sed can be done as follows: sed -i 's/old_str/new_str/' file.txt However if replace.sh is sed -i 's/$1/$2/' $3 the command ./replace.sh old_str new_str file.txt doesn't seem to work -- after making replace.sh executable of course. Why is that? I am aware rpl does exactly the same as I intend to do with replace.sh, but I'd like to understand why is it not working.
I want to do: cat update_via_sed.sh | sed 's/old_name/new_name/' > new_update_via_sed.sh in my program. But I want to use variables, e.g. old_run='old_name_952' new_run='old_name_953' I have tried using them but the substitution doesn't happen (no error). I have tried: cat update_via_sed.sh | sed 's/old_run/new_run/' cat update_via_sed.sh | sed 's/$old_run/$new_run/' cat update_via_sed.sh | sed 's/${old_run}/${new_run}/'
What makes the journal "prestigious" in the first place? I can't myself find any sensible answer. One candidate reason is that some journals have better reviewers. But reviewers are usually not paid, so if it were true that the good reviewers flock to these select few journals, they must be doing so because those journals were prestigious or attractive in some sense in the first place, and so we are back at our original question. Another possible reason is that some journals only publish papers of a high quality. This seems wrong as well. For example, if I decided to create a journal which only published extreme-super-duper-mega-high quality papers, nobody would care about it. Rather it seems to be the other way around: these journals publish the best papers because they are prestigious and therefore receive the attention of the best academics and their best papers. So again, we are back at the original question. A third reason could be readership, but, again, the readership is a consequence of the prestige the journal already possesses. We still don't know where it came from.
Journals like Nature and Science have impressive impact factors. How and why did these top journals become top journals? Why are they able to sustain their statuses?
In order to clean some string, I have to remove some substring that contains some special UTF-8 characters. example: source = "Skoda" to_be_clean = "Škoda Rapid" I need to replace from to_be_clean the string source by nothing. Obviously, the to_be_clean string contains some special character. Is there a way to do this task simply. Here is how I am doing it today. output = to_be_clean.replace(source + ' ', '') I was thinking about a regular expression but I need to list all the possible characters.
I have a Unicode string in Python, and I would like to remove all the accents (diacritics). I found on the web an elegant way to do this (in Java): convert the Unicode string to its long normalized form (with a separate character for letters and diacritics) remove all the characters whose Unicode type is "diacritic". Do I need to install a library such as pyICU or is this possible with just the Python standard library? And what about python 3? Important note: I would like to avoid code with an explicit mapping from accented characters to their non-accented counterpart.
I would like to install Chrome on Ubuntu 14.04 32bit, but it's no longer supported.
I tried to install using following command for 32-bit system. wget https://dl.google.com/linux/direct/google-chrome-stable_current_i386.deb But I got an error: Resolving dl.google.com (dl.google.com)... 216.58.199.174, 2404:6800:4009:807::200e Connecting to dl.google.com (dl.google.com)|216.58.199.174|:443... connected. HTTP request sent, awaiting response... 404 Not Found 2016-06-30 20:05:59 ERROR 404: Not Found.
Is it in the direction of the velocity ? If it is, can anybody describe it somehow that matches my physical feeling? How the shear stress affects another layer of fluid ? I faced a question today that fluid is moving alongside a horizontal tube and and if we write momentum equilibrium we must omit gravity force because it is not in the direction of the velocity, but what about shear stress ?
One book defines the shear stress $\tau$ of a (Newtonian) fluid as $$\tau = \eta \frac{\partial v}{\partial r} $$ where $\eta$ is the viscosity. There is not much context, so I've made some guesses. Are my following assumptions correct? $v$ is the velocity of the flow line, parallel to the wall. $r$ is the distance of the flow line from the wall. the flow must be laminar for the above to hold. (Otherwise, what would $v$ mean?) the "wall" must be a tube for the above to hold. (Otherwise, what would $r$ mean?)
I have the following image... ...that I'm trying to get a vector outline for in a similar way to the Illustrator Offset command. I'm looking to have a finished vector look similar to this... (Note: This is simply a stroke layer style that has been added to the original) The two outlines must be vector shapes. Is there anything in PhotoShop that will allow me to do this?
I drew paths thinking i was drawing a shape but later realized it is only a path. Now i could create a temporary shape like a box and paste this in and delete the box path. But just as there is a option to convert path to selection, is there an option to convert the selected path into shape?
I'm from mathematical background, I want to LEARN tensor as well as relativity(mathematical approach), which book is helpful for me?and what do I need to know first to better understand those topics? Your help will be highly appreciable...
I am currently a 3rd year undergraduate electronic engineering student. I have completed a course in dynamics, calculus I, calculus II and calculus III. I've started self studying tensor calculus, my sources are the video lecture series on the YouTube channel; "MathTheBeautiful" and the freeware textbook/notes; "Introduction to Tensor Calculus" by Kees Dullemond & Kasper Peeters. Other textbooks go much more in depth in advanced math topics. I have been through the first 3 chapters and watched the first 5 videos, but I don't seem to understand the content. I don't know what I should take from these lectures and notes and what part of the work to focus on in order to start practicing as soon as possible. I want to learn tensor calculus in order to study more advanced mathematics and physics such as; General Relativity, Differential Geometry, Continuum Mechanics etc. I've also seen many other textbooks on continuum mechanics and tensor analysis for mathematicians/physicists. All of these sources seem quite different and seem like I require much more advanced topics in mathematics in order to understand. How should I approach tensor calculus? through a physics or through a mathematics perspective? From what I've seen, tensor calculus seems very abstract and more towards the proving side of the spectrum (like a pure mathematics subject), it doesn't look "practicable" as appose to other calculus courses where I could go to any chapter in the textbook and find many problems to practice and become familiar with the concept. Is my current knowledge in calculus and physics + dynamics enough, or do I need to first learn a few more concepts in mathematics in order to begin attacking tensor calculus problems?
I'm trying to do this exercise: Let $n \in \Bbb{N}$. Let $x_1,x_2,\ldots,x_n$ be positive real numbers such that $\prod_{i=1}^n x_i = 1$. Prove that $\sum_{i=1}^n x_i \ge n$ Here is my attempt: Let $S = \{n \in \Bbb{N} | \sum_{i=1}^n x_i < n \}$ and $S \ne \emptyset$. By the well ordering principle, S has a least element. If $ n = 1$, we have: $\prod_{i=1}^2 x_i = 1 \implies x_2 = \frac{1}{x_1} \implies \sum_{i=1}^2 x_i = \frac{x_1^2+1}{x_1}$ and $\frac{x_1^2+1}{x_1} \ge 2 \iff x_1^2+1 \ge 2x_1 \iff x_1^2 -2x_1 +1 \ge 0 \iff (x_1 - 1)^2 \ge 0$ Therefore 1 is not the least element of S. Let k be the least element of S. We can conclude the following: $k \ne 1 \implies k \ge 2 \implies (k-1) \in \Bbb{N} $ (1) $\sum_{i=1}^k x_i < k \implies \sum_{i=1}^{k-1} x_i < k - x_k$ (2) If $\prod_{i=1}^k x_i = 1$ there are 3 cases: (i). $\prod_{i=1}^{k-1} x_i = 1$ and $x_k = 1$ (ii). $\prod_{i=1}^{k-1} x_i < 1$ and $x_k > 1$ (iii). $\prod_{i=1}^{k-1} x_i > 1$ and $x_k < 1$ Assuming cases (i) or (ii) would imply a contradiction with out assumption that k is the least element because we would have: $\sum_{i=1}^k x_i < k \implies \sum_{i=1}^{k-1} x_i < k - x_k \le k-1$ So $(k-1) \in S$ and $S = \emptyset$ In case (iii) I'm stuck. Can we derive a contradiction assuming that $\prod_{i=1}^{k-1} x_i > 1$ and $x_k < 1$ ??? Or is there another approach to this problem? Any help will be appreciated.
Please give me the proof for the following: Let $a_1,\,a_2,\,\dots\,a_n$ be $n$ positive real numbers whose product is equal to $1$. Prove that $$a_1+\cdots+a_n \geq n$$ and that the equality sign holds only if every $a_k$ is equal to $1$.
$$\nabla\cdot(\mathbf{u}\times\mathbf{v}) = (\nabla\times\mathbf{u})\cdot\mathbf{v} - (\nabla\times\mathbf{v})\cdot\mathbf{u}$$ Hi, the above is a vector equation, where u and v are vectors. I am trying to prove this identity using index notation. I am able to get the first term of the right-hand side, but I don't see where the second term with the minus in front comes from. Any help? Thanks! EDIT: I don't think this is a duplicate of that thread since the question in that thread has a scalar f and a vector v, whereas my problem has two vectors u and v, and no scalars.
Verify the vector identity: $\nabla \cdot (a \times b) = b \cdot \nabla \times a - a \cdot \nabla \times b $ Given that: $a = (R_a, S_a, T_a)$, $b = (R_b, S_b, T_b)$ and $\nabla = (\frac{\partial} {\partial x},\frac{\partial} {\partial y},\frac{\partial} {\partial z} )$. Where $R_i, S_i, T_i$ have continuous partial derivatives. I attempted it on paper but cannot get it to work. Can anyone show me how this is done? My working: LHS: $\nabla \cdot (a \times b) = \frac{\partial}{\partial x}(S_a T_b - S_b T_a) + \frac{\partial}{\partial y}(T_a R_b - R_a T_b) + \frac{\partial}{\partial z}(R_a S_b - R_b S_a) $ RHS: $\nabla \times a = (\frac{\partial}{\partial y} T_a - \frac{\partial}{\partial z} S_a)\hat i - (\frac{\partial}{\partial x} T_a - \frac{\partial}{\partial z} R_a)\hat j + (\frac{\partial}{\partial x} S_a - \frac{\partial}{\partial y} R_a)\hat k$ $b \cdot (\nabla \times a) = R_b(\frac{\partial}{\partial y} T_a - \frac{\partial}{\partial z} S_a) - S_b(\frac{\partial}{\partial x} T_a - \frac{\partial}{\partial z} R_a) + T_b(\frac{\partial}{\partial x} S_a - \frac{\partial}{\partial y} R_a)$ Now I computed the other part of the RHS as well however I can't see how I would be able to maninipulate it into the LHS. Anyone have any idea?
My desktop PC keeps waking up every time I put it to sleep. I put it to sleep, it wakes up. I put it to sleep again, it wakes up. I put it to sleep once more, it wakes up! It only stays asleep for about half a minute and then just wakes up again. Why is it doing that? I mean I know that Microsoft was trying to be smart with Windows 8 (on so many levels!) and they have put in place some wake timers so that the PC may wake up in order to install updates or perform some "maintenance" tasks. But I have already been over those settings. They are disabled, and there are no pending maintenance tasks. Have a look: Microsoft Windows [Version 6.3.9600] (c) 2013 Microsoft Corporation. All rights reserved. C:\Windows\system32>powercfg /lastwake Wake History Count - 1 Wake History [0] Wake Source Count - 0 C:\Windows\system32> This output is unintelligible! Not human! If a specific service or process has waken the PC, this command should point it out. But nope, it just says 0. Thanks Microsoft! That says a lot! These are my currently set wake timers: Microsoft Windows [Version 6.3.9600] (c) 2013 Microsoft Corporation. All rights reserved. C:\Windows\system32>powercfg /waketimers There are no active wake timers in the system. C:\Windows\system32> That's right, none! These devices are armed to wake the PC: C:\Windows\system32>powercfg /devicequery wake_armed HID-compliant mouse (002) Realtek PCIe GBE Family Controller Realtek PCIe GBE Family Controller #2 HID Keyboard Device (001) Logitech Optical Gaming Mouse G400s (001) C:\Windows\system32> Here is my power configuration setting: Here is my Action Center setting: As can be seen, all the relevant settings have been set to disabled. So what's the problem then? How do I stop this? Update: It appears now that this has nothing to do with network devices waking my computer, WOL (wake on lan). I have ensured that all my NICs have WOL enabled only for magic packet. If there was any wakes caused by WOL, there should be no wakes caused by WOL wakes anymore. Instead, this appears to be a Windows maintenance issue. I will post my findings at the linked duplicate question page.
When I put my computer into sleep mode, it will wake up while I'm away from it. There's nothing near the computer that could move the mouse or accidentally press a button and I have no idea what might be causing it. I tried checking what woke it, apparently LASTWAKE only tells me that it has been in sleep mode, not what woke it up. I also couldn't find anything in my Power Options regarding Sleep that seems off. Poking around in the Event Viewer I notice the following: The Power-Troubleshooter event at the top notes the following: The system has returned from a low power state. Sleep Time: ‎2012‎-‎10‎-‎27T11:31:53.408927000Z Wake Time: ‎2012‎-‎10‎-‎27T12:25:51.887029300Z Wake Source: Unknown So does anyone have an idea to find out what might be causing it and how I can prevent my computer from randomly waking up?
I am creating a wordpress site (Arabic). It shows arabic text in home page. but when I include footer page the Arabic text in footer shows ?????. Arabic text is displaying properly in my home page. Problem occurs on included page.I have included <META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=iso-8859-6"> in my inluded footer page. But no luck.Can somebody please help me?
I'm setting up a new server and want to support UTF-8 fully in my web application. I have tried this in the past on existing servers and always seem to end up having to fall back to ISO-8859-1. Where exactly do I need to set the encoding/charsets? I'm aware that I need to configure Apache, MySQL, and PHP to do this — is there some standard checklist I can follow, or perhaps troubleshoot where the mismatches occur? This is for a new Linux server, running MySQL 5, PHP, 5 and Apache 2.
I have a CloudPage that is populating a Journey when people sign up to simply send them an email. The problem is that when they fillout the form since they are not a member of our All Subscribers list they are being errored out with this message. Failed - Email.JourneyBuilder.Activities.EmailActivity.EmailAddress: Error binging data bound member I tried re configuring the data extension to make sure the field type was set to email, as well as having the data extension the CloudPage drops into set as sendable. I've also made sure I was sending into a publication list as apposed to All Subscribers, but I am still running into these errors. I have other Journeys running that can execute email sends but this is the only CloudPage Journey we have running. Any help would be greatly appreciated!
In my journey, entrants get admitted into it, but emails arent been sent. When I check the history, they have the following status: Failed: Email.JourneyBuilder.Activities.EmailAddress: Error binding data bound member What does this mean and how do I resolve it?
I replaced my 250Gb HDD with a 500Gb SSD. The problem is that after installing my new SSD and copying all my stuff onto it, my SSD reports it has a single partition of 250Gb and free space of 250Gb instead of a single 500Gb partition. This has more than likely come about because I cloned my SSD from my old HDD (it seemed like a good idea at the time!). If I open Disk Utility, select my SSD and click the Partition button it shows the free space and the SSD with a resize control on the border between the two. The resize control won't let me drag it to the left (clockwise into the free space) no matter how much I try. It also won't let me create a new partition in the free space. My OS is High Sierra and the format is APFS. I've had a look at some third party tools but haven't found any that work with APFS. All the googling I've done on this subject suggests that Disk Utility doesn't work with all the features of APFS. It seems it's possible to increase the size of a partition from the command line in Terminal but I can't find any instructions that deal specifically with my scenario. Here's the output from the diskutil list command: ...and the output from sudo gpt -r show /dev/disk1: I've tried to resize the container using: diskutil apfs resizeContainer disk0s2 500g but this command throws an error: The size (500g) must not be greater than the partition map allocatable size Can anyone help? Ideally I'd like to have a single 500Gb partition.
Hi I am having issues trying to resize my Mac OS partition, I previously had a very large recovery partition almost 100gb as a result of removing my linux installation, I since resized this to 650mb. The problem is I am unsure on how to increase the size of my main Mac OS partition as I have no experience with this new container disk stuff. Here is what diskutil list shows: /dev/disk0 (internal, physical): #: TYPE NAME SIZE IDENTIFIER 0: GUID_partition_scheme *251.0 GB disk0 1: EFI EFI 209.7 MB disk0s1 2: Apple_APFS Container disk1 150.4 GB disk0s2 3: Apple_HFS Recovery HD 650.0 MB disk0s3 /dev/disk1 (synthesized): #: TYPE NAME SIZE IDENTIFIER 0: APFS Container Scheme - +150.4 GB disk1 Physical Store disk0s2 1: APFS Volume Mac OS 122.1 GB disk1s1 2: APFS Volume Preboot 20.3 MB disk1s2 3: APFS Volume Recovery 506.6 MB disk1s3 4: APFS Volume VM 1.1 GB disk1s4 As you can see I resized the Recovery HD partition but the container is still 150gb. I also tried the following command to try reduce the container size: sudo diskutil apfs resizeContainer disk0s2 1g jhfs+ Media 0b But I get the following error: Error: -69605: There is not enough free space in the APFS Container for this operation Additionaly within Disk Utility app if I view the partitions, it shows I have 99.6 GB of "Free space" but I am unable to resize the Mac OS partition as previously mentioned. Any help would be greatly appreciated, Thank you
If G contains a normal subgroup $N \cong \mathbb{Z}_2$ and $G/N \cong \mathbb{Z}$, then $G\cong \mathbb{Z}\times \mathbb{Z_2}$. I'm trying to create an isomorphism $\phi : G \rightarrow \mathbb{Z}\times\mathbb{Z_2}$ as $g \mapsto (gN, ??)$. What can I use for my second coordinate?
Let $G$ be a group containing a normal subgroup $H \cong \mathbb{Z_2}$ such that $G/H$ is infinite cyclic. Then $G \cong \mathbb{Z} \times \mathbb{Z_2}$. Since $G/H$ is infinite cyclic it's isomorphic to $\mathbb{Z}$. And since $H \cong \mathbb{Z_2}$, we have $G/H \times H \cong \mathbb{Z} \times \mathbb{Z_2}$. So the question now is can we make $G/H \times H \cong G$ (without any recourse to the Isomorphism theorems please)? Any hints appreciated.
I'm teaching myself C# and I am up to studying the try, catch and finally. The book I'm using is discussing how the finally block runs regardless of whether or not the try block is successful. But, wouldn't code that is written outside of the catch block be run anyway even if it wasn't in finally? If so, what's the point of finally? This is the example program the book is providing: class myAppClass { public static void Main() { int[] myArray = new int[5]; try { for (int ctr = 0; ctr <10; ctr++) { myArray[ctr] = ctr; } } catch { Console.WriteLine("Exception caught"); } finally { Console.WriteLine("Done with exception handling"); } Console.WriteLine("End of Program"); Console.ReadLine(); } }
Whatever is inside finally blocks is executed (almost) always, so what's the difference between enclosing code into it or leaving it unclosed?
Find the general solution $(x, y)$ ∈ $\mathbb Z × \mathbb Z$ for the system of equations $355x − 113y = 1$ ... eq$1$ $355x + 113y = 1$ ... eq$2$ You need one parameter $t ∈ \mathbb Z$ to describe the general solution. My attempt: Euclid's Algorithm: gcd($355,113$) $= 1$ $1 = 355(-7)+113(22)$ So for eq$2$ $(x,y)=(-7,22)$ And for eq$1$ $(x,y)= (-7,-22)$ So general solution is $(-7,22t)$, where $t$={$-1,1$} Is my answer correct? If not, please how do we solve this?
Find the general solution $(x, y)$ ∈ $\mathbb Z × \mathbb Z$ for the system of equations $$355x − 113y = 1 \tag 1$$ $$355x + 113y = 1 \tag 2$$ You need one parameter $t ∈ \mathbb Z$ to describe the general solution. My attempt: By Euclid's Algorithm: $\operatorname{gcd}(355,113)=1$ $1 = 355(-7)+113(22)$ So for equation $2, (x,y)=(-7,22)$. And for equation $1, (x,y)= (-7,-22)$. So the general solution is $(-7,22t)$, where $t=\{-1,1\}.$ Is my attempt correct? If not, please can you show me how do we solve this?
private PreconfigGroupOpenLPolicyRulesService openlApi; @Override public Object[] getPackageEligibility(IRulesRuntimeContext context, Dimension dimension) { return openlApi.PackageEligibility(context, dimension); } I am new to jUnits. Can anyone help me to write test case for method getPackageEligibility. Which are all i need to do @Mock. i tried PreconfigGroupOpenLComponentService preconfigGroupOpenLComponentService = new PreconfigGroupOpenLComponentService(); @Mock PreconfigGroupOpenLPolicyRulesService openlApi; @Mock IRulesRuntimeContext context; @Mock Dimension dimension; @Test public void testGetPackageEligibility() { Object[] arg = preconfigGroupOpenLComponentService.getPackageEligibility(context, dimension); assertNotNull(arg); } But getting java.lang.NullPointerException at com.exigen.eis.preconfig.policy.group.services.impl.PreconfigGroupOpenLComponentService.getPackageEligibility(PreconfigGroupOpenLComponentService.java:32) at com.exigen.eis.preconfig.policy.group.services.impl.PreconfigGroupOpenLComponentServiceTest.testGetPackageEligibility(PreconfigGroupOpenLComponentServiceTest.java:28)
How do I unit test (using xUnit) a class that has internal private methods, fields or nested classes? Or a function that is made private by having (static in C/C++) or is in a private () namespace? It seems bad to change the access modifier for a method or function just to be able to run a test.
I am using shp2pgsql in a bash script to import shapefiles into postgres. I can successfully do this for shapefiles with hundreds of records however shapefiles with tens of thousands of records (in this case ~40,000) hangs so I have to use the postGIS shapefile importer in pgAdmin (which works ~30-45 seconds to complete). I realize it's a substantial jump in magnitude regarding the number of records. Is it possible if I wait long enough it will succeed? what are the runtime/data limits for shp2pgsql?
I have to import large Shapefiles (> 1 million records) into PostGIS, and I have been wondering about the best way to do it. In my question I used the word "hack", instead of tool, on purpose because I think this is not so much a matter of which tool, but which set of steps, or configuration settings to use. So far, I have tried the plugin (QGIS), the Postgis tool and the GDAL tool. You can view my full review on post. So far, I find all of them really unresponsive, when dealing with a large dataset. I was wondering if someone experienced a similar issue, and if you could share something about the approach.
I have a situation with two structures that are combined as members of a larger structure. The first one is 44 bytes, and the second one is 1047. The second structure ends with a char. Excerpt: typedef struct { ... (total of 44 bytes, all members naturally aligned) } StructA; typedef struct { ...lots of stuff totaling 1046 bytes char flag; } StructB; typedef struct { StructA a; StructB b; } StructC; Printing sizeof of StructA and StructB produces the expected sizes of 44 and 1047 respectively. Printing sizeof StructC produces 1092, which is 44 + 1047 + 1. It seems pretty clear to me that the compiler is padding the overall structure because of the single byte at the end of StructB. But it's at the end...there are no following members that require alignment. So why is it padding StructC? And why does it not pad StructB the same way? This is built with Microsoft Visual Studio 2013; we're also cross-platform, but I don't yet know if GNU compiler on Linux treats this the same or not. If it doesn't, that will also be a concern. Thank you, Doug Follow up: My question was marked as a duplicate but the referral doesn't answer the specific issue I'm trying to address, which is specifically why padding was added at the end of the structure in one circumstance, but not in the other.
Why does the sizeof operator return a size larger for a structure than the total sizes of the structure's members?
I ran mkfs.vfat /dev/sdb (whole device, not just one partition) on my backup drive, ironic, right. Is there any way to recover my files.
When I was installing Mint Debian edition unlike the classic edition, the installation automatically formated my home partition when I did not specify to format. So the formatting previously was ext4 as is now. I believe the data is still there as it was a quick format. I have now booted the computer up on a live USB to prevent writing on it. Ran testDisk. Is there anyway to recover to a previous superblock so i can recover my data?
I'm having some trouble using ID3D11DeviceContext::Map() correctly. Here's the whole function so far: Color Graphics::GetPixel(int x, int y) const { //Temp frame buffer descriptor; CD3D11_TEXTURE2D_DESC pFrameDesc; pFrameDesc.Width = WindowWidth; pFrameDesc.Height = WindowHeight; pFrameDesc.CPUAccessFlags = D3D11_CPU_ACCESS_READ; pFrameDesc.Format = DXGI_FORMAT_B8G8R8A8_UNORM; pFrameDesc.MipLevels = 1u; pFrameDesc.ArraySize = 1u; pFrameDesc.SampleDesc.Count = 1u; pFrameDesc.SampleDesc.Quality = 0u; pFrameDesc.Usage = D3D11_USAGE_DEFAULT; pFrameDesc.BindFlags = D3D11_BIND_UNORDERED_ACCESS; pFrameDesc.MiscFlags = 0u; // Create temp frame buffer(2d texture) wrl::ComPtr<ID3D11Texture2D>pFrame = nullptr; HRESULT hr = pDevice->CreateTexture2D(&pFrameDesc, nullptr, &pFrame); GFX_THROW_INFO(hr); hr = pSwapChain->GetBuffer(0, __uuidof(pFrame), &pFrame); GFX_THROW_INFO(hr); D3D11_MAPPED_SUBRESOURCE map; map.RowPitch = WindowWidth * 4; map.DepthPitch = WindowHeight * 4; //Throwing here, CPU access flags problem. hr = pContext->Map(pFrame.Get(), 0u, D3D11_MAP_READ, 0u, &map); GFX_THROW_INFO(hr); pContext->Unmap(pFrame.Get(), 0u); return { 0.0f, 0.4f, 0.0f, 0.0f }; } I'm getting an exception thrown at pContext->Map() "Map cannot be called with MAP_READ access, because the Resource was not created with the D3D11_CPU_ACCESS_READ flag. " Which is confusing as the newly created resource has the D3D11_CPU_ACCESS_READ flag enabled. This is also true If I try MAP_WRITE and change the access flags to match. I've also tried ORing the flags together with no luck. The ultimate use of this function is to be able to create a CPU side array of Color objects (Colors are currently a struct of four floats) Which I can then send onto the NewTek NDI sdk. But I feel it would also be useful for saving screen shots, creating colour pickers etc. Any ideas welcome!
I want to get access to a texture's pixel color data on the CPU. When trying to map the texture, I get E_INVALIDARG in return from ID3D11DeviceContext::Map. ID3D11ShaderResourceView* resourceView; //represents my texture, already loaded up //... //Getting the resources of the texture view... ID3D11Resource* res = nullptr; ID3D11Texture2D* tex = nullptr; resourceView->GetResource(&res); res->QueryInterface(&tex); D3D11_TEXTURE2D_DESC desc; tex->GetDesc(&desc); //Correct data gets filled out D3D11_RESOURCE_DIMENSION dim; res->GetType(&dim); //value gets set as Texture2D which it should D3D11_MAPPED_SUBRESOURCE mappedResource; HRESULT h; h = context->Map(tex,0,D3D11_MAP_READ,0,&mappedResource); //This always fails h = context->Map(res,0,D3D11_MAP_READ,0,&mappedResource); //This also fails The idea is that I keep only shaderResourceViews for my textures, because that is all I needed until now, and get the relevant resources here. I tried mapping as WRITE_DISCARD also, but to no success. I am really confused, because I never had any problem with mapping constant buffers and vertex buffers. I seem to be certainly missing something? By the way, I am using Wic Texture loader and DDS Texture loader for the DirectXTex toolkit, and tried this code for png, dds textures, with and without mip-maps.
I'm referring to the section in our editing help. It includes this helpful line: You can use either , like lang-cpp or lang-sql, or you can specify a tag, and the syntax highlighting language associated with this tag will be used: However, the link takes us to an answer on , which contains no list of prettify language codes. That answer in turn links to the FAQ question , which does contain the list, and which the previous question is closed as a duplicate of. There's no value now in linking to that intermediate page, so could the help article be updated to directly link the FAQ question?
Reading the help center article on syntax highlighting, one of the paragraphs within it reads: You can use either , like lang-cpp or lang-sql, or you can specify a tag, and the syntax highlighting language associated with this tag will be used: Note the link in there, which goes to . Problem is, a long time ago we removed the list of options from several questions/answers across meta Stack Exchange because it was a pain trying to keep all of them updated. It makes a lot more sense to just have one list that we keep updated, and the most logical place for that list was in the , which is where it now resides. Can the link in the help center be updated to point directly to the list, rather than to a post that explains that the list has been moved?
I have copied the div element to the alert box. Now when I pressed ok button is it possible the text is copied to the user's clipboard. Here is the code for reference: $(document).ready(function(){ $("#bn").click(function(event){ $(alert($('#demo').text()) }); });
What is the best way to copy text to the clipboard (multi-browser)? I have tried: function copyToClipboard(text) { if (window.clipboardData) { // Internet Explorer window.clipboardData.setData("Text", text); } else { unsafeWindow.netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect"); const clipboardHelper = Components.classes["@mozilla.org/widget/clipboardhelper;1"].getService(Components.interfaces.nsIClipboardHelper); clipboardHelper.copyString(text); } } But in Internet Explorer it gives a syntax error. In Firefox, it says unsafeWindow is not defined. A nice trick without using :
I played on the xbox 360 edition of skyrim with the dawnguard and dragonborn DLC. I deleted my progress last summer by accident that was on my flash drive while clearing space. I haven't been playing since that. I got a hard drive so I can store that data again. I want to play it again but I don't want to start over because I had the best stuff and I invested a lot of time in it. If there is a way to retrieve that progress in any sort of way that doesn't cost money please tell me. I wouldn't prefer to use money but if it is the only than I'll have to resort to that.
I have got really far in my second profile in Skyrim, level 41. It took a long time to get back to that level, because I had got a game-breaking bug on my last profile and I erased it by accident as well as my other messed up profile. Is there anyway to get my saved data back on the Xbox 360? If there isn't, I will not play Skyrim again for a very long time and I have no other option. Please help.
I understood that size of host id in the class c network is 8 bits(1 Octet) After started exploring about private networks, in the below link The host id size of the IP address range belongs to the class C network is mentioned in as 16 byte 192.168.0.0 - 192.168.255.255 (16-bit block private address) My Assumption: Class full network is applied for both private and public IP addresses. That is ifthe IP starts with 192.168.x.x is class c network and the size of the host id in the class full network is always 8(1 octet). Is my assumption is wrong or any theory behind it?
This is a about IPv4 Subnets. Related: How does Subnetting Work, and How do you do it by hand or in your head? Can someone explain both conceptually and with several examples? Server Fault gets lots of subnetting homework questions, so we could use an answer to point them to on Server Fault itself. If I have a network, how do I figure out how to split it up? If I am given a netmask, how do I know what the network Range is for it? Sometimes there is a slash followed by a number, what is that number? Sometimes there is a subnet mask, but also a wildcard mask, they seem like the same thing but they are different? Someone mentioned something about knowing binary for this?
After re-watching the Tony vs Thanos scene again, a thought came to mind and made me wonder. At no point did Doctor Strange ever pause time and simply deal with Thanos and proceed further. This would have obviously been the easy way out. Or at least whilst paused, he could have used the sling ring to cut Thanos' head off. I do note about the many different outcomes that he saw, but I still see this as a possibility.
Why didn't Doctor Strange wind back the clock way before Thanos got any of the Infinity Stones?
On Ubuntu, when running sudo apt update; sudo apt upgrade, why sometimes it asks me to restart my OS and sometimes not? What do the packages that have that restart requirement have in common? Is it not possible to update such a package without restart OS requirement? If I am correct, sudo apt update; sudo apt upgrade can also update/upgrade kernel. Does kernel update/upgrade also require OS restart? Thanks. I often keep my Ubuntu up indefinitely long, because I am always running some programs and I don't want to interrupt them.
I experience that my Ubuntu Linux requires a restart every now and then and also that it needs restart more often than in the old days (maybe it's because it updates more). I understand that updating the kernel forces a reboot but is that a convenience and technically feasible to update without rebooting and only complicated? Is it something that is technically impossible to update while the system is running? "The system will go down for maintenance now...." I understand that a BIOS update forces a reboot but I don't understand why it is absolutely necessary or if that is for convenience and making it much easier to update. Reading a , there were not convincing answers. I believe that it is running binaries that should be replaced.
Let $K$ be a compact set and consider $\mathbb{R}^n\setminus K$. It is easy to show that, if $n\geq 2$, the set $\mathbb{R}^n\setminus K$ contains one (and only one) unbounded connected component. Could someone can help m to show that the remaining connected components of $\mathbb{R}^n\setminus K$ are in finite number? Alternatively, also some references will be well accepted.
Let $X$ be a connected, locally compact space and let $K$ be a compact subset of $X$. Is the number of connected components of the complement $X\setminus K$ finite? If it is not, are there some hypotheses over $X$ for finiteness of connected components?
If I put the cylinder on the bottom i replace F2 with normal force N. But it will be at most equal to F1 plus the cylinder weigh N=F1+$\rho$gV. So how can it get a bigger boost from the bottom to be able to float?
Let's say a 10N cube (in air, on Earth) rests flat on a scale at the bottom of a tank of water, and the scale reads 8N, so there is 2N of buoyant force on the cube. How does the buoyant force manifest itself on the cube? I assume the force is normal to the surface of the scale, but if there isn't any water under the cube, how does the water push up on the cube?
While I can easily set up a style template for lists to have the "keep with next" paragraph option, it is usually convenient to have the very last item of a list not having this option such that a page break between the list and the following text is actually permitted. But is there any way to have this automatically applied instead of having to manually change the last item's pagination option?
I'm writing specifications using Word documents with a general style like this: # Heading 1 intro paragraph * bullet1 * bullet2 * bullet3 # Heading 2 intro paragraph * bullet1 * bullet2 # Heading 3 intro paragraph * bullet1 * bullet2 * bullet3 * bullet4 * bullet5 I want each heading, intro paragraph, and associated bullets to stay together whenever possible. As such, I have styles for each with the Paragraph option "Keep with Next" checked. However, this results in everything sticking together too tightly. To fix it I currently go to the last bullet in each list and change its style to one that does not have "Keep with Next" checked. For example, the bullets have a style "ReqBullet" and I create another style "LastReqBullet" that inherits from "ReqBullet", but which has "Keep with Next" turned off. (I could alternatively override the setting on each bullet, but doing it via a style makes it easier to apply, and also easier to see where it is set.) Using manual style application is slightly cumbersome, and error-prone. If I add a new item to the end, I have to swap styles. Often I will forget to apply the style until I realize that the formatting is wonky. The question Is there a way hidden in the bowels of the Style settings to say either: Keep this paragraph with the next but only if it's the same style, or I don't care what the previous paragraph told you, do NOT keep me with it (which I could apply to the headings)
I want to copy large amount of big files from folder A to folder B. I have 2 option in Python. import shutil shutil.copy(src, dst) with subprocess import subprocess command = "ROBOCOPY {} {} /MOVE /E".format(src, dst) subprocess.Popen(command, shell=True) When I used above methods my Python IDE do copy operation blindly. Is there some way I can show the file copy progress.
When copying large files using shutil.copy(), you get no indication of how the operation is progressing.. I have put together something that works - it uses a simple ProgressBar class (which simple returns a simple ASCII progress bar, as a string), and a loop of open().read() and .write() to do the actual copying. It displays the progress bar using sys.stdout.write("\r%s\r" % (the_progress_bar)) which is a little hackish, but it works. You can see the code (in context) Is there any built-in module that will do this better? Is there any improvements that can be made to this code?
I've had this problem for at least several months. I noticed a lot of threads without a happy ending: And I did try all the suggestions made in these threads including: Updating the windows to the latest version Troubleshoot network, update, etc killing all other software, changing MSISUPPORTED of my SSD disk in regedit etc. One thing I noticed is that the problem disappears in safemode.
Since installing the Windows 10 Fall Creators Update, I have a svchost.exe process that is constantly using about 14​ % of CPU time: This svchost.exe instance is responsible for hosting three services: The CPU time is consumed by a thread inside that process that cannot attribute to any of these three services: Given that these three services are considered critical system services, it's hard to do anything about them. These services cannot be stopped or disabled by services.msc, and terminating the process triggers a bugcheck (CRITICAL_PROCESS_DIED). Disabling the Windows Defender Firewall through the settings UI does not reduce CPU usage. I'm out of ideas. What could be causing this? How can I debug this further? Is there a workaround to stop these services? Update: After some debugging with , we've isolated this to the Windows Defender Firewall service. Process Monitor shows that it's constantly accessing the registry: A CSV export of a Process Monitor capture, filtered to that process, is available . I’m still looking for a way to stop that behavior. Update 2: Analysis with the Windows Performance Analyzer shows that most CPU time is consumed by code from rpcrt4.dll:
I have Ubuntu 14.04 and I need the latest version of Java JRE to run certain games but I have the old version and I do not know how I can update it. I tried downloading it from but I couldn't rub the downloaded file, Also tried looking at other people's questions but I couldn't really understand them.The error I get is "the application requires a Java runtime environment 1.6.0" Here's a screen shot of the error:
I want to install Oracle's JRE and to update to the latest version with the Software Updater when they released. Is there a Ubuntu package that is provided by Canonical or Oracle? Before release Java 7, I followed to install Java 6. But it doesn't work for Java 7. There is no package sun-java7-xxx. How can you install Java 7?
I am attempting to see whether a file exists within a directory then if it doesn't exist, create it. I'm using Anaconda and Python version 3.7.4. However when I run the code I recieve the error NameError: name 'found' is not defined. I'm using Visual Studio Code and am quite new to programming! import fnmatch import os print() for file in os.listdir('/home/user/CI6724_J0874321_John/'): if fnmatch.fnmatch(file, 'CI5232_Logs.txt'): found = True if found: print('File exists') else: open('/home/user/CI6724_J0874321_John/', 'w')
How do I check whether a file exists or not, without using the statement?
I am facing an issue and am sure there must be very simple solution for this.Can anyone help me ? I have bamboo server running which picks up stash rep where I have committed my code from Eclipse Force.com IDE. When I run the bamboo plan , it kind of deploys everything (all files from src) when I have committed only one component (say VF page). I modified mt package.xml to include only that VF page and nothing else. But still deployment runs across all 13k components. I know I can remove all those components from my src folder and keep only VF page. SO that it deploys only that component. But is there any way , so that it picks up only the commit and not entire src folder ? Any pointers helps greatly appreciated.
I am setting up a continuous integration for a team development process using GitHub and Ant (and eventually Jenkins) and have a problem with deploying to dev sandboxes to keep them in sync with Production: How do you programmatically customize the Package.xml and the src/ folders to only include the metadata files that have changed in Production? Our Production environment has over 5000 files so if I retrieve the entire metadata set from Production to the master branch, rebase the dev sandbox branch and attempt to deploy that to its dev sandbox, I hit the API limit for deploying metadata via the API. The metadata in Production changes both from packages deployed from sandboxes as well as from changes made directly in Production by Admins, so I cannot rely on combining all pushed metadata files and package.xml files.
I'm watching Suits TV Series, and there was something that caught my attention. 2 guys meet, have a drink, chat, and then one guy says: I mean it's time I told you. I made a deal with Darby to take over the firm from Jessica. Why is "told you" in paste tense? What exactly does it mean? He is saying that news right now. If I were to say that, I would say "it's time to tell you" or "it's time I'm gonna tell you". Thanks!
Why do we use the simple past but not the present or future in the following expressions: Don't you think it's time we went a little further Don't you think it's time we ate Don't you think it's time we went home
I have a data set with the amount of bicycle accidents and the year in which the bicycle accident occurred. I would like to see if there is a significant increase in the amount of bicycle accident per years and by which amount. I am doubting between Pearson's correlation and Spearman's Correlation. (Or should I use a linear regression analysis?)
I have a nominal variable (different topics of conversation, coded as topic0=0 etc) and a number of scale variables (DV) such as the length of a conversation. How can I derive correlations between the nominal and scale variables?
I've made a huge mistake by running rm -r /* on my ubuntu 16.04. But i managed to cancelled the on going command quickly using ctrl-c. Now all my bash is not working. For example if i type 'ls' in my directory, it will show 'command not found'. it seems that all command is affected and i just can use cd command. what i found out is that my files at /var/www/html is still intact and not deleted and my web application is still running with minor issues. I have done the change PATH fix but i found out that my /bin is deleted and my home directory is deleted. Question 1 : is there any way i can repair my ubuntu 16.04 without losing my files at /var/www/html? Question 2 : is there any way i can salvage my files at /var/www/html?
Please note: The answers and comments to this question contains content from another, similar question that has received a lot of attention from outside media but turned out to be hoax question in some kind of viral marketing scheme. As we don't allow ServerFault to be abused in such a way, the original question has been deleted and the answers merged with this question. Here's a an entertaining tragedy. This morning I was doing a bit of maintenance on my production server, when I mistakenly executed the following command: sudo rm -rf --no-preserve-root /mnt/hetznerbackup / I didn't spot the last space before / and a few seconds later, when warnings was flooding my command line, I realised that I had just hit the self-destruct button. Here's a bit of what burned into my eyes: rm: cannot remove `/mnt/hetznerbackup': Is a directory rm: cannot remove `/sys/fs/ecryptfs/version': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/inode_readahead_blks': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/mb_max_to_scan': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/delayed_allocation_blocks': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/max_writeback_mb_bump': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/mb_stream_req': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/mb_min_to_scan': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/mb_stats': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/trigger_fs_error': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/session_write_kbytes': Operation not permitted rm: cannot remove `/sys/fs/ext4/md2/lifetime_write_kbytes': Operation not permitted # and so on.. I stopped the task and was relieved when I discovered that the production service was still running. Sadly, the server no longer accept my public key or password for any user via SSH. How would you move forward from here? I'll swim an ocean of barbed wire to get that SSH-access back. The server is running Ubuntu-12.04 and hosted at Hetzner.
I have a jsonline file like below: {"id":0,"country":"fr"} {"id":1,"country":"en"} {"id":2,"country":"fr"} {"id":3,"country":"fr"} I have a list of codes, i want to attribute a code to each user, by updating the file lines. The result should be the following: {"id":0,"country":"fr", code:1} {"id":1,"country":"en", code:2} {"id":2,"country":"fr", code:3} {"id":3,"country":"fr", code:4} This is how i do it now: import ujson fh, abs_path = mkstemp() with open(fh, 'w') as tmp_file: with open(shooting.segment_filename) as segment_filename: for line in segment_filename: enriched_line = ujson.loads(line) code = compute_code() if code: enriched_line["code"] = code tmp_file.write(ujson.dumps(enriched_line) + '\n') My question is, is there a faster way to do this ? May be via a linux command launched via sarge for example ? or any pythonic way without having to read the read / write / replace the original file ? Thank you !
I want to loop over the contents of a text file and do a search and replace on some lines and write the result back to the file. I could first load the whole file in memory and then write it back, but that probably is not the best way to do it. What is the best way to do this, within the following code? f = open(file) for line in f: if line.contains('foo'): newline = line.replace('foo', 'bar') # how to write this newline back to the file
My wife has multiple lenses from her old Canon Ae1 film camera with a doubler, I would like to upgrade her to a Canon rebel T5. Is there an adapter available to make use of her old lenses ? If so , where would I purchase one ?
I have a Canon AE-1 (film) and I bought a digital slr camera Canon EOS 60D. I have lenses from the AE-1 camera, but I don't know if there are some adaptors to use so they fit in the 60D camera... any ideas?
While I really like low temperature cooked dishes, I ask myself whether all microorganisms are killed with these methods. I'm worried that not all parasites and bacteria are killed at 60-70°C. Is there a table with meat cooking temperatures and the corresponding surviving species that might remain in the products?
What general rules do I need to follow to keep my food safe? How do I know what temperature to cook something to, or whether my food is safe at room temperature?
Is it acceleration or speed that leads to time dilation or both? For example, when a spaceship accelerated to (almost) the speed of light, then reversed course to come back towards earth, does this affect time dilation in the same way as if the the spaceship landed on a planet with very high gravity for a while? I notice that in many videos they say that speed is the relevant factor that makes time slow down. But speed is relative, isn’t it? Both would travel with almost the speed of lost. Is it therefore only the the acceleration that matters?
What causes time dilation? Acceleration or velocity? I've seen multiple comments on this forum that assert velocity is the cause, but that doesn't seem right to me. You can't have velocity without acceleration. It's the inertial force with acceleration that breaks the symmetry. My understanding is that the asymmetry is where the inertial frame changes. Measuring time between two objects with different inertial frames is where you have time dilation. When the acceleration ends, the object is effectively at rest in a new inertial frame and has velocity relative to another object in the original inertial frame. In other words, acceleration (changing reference frames) is the cause...velocity and time dilation is the effect. Am I right about this? If there are flaws in my logic I'd like to find and correct them.
i have download one source code (glibc,linuxthreads) form GNU site .and install it in /usr/local. I want to compiler glibc and change some code ,but i don't know where can download the source code. question: is other program need? how can i install it?
I am assuming that all application installed through apt-get are open source; but for those that are available in that manner, where can I get the source code for these applications as well as update them? I have a couple applications I use regularly that aren't being actively developed any longer and I would like to add features. Where would I go to get the rights to update these applications? In this case specifically, I am referring to the hellanzb package
In Infinity War Cull Obsidian loses his arm when a worm hole closes up, So could Thanos have lost his arm like this too WHEN he had all the stones on the Gauntlet?
Doctor Strange seemingly has the ability to open portals wherever he wants. We see at the beginning of Infinity War what happens when he closes a portal and someone isn't fully through it. Is there any reason why he can't open a portal around the left-elbow of Thanos, and then close it? I realize that Thanos probably wouldn't allow this to happen normally, but when he is mostly asleep, and Tony and Spider-Man are pulling on the gauntlet, Doctor Strange has ample opportunity, and plenty of space to just sever Thanos' arm. Why doesn't he?
I like some of the changes in the new stackoverflow/stackexchange site but I miss the section with the top questions (when you clicked on the stackexchange name) - it was like my morning newspaper! Can I find the top questions somewhere else?
Since the new top bar has been rolled out - a number of different people, established and new users alike, have asked questions on where a specific link has disappeared to with the new top bar design. Where has the link to <X> gone?
Looking for a 1960s book about people who think they are exploring a planet until they find they are on a huge space 'ark' going somewhere that has been travelling for generations.
The story starts with a tribesman going on a exploratory voyage around the land, meeting other progressively more and more distant tribes, learning about the world. Gradually he or she discovers that the "world" is actually a giant spaceship flying through space. The story climaxes by the hero ascending to the commanding deck and learning who actually pilots the ship and to what purpose.
I'm trying to make these corners sharper after SubSurf. The solution that comes to my mind is adding edge loops to limit its space, but when I try to add edge loops they also affect the intake shape in front of the object in the same loop, deforming it in the way I don't want (I want sharper edges, but not round as I've done) Any ideas besides boolean?
I tried to apply a Subdivision Surface on a part of my object. I can't keep the angles sharp, they all turn into rounded angles. The angle before applying the Subdivision surface... ...And after
I'm trying to have an boost::container::vector containing instances of a few class that all inherit from the same superclass, and then have some functions only apply to the instances of a specific class, but I can't seem to get it to work. This is the first time I try this, so maybe I just made a rookie mistake, can one of you tell me where I went wrong, and why ? Here's an example code : using boost::container::vector; class card{ public: card(int aa,int bb):a(aa),b(bb){} virtual ~card(){} int a,b; }; bool operator==(card l, card r){ return l.a==r.a; } bool operator<(card l, card r){ if(l.a<r.a){ return true;} else{ return l.b<r.b; } } std::ostream& operator<<(std::ostream& os, card c){ os << c.a << ":" << c.b; return os; } class subcard:public card{ public: subcard(int a, int b):card(a,b){} virtual ~subcard(){} int c=0; }; int main() { cout << "Hello, World!" << endl; vector<card> v1; v1.push_back(card(2,2)); v1.push_back(subcard(1,1)); for (int i = 0; i < v1.size(); ++i) { cout<<v1[i]<<endl; } for (int i = 0; i < v1.size(); ++i) { if(subcard* sc = dynamic_cast<subcard*>(&(v1[i]))){ cout<< "found : " << sc <<endl; } } return 0; } Thank you very much :)
Someone mentioned it in the IRC as the slicing problem.
I want to store symbols like █ ▄ in my mysql db and show them with php. I tried to use ord and chr but it shows this symbol after: â How can I do that? Kind regards, Damon
I'm setting up a new server and want to support UTF-8 fully in my web application. I have tried this in the past on existing servers and always seem to end up having to fall back to ISO-8859-1. Where exactly do I need to set the encoding/charsets? I'm aware that I need to configure Apache, MySQL, and PHP to do this — is there some standard checklist I can follow, or perhaps troubleshoot where the mismatches occur? This is for a new Linux server, running MySQL 5, PHP, 5 and Apache 2.
I have asked similar question before also but want to try again - I followed everything from this project but still, the magnet is not levitating - The best I can do is to make the magnet jump up and down fast but it never levitates. Have tried changing PID setting from the project as aggressive and mild but still didn't achieve the final result. I need advice from an expert to tell me what I am doing wrong here. All components are in good condition and 5v electromagnet is strong enough. So what am I missing here?
I am following a hackster project on magnetic levitation here - However, I have followed everything but still, it's not working. Here are changes to the circuit I made: The electromagnet which I am using is that of 5V instead of 12V The transducer which I am using is ss8050 instead of TIP120 Hall sensor is tapped just at the bottom of the electromagnet Electromagnet link - Update:- The best I can do is to make the magnet jump up and down fast but it never levitates. Have tried changing PID setting from the project as aggressive and mild but still didn't achieve the final result. I need advice from an expert to tell me what I am doing wrong here. All components are in good condition and 5v electromagnet is strong enough. So what am I missing here?
$x_1, x_2, x_3,.\cdots ,x_n$ and $y_1, y_2, y_3,\ldots,y_m$ are two series of positive integers, such that $m\not=n$. Given that $1<x_1< x_2<x_3<\cdots<x_n<y_1< y_2< y_3<\cdots<y_m$ and $x_1+ x_2+ x_3+\cdots+x_n > y_1+ y_2+ y_3+\cdots+y_m$, prove that $x_1x_2x_3\cdots x_n>y_1y_2y_3\cdots y_m$. I have tried to prove it for conservatives. I have no idea how to deal with this type of inequality properly.
For two positive integer sequences $x_1,x_2,\ldots,x_n$ and $y_1,y_2,\ldots,y_m$ satisfying $x_i\neq x_j\quad \text{and}\quad y_i\neq y_j\quad \forall i,j, i \ne j$ $1<x_1<x_2<\cdots<x_n<y_1<\cdots<y_m.$ $x_1+x_2+\cdots+x_n>y_1+\cdots+y_m.$ Prove that: $x_1\cdot x_2\cdots x_n>y_1\cdot y_2\cdots y_m$. (from internet) I don't have an idea for this problem. Thanks for your help.
I have this counter which I have defined using \newcounter{myCounter}. Printing the value of myCounter can be easily done via \arabic{myCounter}. How can I print the value of (myCounter - 2)?
I have defined a new counter that keeps increasing each time I call the macro that's using it. How can I print the counter value minus one? Something like \value{\theCounter-1} but formatted for text? MWE \documentclass{article} \usepackage{parskip} \newcounter{myCount} \setcounter{myCount}{1} \newcommand\newSec[1]{\par\underline{\textsc{newSec}~\themyCount}\hspace{0.5em}{\footnotesize(#1~number)}\stepcounter{myCount}\par} \begin{document} \newSec{2} Some text \newSec{5} Here I refer to the counter used before it was incremented: \themyCount. Should print 2. \end{document}
Can someone explain the answer to this question: 'Imagine there are a 100 people in line to board a plane that seats 100. The first person in line realizes he lost his boarding pass so when he boards he decides to take a random seat instead. Every person that boards the plane after him will either take their "proper" seat, or if that seat is taken, a random seat instead. Question: What is the probability that the last person that boards will end up in his/her proper seat.' If instead of only the first person having lost their ticket the first two people have lost their tickets and take random seats?
I recently came across a quite interesting problem: "One hundred passengers are lined up to board a full flight. The first passenger lost his boarding pass and decides to choose a seat randomly. Each subsequent passenger (responsible enough to not lose their boarding pass) will sit in his or her assigned seat if it is free and, otherwise, randomly choose a seat from those remaining. What is the probability that the last passenger will get to sit in his assigned seat?" I figured out that the probability would be 0.5. If you would like to know why I would link you to another topic on this site where this problem was discussed. However, I kept thinking about what the probability would be if there were multiple people who lost their boarding pass. So for example, the first 5 people out of the 100 passengers lost their boarding pass so they take a random seat. Every person that boards the plane after him will either take their "proper" seat, or if that seat is taken, a random seat instead. Then what is the probability that the last passenger will get to sit in his assigned seat? I have trouble figuring it out and I hope that some of you could help me. Thanks in advance!
Is there a way, I can use of strlen() to find the length of the arrays, instead of specifying in the loop. First Code: Working With x < 4 Which is the size of the array of temps[4]. #include <stdio.h> #include <string.h> int main(){ float temps[4] = {72.5, 73.4, 74.7, 75.2}; int x; printf("Local Temperatures\n"); for(x = 1; x < 4; x++){ printf("Station %d: %.1f\n",x,temps[x]); } } My Second Code, Not Working, But Looking At What, I Am Trying To achieve with strlen() to find the size of the array.: #include <stdio.h> #include <string.h> int main(){ float temps[4] = {72.5, 73.4, 74.7, 75.2}; int x; float size; size = temps; printf("Local Temperatures\n"); for(x = 1; x < strlen(size); x++){ printf("Station %d: %.1f\n",x,size[x]); } }
How do I determine the size of my array in C? That is, the number of elements the array can hold?
I'm going crazy with this error: Bad math environment delimiter. \end{equation} You can't use `\eqno' in restricted horizontal mode. \end{equation} of the following MWE: \documentclass[border=1 pt]{standalone} \usepackage{amsmath} \usepackage{mathrsfs} \usepackage{tikz-cd} \begin{document} \begin{tikzcd}[row sep=huge, column sep=huge] \textbf{B} \arrow[r,"M"] & \text{Y}\\ \textbf{X} \arrow[r,swap,"M"] \arrow[u,"project"] & \text{A} \arrow[u,"project", swap] \end{tikzcd} \begin{equation} project \circ M = M \circ project \end{equation} \end{document}
I was surprised to find that standalone package can not compile a document with an equation: \documentclass{standalone} \begin{document} \begin{equation} % not working! F(V, T) = E(V) + D(T) \end{equation} \end{document} Is there an option or some workaround that allows this? The current error is something like: ! Missing $ inserted. in line 4. (The idea of course is that the including (main) document can just \input the standalone without knowing if is going to be an equation or something else)
I am trying to parse a file for an instance of a word in Java. The word is input from a JTextField. Depending on which selection is made in a JComboBox the filepath may change. The Text file contains names and their popularity. The desired output is how that name ranked for the year that is selected. I'm struggling with setting up an appropriate search. I have been able to get the file to open and output some of the contents of the file to the Java Console, but the file contains 1000 lines and I notice that the output in the console only begins with entry number 950 or so. Here is what I have so far: public void actionPerformed(ActionEvent e) { //Parse Input Fields String name = inputArea.getText(); String genderSelected = genderList.getSelectedItem().toString(); String yearSelected = yearList.getSelectedItem().toString(); String yearFile = "Babynamesranking"+yearSelected+".txt"; try { File inputFile = new File(yearFile); BufferedReader in = new BufferedReader(new FileReader(inputFile)); /**This is where I draw a blank and need help*/ in.close(); } catch (IOException exception) { JOptionPane.showMessageDialog(null, "Error Reading File"); } I have more work to do after I get this part working to display the results in the GUI and such, but that is easy and I can do that. Just struggling with how to get this part to work. Example of text file we are parsing: 1 Jacob 22,507 Emma 18,765 2 Michael 20,524 Isabella 18,564 3 Ethan 20,174 Emily 17,397 4 Joshua 19,133 Olivia 17,030 5 Daniel 18,935 Ava 17,007 6 Alexander 18,639 Madison 16,985 7 Anthony 18,347 Sophia 16,042 8 William 18,337 Abigail 15,045 9 Christopher 17,876 Elizabeth 11,956 10 Matthew 17,526 Chloe 11,802 11 Jayden 17,088 Samantha 11,157 12 Andrew 16,711 Addison 10,742 13 Joseph 16,483 Natalie 10,179 14 David 16,246 Mia 10,156 15 Noah 15,748 Alexis 9,685
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 definition that claims that two sets are equal A = B, if and only if: $\forall x ( x \in A \leftrightarrow x \in B)$ An empty set contains no elements. If I define the sets: A = $\emptyset$ B = $\emptyset$ then can I conclude that A $\neq$ B? Since they contain no elements? Or would I have to show that an elements exists in one but not the other? To me it seems that these are not equal, but I'm struggling to wrap my head around this. Thanks, Paul
I Have a question. Given only the definition of equality of two sets, how can we prove that there is one and only one empty set. I mean by equality of two sets the following: $$A=B \iff \forall x (x \in A \iff x \in B)$$
The question "" was closed for being a duplicate. The linked question "" was also closed as a duplicate question. Following this link leads us to the actual question we're looking for, "". How should these scenarios be handled? Is there a way to suggest updates to the referenced duplicate question? Edit: This question is different from . I am asking what I should do as a user when duplicates of duplicates are found, while the linked question asks whether duplicate links should be remapped automatically.
On found exact duplicates, should these be voted to close directly against a preferred, or ultimate, canonical question? Or is a chain of possible duplicates (where one question is closed as duplicate of another, which itself is a duplicate of another, and so on and so on) allowable or OK? One example of this situation can be found .
As a matter of style, could these pass muster to you in terms of conciseness and punctuation - yes or no? I think they are clear and uncluttered. 5-10 year olds 5-10 year old prodigies 10-15 year mortgage 1-2 inch laceration $2-3 million a year contract $5-10,000 per year savings
Without recasting and in lieu of unsightly suspensive hyphenation, could these work? The en dash (which means "to") is used between the figures, and the hyphens are used in the compound modifier. To me, the examples below are concise and clear. Do you agree that the examples below are 100% punctuated correctly--yes or no? 45–50-year-old men 10–20-mile radius $45–$55-million-per-year industry $100,000–$150,000-a-year savings 10–15-degree temperature difference $2–$5-per-day service fees 45–75-cent-a-week raises 55–65-mph speed zone 15–20-ounce steaks 20%–40%-a-year tax increases
I'm a Linux Mint user, and I use Ask Ubuntu a lot. However, some questions about the Mint GUI don't fit there. Should we start a Mint site?
I have an idea or subject that should have a Q&A, and want to propose a new site. How can I do this? Related:
I have a 600D and a 7D and I use the kit lens " EF-S "18-55mm and the 55-250 mm , and I am thinking of buying a 24-105mm f4 IS USM L... so does the EF-S suffer from the same 1.6x crop factor as the EF? For example, the 24-105 IS USM L on an APS-C sensor is like 33mm to 168mm, and the 18-55mm has is equivalent to 28.8-88mm?
I have a Canon 7D, which has a crop factor of 1.6x. When using a Canon EF-S lens I get the focal length stated on the lens, when using a Canon EF lens I get the focal length times 1.6 when used on the APS-C body. At least that's what I thought. I just compared two lenses: Canon EF-S 15-85mm f3.5-5.6 Canon EF 70-200mm f4 . The top photo is shot with the 15-85, the bottom photo with the 70-200 - both lenses are set to 70mm. Now why do they look the same? I thought I would get 112-320mm (70mm*1.6 crop factor). What did I misunderstand about the crop factor calculation? Lightroom also displays the photos as having "70mm" and not 112mm.
I am new to Stack Exchange. Math and physics newsletters get to my inbox every Thursday, and every Thursday there are 5-day-old answers to questions as I read them for the first time. Too often a question of interest has already been closed because of the low quality of recent answers and comments. I have no reputation, and to do almost anything requires more reputation than I have. Nothing I have found in Help helps (however I noted one user submitted an "answer" because he said he did not have the reputation to comment. I have started wondering if Joseph Heller is looking over my shoulder. Any help, please? Thank you to those who made useful suggestions. The question, "How does a new user begin using Stack Overflow/Stack Exchange?," clearly expressed my difficulties. I would close the question if I knew how. Good night.
I have been reading Stack Exchange for years - mostly not logged in, and have never posted (this is my first). I'm simply not very talkative, and very good at googling. Recently a few occasions have come up when I've wanted to comment on a question. I wanted either to ask for, or provide, clarification which did not warrant a new answer. How do I gain enough reputation to comment without: asking questions which have already been answered or that I can figure out on my own, or posting my comment like as an answer (i.e. being rude)?
I want to prove the following so I decide to rewrite the RHS $$A \setminus (B\setminus C) = (A\setminus B)\cap (A \cup C)$$ $$ A\setminus(B\setminus C) = A\setminus (B \cap C^c) = A\cap (B\cap C^c)^c = A\cap(B^c\cup C) = (A\cap B^c)\cup(A\cap C) $$ there is way that $(A\cap B^c)\cup(A\cap C)\rightarrow (A\setminus B)\cup(A\cap C) = (A\setminus B)\cap (A \cup C)$? thanks. EDIT LHS: $$x\in A \vee x\in A\cap C \rightarrow x\in A \wedge x\in C$$ RHS: $$x\in A \wedge x\in A\cup C \rightarrow x\in A \vee x\in C$$ how it can help me?
Show that $A \setminus ( B \setminus C ) \equiv ( A \setminus B) \cup ( A \cap C )$ This is an exercise I was trying to do ( not homework ) and I got stuck as follows: Working from $A \setminus ( B \setminus C )$: $x \in A \wedge x \notin ( B \setminus C )$ $x \in A \wedge ((x \in B \wedge x \in C) \vee (x \notin B \wedge x \in C) \vee (x \notin B \wedge x \notin C) )$ At this point I'm not sure how to proceed. Working from the other side $ ( A \setminus B) \cup ( A \cap C ) $: $ x \in ( A \setminus B) \cup ( A \cap C ) $ $ x \in ( A \setminus B) \vee x \in ( A \cap C ) $ $ ( x \in A \wedge x \notin B ) \vee ( x \in A \wedge x \notin C ) $ $ x \in A \wedge (x \notin B \vee x \notin C ) $ $ x \in A \wedge x \notin ( B \cap C ) $ $ A \setminus ( B \cap C ) $ I could also use some formating tips like how display logical not and how to get the lines to display properly without blank lines inbetween. :-)
Do images in deleted answers stick around forever? I think I already know the answer and I think this is a dumb and/or obvious question but I just want to make sure. I have an answer with SE-uploaded imgur images in it. I intend to delete the answer but link to one of the images in a comment elsewhere. I was just going to use the generated link from the answer, and want to make sure it'll stick around as long as the comment does.
What happens to the images from deleted questions and/or answers? Will they be kept or they will be deleted with the answer? What happens with the images, that are edited out from the post? The links are still there in revision history, but what with the image under that link?
I have setup a Central Management Server and registered all of my SQL servers (prods and devs). I want to save the results of sp_BlitzFirst from running it against all of my servers to a centralized database 'DBAtools' on my test box for later analysis. What is the most efficient method for achieving this task? Thank you so much in advance.
I am using , and want to use it to execute the checks on all of my SQL Servers and have it write the results to a single table. Do I need to create linked servers on the central instance to connect to the other instances, or is there some other way to input the server names into the sp_Blitz stored procedure?
At the end of this month I have a flight from St. Lucia to New York and then New York to Phoenix where I live. There is a 24 hour layover in New York so I figured I would stay an extra day. In order to change my flight and cancel the existing reservation to change it was about $500. I could book with a separate airline and it will cost a fourth of that. My question is: If I miss my flight from New York to Phoenix and take a flight with a different airline, will I be OK?
Say I want to book a flight from Fort Lauderdale to Chicago. Say the airline also flies to St. Louis from Fort Launderdale but has a connecting flight through Chicago. If I book that flights from FLL->ORD->STL and just get off in Chicago, what possible problems can I run into, assuming I didn't check any bags and only have carry on? This scenario exist for Southwest, but I wanted this be more of a general question that would apply to all airlines.
I have to process multiple files that I dont have the entire name for. I am running an if statement using a wildcard. for example... if [ "ESGSN_*.SMS.EDR" ]; then echo "There are files to process in this run" for F in ESGSN_*.SMS.EDR; do gzip < "$F" > "$F.gz" done fi If there are multiple files or a single file this will work and zip them. But if there are no files it will still run the zip rather than just end. I was wondering if there is any way to get it to complete and move on. I have tried using the operators "-f" and "-a" within the brackets just before the filename, but those will error out with: "binary operator expected" for some reason the asterisk in the filename is not showing down below in the message. So the file name is "ESGSN_"*".SMS.EDR" where the double quotes is the asterisk.
Is there a good clean conventional way to do this? For example, if there are any ".gz" files in a certain directory, I want to unzip them. But if there aren't, I don't want to see any error. If I use gzip -d /mydir/*.gz, I get the error: gzip: /mydir/*.gz: No such file or directory If I first shopt -s nullglob and then gzip -d /mydir/*.gz, I get the following: gzip: compressed data not read from a terminal. Use -f to force decompression. For help, type: gzip -h I have one method I know will work, which I'm posting as an answer. I'm wondering if there's a better/cleaner way. POSIX compatibility is a bonus, but not required.
We say that a function, $f: X \to Y$ ($X, Y$ are topological spaces) is sequentially continuous if $f(x_n)$ converges to $f(x)$ whenever $x_n$ converges $x$. Give an example of a function that is sequentially continuous but not continuous. I tried letting $X$ be $\mathbb R$ with cofinite topology and $Y$ be $\mathbb R$ with discrete topology where $f$ is identity map but $f$ is neither sequential continuous or continuous. There are no simple solutions online since most use ordinal sets and we have not yet covered that in our topology class.
Can you give me an example of a function which is sequentially continuous but not continuous? (I know that in first-countable spaces this is equivalent, but what about in spaces without this condition?) Thank you :)
I'm trying to understand the use of super(). From the looks of it, both child classes can be created, just fine. I'm curious to know about the actual difference between the following 2 child classes. class Base(object): def __init__(self): print "Base created" class ChildA(Base): def __init__(self): Base.__init__(self) class ChildB(Base): def __init__(self): super(ChildB, self).__init__() ChildA() ChildB()
What's the difference between: class Child(SomeBaseClass): def __init__(self): super(Child, self).__init__() and: class Child(SomeBaseClass): def __init__(self): SomeBaseClass.__init__(self) I've seen super being used quite a lot in classes with only single inheritance. I can see why you'd use it in multiple inheritance but am unclear as to what the advantages are of using it in this kind of situation.
I have a laptop running OS X 10.9.2 and 10.7.5. On both I use Terminal extensively. I have Terminal set up open with Homebrew settings on startup on both 10.7 and 10.9. The issue occurs when I close all open tabs and Terminal windows with ⌘ + w, so that the app is still running but there are no windows visible. The behaviour of Terminal on 10.7.5 is as I would expect. When I open a new window with ⌘+n the new terminal window opens with "Homebrew" settings. The behaviour with 10.9.2 is not what I would expect (maybe I need to have it explained). Again if all windows are closed but Terminal is left active and I start a new window using ⌘+n the new window has "Basic" settings instead of "Homebrew". I have checked this behaviour and it is consistent on both a MBP and Mini I have running with Maverics. Is this behaviour normal? If so, is there a way to modify it, so that Maverics behaves like 10.7?
I want to set the "Homebrew" theme to be the default in Terminal. I've changed the setting in the preferences: I chose "on startup, open" : "new window with settings" : "Homebrew". Here is a screenshot: Terminal uses "Homebrew" only for the first window. Then I do cmd-W to close the window and cmd-N to get a new window. The new window appears with the "Basic" theme! But if I do cmd-Q and restart Terminal then it gives me a "Homebrew" window again. Why don't terminal themes work properly?
I wander why c++ allows to declare this? void f(int x); int main() { int x; const int y=0; f(x); f(y); } void f(const int x) { } Why compiler allows you declare function with one signature, but define with another (cv qualifier added)?
How far do you go with const? Do you just make functions const when necessary or do you go the whole hog and use it everywhere? For example, imagine a simple mutator that takes a single boolean parameter: void SetValue(const bool b) { my_val_ = b; } Is that const actually useful? Personally I opt to use it extensively, including parameters, but in this case I wonder if it's worthwhile? I was also surprised to learn that you can omit const from parameters in a function declaration but can include it in the function definition, e.g.: .h file void func(int n, long l); .cpp file void func(const int n, const long l) Is there a reason for this? It seems a little unusual to me.
I am currently solving a simple cryptanalysis problem where I need to decrypt a text file using frequency analysis. The text has been encrypted using an affine cipher over a 68 character alphabet which includes lower and upper case English letters, digits from 0 to 1, as well as those characters: ". , ; : _ \n" where _ denotes space. Going over the frequency histogram of the text, the most frequent character is "," followed by "z". According to what I know, the most frequent character for the 68 character alphabet is space followed by "e". Thus I end up with those two equations: $$66a + b = 63 \bmod 68$$ $$4a + b = 25 \bmod 68$$ Which gives me: $$62a = 38 \bmod 68$$ $a = 38 \cdot 62^{-1} \bmod 68$ However, 62 isn't invertible mod 68. I am quite new to cryptography so I am quite unsure if there is some method to solve this issue.
I am trying to perform Cryptanalysis on Affine cipher . Given Plain Text "GO" and cipher text "TH" We know , $G =6 , O=14 , T=19 , H= 7$ By brute force method I'm getting key $(a,b)$ as $(5,15 )$ But by known plain text attack method $6a + b = 19 \\ 14a +b = 7$ on solving the equations . im getting $-8 a + 0 = 12 $ taking addictive inverse of $-8 = 18$ We get , $18a +0 =12$ , Now $a= 12*$ multiplicative inverse of $(18)$ Multiplicative inverse of 18 doesnt exist then how to proceed ? Is my approach correct ?
Can someone help me with counting number of exact letter? int numberOfX = 0; foreach (char x in textBox1.Text) { numberOfX++; } this.Text = ($"Number of X: {numberOfX}");
I am doing something where I realised I wanted to count how many /s I could find in a string, and then it struck me, that there were several ways to do it, but couldn't decide on what the best (or easiest) was. At the moment I'm going with something like: string source = "/once/upon/a/time/"; int count = source.Length - source.Replace("/", "").Length; But I don't like it at all, any takers? I don't really want to dig out RegEx for this, do I? I know my string is going to have the term I'm searching for, so you can assume that... Of course for strings where length > 1, string haystack = "/once/upon/a/time"; string needle = "/"; int needleCount = ( haystack.Length - haystack.Replace(needle,"").Length ) / needle.Length;
i'm running Windows 10 on a laptop, upgraded from 8 to 8.1 then 10, cpu is core i5 4200u, can it handle Ubuntu? if i installed 15.10, can i upgrade to 16.04 LTS when it comes out?
I'm thinking about installing Ubuntu Desktop, but I don't know what flavor is the best for my system. What are the minimum and recommended hardware requirements? What kind of CPU? How much memory? Should I have Hardware Acceleration? What flavor should I use? This is an attempt of a canonical answer. My answers have the "official requirements", the recommended are a mix of official sources and opinion based (along with the answer it's told the source). You can comment or edit if you feel that the information is obsolete or incomplete. It is a good rule of thumb that any system capable of running Windows Vista, 7, 8, x86 (Intel) OS X will almost always be a lot faster with any Ubuntu flavor even if they are lower-spec than described below.
I am using SQL Server 2008 and I need to implement this :-> I get a result like this : Table:-sql query .............. acc_no name 001-000001 John 001-000001 Bob 001-000001 James 001-000002 Sam 001-000002 Bin 001-000002 Dus So, the condition is that; multiple persons can have same acc_no. So i want following result: acc_no name 001-000001 John,Bob,James 001-000002 Sam,Bin,Dus There are other conditions for displaying the results but I got stuck in displaying this format.
I've got two tables: TableA ------ ID, Name TableB ------ ID, SomeColumn, TableA_ID (FK for TableA) The relationship is one row of TableA - many of TableB. Now, I want to see a result like this: ID Name SomeColumn 1. ABC X, Y, Z (these are three different rows) 2. MNO R, S This won't work (multiple results in a subquery): SELECT ID, Name, (SELECT SomeColumn FROM TableB WHERE F_ID=TableA.ID) FROM TableA This is a trivial problem if I do the processing on the client side. But this will mean I will have to run X queries on every page, where X is the number of results of TableA. Note that I can't simply do a GROUP BY or something similar, as it will return multiple results for rows of TableA. I'm not sure if a UDF, utilizing COALESCE or something similar might work?
Given $a_1 \in \mathbb{R}$ , consider the sequence {$a_n$} defined by $ a_{n+1} = \begin{cases} \frac{a_n}{2} &\text{ for even n} ,\\ \frac{ 1+ a_n}{2} & \text {for odd n} \end{cases}$. find the the limit points of this sequence.. My attempt : For n odd i get $ a_{n+1}= \frac{ 1+ a_n}{2}$ nad putting $a_{n+1} = {a_n} = l$ Now i get $l= \frac{ 1+ l}{2}$ as i get $l = 1$ for odd.. as I don't know how to find the $a_{n+1}$ when n will even Pliz help me,,,,,
Given $a_1 \in \mathbb R$ . Consider the sequence $\{a_n\}$, which is recursively defined by$$ a_{n+1} =\left\{\begin{array}{ccc} \dfrac {a_n}{2} & \text{if $n$ is even,}\\ \dfrac {1 + a_n }{2} & \text{if $n$ is odd}.\end{array} \right. $$ Find the sub-sequential limit of this sequence. I think for odd $n$ the limit point will be $l= \frac{1+l}{2}$ now $2l = 1+l$ , here $ l = 1$ I don't know the limit point for0 even $n$. Please help me.
Say we have a group containing 4 items $[A, B, C, D]$ and we allow sub-groups of size 2, then 6 sub-groups are needed to ensure every element is grouped with every other element at least once. $[A,B] [A,C] [A,D] [B,C] [B,D] [C,D]$ or 3 if we allow sub-groups size 3 $[A,B,C] [A,B,D] [B,C,D]$ Expanding this to 8 elements and sub-groups size 4, 6 sub-groups are also required. It also appears that if you have $n$ elements and a sub-group size $m$ which require $x$ sub-groups to ensure element grouping, then $kn$ elements with sub-group size $km$ also requires $x$ sub-groups. So possibly only prime numbers for $n$ or $m$ have unique values of $x$. I tried initially looking at binary representations as a way to get all possible arrangements, then counting the instances of Hamming Weight $m$ from $0$ to $2^n$ but the pattern did not hold. I am trying to generalize it so if you have $n$ elements with sub-group size $m$ $\binom{n}{m}$ where $1<m<n$ , $m \in \mathbb{Z}$ , $n \in \mathbb{Z}$ some function $F(n,m) = x$ Is there a formular to express the minimum number of sub-groups size $m$ so that each element in $n$ is grouped with every other element at least once? I'm having trouble describing elements as having already been grouped mathematically.
Background: I'm working on for , and I've run into a problem with how I'm creating the individual matchups (groups of 4 entries). Currently, I'm simply generating all combinations of 4 elements (in the combinatoric sense) of entries, but that gets really big really quickly: $$x \choose 4$$ (from ) Therefore, my question is: How can I choose subsets (of length $n$) of a set such that each element of that set appears in the same subset as every other element at least once, while maintaining a minimal amount of subsets? I can figure this out for $n = 2$, since the solution is quite intuitive: simply combine the first element with every other element, combine the second element with every other element that comes after it, etc. For a set of length $L$, this yields: $$\sum_{x=1}^{L-1}(L - x)$$ (from ) which is much smaller and more manageable. However, I still have not been able to figure out: How can I generalize this to any $n$?
My question is as follows: $a,b \in L$ where $L$ is a ring. We are given that $ab=1$. I need to prove or disprove that $a$ is invertible (meaning, there is an element $x \in L : ax=xa=1$). But how can we say that for sure? just because $ab=1$ doesn't mean that $ba=1$, ba could be something else altogether, we werent given that this is a commutative ring. Please give advice on how to solve, thank you. Word by word translation of the question to make it clearer: Prove or disprove that if $a$ and $b$ are elements of $L$ and $ab=1$, then $a$ is invertible.
Can I have a hint on how to construct a ring $A$ such that there are $a, b \in A$ for which $ab = 1$ but $ba \neq 1$, please? It seems that square matrices over a field are out of question because of the determinants, and that implies that no faithful finite-dimensional representation must exist, and my imagination seems to have given up on me :)
After doing research for a while, I figured out a topic (1) that nobody has done it before (2) and I think It's pretty cool and valuable (3) to the community in my field. So, I proposed the idea to my professor with some drafts. But, my professor told me to find out if there is any interest in the topic in the publishing industry (journals) If no one cares about that It's not worth it. It's like I created a paradox. How can I find out the interests in the topic if nobody has done it before? If you guys have any ideas or tips that can help me I would be really appreciated! Thanks (1) I'm working on Fault Management Framework for Network Function Virtualization. (2) I cannot find any relevant paper that employs it. They're mostly about Fault Management for SDN or cloud or on a specific problem whereas I want to design a complete solution. (3) I think it is valuable because It will save time for the deployer/implementor by including all the best practices. There'are several reasons why this question is different than the one at because of: It's not about selecting a journal to publish, It's about whether the journals are interested in my topic. I've already known which ones I want to publish to. It's just that I'm not sure if they're interested in my idea. The question in which mine was marked as duplicated with is much broader than mine I think.
I am a PhD candidate in a small country. I have two Master degrees, one from an American university. I am also an experienced professional and an expert in the subject of my PhD studies (in my country, clearly). I need to publish a paper in an international journal as a condition to obtain my PhD. How do I choose a journal? I cannot afford years of waiting for the paper to be published, submit it and be rejected many times. I am looking through the journals, and there is simply no way to know which one is suitable for me. Any help? I understand about looking for journals which had previously published similar articles, but how to know that it is a journal which is likely to accept my article? Thank you!
I have been trying to print some characters on my php page and it returns something else, like corrupted characters like "joão", ø, ç, etc echo '<br>não<br>' the return is não instead: não is this a problem with econding utf-8? i have tried this code header('Content-Type: text/html, charset=utf-8'); but no result
I'm setting up a new server and want to support UTF-8 fully in my web application. I have tried this in the past on existing servers and always seem to end up having to fall back to ISO-8859-1. Where exactly do I need to set the encoding/charsets? I'm aware that I need to configure Apache, MySQL, and PHP to do this — is there some standard checklist I can follow, or perhaps troubleshoot where the mismatches occur? This is for a new Linux server, running MySQL 5, PHP, 5 and Apache 2.
If G is a group of order d, then does there exist a subgroup of order c for all divisors c of d? I cannot find a proper countetexample. Could anyone provide me with one?
Can a kind algebraist offer an improvement to this sketch of a proof? Show that $A_4$ has no subgroup of order 6. Note, $|A_4|= 4!/2 =12$. Suppose $A_4>H, |H|=6$. Then $|A_4/H| = [A_4:H]=2$. So $H \vartriangleleft A_4$ so consider the homomorphism $\pi : A_4 \rightarrow A_4/H$ let $x \in A_4$ with $|x|=3$ (i.e. in a 3-cycle) then 3 divides $|\pi(x)|$ so as $|A_4/H|=2$ we have $|\pi(x)|$ divides 2 so $\pi(x) = e_H$ so $x \in H$ so $H$ contains all 3-cycles but $A_4$ has $8$ $3$-cycles $8>6$, $A_4$ has no subgroup of order 6.
Today I was trying to install Ubuntu and dual boot with my already installed windows 10. I downloaded Ubuntu's latest stable version and burned it to a flash disk. I chose the language then I saw this message The machine's firmware has started the installer in UEFI mode but it looks like there may be existing operating systems already installed using BIOS compatibility mode.If you continue to install Debian in UEFI mode, it might be difficult to reboot the machine into any BIOS-mode operating systems later. If you wish to install in UEFI mode and don't care about keeping the ability to boot one of the existing system, you have the option to force that here. If you wish to keep the option to boot an existing operating system you should choose NOT to force UEFI installation here. Then there were 2 options (go back or continue to UEFI mode). I clicked continue to UEFI. Then I chose Something else. After that I accidentally clicked on "revert". After I clicked the bar on the top turned green and things look like this. Now I can't boot to Windows. I also can't see my data from the Ubuntu. I used to see my data when I use the "try Ubuntu" before clicking on revert but now they are gone. Is there is a way to get my partitions and data back? :'( I am using a Dell xps 15 laptop. 512 GB ssd. I had 2 partitions + windows (450MB I think system partition). Before trying to install Ubuntu I disabled fast boot and secure boot. I use UEFI and AHCI mode. Here is my RESULTS file from the boot info script:
About two weeks ago I had a problem with my PC that my brother wrote a question about at . I still haven't solved the problem, so my PC is unusable now. Now I think that it would be simpler to re-install both Win7 & Ubuntu than repair them, but there're some data on their partitions. I want to recover this data. These partitions are not mountable for some reason. I don't know why. sudo fdisk -l about the problematic partitions: Device Boot Start End Blocks Id System /dev/sda1 2048 147912703 73955328 83 Linux /dev/sdb2 206848 174079999 86936576 7 HPFS/NTFS/exFAT And in GParted: And the error of the mount command: Failed to mount '/dev/sdb2': Invalid argument The device '/dev/sdb2' doesn't seem to have a valid NTFS. Maybe the wrong device is used? Or the whole disk instead of a partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around? And the exact same message for /dev/sda1 How can I recover my data from those HDDs? EDIT I have tried to specify the type of the drive: $ sudo mount -t ext4 /dev/sda1 /olddisk mount: wrong fs type, bad option, bad superblock on /dev/sda1, missing codepage or helper program, or other error In some cases useful info is found in syslog - try dmesg | tail or so $ sudo mount -t ntfs /dev/sdb2 /olddisk NTFS signature is missing. Failed to mount '/dev/sdb2': Invalid argument The device '/dev/sdb2' doesn't seem to have a valid NTFS. Maybe the wrong device is used? Or the whole disk instead of a partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around? EDIT sudo ntfsfix /dev/sdb2 returns: Mounting volume... NTFS signature is missing. FAILED Attempting to correct errors... NTFS signature is missing. FAILED Failed to startup volume: Invalid argument NTFS signature is missing. Trying the alternate boot sector Unrecoverable error Volume is corrupt. You should run chkdsk.
The beta sites and have the same icon. Icon of Earth Science: Icon of Spanish: They both have "ES" in a blue speech balloon. Can they please have different icons?
The favicon is used in various places around the Stack Exchange (SE) network, to identify the site. Currently, Earth Science has for main and for meta. The problem I see is that these are awfully similar (i.e. exactly the same, as demonstrated here) to those for Spanish.SE, which are for main and for meta. The larger versions offer slight differences, but it's still hard to tell quickly which is which. Power users on this site, did you guess right, even after some time to think about it? (Answers under spoiler tag). for main and for meta. for main and for meta. The first one is Earth Science and the second is Spanish. Should SE visually distinguish between the two very different sites?
I am using URLDownloadToFile to download the files from URL. while downloading URLDownloadToFile API creates cache files in INETCache if "Temporary Internet files and website files" is unchecked in Internet Explorer "Delete browser history settings". can we prevent creating these cached files ? Your help will be appreciated :)
I am using URLDownloadToFile to retrieve a file from a website. Subsequent calls return the original file rather than an updated version. I assume it is retrieving a cached version.
I just downvoted this question (screenshot in case it gets deleted): However, when I go to the timeline, it shows that my vote happened 14 hours ago. The question was only asked 2 hours ago: Has SE invented a voting time machine?
The new timeline is pretty snazzy. But there's one thing I've noticed that's a bit jarring; the timestamp for vote summaries is always 0:00:00 on a particular day, and the summary covers the rest of that day. So you end up with a summary that always shows up earlier than the events that presumably triggered the votes that show up in it. A simple solution is to have it display 23:59:59 instead, and sort accordingly. This way the summary comes in after the events it summarizes.
I downloaded a software package in a .tar.bz file. I understand that I can install such packages through make install, but then there's no easy way to uninstall. Is there a way that I can add this package to my local repository, so that I can install/uninstall it through apt-get?
I have always had a problem installing and removing compiled software, so I have decided I would like to build software from source into a .deb package for easier installation/removal. I would like to know of an easy and short way to build source into a .deb package, as an end user. I have tried: , which did not work for me This guide, but I found it too long
In bash, I tried writing a script to run the last N commands. For say, N=5 for i in {1...5} do !-5 done The problem is that !-5 gets replaced by the 5th-last command on my shell (say time) and the 'time' command runs 5 times. Can I make any alteration to my script to make it run the last 5 commands on my shell in series? NOTE: I posted this question AFTER checking out other similar question which did not answer my requirements. The situation were analogous to this: Qn1 - "How do you print 3 consecutive tildes '~~~' in C++" Ans: cout<<"~~~"; Qn2 - "How do you print N consecutive tildes '~~~' in C++" Ans: Run a loop and do cout <<"~"; inside the loop The questions marked duplicate are similar to Qn1 from above and what I wanted was the answer to Qn2 from above. So, I debate the fact that it is a duplicate to the previous question.
Suppose I want to execute a sequence of four commands that I have executed before. If the first one is 432 in the command-history, then I could do: $ !432; !433; !434; !435 I'm curious, is there a more efficient way to accomplish this?
Imagine a scenario where there are only two players. One of the players has only one card left, which is Draw 2 card. If he/she puts the card in the field, can the other player counter act with a Draw 2, or is the game over?
When playing with progressive Draw 2 and Draw 4 and (say that there are 2 players playing) and Player 1 goes out with a Draw 2 Player 2 puts down a Draw 2 Does player 1 have to pick up 4 cards?
I have Ubuntu server and we are using putty to take remote session from Windows. I want to record the activity which was done by putty session by any user. Is it possible? If yes then how?
Our small company runs an Ubuntu Server 11.10, to which a couple of people have SSH access. The actual terminals are sometimes used, too. How can we locally log all Bash commands run, along with user and time stamp? We can assume that no-one is nefarious and actively trying to avoid the logging, but we'd still prefer the users not to have direct write-access to their log files. Simultaneous sessions must be handled correctly.
Which of the following cases is better for performance or proper techniques? CASE #1 function SomeClass () { this.someVar = null; this.someFunc = function () {} } CASE #2 function SomeClass () {} SomeClass.prototype.someVar = null; SomeClass.prototype.someFunc = function () {}
What's the difference between var A = function () { this.x = function () { //do something }; }; and var A = function () { }; A.prototype.x = function () { //do something };
I beat Rogue Legacy twice recently and I'm now at New Game +2, however, I don't like it. It's too difficult for me. Is there a way to go back to New Game+ without re-doing everything? I have located the save files but opening in notepad doesn't really tell me anything. Is there a way to edit the save files, or even an in-game option?
I've defeated the final boss in a very cheesy way (Babarian Tank with a lot of Damage Return). Now I have a hard time even getting some money in the castle of New Game Plus - is there some way to return to the old "easy" castle ?
I don't have SAS and the dataset with me, so I made up this table (from my memory). Basically this is what I got: After deciding to leave the variable $age$ and $risk$ in my model, I created this interaction term. According to the yellow table, I suppose I should not drop this term since that would significantly impact my model (if I haven't interpreted it wrong). However, there are several levels within each class. We see that the test statistics of $old*standard$ is insignificant. Question 1: Does it make sense to drop this particular level of interactions and run regression on the others? Question 2: If that does make sense (which I doubt), do I create dummy variables on the reference levels as well? How would I interpret the intercept then?
After seeking clarification about linear model coefficients I have a follow up question concerning non-signficant (high p value) for coefficients of factor levels. Example: If my linear model includes a factor with 10 levels, and only 3 of those levels have significant p values associated with them, when using the model to predict Y can I choose to not include the coefficient term if the subject falls in one of the non-signficant level? More drastically, would it be wrong to lump the 7 non-significant levels into one level and re-analyze?
The dihedral group consists of rotations and symmetries. But the symmetry group is a group only if n is even, thus the group of rotations is a normal subgroup of the dihedral group. So how to describe this normal subgroup(rotations) and are there any other normal subgroups of the dihedral group?
In relation to , I am curious about what exactly are the normal subgroups of a dihedral group $D_n$ of order $2n$. It is easy to see that cyclic subgroups of $D_n$ is normal. But I suspect that case analysis is needed to decide whether dihedral subgroups of $D_n$ is normal. A little bit of Internet search suggests the use of semidirect product $(\mathbb Z/n\mathbb Z) \rtimes (\mathbb Z/2\mathbb Z) \cong D_n$, but I do not know the condition for subgroups of a semidirect product to be normal. I would be grateful if you could suggest a way to enumerate the normal subgroups of $D_n$ that does not resort to too much of case analysis.
I need to add leading zeros to integer to make a string with defined quantity of digits ($cnt). What the best way to translate this simple function from PHP to Python: function add_nulls($int, $cnt=2) { $int = intval($int); for($i=0; $i<($cnt-strlen($int)); $i++) $nulls .= '0'; return $nulls.$int; } Is there a function that can do this?
Given: a = 1 b = 10 c = 100 How do I display a leading zero for all numbers with less than two digits? This is the output I'm expecting: 01 10 100
If I have priority and cast an on a just summoned 2/3 creature, then, passing priority, my opponent casts a on that creature, does my creature survive? The first spell that resolves is obviously the bolt, that deals 3 point of damage to the creature; but immediately after, will the Unholy Strength resolve (giving +2/+1), allowing the creature to survive?
If I have got a creature with "inflatable abilities" - just like , or - I want to know what happens when activating it. Since inflatable abilities are activated abilities, if I activate three times Granite Gargoyle's ability ({R}: +0/+1 until end of turn) in response to each other, they go on the stack one after the other, and my opponent may respond to this with a Shock targeting the Gargoyle. So, in such a situation, the Gargoyle dies, and goes to the graveyard before his ability comes to rescue. Is this correct?
How to block all the network traffic from one user? But other users are alive to the network that the blocked user is able to connect to other users who have the permission to the internet.
Let's say there are two users on the LAN, A and B. How do I restrict user A from internet access using iptables rules and saving the rules so that after reboot, they are still effective. Suppose also that I want to grant that user access at some point; how do I enable it again? I am using Ubuntu Linux 10.04. It would be nice if anybody show me how to do it from the command line, as I often login to the machine using a local ssh login.