Which StackExchange site is for asking about AutoCAD?
Which Stack Exchange site is best for AutoCAD questions?
$x_{1}...x_{n}$ are independent continuous random variables with common distribution function $F(x)$,consider the order statistics $(x_{(1)},...,x_{(n)})$, compute $E(F(x_{(n)})-F(x_{(1)}))$  I have no idea to this problem, anyone could help me? Thanks! With \setbeamercovered{transparent} covered parts of a slide are displayed transparently. If there is a (small) picture among the text, it is shown as it is. Beamer has only this picture, so it shows this picture. My question: How can I give a gray version of the picture to beamer such that in covered parts of a slide, this gray version is used? How can I get numbered classes on rows? I worked briefly with Drupal 7 and I thought it was possible there but in Drupal 8 is it possible to have a view output an increasing numbered CSS classes for Views rows?  This is what I want.  &lt;div class="view"&gt;   &lt;div class="view-row-1"&gt;&lt;/div&gt;   &lt;div class="view-row-2"&gt;&lt;/div&gt;   &lt;div class="view-row-3"&gt;&lt;/div&gt;   &lt;div class="view-row-4"&gt;&lt;/div&gt; &lt;/div&gt;   I know I can add a CSS class to every row and give every row the same class. Render scene with background jpg in python Fairly new to python and blender, so apologies if this is super basic. I've searched around and haven't found an answer.  I'd like to render some procedurally generated objects with a background image. In case it makes a difference, I'm using:    I don't need any interaction between the generated object and the background image so I've left a skeleton script I'm using to render below  import os DIR ="/home/path/to/folder" bg_file = os.path.join(DIR, "myimage.jpg") bg_img = bpy.data.images.load(bg_file) bpy.data.scenes['Scene'].render.filepath = os.path.join(DIR, "image") bpy.context.scene.camera = bpy.data.objects['Camera'] bpy.ops.render.render(write_still=True)   I managed to find some scripts that seem to be trying to do what I want online, but none that I could get to work. e.g.  import bpy filepath = "/home/path/to/folder" img = bpy.data.images.load(filepath)  for area in bpy.context.screen.areas:     if area.type == 'VIEW_3D':         space_data = area.spaces.active         bg = space_data.background_images.new()         bg.image = img         break  cam = bpy.data.cameras.new("Camera") cam_ob = bpy.data.objects.new("Camera", cam) bpy.context.scene.camera = cam_ob bpy.context.scene.objects.link(cam_ob) bpy.context.scene.objects.active = bpy.context.scene.objects["Camera"]   Any thoughts/tips would be greatly appreciated! Why won't attribute modifiers add up on my armor? Effect of elementary row operations on determinant? Linear regression with fixed point I have a data set to which I want to add a trend line. For my system, there will always be a fixed point on (2, 0). I have the line representing this system, but currently I do not account for the fixed point. Is there functionality to achieve this?  \begin{figure} \begin{tikzpicture} \begin{axis} [     ylabel={Some Time [ms]},     ]     \addplot[only marks, color=red, error bars/.cd,                        y dir=both, y explicit]         table [x=num_of_nodes, y=MyData, y error=stdev_delay_var] {MyData.dat};     \label{plot_one}     \addplot +[mark=none, dashed]          table[y={create col/linear regression={y=MyData}}]         {MyData.dat}; \end{axis} \end{tikzpicture} \caption{Test Results} \label{fig:test_results} \end{figure} I work at an embedded software company. This morning I found a USB stick in the parking lot in front of the building. With all the stories of "dropped USB stick attacks" in mind, I'm obviously not going to just plug it into my laptop. OTOH, I'm curious to know whether this was actually an attempt to compromise our systems, or it's really just an innocent case of somebody accidentally losing a USB stick. How do I safely inspect the USB stick without risking exposure?  I'm worried not just about malware and crafted file system images; there's also stuff like power surge attacks:.  EDIT: Many of the answers seem to assume I want to keep the drive and use it afterwards. I have no interest in that at all, I know USB sticks are cheap, and that it wouldn't be mine to keep anyway. I only want to know whether this was indeed a semi-targeted attack, partly out of curiosity whether this actually happens in real life and not just in security papers, but also so that I could warn my coworkers.  I want to know how I would figure out whether the stick contains malware. And that's not just a matter of looking at the drive contents and seeing a suspicious autorun.inf or a carefully crafted corrupt file system - I very much also want a way to inspect the firmware. I sort-of expected that there were tools for extracting that and comparing to known-good or known-bad binaries. Working in a group blender project Me and my team are new to blender, we are now planning for a small project. What I want to ask here are some questions regarding the team work:   We use git for version control in web projects, Is there any special version control for blender project. Creating object of each file and integrating in the project is one way we saw to complete the project. But is there any good way to work in the group?   Please tell us from your experience what might be the best way to work together in a group blender project. Prove that $ S=\{0\}\cup\left(\bigcup_{n=0}^{\infty} \{\frac{1}{n}\}\right)$ is a compact set in $\mathbb{R}$, but $\bigcup_{n=0}^{\infty} \{\frac{1}{n}\}$ is not a compact set.   (Can we use definition of compact set for this problem? ) OK, I've been having weird problems for the last 1/2 hour trying to  on StackOverflow, and I keep getting this result (on Firefox 3.6)     The connection was reset      The connection to the server was reset while the page was loading.         The site could be temporarily unavailable or too busy. Try again in a few        moments.   If you are unable to load any pages, check your computer's network        connection.   If your computer or network is protected by a firewall or proxy, make sure        that Firefox is permitted to access the Web.      The problem seems to occur when I try to post some code with 'd--- table' in it, where 'd---' is replaced by the word drop.  I cannot post the following 3 lines, in either SO or this site, if they include the well-known SQL statements DROP.  stat.executeUpdate('d--- table if exists people;'); stat.executeUpdate('create table people (name, occupation);'); prep = conn.prepareStatement(...     'insert into people values (?, ?);');   test again:  'dro* table' 'drop ball' drop the table drop fable drop    t*ble droptable   drop a table  The evil words for me are "drop" and "table"... how come you guys can post? :(  edit: Could someone please suggest another online site that is not stackoverflow that is a quick way to try out a POST request of a text field?  UPDATE: Never mind. I don't know what the answer is, but the same problem occurs on Google's website. So it's not stackoverflow. Now to go to my IT Dept... How to delete directories with path/names too long for normal delete error when adding user to wheel group in CentOS 7 I am trying to grant sudo privileges to a user of a CentOS 7 devbox by typing gpasswd -a user wheel, but the attempt is failing.  What am I doing wrong?    Here is what I typed:    I discovered that the user is not in the wheel group as follows:    [user@localhost git]$ sudo yum install git [sudo] password for user:  Sorry, try again. [sudo] password for user:  Sorry, try again. [sudo] password for user:  user is not in the sudoers file.  This incident will be reported.   I then logged in as root and typed the following to add the user to the wheel group:    [user@localhost git]$ su - Password:  Last login: Thu Aug 20 17:11:31 PDT 2015 on pts/0 [root@localhost ~]# gpasswd -a user wheel Adding user user to group wheel [root@localhost ~]# exit logout   I finally tried to use the sudo command again but it failed as follows:    [user@localhost git]$ sudo yum install git [sudo] password for user:  user is not in the sudoers file.  This incident will be reported. [user@localhost git]$ I improved an edit... but did I actually? I don't know how I did manage to do it.  I just ... Oh wait, did I do it actually? I actually simply approved it! You can see it . Apparently, I made no changes myself.  But now I'm struggling to understand how exactly was I able to do it, because in 79% of cases I am greeted with this message:        and in another 20%, this faked "improve" goes through (while I don't change completely anything) and I can haz a binding approval vote :D  And in other 1%,  it when I clicked improve (now I know ).  So it's definitely a bug, but I can't find the exact way of reproing.  Note: earlier there was actually a bug which allowed me to approve an edit by clicking improve and submitting with no changes, then it was fixed and for some time the message I've shown above stopped me constantly, and now there is another bug Use of Predictable Network Interface Names with alternate kernels Almost constantly, I use kernels from the , or kernels I have compiled myself, using the Ubuntu kernel configuration.  The problem is when I am using the stock kernel it seems to default to using predictable network interface names (i.e. "p4p1"), but when I use any alternate kernel it seems to default to using the old method (i.e. "eth0").  While not really relevant to this question, I had a hard disk failure on my test computer and am doing a new install of Ubuntu Server 14.04.2.  I have not been able to determine what is the difference between the kernels. I suspect a kernel configuration parameter, but have been unable to identify which one.  My question: How can I make predictable network interface names work consistently across all kernels?  Additional notes: Somewhere I saw to disable predictable network interface names to add this to grub:  GRUB_CMDLINE_LINUX_DEFAULT="net.ifnames=0 biosdevname=0"   so, I thought the opposite might help:  GRUB_CMDLINE_LINUX_DEFAULT="net.ifnames=1 biosdevname=1"   but it made no difference. Actually, I can never get the non-stock kernel to use biosdevname, no matter the setting. And I can never get the stock kernel to generate a /etc/udev/rules.d/70-persistent-net.rules file (even though, that is not what I want), no matter the setting of net.ifnames. If I have net.ifnames=1, then at least the non-stock kernel doesn't generate an incorrect /etc/udev/rules.d/70-persistent-net.rules file.  Excerpts from /var/log/udev: stock kernel:  KERNEL[9.216730] add      /devices/pci0000:00/0000:00:1c.4/0000:03:00.0/net/p4p1 (net) ACTION=add DEVPATH=/devices/pci0000:00/0000:00:1c.4/0000:03:00.0/net/p4p1 IFINDEX=2 INTERFACE=p4p1 SEQNUM=1945 SUBSYSTEM=net ... UDEV  [9.241073] add      /devices/pci0000:00/0000:00:1c.4/0000:03:00.0/net/p4p1 (net) ACTION=add DEVPATH=/devices/pci0000:00/0000:00:1c.4/0000:03:00.0/net/p4p1 ID_BUS=pci ID_MODEL_FROM_DATABASE=P8P67 and other motherboards ID_MODEL_ID=0x8168 ID_NET_NAME_MAC=enxf46d04652d8e ID_NET_NAME_PATH=enp3s0 ID_OUI_FROM_DATABASE=ASUSTek COMPUTER INC. ID_PCI_CLASS_FROM_DATABASE=Network controller ID_PCI_SUBCLASS_FROM_DATABASE=Ethernet controller ID_VENDOR_FROM_DATABASE=Realtek Semiconductor Co., Ltd. ID_VENDOR_ID=0x10ec IFINDEX=2 INTERFACE=p4p1   From Ubuntu PPA kernel 4.1RC5:  KERNEL[10.772566] add      /devices/pci0000:00/0000:00:1c.4/0000:03:00.0/net/eth0 (net) ACTION=add DEVPATH=/devices/pci0000:00/0000:00:1c.4/0000:03:00.0/net/eth0 IFINDEX=2 INTERFACE=eth0 SEQNUM=1962 SUBSYSTEM=net ... UDEV  [11.185866] add      /devices/pci0000:00/0000:00:1c.4/0000:03:00.0/net/eth0 (net) ACTION=add DEVPATH=/devices/pci0000:00/0000:00:1c.4/0000:03:00.0/net/eth0 ID_BUS=pci ID_MODEL_FROM_DATABASE=P8P67 and other motherboards ID_MODEL_ID=0x8168 ID_NET_NAME_MAC=enxf46d04652d8e ID_NET_NAME_PATH=enp3s0 ID_OUI_FROM_DATABASE=ASUSTek COMPUTER INC. ID_PCI_CLASS_FROM_DATABASE=Network controller ID_PCI_SUBCLASS_FROM_DATABASE=Ethernet controller ID_VENDOR_FROM_DATABASE=Realtek Semiconductor Co., Ltd. ID_VENDOR_ID=0x10ec IFINDEX=2 INTERFACE=eth0 SEQNUM=1962 SUBSYSTEM=net USEC_INITIALIZED=3227   Note: I have temporarily moved past this issue by allowing a /etc/udev/rules.d/70-persistent-net.rules file to be created, and then editing it for proper device names. Ultimately, I would like to get rid of the file. Question about a bijection between $\mathbb R$ and $\mathbb R \cup \{\infty\}$ About a bijection between $\mathbb R$ and $\mathbb R \cup \{\infty\}$  If we'll take a line $f(x)=\begin{cases} ax &amp;, x\in\mathbb R\\ 0 &amp;, x=\infty  \end{cases}$ then we'll have a bijection.   But about this function: $g(x)=\begin{cases} x &amp;, x\in\mathbb R\setminus \{0\}\\ 0 &amp;, x=\infty  \end{cases}$ ? it appears to be a bijection and it's even simpler. Say if $A$ is an $n \times  n$ matrix, why is it that if $A^{T}A$ is positive definite, the matrix $A$ is then invertible? All I know is $A^{T}A$ gives a symmetric matrix but what does $A^{T}A$ is positive definite tell or imply or hint about the matrix $A$ itself that leads to the fact that it will be invertible? My question is not about (pseudo) philosophical debate; it concerns mathematical operations and experimental facts.  What is an observer? What are the conditions required to be qualified of observer, both mathematically and experimentally? Getting a random object from NSArray without duplication Create Generic method constraining T to an Enum I'm building a function to extend the Enum.Parse concept that  Allows a default value to be parsed in case that an Enum value is not found Is case insensitive  So I wrote the following: public static T GetEnumFromString&lt;T&gt;(string value, T defaultValue) where T : Enum {     if (string.IsNullOrEmpty(value)) return defaultValue;     foreach (T item in Enum.GetValues(typeof(T)))     {         if (item.ToString().ToLower().Equals(value.Trim().ToLower())) return item;     }     return defaultValue; }  I am getting a Error Constraint cannot be special class System.Enum. Fair enough, but is there a workaround to allow a Generic Enum, or am I going to have to mimic the Parse function and pass a type as an attribute, which forces the ugly boxing requirement to your code. EDIT All suggestions below have been greatly appreciated, thanks. Have settled on (I've left the loop to maintain case insensitivity - I am using this when parsing XML) public static class EnumUtils {     public static T ParseEnum&lt;T&gt;(string value, T defaultValue) where T : struct, IConvertible     {         if (!typeof(T).IsEnum) throw new ArgumentException(&quot;T must be an enumerated type&quot;);         if (string.IsNullOrEmpty(value)) return defaultValue;          foreach (T item in Enum.GetValues(typeof(T)))         {             if (item.ToString().ToLower().Equals(value.Trim().ToLower())) return item;         }         return defaultValue;     } }  EDIT: (16th Feb 2015) Christopher Currens has posted  below, which is well worth a look, and an upvote. I will remove this edit if the solution bubbles further up the page. EDIT 2: (13th Apr 2021) As this has now been addressed, and supported, since C# 7.3, I have changed the accepted answer, though full perusal of the top answers is worth it for academic, and historical, interest :)