Using the caption package I can set the style for captions for all floating elements in my document:  \usepackage[font={small,it}]{caption}   Now, suppose I want my figures captioned like this, but my tables captioned in bold. How can I achieve this?  The documentation tells me I can define two caption styles, and switch between them manually every time I insert a figure or table using the \captionsetup command. Is there a better way?

I need to have different caption format for figures and for tables. Captions for figures have to be centered and captions for tables - left aligned. How to define this?


Background  I have a Dell Inspiron 1525 laptop from 2008, which has a Broadcom wireless chip. I have previously successfully used Ubuntu/Kubuntu on it by installing the firmware-b43-installer package, certainly on 14.04, I can't recall if I've installed 16.04 before on this laptop.  Recently, I installed Ubuntu 16.04, and installed firmware-b43-installer as before. Running sudo modprobe b43 makes the wireless work, but this does not persist after reboot.  The b43 module is blacklisted by /etc/modprobe.d/blacklist-bcm43.conf, which is autogenerated by bcmwl-kernel-source. This blacklisting doesn't stop sudo modprobe b43 from working - it loads the module anyway and WiFi then works until reboot.  What I've tried   Adding b43, preceeded by its dependencies, in /etc/modules, running sudo update-initramfs -u, and rebooting. The module does not get loaded. Adding b43, preceeded by its dependencies, in /etc/initramfs-tools/modules, running sudo update-initramfs -u, and rebooting. The module does not get loaded. Adding b43, preceeded by its dependencies, in both /etc/modules and /etc/initramfs-tools/modules, running sudo update-initramfs -u, and rebooting. The module does not get loaded. Uninstalling bcmwl-kernel-source in order to remove /etc/modprobe.d/blacklist-bcm43.conf, in combination with 1, 2, and 3 above. The module does not get loaded, and running sudo modprobe b43 manually no longer works, so I presume that the bcmwl-kernel-source package is necessary for b43 to work, despite the fact that bcmwl-kernel-source blacklists b43. Leaving bcmwl-kernel-source installed, but manually deleting /etc/modprobe.d/blacklist-bcm43.conf, in combination with 1, 2, and 3 above. The module does not get loaded, but running sudo modprobe b43 manually once booted works. Adding a script to root's crontab on @reboot that loops running modprobe b43 until lsmod indicates that it is loaded. The script runs, and keeps running indefinitely, but the module never gets loaded, despite the fact that the script works when run manually from a terminal once booted.

I'm having serious problems installing the Broadcom drivers for Ubuntu. It worked perfectly on my previous version, but now, it is impossible.   What are the steps to install Broadcom wireless drivers for a BCM43xx card?  I'm a user with no advance knowledge in Linux, so I would need clear explanations on how to make, compile, etc.    lspci -vnn | grep Network showed:   Broadcom Corporation BCM4322 802.11a/b/g/n Wireless LAN Controller [14e4:432b]      iwconfig showed:  lo        no wireless extensions. eth0      no wireless extensions.   NOTE: Answer below is updated every time new information is added and confirmed working.


I currently have  and would like to add automatic control over the PWM based on a thermistor reading. Any insights?

I am mildly familiar with electronics, mostly from playing around with electronics kits as a kid. That was a long time ago, though, maybe as much as 20 years ago. I am currently working on a cold or "chill" box for my Canon 5D III, so I can keep it's temperature very low, and very consistent, for doing low noise astrophotography.  I have a general design for the box, and I'm using a single 12v 5.8amp peltier (TEC) attached directly to a copper box for cooling. The box is currently insulated with extruded foam board, and the hot plate of the peltier will be cooled with a water cooler from an old computer kit.   I'm getting more ambitious with my project, however. I want thermal regulation, to maintain a consistent temperature, and I'd eventually like to get into two-stage cooling to achieve a Delta-T of closer to -55-60°C relative to ambient (the chill box will be cooling the camera, so the sensor will be warmer, probably by as much as 10°C, than the temperature of the copper plating in the box itself.) I want to have two primary modes:   Rapid cooling mode, operating the peltier at 12v or higher (max voltage is 15.4v) to quickly cool the box down to the target temperature. Regulated maintenance mode, operating the peltier at lower voltages to maintain a consistent temperature, above the maximum potential cooling the peltier can supply (for headroom as the voltage is adjusted in response to small temperature fluctuations).   I'd like to maintain temperature within 2-3°C if possible. I've looked into Arduino (and I've messed with similar things in the past), and it seems perfectly ideal for the task, with one exception: It doesn't seem to handle the kind of current I need top power a single peltier, and certainly not two.   I've done some research on how I might achieve this, but I'm falling up short on my understanding of the electronics involved. I've found a two-relay "shield" for Arduino Uno that can power two devices with up to 8amps each, and up to 30v each. That can be controlled from the Arduino itself. It seems the design of a relay uses a magnetic coil to actuate a switch that allows an independent power source to be used to power components like a motor, solenoid, or in my case a peltier. I haven't found any way of actually regulating the voltage of the relay with the Arduino, however.  So I kept investigating, and I came across some schematics that showed how to use transistors, specific mosfets to be exact, where the base was connected to an Arduino output, and the collector/emitter were connected to the power loop of whatever needed to be powered at a higher voltage (not sure about current here), and this still allowed control of the voltage.   It's been so long since I messed with any of these components, my memory is extremely rough, and I'm not quite connecting how it all works. I'd be happy with some references to complete examples of powering, and controlling the voltage of, high powered devices via an Arduino, but if anyone here can explain how all this works and why, that would be most ideal. I'd rather understand the concepts, so I can reapply them later, than just have a pattern to follow.


I want a few formulae left align (but not all in formulae in the document) and use flalign following   but the result shows the formula in the center. Why?  \documentclass{article} \usepackage{amsmath}  \begin{document} the formula:  \noindent A \hfill Z \begin{flalign} 1 \in N \end{flalign}  \noindent A \hfill Z  more text   \end{document}   result:

When using the flalign, I either get LHS and the = on te far left and the RHS on the far right.    \begin{flalign} x & = & 1 \end{flalign}   Or I the equation centers itself when I try    \begin{flalign} x & = 1 \end{flalign}   How can I get everything on the LHS?


While I understand I'm probably better off importing the entire class,  I'm still wondering how I could import static functions from a class so that I can call them without precursing their names with the class name.  Specifically, I'm trying to run this:  import java.lang.Math.pow;   so that I can call pow(2,3) instead of Math.pow(2,3)  This obviously gives an error... What's a more appropriate way to write it?

When used like this:  import static com.showboy.Myclass;  public class Anotherclass{}   what's the difference between import static com.showboy.Myclass and import com.showboy.Myclass?


You can delete a question you posted, you can delete a comment you posted, it's absolutely ridiculous that you cannot undo flagging a comment if you flagged it by mistake.  Please implement this feature.

I'm wondering (since it just happened to me), is it possible to "cancel" ("undo", "delete", "retract", whatever) a flag I just raised if I misclicked it, so the mods won't waste time?  I looked everywhere, but I can't find such a feature.


I'm doing my Master in Occupational Safety and Health. My research topic is on the association between  working condition, safety behaviour and work-related injuries among construction workers.   Safety behaviour was measured for individual workers by observation checklist "Safe - Unsafe and N/A". For some items like Personal Protective Equipment, some workers in specific situation don't have to wear some specific PPE; for example ear defender; when Noise is not exceeding the Threshold limit this PPE in checklist is N/A.   So, the issue is what value should I give to N/A to calculate the overall score for safety behaviour ? Or should I consider it as a missing value ? If so, the overall score will be calculated only for the valid cases and I can not determine the association..

I have the following scales:   1 (Strongly Disagree); 2 (Disagree); 3 (Not Applicable); 4 (Agree); 5 (Strongly Agree);     Questionnaire responses:   Question Item1: 2; Question Item2: 3; Question Item3: 1; Question Item4: 1; Question Item5: 4;   If I need to average the above responses into the Excel Sheet, while treating Question Item2: zero (since it is considered missing data), do I need to divide by 5 or 4 items to obtain the average?  $$\text{Average} = \frac{2 + \mathbf 0 + 1 + 1+ 4}{5}\quad\text{or}\quad\text{Average} = \frac{2 + \mathbf{\_} + 1 + 1+ 4}{4}$$  Kindly advise.


I have a string that I've converted to a datetime object using parse.  time = 'Tue, 30 Sep 2014 16:19:08 -0700 (PDT)' date_object = parse(time)   I want to find the time that has elapsed since then. I tried using datetime.datetime.now() and subtract the two, but they are different format and was throwing an error.  What is the best way to do this?

I have a Python  object. What is the best way to subtract one day?


For some "extraction" operation I am trying to get the following snippet work, without using the spread operator, because IE 11 doesn't knows about spread operators. works in Chrome, but not IE 11: html_col_width =[{"targets":0, "width":50}, {"targets":1, "width":100},{"targets":2, "width":442}]          ... some other code         order: [             [response.order_by_column, response.order_by]         ],         columnDefs: [                       ...html_col_width,                       {other: stuff},                       {other: stuff}     })  See columnDefs: ...html_col_width How can I achieve the following without the spread operator: columnDefs: [           {"targets":0, "width":50},           {"targets":1, "width":100},           {"targets":2, "width":442},           {other: stuff},           {other: stuff}     })  I have read and tried the following, but this is not working if the array of objects contains 2 keys: . The content at the provided link is about merging different objects, which makes the question rather different.

I need to be able to merge two (very simple) JavaScript objects at runtime.  For example I'd like to:  var obj1 = { food: 'pizza', car: 'ford' } var obj2 = { animal: 'dog' }  obj1.merge(obj2);  //obj1 now has three properties: food, car, and animal   Does anyone have a script for this or know of a built in way to do this?  I do not need recursion, and I do not need to merge functions, just methods on flat objects.


I'm new to Blender and I was getting hooked on this program. I was working on a project using the viewport shading set to Rendered with the EEVEE render engine because I don't have a very powerful graphics solution. However, last days, the materials on this project didn't appear in viewport shading, or even in the final render. All the previews of the materials have become completely transparent. I thought it was just the damaged project, but unfortunately this problem occurred on all old and new projects. I leave some images and a file as examples. Opening the file on my friend's computer, the materials work (EEVEE), but I can't work on his machine. One more thing, using Cycles the materials work, but using EEVEE they don't work. Unfortunately I can't work using Cycles, it takes too much time and sometimes blender crashes. I tried looking online for solutions to problem like mine or who had a similar experience and I have already tried to apply their various solutions, but none of these solve my problem:       The last topic I didn't understand what should happen if I press Ctrl + Alt + B? Under the View menu, I didn't find View Borders, but using the blender command search I found Clear Render Border, I tried to activate the command but it didn't work. I also tried reinstalling Blender, but it doesn't seem to work and it even remembered my personal configurations! I also tried installing add-ons to try to find an alternative to the EEVEE engine (Radeon pro render [rpr], EEVEE-Preset) but no one of them are for me or repair the EEVEE engine. If you find this information useful to solve my problem as computer I have a  Ryzen 5 2600 processor, Radeon Rx 580 4 GB graphics card 16 GB of RAM.  Just a clarification, I use Blender 2.90.1, can someone tells me a way to restore the correct functioning of EEVEE materials?  Unfortunately I no longer know where to turn and I'm crazy to see all my projects be transparent.

I don't know why but now, when i go in material preview or rendered (in solid mode it works fine), my object is entirely gray, or invisible idk, because it has the same color of the background. I've been working for days on this project without having this issue, it suddenly showed up. I tried opening other old projects and suddenly they all do the same so i guess it is some blender program setting that applies for all the projects, but idk how it happened cuz i didn't change anything :/, anyone got any tips?


We know for any $n\in \mathbb{N}$ ,we can find find n+1. Because we wants to prove it with ınduction. For example$ A=\{a_1,a_2,...a_n\}$ and I proof with Induction $B=\{a_1,a_2,...a_{n+1}\}$ . How should I begin?

What is the proof that given a set of $n$ elements there are $2^n$ possible subsets (including the empty-set and the original set).


I have a separate machine Dell 1545 laptop. I was wondering how to have  a full install using 12.04 LTS on my Vista machine? Can I just put the burned ISO disc in the disc tray and restart then go into Bios- selecting Boot from CD or is it more different than that? I Do Not want to Dual Boot!  Thanks.

I would like to see a full how-to guide on how to install Ubuntu.


I just want to ask you, if I'm installing the Ubuntu beside the windows without any partition changes, using wubi does the ubuntu using more performance (CPU, memory, hard drive), or same as a normal installation?  Thanks.

I know that Wubi is slower in disk IO, but I can't find anything about it online other than vague statements such as "slightly slower disk seeks".  Has anyone done any benchmarks to quantify the speed difference?


I have 2 classes and 2 interfaces in my project. In my main(), i have Null Pointer Exception on produce() function. I tried to do produce function to static but it didn't work for me well. Here is my codes, what's the problem ?  This is my CarProjectTest.java codes  import java.util.Scanner;  public class CarProjectTest{     private static int velocity;     private static double time;     private double price;     private CarDecorator carDecorator;     public static void main(String[] args){         String carType;         Scanner user_input = new Scanner( System.in );         // TODO initiate factory!         ICarFactory factory = null;         System.out.print("Lütfen üretilecek arabanın modelini giriniz: ");         carType = user_input.next();         System.out.println(carType);         System.out.print("Lütfen ortalama hızı giriniz: ");         velocity = user_input.nextInt();         System.out.println(velocity);         System.out.print("Lütfen zamanı giriniz: ");         time = user_input.nextDouble();         System.out.println(time);          ICar car1 = factory.produce(carType);          System.out.println("Price: " + car1.getPrice());         System.out.println("Message: " + car1.getMessage(90));         System.out.println("Fuel Consumption: " + car1.getFuelConsumption(100, 1.2));          /*car1 = AirConditioningDecorator(car1); // please read the name carefully and think about the hints         System.out.println("Price: " + car1.getPrice()); // Price should increase by 1000 TL          car1 = AutoShiftDecorator(car1);         System.out.println("Price: " + car1.getPrice()); */     }      //functions         public ICar produce(String carType){         if(carType.equals("TN100")){             carDecorator.setEngineVolume(1.33);             carDecorator.setWeight(768);             carDecorator.setPrice(20000);             carDecorator.setFuelConsumption(velocity, time, 5);                                    }         else if(carType.equals("TN200")){             carDecorator.setEngineVolume(2);             carDecorator.setWeight(900);             carDecorator.setPrice(25000);             carDecorator.setFuelConsumption(velocity, time, 7.2);                                                }         else if(carType.equals("TN300")){             carDecorator.setEngineVolume(2.4);             carDecorator.setWeight(1100);             carDecorator.setPrice(30000);             carDecorator.setFuelConsumption(velocity, time, 9);                                         }         return carDecorator.getDecoratedCar();                                         }  }   and there is my ICarFactory class  public interface ICarFactory {      public ICar produce(String carType);  }   This is the error what i take;  Exception in thread "main" java.lang.NullPointerException     at com.project.factory.CarProjectTest.main(CarProjectTest.java:25)  25th line is: ICar car1 = factory.produce(carType); in Test class

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


I have a jsfiddle here -   I know this is simple but it's driving me mad  I have a div containing a ul list with a links in.  I need the links to be dead center, I need the gap between the links to be dead center.  Whatever I do the links are always slightly off.  Is there a way to have them dead center.  In the actual design it is obvious as the page is split with a color down the center.

Link One

Link Two

How can I horizontally center a
 within another
 using CSS?

Foo foo


I want to find all integer solutions for $1+2^{a}+2^{2a+1}=b^2$. How could I do this?

What are the solutions in positive integers of the equation:  $${1+2^x+2^{2x+1}=y^2}$$ I tried to factorize the equation but it didn't help much. Clearly $y $ is an odd integer. Substituting $y =2n+1$, we get  $2^x+2^{2x+1}=(2n)\cdot{(2n+2)}$ $\Rightarrow (2^{x-2})\cdot(1+2^{x+1})=(n)\cdot(n+1)$ Which is the product of 2 consecutive integers. Does it help? I don't know.


I have an external HDD which suddenly seems infected and one of my folders which contain my photos changed to something like this:    One of Super User guys suggests that I install an Ubuntu and try to scan and change permissions, but I am not an Ubuntu expert, and believe me if my problem solve I will switch to it ('cause all I do is writing and taking photos. I am tired of malware, etc.)   Now I have Ubuntu and Fedora installed (after a long read through guides); both of them show infected folder as empty (in Windows 7 I see this strange folders, as you can )

I have an external hard disk , just connected to another system and when i connected to my own computer one of my folders which contain photos become hidden system files AND all folders in it rename to same name !?!? and my access is denied ( Screenshot )    I tried to change ownership but i can't  Any solution !?


The hardest thing for me on this site is always determining how much detail to hit someone with: do I make it generic and possibly miss the exact point? Or make it specific and in depth, in which case it feels like I am just providing a solution?  There are always factors to take into account (My main two are always: Is the question genuine? Is the asker seeking an explanation or simply trying to get a pre-made answer?)  Any help would be greatly appreciated, as I believe it would help to improve not only my answers but perhaps provide a reference point for everyone who feels in the same position as myself.  In regards to situations where someone is simply looking for a straight up solution to a problem, the choice is easy: either ignore them if they have not put in any reasonable effort of their own or leave a comment with no answer forthcoming.   However, how much detail should one go into when answering a valid question? Should we give a fully worked demonstrable answer or theoretical overview (generally speaking I mean, as sometimes one or the other will be more appropriate based on phrasing of the question).

If a user asks a question that is rudimentary and shows that perhaps they are new to programming, is it better to give a complete, working solution or point them in the right direction so they can teach themselves?  More specifically, I mean in a situation where the user seems to want 'codehereplz' instead of at least giving something a try after being given 'hints' or a partial non-code solution.  I know that I learn best by doing something myself after being pointed in the right direction, but is that the best thing to do?


I couldn't find a duplicate-like of this question. I'm also not sure whether this is an electrical engineering question or a physics question.   As most of you noticed when one needs to use larger capacitor values the type of capacitors available to use are polarized capacitors such as tantalum or electrolytic capacitors.   What is the relation between large capacitance and being manufactured polarized?  is that the same reason: if we ask why are capacitors with small values are manufactured non-polarized?

Question emerged from my last question about small caps' markings, better to open new question so not become bloated.  Heard term polarization in the context of light but not with caps. Googling revealed the effect: . Not sure whether it is the right effect but at least it mentions cap.  1. What does the term "polarized" mean?  2. Why should I use "polarized" cap instead of non-polarized cap?  3. Why does the circuit need a polarized cap?


We very well know that  is given by $E = mc^2$. My question however is how would we actually convert an object or some mass into its pure energy state and then if possible even back to its original state. The answer needs to state the requirements for conversion into pure energy. We all know its possible theoretically but how would it be done in a practical world. Just assume that the mechanism required for the process is possible. In short I want the process/mechanism for how to go about it.

I understand the energy and mass can change back and forth according to Einstein. It is fluid; it can go from one to the other. So, what keeps mass from just turning into energy? Is there some force holding a subatomic particle together? What keeps mass in it's state? I hope this is not a silly question but I am clueless. Thanks


This question may seem like a duplicate, but I haven't seen any satisfactory answer in similar questions.  Is there a way to add a line break in displayed math mode without using multiple-line environments such as gather or eqnarray? I want to display an equation that spans multiple lines inside an equation environment (so that the entire thing only gets one number).  My current code:  \begin{equation}    A_i=A_0-\sum_{j=0}^{i-1}[(2^i\cdot3)\cdot\frac{s_i^2}{18}\cdot sin(\alpha)]=%    \sum_{j=0}^{i-1}[(2^i\cdot3)\cdot\frac{(\frac{s_0}{3^i})^2}{18}\cdot sin(180º-\frac{120º}{2^i})]=%    \sum_{j=0}^{i-1}[(2^i\cdot3)\cdot\ddfrac{s_0^2}{18\cdot3^{2i}}\cdot sin(180º-\frac{120º}{2^i})] \end{equation}   This "overflows" the line:   I want to add a line break in between (after one of the = signs), but still have the whole thing labelled as (4.7).

I am having the following equation:  \begin{equation}   Q(\lambda,\hat{\lambda}) = -\frac{1}{2} P(O \mid \lambda ) \sum_s \sum_m \sum_t \gamma_m^{(s)} (t) \left( n \log(2 \pi ) + \log \left| C_m^{(s)} \right| + \left( \mathbf{o}_t - \hat{\mu}_m^{(s)} \right) ^T C_m^{(s)-1} \left(\mathbf{o}_t - \hat{\mu}_m^{(s)}\right) \right) \end{equation}   which does not very well fit on one line. How can I split this over two lines? What I have in mind is that I specify the splitting place, and that the first line is left aligned and the second line right aligned to make clear that it is still the same equation.  The linebreak \\ does not work.


I can't seem to run an exe file in ubuntu 12.04.  I don't have anything configured, and I'm a complete novice to Wine, so put it in layman terms.

Can .exe and .msi files (Windows software) be installed in Ubuntu?


It's my first time working with a two-column document (declared as an argument to \documentclass) and I need to put in a very wide figure. The thing is, LaTeX puts it bounded by a column so it either (1) gets truncated, bleeding off the border or [right column] or (2) displays with an awkward text/line wrapping. Is there any way for me to get it to display the way \maketitle does, that is, at the top of the page (ideally) but at least spanning both columns and no awkward line wrapping? BTW, I use the following code to display my figure: \begin{figure}     \centering     \includegraphics[width=6in]{tictac.png}     \caption{\textsf{The structure of our tic-tac-toe implementation.}}     \label{fig:ds} \end{figure}

If I just try to set the figure's size to 0.9\textwidth my figure will just end up on the right column, sized to be two-columns wide.  Has anyone done this before?


Does anybody know what this style of art called?  As I want to recreate the same style, is there any suggestion for techniques?

There are plenty tutorials online on how to create 3D red/cyan anaglyphs from existing photos in Photoshop or similar software. However, I'm wondering if it is possible to draw a 3D image by hand on for example a whiteboard using markers.  My plan is to tape together a red and blue marker and draw with it using the same rotation/inclination of the marker across the drawing. Will this give a 3D effect when viewed through red/cyan glasses? Or is the 3D anaglyph method more complex than just offsetting red and cyan lines?


When I try to unwrap my mesh, nothing shows up in my UV/Image editor window.  I have tried simple and complex parts, imported and native mesh, all same result. Nothing shows up when I hit unwrap.

I'm trying to unwrap a cube (I know, super complicated). I've got the seams marked, the UV editor open in a 2nd window, and all the geo highlighted. When I tell the cube to unwrap nothing happens. That's pretty much the long and short of the problem. Now I've been working off this one file for a couple weeks now, saving it off the original file and continuously cloning geometry. It's entirely possible I did something, pressed a button, something.   Any thoughts.


How do I use ClamAV to scan the entire computer? Im on Ubuntu 16.

I installed  via Terminal (Ctrl+Alt+T) with:  sudo apt-get install clamav   but how can I scan for viruses?


I created a timeline view and it works fine, still, I need to add translatable nodes, I added another display and replace it in the page that I want, my problem is when I change the page to the other language, it's showing me all the nodes that I made in content types that related with the timeline. How can I add only the translatable nodes to the other view display? is there another way to add these nodes? appreciate any help with this issue.

This is probably very easy but endless searching has proved fruitless - there's lots of UI changes between the D7 and D8 versions of these modules it seems.  What I want to do is create a blog in two languages. The default language is English. Mostly, the author will be translating the articles to Italian. However, I would like to create the blog view such that:   only one translation shows in the list, per node if viewing the site in italian but there is no translation of a specific list item to italian, the english version shows (fall back to default language) if he's only written an italian version, show that anyway instead of the non-existent english one   The options in views are similar looking to everywhere else, but in those other places this isn't really an issue. In standard nodes, the fallback kicks in automatically. Any ideas of how to configure this?


Let $A, B, C, D$ will be square matrices $n  \times  n$ over $R$.  Suppose that with $AB ^{T}$ and $CD ^{T}$ are symmetrical and $AD ^{T} - BC ^{T} = I$.  Show that: $A ^{T} D - C ^{T} B = I$:  I'm trying to transform the last equation, but it comes to me something like this: $A^{T} C   = C ^{T} A$ I do not know I can prove it. maybe I do it not as it should be, I would ask for any hint.

Let A,B,C,D be complex matrices $n \times n$ such that $AB^T,CD^T$ are symmetric and $AD^T-BC^T=I$. Prove that $A^TD-C^TB=I$. Can anyone give me any idea? Thank you.


Some weeks ago I downloaded Blender 2.71 (Win64) from the official website. The version I was using before was the 2.69, which didn´t give me any problem. But the newest version wont let me use the render preview in cycles, showing me a purple screen instead. Firstly I thought the problem was on the version, but today I installed the program in some friend´s computer and works fine.   I have windows 7 (the same OS as my friends), Acer Aspire, and just formatted it. The blender render lets me use the render view though and I can render images (both with f12 and on the render options) in cycles. I have tried both win32 and win 64, as well as the portable and the installable versions. Any ideas?   Thank you in advance.  Edit: The scene of the image is the default one, with only the cube, the camera and the point lamp on display. The sky has no texture, just the default solid grey. The problem is that the whole viewport turns purple, which could mean that it´s not a missing textures issue. I think that the problem might lay on the graphic drivers, but I don´t know what to do. I really hope the next blender version or ATI actualization may fix the problem.

I made a character, and its one of my first times texturing, and I saved my character into a new folder, and when I came back to the model ALL the textures were pink, I used to know what to do, but I stopped texturing, how do I bring my textures back?


I have several windows drives, allthough I'ḿ not using Windows anymore but too many data on it. Is there a way to convert the filesystems without losing the data or how to fix this issue?  I have 4 drives, 3 of them are mounted, one isn't and gives me following error:  Error mounting /dev/sdh2 at /media/andreas/photo's: Command-line `mount -t "exfat" -o "uhelper=udisks2,nodev,nosuid" "/dev/sdh2" "/media/andreas/photo's"' exited with non-zero exit status 32: mount: unknown filesystem type 'exfat' (udisks-error-quark, 0)

When I insert a USB stick or camera flash card I get the following error:  unknown filesystem type 'exfat'   Is there a simple way to add exFAT support to Ubuntu without kernel patching?


I want to insert a line in my Sage software.  What do I use for an insert key? Thanks.  Please just answer if you actually have done it, because some of these other answers do not actually work. Thanks

Long story short, I am using Citrix to remote into my PC at work, and several applications require the use of the INSERT key, which, as everyone knows, Apple chose to eliminate from their keyboards. I've tried everything I can think of, and never been able to find an easy way to send this keycode via Citrix.  I'm sure there are other uses for this, and I've read quite a few people's questions on the subject, but no one seems to have offered a viable solution.  I have the Apple USB keyboard (full-size, with numeric keypad), and in the position where the INSERT key would normally exist, Apple placed the "fn" key. Now, I still need this key from time to time, but what I'd love to see is perhaps Control-fn or similar to send the keycode for INSERT.  If anyone knows how to achieve this, preferably without installing 3rd-party software (adware?), I'm all ears.


public class MainActivity extends AppCompatActivity {  Cursor cursor; ArrayList<String> vCard; String vfile; static Context mContext;  @Override protected void onCreate(Bundle savedInstanceState) {     super.onCreate(savedInstanceState);     setContentView(R.layout.activity_main);      getVCF(); }  public static void getVCF() {     final String vfile = "Contacts.vcf";      Cursor phones = mContext.getContentResolver().query(    // exception here at this line             ContactsContract.Contacts.CONTENT_URI, null,               null, null, null);     phones.moveToFirst();     for (int i = 0; i < phones.getCount(); i++) {         String lookupKey = phones.getString(phones                 .getColumnIndex(ContactsContract.Contacts.LOOKUP_KEY));         Uri uri = Uri.withAppendedPath(                 ContactsContract.Contacts.CONTENT_VCARD_URI,                 lookupKey);         AssetFileDescriptor fd;         try {             fd = mContext.getContentResolver().openAssetFileDescriptor(uri, "r");             FileInputStream fis = fd.createInputStream();             byte[] buf = new byte[(int) fd.getDeclaredLength()];             fis.read(buf);             String VCard = new String(buf);             String path = Environment.getExternalStorageDirectory()                     .toString() + File.separator + vfile;             FileOutputStream mFileOutputStream = new FileOutputStream(path,                     true);             mFileOutputStream.write(VCard.toString().getBytes());             phones.moveToNext();             Log.d("Vcard", VCard);         } catch (Exception e1) {             // TODO Auto-generated catch block             e1.printStackTrace();         }     } } }   error      FATAL EXCEPTION: main  Process: com.example..myapplication, P       java.lang.RuntimeException: Unable to start activity   ComponentInfo{com.example..myapplication/com.example.myapplication.MainActivity   }: java.lang.NullPointerException: Attempt to invoke virtual method    'android.content.ContentResolver android.content.Context.getContentResolver()' on a null object reference                                                                                Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.ContentResolver android.content.Context.getContentResolver()' on a null object referenc   at com.example..myapplication.MainActivity.getVCF(MainActivity.java:36at com.example..myapplication.MainActivity.onCreate(MainActivity.java:30)

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


At work, we run a portal server to access all of our "real" servers. Essentially, anyone who needs to SSH into one of the "real" (web) servers would first SSH into the portal, so it looks like this:  mike@localhost#    ssh mike@portal #ssh login notice stuff blah blah mike@portal#    ssh mike@webserver   I'm trying to write a bash alias or function to combine these two steps into one. I'm not the sysadmin by any stretch, so keeping this as simple as possible without installing extra software would be nice.  I've tried the following but it won't go through as I had hoped:  ssh mike@portal; ssh mike@webserver #terminates on terminal for portal ssh mike@portal `ssh mike@webserver` #hangs ssh mike@portal ssh mike@webserver #connects, but gives error "pseudo-terminal will not be allocated because stdin is not a terminal"   Any ideas or workarounds for this?

I have three Computers.  PC1 and PC2 is on a private LAN, where PC1 is known to PC2 as 192.168.0.2  PC2 and PC3 is on a another  LAN, where PC2 is known to PC3 as 192.168.123.101  How can I connect to PC1 from PC3 with SSH.  Is there something like:  ssh user@192.168.0.2 -via user@192.168.123.101


list= []  x = ['A', 'B', 'C', 'D', 'E', 'F', 'G']  for i in range(2):            list.append(x)  list[0][0]="x"  print list   And after printing I get this:  [['x', 'B', 'C', 'D', 'E', 'F', 'G'], ['x', 'B', 'C', 'D', 'E', 'F', 'G']]   The first item in every list was replaced by 'x' whereas I only wanted the first item in the first list to be replaced by 'x'(hence the line list[0][0]="x")

I needed to create a list of lists in Python, so I typed the following: my_list = [[1] * 4] * 3  The list looked like this: [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]]    Then I changed one of the innermost values: my_list[0][0] = 5  Now my list looks like this: [[5, 1, 1, 1], [5, 1, 1, 1], [5, 1, 1, 1]]    which is not what I wanted or expected. Can someone please explain what's going on, and how to get around it?


I'm working on a problem: A woman has a basket of eggs and she drops them all. All she knows is that when she puts them in groups of 2, 3, 4, 5, and 6, there is one left over. When she puts them into groups of 7, there are none left over. What is the minimum number of eggs she could have in her basket?  Here's where I've gotten.  Since all 2, 3, 4, 5, and 6 have a remainder of one, the number must be a multiple of their lcm + 1. So, we know that $$  x = 60t + 1. $$ So, I checked integer values of t and then found their remainder when divided by 7. The solution was when $t = 5,  x = 301$. What I want to know is, is there a 'better' way to do this? And if so, how? I ran into the Chinese Remainder Theorem, but everything I saw didn't make much sense to me.  Thanks!

$$\begin{align*} x&\equiv 1\pmod2\\ x&\equiv 2\pmod3\\ x&\equiv 3\pmod4\\ x& \equiv 4\pmod5\\ x&\equiv 5\pmod6\\ x&\equiv 0\pmod7\\ \end{align*}$$  So the solution says we can eliminate $x\equiv 5(\bmod6)$ because the first two cases cover it, but I don't really know how it does. How do we solve it in cases like this where the moduli are not mutually relatively prime.


My recollection is that Darth Vader wore a helmet for life support after a devastating accident. Much like some people cannot survive without dialysis after kidney failure. But Kylo Ren seems able to survive without his helmet. We get the sense that Kylo Ren is just wearing a costume like a security blanket to pretend he is his grand father. Is there any documented reason why Kylo Ren wears a helmet?

Is there an explanation on why Kylo Ren wears that mask in The Force Awakens? It even has a voice synthesizer and everything.  It makes him look like a Darth Vader fanboy and really tries to be/look/sound like him.   It doesn’t look like he needs it or anything.


I'm trying to get the border of a
 element to only take up the space occupied by text. Here's the relevant part of my html:
        Plate number:

5649JSN

    And here's how it looks:  How can I fix this? Thanks in advance Edit: I can't know beforehand how much space the plate number will take

I have a layout similar to:  <div>     <table>     </table> </div>   I would like for the div to only expand to as wide as my table becomes.


I have a application which reads SAS xpt file and stores column value into ByteBuffer and then using getValue() method of it to get Double object. Now I have to print Double upto 12 significant digit after decimal. I found one answer from this from which is working fine but few cases  BigDecimal bd = new BigDecimal(dblColumnData.doubleValue()); System.out.println(String.format("%."+15+"G", bd));   Here 15 is given because there are 3 digits in integer part and there must be 12 significant digit after decimal.  Cases where it is not working is because BigDecimal created from Double. If I print Double then it contains more than 12 digits after decimal and it round correctly with same above approach.  Therefore I think if I can get similar format method for Double the it will solve my problem.

What I would like is a method to convert a double to a string which rounds using the half-up method - i.e. if the decimal to be rounded is 5, it always rounds up to the next number. This is the standard method of rounding most people expect in most situations.  I also would like only significant digits to be displayed - i.e. there should not be any trailing zeroes.  I know one method of doing this is to use the String.format method:  String.format("%.5g%n", 0.912385);   returns:  0.91239   which is great, however it always displays numbers with 5 decimal places even if they are not significant:   String.format("%.5g%n", 0.912300);   returns:  0.91230   Another method is to use the DecimalFormatter:  DecimalFormat df = new DecimalFormat("#.#####"); df.format(0.912385);   returns:  0.91238   However as you can see this uses half-even rounding. That is it will round down if the previous digit is even. What I'd like is this:  0.912385 -> 0.91239 0.912300 -> 0.9123   What is the best way to achieve this in Java?


How can I please union of cells according to the picture? Thank you.  \documentclass[12pt,a4paper]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage[czech]{babel}  \usepackage{indentfirst} \usepackage{amsmath} \usepackage[left=2cm,right=2cm,top=2.5cm,bottom=2.5cm]{geometry} \usepackage{tabularx} \usepackage{caption}  \captionsetup[table]{skip=10pt} \begin{document}      \begin{table}[h!]\footnotesize     \caption{Zářič $^{137}$Cs - přirozené pozadí}     \centering         \begin{tabular}{|c|c|c|c|c|c|}         \hline $PEAK$ [keV] &$E_{tab}$ [keV] &Zdroj& $FWHM$ [keV]&$NET$&$GROSS$ \\  \hline  609,35& 609,31& $^{214}$Bi& 1,38&   539&    4675\\ \cline{1-2} \cline{4-6} 1120,29&    1120,29&    &   1,95&   558&    1530\\   1764,57&    1764,49&    &   2,08&   451&    574\\ 2204,36&    2204,21&    &   1,86&   141&    188\\ 1460,81&    1460,75&    $^{40}$K&   1,73&   422&    738\\ 74,71&  rtg&    $^{214}$Pb& 1,15&   2321&   34035\\ 84,54&  &   &   1,22&   891&    16412\\          \hline         \end{tabular}      \label{Csp} \end{table} \end{document}

Here is a simple table.  I want to merge 4 cells. I want to combine the three "this" cells area in this table. I thought I have to use multirow and multicolum at same time. However, I could not find how to use it.  If possible, could you post the modified LaTeX source code?     My LaTeX code:  \documentclass{article} \usepackage{multirow}% http://ctan.org/pkg/multirow \usepackage{hhline}% http://ctan.org/pkg/hhline \begin{document}  \begin{table}[ph] \begin{center} \begin{tabular}{c|c|c|c|c} \hline \multirow{2}{*}{Raaa (k)} & \multicolumn{4}{c}{C ()} \\ \hhline{~----}  & 3.3 & 2.5 & 1 & 0.5 \\ \hline \multirow{2}{*}{Raaa (k)} & \multirow{2}{*}{this} & this & 0.5 & 0.6\\ \hhline{~~~--}            &                       & this & 0.7 & 1.2 \\ \hline \end{tabular} \caption{R, C ripple size} \label{T:peak} \end{center} \end{table} \end{document}


I restricted the access permissions of F drive on my hard disk after that my os is changed without removing the permissions thats why i am not able to access that drive, can any one help me ??

I have a 1TB external (USB) HDD which i used for additional data storage (mostly media files).  Unfortunately, i appear to have changed the permissions on one of the sub-folders, and this is my problem.  The PC which i used the drive on most of the time, has died. Now, putting this external drive into a new PC, i cannot access the said sub-directory (Music) as i do not have permission.  Is it at all possible to resore the permissions of this directory to the default (ie FULL access to EVERYONE with no specifically defined "owner"?  I think the problem now is that the Owner of the folder is my user account from my (now dead) previous PC.  I dont know if this helps but the permissions were adjusted (originally) on a Windows 8 PC, where i was logged in using my Micrsoft Account. Even when plugging in the drive to another Windows 8 PC (this time Surface Pro), and logging in using the same Microsoft Account, i still cannot access the files in the music folder.  Is this possible?


Let $f\colon U\to\mathbb{C}$ be analytic on a region $U$. If $f=u+iv$ and $3u+2v=c\in\mathbb{R}$ is constant, is it true that $f$ is also constant?

Suppose that $f$ is analytic on some region $R\in\mathbb{C}$. If Im$(f)$ = $k\cdot$Re$(f)$ for some nonzero constant $k\in\mathbb{C}$, then show that $f$ is constant on $R$.  I know that if $f'(z)=0$ for all $z$ in some region $R$, then $f(z)$ is constant. However, I'm not sure how to apply this to the question at hand. I also think the Cauchy-Riemann equations could be helpful, but again, I'm not sure how to apply them to the question.  Any guidance would be greatly appreciated. Thank you!


Is there a way for me to create a button or a badge on my website. That links back to my user account on stack overflow?   Im a proud member of StackExchange I would like to have that on my blog.   I googled around but couldnt find anything about it.  Someone mind pointing me in the right direction?

I want to include a tag or kind of business card on my homepage where a link to my account, my current reputation and my current badges are show. Could be something like the user card under a question or answer:        Is there an API for this or is it allowed to parse it from the Stack Overflow website?


I am following along . For scalar functions $f$ and $g$ we define the Klein-Gordon inner product as follows: $$ \langle f,g \rangle \ = \ i \int_{\Sigma} d^{3}\mathbf{x}\ \left[ f^{\ast}(t,\mathbf{x}) \frac{\partial g(t,\mathbf{x})}{\partial t} - \frac{\partial f^{\ast}(t,\mathbf{x})}{\partial t} g(t,\mathbf{x}) \right]  $$ Where we take $\Sigma$ to a 3D hypersurface of constant $t = t_{0}$. If $f$ and $g$ are the solutions to the Klein-Gordon then the above is independent of the choice of $t_0$ used to integrate it. One can use this to show that the modes $u_{\mathbf{k}} \propto e^{-i \sqrt{\mathbf{k}^2 + m^2} t + i \mathbf{k} \cdot \mathbf{x}}$ are orthogonal to one another. My question is; where does this inner product come from? I under stand that $i \phi^{\ast} \frac{\partial \phi}{\partial t} - i \phi^{\ast} \frac{\partial \phi}{\partial t} $ is a conserved current, but why would you put a conserved current under and integral sign to define an inner product? It seems arbitrary. What if one came up with a different inner product? What benefits does the KG inner product have?

Studying the scalar field and Klein-Gordon equation in quantum field theory I came across this definition for the inner product in the space of the solutions of the K.G. equation:  $$\langle \Phi_1 | \Phi_2 \rangle = i\int \mathrm{d}\vec{x}(\Phi_1 ^* \overleftrightarrow{\partial_0}\Phi_2) = i\int \mathrm{d}\vec{x} (\Phi_1 ^* \partial_0\Phi_2 -  \Phi_2 \partial_0\Phi_1^*).  $$  I see that this definition should be invariant under Poincaré transformations, but I couldn't prove it.    Moreover I couldn't find the reason why such a scalar product is introduced. Aren't there other possible scalar products? Why choose this one?


I want to plot this (based on this image from ):    As far I get this:  \documentclass[tikz,border={20pt}]{standalone}  \usepackage{pgfplots} \pgfplotsset{compat=1.10} % \pgfplotsset{samples=60}  \begin{document} \begin{tikzpicture} \begin{axis}[view={45}{30},domain=0:4*pi,axis x line=none,axis y line=none,axis z line=none] \addplot3[thick,blue!70,no markers,samples y=0] (x,0,{sin(pi * deg(x) / 5)}); \addplot3[thin,gray] (x,0,0); \addplot3[thick,blue!70,no markers,samples y=0] (x,1,{1/3 * sin(3 * pi * deg(x) / 5)}); \addplot3[thin,gray] (x,1,0); \addplot3[thick,blue!70,no markers,samples y=0] (x,2,{1/5 * sin(pi * deg(x))}); \addplot3[thin,gray] (x,2,0); \addplot3[thick,blue!70,no markers,samples y=0] (x,3,{1/7 * sin(7 * pi * deg(x) / 5)}); \addplot3[thin,gray] (x,3,0); \addplot3[thick,blue!70,no markers,samples y=0] (x,4,{1/9 * sin(9 * pi * deg(x) / 5)}); \addplot3[thin,gray] (x,4,0);  \addplot3[thick,red!70,no markers,samples y=0] (x,-1,{sin(pi * deg(x) / 5) + 1/3 * sin(3 * pi * deg(x) / 5) + 1/5 * sin(pi * deg(x)) + 1/7 * sin(7 * pi * deg(x) / 5) + 1/9 * sin(9 * pi * deg(x) / 5)}); \end{axis} \end{tikzpicture} \end{document}     So far I have next issues:   out of memory for larger samples; how to add grey rectangles; optimize code (it's really robust and straightforward now); plot with lines on the left.

The following time-frequency correspondence illustration is in .    Also a gif animation version (if the animation doesn't show, please open the following image in a new window):    This picture has so much explanatory power, and I would like to replicate it in TikZ for future use.  Here is what I came up with:  \documentclass{minimal} \usepackage{tikz}  \begin{document} \begin{tikzpicture} [x={(1cm,0.5cm)},z={(0cm,0.5cm)},y={(1cm,-0.2cm)}] \draw[->,thick,blue!90] (0,6.5,0) -- (6.2,6.5,0) node[right] {Frequency}; \draw[->,thick,red!90] (0,0,0) -- (0,6.5,0) node[below] {Time}; \draw[->,thick] (0,0,0) -- (0,0,2) node[above] {Magnitude}; \foreach \x in {0.5,1.5,2.5,3.5,4.5,5.5}{   \draw[blue!50] (\x,0,0)   \foreach \y in {0,0.02,...,6.28}{     -- ({\x},{\y},{sin(\x*\y*(157))/sqrt(2*\x)})   };   \draw[blue!90, thick] (\x,6.5,0) -- (\x,6.5,1/\x); }  \end{tikzpicture} \end{document}   This is the output so far.    I have two questions:   How to produce that red superposed sine wave of all the blue sine waves? I don't know if there is a sum function or I have to use loop yet again? How to make the camera projection in TikZ more similar to the perspective in that wikipedia illustration?   Any suggestion and tweaking of the parameters I used in the sample drawing are welcome as well.  Thanks in advance!    Update 1:  Here is a new version using tikz, more readable than the first one. Yet the superposition of the sine waves are done manually...I still don't know how to use foreach to produce a sum.  \begin{tikzpicture}[x={(1cm,0.5cm)},z={(0cm,0.5cm)},y={(1cm,-0.2cm)}] \draw[->,thick,black!70] (0,6.5,0) -- (6.2,6.5,0) node[right] {Frequency}; \draw[->,thick,black!70] (0,0,0) -- (0,6.5,0) node[below right] {Time}; \draw[->,thick] (0,0,0) -- (0,0,2) node[above] {Magnitude}; \foreach \y in {0.5,1.5,...,5.5}{ \draw [cyan!50, domain=0:2*pi,samples=200,smooth]   plot (\y,\x, {sin(4*\y*\x r)/\y }); \draw[blue, ultra thick] (\y,6.5,0) -- (\y,6.5,1/\y); } \draw [red, thick, domain=0:2*pi,samples=200,smooth]  plot (0,\x, {sin(4*0.5*\x r)/0.5 + sin(4*1.5*\x r)/1.5 + sin(4*2.5*\x r)/2.5 + sin(4*3.5*\x r)/3.5 + sin(4*4.5*\x r)/4.5 + sin(4*5.5*\x r)/5.5} ); \end{tikzpicture}   The result is as follows:


I want to remove some vertical spacing in my page. Actually, the page is formatted automatically through this command: \documentclass[12pt,twoside]{report} \begin{document}  \chapter{Conclusions} \input{tex/08_conclusion.tex}  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%              APPENDIX             %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%             REFERENCES            %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \pagebreak \addtotoc{Bibliography} \printbibliography  \end{document}  Top of the page:  The output is shown in this way:

I have a problem. I have several large equations within the text. And when LaTeX does not manage to put the equation on the same page and moves it to the next one, he spreads the paragraphs of the text in the first page. How could I prevent this? I know about \pagebreak and \newpage, but I do not want to force the \newpage, as the text may move (if I add something later or so on) and the pagebreaks may not be valid. I would like to make LaTeX not to spread the paragraphs over a page automatically. Is it possible?  I tried to make an example:  \documentclass[a4paper,12pt,twoside]{book} \usepackage{amsmath} \begin{document}  LaLaLa\\\  LaLaLa\\\  LaLaLa\\\  LaLaLa\\\  \begin{eqnarray} 123&+&123 \\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ \end{eqnarray}  LaLaLa\\\  LaLaLa\\\  \begin{eqnarray} 123&+&123 \\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ 123&+&123 \nonumber\\\ \end{eqnarray}  \end{document}


I am very new to SalesForce and Salesforce development.  I am trying to create a VisualForce page which takes in a case by query sting using the id key (ie ?id=01p18000000DwhA).  I'd for that VisualForce page all of the user of that page to be able to input only a description.  Once the user clicks save after inputting the description, I'd like for my Apex class extension to create a new child case (with the case that was passed in via query string being the parent class), which has mostly all the same properties as the parent class with only the description being different.  So far I have the following VisualForce page:  <apex:page standardController="Case" extensions="ChildPageControllerExtension" sidebar="false" >     <style>         .textArea {             height:200px;             width:500px;         }     </style>     <apex:form >         <apex:pageBlock >             <apex:pageBlockButtons >                 <apex:commandButton value="Save" action="{!save}"/>                 <apex:commandButton value="Cancel" action="{!cancel}"/>             </apex:pageBlockButtons>             <apex:pageBlockSection >                 <apex:inputTextarea styleClass="textArea" value="{!case.Description}"/>             </apex:pageBlockSection>         </apex:pageBlock>     </apex:form> </apex:page>   And the following Apex class extension:   public class ChildPageControllerExtension  {      public Case child       {          get;          set;      }       public ChildPageControllerExtension (ApexPages.StandardController controller)      {          child = new Case();             }       public void Save()      {          insert child;      }  }   Any help would be greatly appreciated!  I'm not quite sure how to continue on from here, but I believe I am close once I figure out how to derive a child case based on the parent case.  Thanks.

I have a VF page that is the 'edit' page for a certain object. I have a button 'Clone'. Upon clicking this button, I wish to be redirected to a new edit page with all the previous objects fields still intact (except for a few that should be cleared and set to default). Note that this new object should not be inserted until I click 'Save'. The Id of the object should be different compared to the previous object, so that on Save, the previous object is not overwritten.   I am thinking I will split this up into two parts, an apex method, and a javascript method for resetting the fields:  <apex:commandButton action="{!saveAsTemplate}" onclick="initTemplate();" value="Clone" />   The javascript portion is easy enough, but I'm having trouble of figuring out what to do on the apex side, besides for setting the id of the record to null.


Here is an example code:  set.seed(3)  data1 = iris[sample(c(1:dim(iris)[1]), 30), ] data2 = iris[sample(c(1:dim(iris)[1]), 50), ]  model1 = lm(Petal.Length ~ log(Petal.Width),             data = data1) model2 = lm(data2$Petal.Length ~ log(data2$Petal.Width))  par(mfrow = c(1, 4)) plot(data1$Petal.Width,       data1$Petal.Length) points(sort(data1$Petal.Width),        predict(model1, newdata = data1[order(data1$Petal.Width), ]),        col = "red",         type = "l")  plot(data2$Petal.Width,       data2$Petal.Length) points(sort(data2$Petal.Width),        predict(model1, newdata = data2[order(data2$Petal.Width), ]),        col = "red",         type = "l")   summary(model1) summary(model2)   As in the code, I fitted two different curves from two different datasets using the simple regression method in which the explanatory variable is in logarithm form. Like in the code, the datasets have the same variables with different size. I want to check that the two curves (model1 and model2) are statistically different or not. How can I do it in R?  ---- edited ---- I know that there are many questions about comparing regression lines, but my case is a different one from previous ones because I want to compare different models built from different data sets while other cases are to compare different models built from the same data set.  Let me state more about the context of my purpose to elaborate on the term "compare." I made a model (the curve) for an experimental site and want to apply this model to many other sites (over the country). I acknowledge that it would not proper to apply the model to other sites where the model is not based on (the resulted curve of another site may be different from the previous one). So, I made one more curve for another study site and trying to compare the two models built from different sites. This is why the two data sets have the same variable list. And the common points of the two data sets in the example can be ignored in term of my purpose.  Thank you!

So first of all I did some research on this forum, and I know   questions have been asked but they usually haven't been answered properly or sometimes the answer are simply not detailed enough for me to understand. So this time my question is : I have two sets of data, on each, I do a polynomial regression like so :  Ratio<-(mydata2[,c(2)]) Time_in_days<-(mydata2[,c(1)]) fit3IRC <- lm( Ratio~(poly(Time_in_days,2)) )   The polynomial regressions plots are:    The coefficients are :  > as.vector(coef(fit3CN)) [1] -0.9751726 -4.0876782  0.6860041 > as.vector(coef(fit3IRC)) [1] -1.1446297 -5.4449486  0.5883757    And now I want to know, if there is a way to use an R function to do a test that would tell me whether or not there is a statistical significance in the difference between the two polynomials regression knowing that the relevant interval of days is [1,100].  From what I understood I can not apply directly the anova test because the values come from two different sets of data nor the AIC, which is used to compare model/true data.  I tried to follow the instructions given by @Roland in the related question but I probably misunderstood something when looking at my results :  Here is what I did :   I combined both my datasets into one.  f is the variable factor that @Roland talked about. I put 1s for the first set and 0s for the other one.  y<-(mydata2[,c(2)]) x<-(mydata2[,c(1)]) f<-(mydata2[,c(3)])  plot(x,y, xlim=c(1,nrow(mydata2)),type='p')  fit3ANOVA <- lm( y~(poly(x,2)) )  fit3ANOVACN <- lm( y~f*(poly(x,2)) )   My data looks like this now :    The red one is fit3ANOVA which is still working but I have a problem with the blue one fit3ANOVACN the model has weird results. I don't know if the fit model is correct, I do not understand what @Roland meant exactly.  Considering @DeltaIV solution I suppose that in that case :  The models are significantly different even though they overlap. Am I right to assume so ?


I know about User Preferences. I know about enabling the different file formats. What I don't know is why I am not seeing any model in the viewport despite using File-Import-Wavefront(.obj)...

I have opened a new blender file and deleted the default cube, then imported an obj file . I did not see any thing so i selected it and i zoomed ,nothing appears.In the outliner i saw the object name ,But in the info panel i see that there isn't any verts/faces/edges.  When i opened the obj file in a text editor i found Mesh data in it. I tired this in all blender versions (2.78c/2.78.5/7.9). Can any one help how to view the mesh?


I am a high school student. Yesterday I attended a lecture on vector multiplication (first time). There was something I was not able to understand. The only concept of multiplication I had before is 2x3=6, means that if we write '3' 2 times we'll get 6.  But now there are two types of multiplications:   Dot product Cross product   Dot product  What I understood is that dot product of two vectors is a scalar quantity, But how?   Here if we multiply projection of A on B (A cos0) with B, finally that product would be in the direction of B?, am I right or wrong?  Secondly please specify the difference between this dot product and ordinary multiplication which I stated above (2x3=6)?  Cross product:    By Cross product I understand that it's the product of the 'length of perpendicular produced for projecting A on B' and 'B'?   What is the purpose and meaning of this product?  And After multiplication product is multiplied by unit vector n, which perpendicular to the A and B.  Why the cross product is always perpendicular to the given vectors?  And if I am right that Cross product is the product of the 'length of perpendicular produced for projecting A on B' and 'B' then why that projection is not shown in this diagram of cross product (which is taken from wikipedia)?

I get the physical significance of vector addition & subtraction. But I don't understand what do dot & cross products mean?   More specifically,    Why is it that dot product of vectors $\vec{A}$ and $\vec{B}$ is defined as $AB\cos\theta$? Why is it that cross product of vectors $\vec{A}$ and $\vec{B}$ is defined as $AB\sin\theta$, times a unit vector determined from the right-hand rule?   To me, both these formulae seem to be arbitrarily defined (although, I know that it definitely wouldn't be the case).   If the cross product could be defined arbitrarily, why can't we define division of vectors? What's wrong with that? Why can't vectors be divided?


Given sets $A$ and $Y$, I want to show that there is a set $T$ such that given $a\in A$ an $y\in Y$ the ordered pair $(a,y)$ belongs to $T$.   $$$$   In other words we want to show that the existence of the set of ordered pairs $A\times Y$, or not?   For that do we have to apply the axioms of sets?

In ZFC set theory, every element object is a set. We know or feel that if $X$ and $Y$ are sets, their cartesian product $X\times Y$ is a set.  My question is: Why if $X$ and $Y$ are sets, their cartesian product $X\times Y$ is a set?


Google Chrome becomes more and more unusable: crashing, eating memory, etc. So I decided to come back to IE and use it as my default browser. Chrome used to be much faster. But not recently. It slows down all my laptops now.  The first thing I wanted to do after starting using IE is to change Bing to Google Search as the search engine for toolbar searches.  I go to that page to add Google Search Add-on:    And it is not there. I tried on both Win8 and Win7. Am I missing something? Can anybody else install Google Search Add-on for IE?  Thanks!

I have been trying with no luck to use Google as the default search provider for IE11 on Windows 8.1  Currently I can only add Google Australia as an "Accelerator" however this does not provide the capability to search Google from the IE11 address bar.  It currently seems that unless your IE11 came with multiple built in search providers, you are pretty much stuck with Bing for now.  Has anyone figured out how to do this?


Wizard A wants to cast Minor Illusion on Target B, specifying black discs in front of the eyes. Does it work?  In other words, are status effects something Minor Illusion can inflict?

Last session, one of my players said he wanted to cast minor illusion - creating a high-pitched screaming noise - within the inner ear of a Worg. I ruled it was permissible, got the Worg to take a Constitution check to not be alarmed, and it succeeded, remaining unperturbed.  But I've since been thinking - could you cast minor illusion in such a small, specific location within combat? Could I perhaps rule that the PC should take a penalty of some sort? Is a Con check appropriate? What would the effects of such below-the-belt tactics be if they succeed?


I am using Sony Xperia Z with android 4.3. Is there any way I can save Web pages on my device to view it offline. Will it require an app? If yes, any free app for the purpose.

I have a lot of saved web pages that I want to view whenever I want without the page connecting to the web site (I can do this on WM). How do I do this on Android? Every time I click on the HTML file it says "no connection".


Every time I renew my page, I get a green and red notification at the top of the page, for notifications that I have already seen.  As more notifications appear, the reincarnating number has gone up.  It started when I logged on an hour ago, with the one new message and one rep change.  It goes away after I acknowledge it while I am on the page, but reappears as soon as I navigate to a new page.

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


04-03 10:19:34.572    2189-2189/com.techexpert4u.duaaadhkaar E/AndroidRuntime﹕ FATAL EXCEPTION: main     Process: com.techexpert4u.duaaadhkaar, PID: 2189     java.lang.RuntimeException: Unable to start activity ComponentInfo{com.techexpert4u.duaaadhkaar/com.techexpert4u.duaaadhkaar.MainActivity}: java.lang.NullPointerException             at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2195)             at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2245)             at android.app.ActivityThread.access$800(ActivityThread.java:135)             at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)             at android.os.Handler.dispatchMessage(Handler.java:102)             at android.os.Looper.loop(Looper.java:136)             at android.app.ActivityThread.main(ActivityThread.java:5017)             at java.lang.reflect.Method.invokeNative(Native Method)             at java.lang.reflect.Method.invoke(Method.java:515)             at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)             at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)             at dalvik.system.NativeStart.main(Native Method)      Caused by: java.lang.NullPointerException             at com.techexpert4u.duaaadhkaar.MainActivity.onPostCreate(MainActivity.java:936)             at android.app.Instrumentation.callActivityOnPostCreate(Instrumentation.java:1150)             at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2178)             at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2245)             at android.app.ActivityThread.access$800(ActivityThread.java:135)             at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)             at android.os.Handler.dispatchMessage(Handler.java:102)             at android.os.Looper.loop(Looper.java:136)             at android.app.ActivityThread.main(ActivityThread.java:5017)             at java.lang.reflect.Method.invokeNative(Native Method)             at java.lang.reflect.Method.invoke(Method.java:515)             at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)             at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)             at dalvik.system.NativeStart.main(Native Method)   i NEED HELP ON THIS PLEASE HELP ME.  @Override protected void onPostCreate(Bundle savedInstanceState) {     super.onPostCreate(savedInstanceState);     // Sync the toggle state after onRestoreInstanceState has occurred.     mDrawerToggle.syncState(); }

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


For instance, in The Proclaimers' hit song I'm Gonna Be they say     I would walk five hundred miles, and   I would walk five hundred more   Just to be the man who walked a thousand miles to fall down at your door   The protagonist in the song isn't literally going to walk a thousand miles, they're using this construction to intensify their description of their feeling for the person they're singing to/about.  If I were describing it in a phrase I might say "exaggeration for effect," but is there a (more) specific term for it? If so, what is it?

Like:      "Sam and Lilly hate each other now. Their relationship is spiraling to an end."   "It is," she said, and she spoke like a fortune teller that made my previous _________ about their fall true.


I've obtained a multiple linear regression model in the form $$ \mathrm{log}(Y) = \beta_0 + \beta_1x_1 + \dots + \beta_4x_4 + \beta_5x_1x_2 + \dots + \beta_{10}x_3x_4 + \beta_{11}x_1^2 + \dots + \beta_{14}x_4^2  $$ from the model I've obtained some contour plots that, for a more immediate interpretation, I've back transformed in original units (using $10^{\tilde{y}}$).  Now my question is: do I need to back transform also the model parameters, the confidence intervals of the parameters themselves and the interval of prediction for new responses? How?  I think that would be nice to back transform at least the RMSEP and RMSE in order to obtain an estimate in original units of the mean error associated with the model in prediction and in fitting. How?

I'm fitting a regression on the $\log(y)$.  Is it valid to back transform point estimates (and confidence/prediction intervals) by exponentiation?  I don't believe so, since $E[f(X)] \ne f(E[X])$ but wanted other's opinions.  My example below shows conflicts with back transforming (.239 vs .219).  set.seed(123)  a=-5 b=2  x=runif(100,0,1) y=exp(a*x+b+rnorm(100,0,.2)) # plot(x,y)  ### NLS Fit f <- function(x,a,b) {exp(a*x+b)}  fit <- nls(y ~ exp(a*x+b),  start = c(a=-10, b=15))  co=coef(fit) # curve(f(x=x, a=co[1], b=co[2]), add = TRUE,col=2,lwd=1.2)  predict(fit,newdata=data.frame(x=.7)) [1] 0.2393773  ### LM Fit # plot(x,log(y)) # abline(lm(log(y)~x),col=2) fit=lm(log(y)~x) temp=predict(fit,newdata=data.frame(x=.7),interval='prediction') exp(temp)         fit       lwr       upr 1 0.2199471 0.1492762 0.3240752


The "LSM-tree" is an acronym term for "Log-Structured Merge Tree". I wrote "a LSM-tree", but Grammarly keeps reminding me it should be "an LSM-tree". What is the reason for this?

99% of the time, I'm clear on when I should use "a" versus "an." There's one case, though, where people & references I respect disagree.  Which of the following would you precede with "a" or "an," and why?   FAQ FUBAR SCUBA   [Note: I've read the questions  and , but the rules given there don't necessarily apply here.]    [Edited to add]  Here's a shorter (and hopefully clearer) version of the question…  In written English, which is correct (and why): "a FAQ" or "an FAQ"?  Some references with differing opinions:   an: the  and  a: the Microsoft Manual of Style for Tech Publications, 3e either: the  and


I am going to have about 300 shapefiles representing the range of different species in the wild. What I want to be able to do is find areas where the most species occur to highlight areas where many of these species exist.  Is there a simple way to do that in ArcGIS Desktop 9?

How do you take a vector layer with overlapping polygons and turn it into a raster where each cell counts the number of polygons containing that cell?    We are looking at polygons of fire burn areas between 1976 to 2000 and want to see how many fires would be contained in each raster cell.


During an academic discussion regarding file formats I received from a most excellent designer, I thought I was correct in writing (based on my experience with hired work):     ...the industry standard for logos is vector...   I received the following response:     Industry standards are interesting things, in that they are more often talked about than actually followed...   We can find all sorts of references to push one point or another, I only talk from experience, and my experience is that even large corporations ala Microsoft are fine with raster.   My question then is perhaps not as simple as I thought:  When hiring a designer to create a logo for an organization (corporate, non-profit, etc.), what is the industry standard deliverable file format (vis-à-vis vector versus raster)?  (Of course, hiring a designer should come with a contract that explicitly states the file format, but most people aren't aware [or don't care] about various file formats and might therefore neglect such a clause.)  This is different than asking what should go into the deliverable package. This question is about an authoritative source that describes what is expected of professional-level deliverables from designers. Some people agree that vector graphics should be included, but is that a de facto standard, or is there an official (or semi-official) body that dictates what people should expect as deliverables from graphic design?

What files should i put in a logo pack to give to clients? Should I put small, medium and large version of my logo as well as the vector file.


In a CentOS shared web hosting environment (I don't know a CLI way to check CentOS version) with Bash 3.2.52 I tried the following command: cp "${domain_dir}/google*.html" "${specific_backups_dir}"  Although the variables have been declared and already used successfully for other commands and although a file in the domain directory with a matchable name (googleNUMBER.html) exists, I got the error (relating to that file):  No such file or directory  What may cause that problem?

This will be an easy one, but in my memories, when shell scripting, using double quotes would allow expanding globbing and variables.  But in the following code:  #!/bin/sh  echo *.sh echo "*.sh" echo '*.sh'  echo $LANG echo "$LANG" echo '$LANG'   I get this result:  bob.sh redeployJboss.sh *.sh *.sh en_US.utf8 en_US.utf8 $LANG   So single quoting prevent glob AND variable expansion but double quoting allows only variable expansion and no globbing?  Can I glob in any quoting pattern?


If we define the sine and cosine functions by their Maclaurin expansions, how do we prove they are periodic with period $2\pi$?

With the Taylor series representation of $\sin$ or $\cos$ as a starting point (and assuming no other knowledge about those functions), how can one:  a. prove they are periodic?  b. find the value of the period?


As a company, we store a large amount of product images on Google Drive. To illustrate the point: we have one product with multiple images (eg. from different angles) all saved with different suffixes e.g. 123456C.jpg, 123456Ca.jpg, 123456Cb.jpg etc.  Working from different browsers on both mac and PC, non of us can search for any file unless we type in the full file name. This makes workflow tricky when usually we'd type in the first 3 numbers or so and up would pop (in the dropdown) all related images.  The small dropdown arrow next to the blue search button with search parameters is set to all file types, unspecified and owned by anyone.  The design studio we work with and have images shared with does not have the same problem. They could start typing in 123... and all the files that start with 123 would pop up to select (below the search bar).  To confuse things further, if we type title: "123" and enter, this works. But it's a workaround, not a solution.Can anyone help?  EDIT: No duplicate qn. - I want to search with the beginning of a filename, not the middle. It seems to work with one account that has shared images with us, but not ours. I believe the problem lies in sharing and ownership but can't work out where.

I'd like to be able to find all files in my Google drive that contain the string "_INSTRUCTION_" in the file name. Is there a way to do this?  EDIT 1: When I search for "RMA2013", I should get a dropdown with several options. As you can see, there are several Word and .pdf files with the phrase "RMA2013". Still I get no dropdown help:   And even if I click the search button, I get nothing:


package qwertyuiop;  public class Confusion {     Confusion com = new Confusion();      public static void main(String[] args) {         Confusion con = new Confusion();         System.out.println(4);         con.A();         System.out.println(5);     }      public void B() {         System.out.println(3);     }      public void A() {         System.out.println(4);         com.B();         System.out.println(4);     } }   I know the code is wrong but I am interested in knowing why this is throwing StackOverflowError. I would also like to know how this code is executing internally.

What is a StackOverflowError, what causes it, and how should I deal with them?


A room contains 1001 bulbs each numbered from 1 to 1001. the bulbs are controlled by a toggle switch and all the bulbs are initially turned off. There are 1001 number theory experts each wearing a label also numbered from 1 to 1001. Each number theory expert is assigned to go into the room and press  the switch of a bulb once if and only if the label he or she is wearing is a divisor of the number on the bulb. Which bulbs would be switched on after all the number theory experts have finished their assignment?

There are  1000  light bulbs and 1000 tutors. All light bulbs are off. Tutor 1 goes flipping light bulb 1,2,3,4... tutor 2 then flips 2,4,6,8... tutor 3 then 3,6,9...etc until all 1000 tutors have done this.  What is the status of light bulb 25? 93? 576?  Is there a general solution to find out the status of any light bulb?  How many light bulbs are on after all 1000 tutors have gone by?  Not homework but a UK university interview question. Please help.


Let $X := [0, 1]$ , the closed unit interval. Then     $$\|f\|_2 := \left(\int_{0}^{1} |f(t)|^2 dt \right)^{\frac{1}{2}}$$   defines a norm on the set of all continuous real/complex valued functions on $[0, 1]$. Two properties of norm were easy to verify. But i am stuck in triangle inequality of the norm. For $1\le p<\infty$, is $\|f\|_p := \left(\int_{0}^{1} |f(t)|^p dt \right)^{\frac{1}{p}}$ also a norm ?    non-negativty is trivial and $\|f\|_2 = 0 \iff $ $f=0$. $\|\alpha f\|_2 $ = $\left(\int_{0}^{1} |\alpha f(t)|^2 dt \right)^{\frac{1}{2}}$  $= |\alpha|\left(\int_{0}^{1} | f(t)|^2 dt \right)^{\frac{1}{2}}=|\alpha |\cdot\|f\|_2$ for all $\alpha \in \mathbb{R}$ $\|f+g\|_2 $ $= \left(\displaystyle\int_{0}^{1} |f(t)+g(t)|^2 dt \right)^{\frac{1}{2}}$ $\le\left(\displaystyle\int_{0}^{1} \left(|f(t)|+|g(t)|\right)^2 dt \right)^{\frac{1}{2}} \le$ ?

I am posed with a problem as below.  Let $X$ be the collection of real valued functions that are measurable on $[0,1]$. For a given number $p\geq 1$ define the $L^p$ norm by $(\int_0^1|f(x)|^p)^\frac{1}{p}$.  I need to show for $p=1,2$ that this defines a semi norm on $X$. $p=1$ was simple as was all of $p=2$ except for the triangle inequality. I am having trouble proving the triangle inequality for this. Could anybody nudge me into the right direction or am I simply over thinking it? I think I can prove it for vectors but I'm not sure how to tackle it with integrals. Right now I can only use relatively basic results because this in for an introductory measure theory course.  Thanks!


We see in Return of the Jedi that the Rebel fleet, including the fighters (B-Wing, X-Wing, etc.) make the jump to lightspeed to get to Endor and commence their assault on the Death Star.  Are TIE fighters also capable of travelling faster than light? Or do they need to rely on being docked in a Star Destroyer or the Death Star in order to get far distances?

I distinctly remember in Star Wars, A New Hope, in the scene when the Millennium Falcon arrives at the remains of what was once Alderaan, a TIE fighter passes close by and Han Solo gives chase. Obi-Wan says "A fighter that size couldn't get this deep into space on its own." Is he implying that TIE fighters don't have Hyperdrives or that they are too far from Imperial space? I ask this because I distinctly remember that, at least by "ROTJ" X-Wings are very capable of hyperdrive as in the scene at the beginning of the Battle of Endor when the entire rebel fleet makes the jump into hyperspace including a squadron of X-Wings. X-Wings are not much bigger than TIE fighters. Thank you


Assuming the rings of Saturn started out as a disorganized cloud of debris, what forces made these rings so thin and flat? Does frame dragging play a part in this?

Take a look at this picture (from APOD ):   I presume that rocks within rings smash each other.  Below the picture there is a note which says that Saturn's rings are about 1 km thick. Is it an explained phenomenon?


I recently moved over to Verizon FIOS and I must use their router. I want to try to use my old Netgear router as a switch (no wireless) for additional ports.  I connected the main router into a LAN port on the Netgear switch and then plugged a computer into a LAN port and the computer was able to get on the internet.  I now want to get into the settings of the Netgear router, which has DD-WRT firmware on it. I can't figure out how to access the settings.  www.routerlogin.net doesn't work.  I tried looking at IP addresses on my Verizon router to see what is connected and tried putting the IP address of every Ethernet connection into my address bar, hoping that one is my router. However nothing worked.  Any ideas?

I have a couple of modem/routers that came with ISP services that are no longer being used. At the moment I have the current ISP's router running the wireless network and a wired portion to a couple of rooms. In one of those rooms I have a switch to connect all the computers there to the cable coming from the router.  In the other room I have a couple of cables (actually one split into two) but I need at least one additional wired connection there.  Can I convert the existing routers that I have to behave as switches? I don't want these routers to control their own subnet giving IPs to devices connected to it. They should be as transparent to the network as if I just had a few additional wired connections available there.


I cannot seem to land properly on a station with just pads.  I fly in with landing gear extracted, the pad icon is blue and high freq beeps. I have to fly out cancel docking and try again. Often the 2nd time I can dock without issues.  Is it some bug?

Does anybody else sometimes have trouble docking? I am granted docking permissions, I have my landing gear out, and I am in the "docking circle" (it shines in blue).  Most of the times I just bump into the station while hoovering down. After a few retries (including sometimes flying a kilometer from the station and back), the docking is successful.  To be more detailed, this is my procedure:   Ask for docking permission and get granted. Fly to the docking pad, at the same time toggling the landing gear Position myself over the landing pad, in the accepted landing zone Use vertical controls to lower altitude   In other words, a quite straight-forward procedure.   This is getting quite annoying. Has anybody else experienced this? Is there a workaround?


This question must have been asked before, but I couldn't find anything. How would I create lists like this one: (1) This    is     a      sentence                               (Note 1)      Gloss1  Gloss2 Gloss3 Gloss4          'This is a sentence'                        (2a) yyy                                                         (Note 2a)  (2b) zzz                                                         (Note 2b)  (2c) uuu                                                         (Note 2c)  (3) qqq                                                          (Note 3)  (3') www                                                         (Note 3')  (4) ttt                                                          (Note 4)  in a way that I can refer to all those bullet points like (3') or (2b) both before and after they appear and also that allows those "www", "yyy", etc. to be three-line glosses, as in (1)? I can probably do all the labels "1", "2a", etc. manually, but I was wondering if this can be at least partially automated.

I do linguistics and I'm looking for a way to enumerate language examples that lets me reference to them in the text.        (1) This is an example.  Sentence \ref{...} provides a good example of basic English.   Bonus points if it's usable with \item, which makes it easy to use with org-mode.


Suppose we have the following:  class base{ }  class derived1 : public base{   private:   void fun();   friend class derived2; }  class derived2 : public base{   derived1 ob;   void fun2(){   ob->fun(); }   I want to use fun() of derived1 in derived2's fun2() wihtout using friend class and keeping fun() private in derived1.

Disclaimer Yes, I am fully aware that what I am asking about is totally stupid and that anyone who would wish to try such a thing in production code should be fired and/or shot.  I'm mainly looking to see if can be done. Now that that's out of the way, is there any way to access private class members in C++ from outside the class?  For example, is there any way to do this with pointer offsets? (Naive and otherwise non-production-ready techniques welcome) Update As noted in the comments, I asked this question because I wanted to write a blog post on over-encapsulation (and how it affects TDD).  I wanted to see if there was a way to say "using private variables isn't a 100% reliable way to enforce encapsulation, even in C++."  At the end, I decided to focus more on how to solve the problem rather than why it's a problem, so I didn't feature some of the stuff brought up here as prominently as I had planned, but I still left a link. At any rate, if anyone's interested in how it came out, here it is:   (I suggest reading it before you decide that I'm crazy).


I know that when a package is being installed, the root directory [I think?] gets an administrator lock and can't make an other installation at the same time.   Is there a way to stop that installation? If it is so, is it good to do?  I heard that it is better to leave the package to get installed and then try removing it. Is that true?

I get this error when trying to use apt-get:  E: Could not get lock /var/lib/dpkg/lock - open (11 Resource temporarily unavailable) E: Unable to lock the administration directory (/var/lib/dpkg/) is another process using it?     How can I fix this?


I want to compute following:  $$ \lim_{x \rightarrow 0} \frac{x-\sin(x)}{x-\tan(x)}$$  I have tried to calculate this with l’Hôpital's rule. l’Hôpital's rule states that: $$ \lim_{x\rightarrow a} \frac{f(x)}{g(x)}=\lim_{x \rightarrow a } \frac{f'(x)}{g'(x)} $$  Now i can get to the right result with l’Hôpital's rule but it took a little over two pages on paper. Had to use l’Hôpital's rule 4 times. How do you solve this without l’Hôpital's rule ?  The result appears to be(with l’Hôpital's rule):  $$  \lim_{x \rightarrow 0} \frac{x-\sin(x)}{x-\tan(x)}=-\frac{1}{2} $$  If someone can provide alternative solution to this problem that would be highly appreciated.

$$\lim_{x\to0} \frac{x-\sin x}{x-\tan x}=?$$ I tried using $\lim\limits_{x\to0} \frac{\sin x}x=1$. But it doesn't work :/


I've been having a problem with this one error when I try to log onto a server, and I've looked for answers but haven't found any. What causes the error and how to fix it?     Internal Exception: java.io.IOException: An existing connection was forcibly closed by the remote host

Upon entering any given minecraft server, after a minute or two I am forced out of the server, and I'm given the following error:  java.io.IOException: An existing connection was forcibly closed by the remote host.  What does this mean, and how can I prevent it from happening again?


Every Linux user has experienced this annoying thing: you begin typing a long and boring command, then realise you should have executed another one before. How to save the first one to execute it later?  Example  You begin typing   mycommand -a -F --conf /very/long/path --and /another/one /input/file.txt   But before pressing "Enter", you realise you should've done cp f.txt /input/file.txt at first.  So, you're stuck with your command, and if you don't press Enter you won't be able to have it back using your bash history.  What's the best way to handle this?

I often find myself in the following position: I've started typing a long command at the bash prompt, but half-way through I find out I need to check something with another command. This is a problem when I'm at the console (no X), which is often the case, because then I only have the following unsatisfactory ways to do it, that I know of:    Hit ctrl+alt+F2 and log in on another virtual console, and find out what I wanted, then go back and continue  ctrl+a, type echo + space + enter, find out what I wanted, press ↑ until I find my command, ctrl+a, del x 5, ctrl+e, and continue  Highlight what I've typed so far with my mouse (if gpm is running, which it usually is), press ctrl+c to interrupt, find out what I wanted while being careful not to use my mouse to highlight stuff, then press middle mouse button on a new prompt and continue  Pray to the command line gods that the half-written command will have no adverse effects but simply fail, and gingerly press enter, then find out what I wanted, press uparrow until I get my command back, and continue  Jump into my time machine, travel back in time and remind myself to start screen before starting to type command, travel back to the present, press ctrl+a c, find out what I wanted, press ctrl+a ctrl+a, and continue   So what I want to know is, is there some more elegant way of doing this? A sort of subshell-command or similar?  I'm most interested in methods that do not require any preparations or setup to work.


When I connect devices to my Windows machine, the "upwards" sound is heard. When I disconnect it -- the "downwards" sound is heard.  Is there a way to find events, corresponding to these sounds in event viewer?  I want to see what device was connected and how successful it was.  UPDATE  This is USB device.

Windows 7 frequently plays the usb/new device connection/disconnection sound. It happens both when the computer is idle and under load. All usb device connections have been checked (though I can't rule out a bad cable yet). I thought a good way to track down the issue would be to wait for the sound and then check the log file for the latest connected/disconnected device. I just need to know which log file has this information.  Edit: I'm going to leave the answer accepted, however the issue persists. I get that sound seemingly randomly throughout the day. Anyone else have any ideas?


How to find $A^{100}$ where $A=\left(\begin{matrix}\cos \theta &  -\sin \theta\\  \sin \theta & \cos \theta\end{matrix}\right)$. ? (Given$\theta=\frac{2\pi}{7}$)   I am a highschool student and new in linear algebra and seeking for only problem solving strategies. I found somewhere the trick to solve this kind of problem is find characteristic equation and then for some of the cases it is possible to find any power of matrix just by exponentiation of both sides. But here this is not applicable. The characteristics equation found to be $\lambda^2-2\lambda \cos \theta+1=0$ I  how to proceed now ?

Let $\theta=\frac{2 \pi}{67}$. Consider the matrix   $$A = \begin{pmatrix} \cos\theta  & \sin\theta\\   -\sin \theta&  \cos \theta \end{pmatrix} $$   Then the matrix $A^{2010}$ is?   My approach $$A^2 = \begin{pmatrix} \cos2\theta  & \sin2\theta\\   -\sin 2\theta&  \cos 2\theta \end{pmatrix} $$  $2010$ is a multiple of $67$. So I'm trying to convert in such format by taking $A$ matrix as power of $2$ and multiplying. But $2048$ is the nearest $2$ power term. So help please. I dont know if you can understand what I did!! Sorry for being not explaining properly


\documentclass[tikz,border=2pt]{standalone}  \begin{document}  \begin{tikzpicture}    \node at (0,0) (A) {A};    \node at (0,1) (B) {B};    \node at (1,0) (C) {C};    \draw (A) -- (B) -- (C) -- cycle; \end{tikzpicture}  \begin{tikzpicture}    \draw (0,0) node (A) {A} --           (0,1) node (B) {B} --           (1,0) node (C) {C} --           cycle ; \end{tikzpicture}  \end{document}   Some of the subtitles of TikZ are a little confusing. The example above produces the following pictures     In the first case, the lines don't enter the node labels, but the cycle command isn't activated. In the second, the lines enter the node labels, but the cycle command is activated. I naively thought the two pictures should be the same. Why are the pictures different? Why do the lines behave differently? Why does cycle behave differently?  There is a similar question here.    in which the answer explains that "bare nodes" do not have zero size. But it doesn't explain why the nodes are treated differently in these two cases. The phrase "bare node" does not appear in the TikZ Manual.

Cycle lets you close curves when drawing, and  \coordinate (a) at (0,0); \coordinate (b) at (1,0); \coordinate (c) at (0.5, -1); \draw (a) -- (b) -- (c) -- cycle;   works fine. Shouldn't also  \node (a) at (0,0) {}; \node (b) at (1,0) {}; \node (c) at (0.5, -1) {}; \draw (a) -- (b) -- (c) -- cycle;   give the same result?  The former gives a triangle, while the second doesn't close up. Is this a bug or am I missing something regarding the cycle option?  (Of course, as a workaround I could use the coordinates to draw the cycled path, and then draw the nodes at the same coordinates, but still...)


Let's say I have a String array with multiple items in it String[] dog = {"doggy","doggo","BigDog","dawgg"};  How do I remove "doggo" from the string array?

Given an array of n Objects, let's say it is an array of strings, and it has the following values:  foo[0] = "a"; foo[1] = "cc"; foo[2] = "a"; foo[3] = "dd";   What do I have to do to delete/remove all the strings/objects equal to "a" in the array?


On the Software Center I've seen that there are two versions of VLC. The first one is the 2.2.2-5ubuntu0.16.04.4, the one that I already have installed, and that has all the reviews on the page, and the second one is the  3.0.1-4-g14a4897.  Why? And should I uninstall the old one and switch to the other one, or not?

When I search for Chromium in Ubuntu Software on Ubuntu 16.04, There are 2 options.    Which one should I select?    The same can be observed with , ,  etc.


What are the open sets in $\mathbb{Q}$ wrt euclidean topology?   Basically I want to know whether an arbitrary open set in a metric space is countable union of closed sets or not, with or without depending on the locally compactness of the metric space.

Show that every open set $A$ is in a metric space $(X,d)$ is the union of closed sets.  This is a question on my analysis homework. I understand that this can only be true if we consider the union of infinite closed sets. However, I am not sure what I can do. I understand to prove a set is open, then a ball centered at an arbitrary point with a radius will be completely contained in the set. But what is the radius? Is this the correct approach?


I would like to know why in the context of vibrating systems, we define degrees of freedom in terms of number of independent coordinates (by coordinates I mean the numbers which specify the components of vectors) required to specify the motion instead of the configuration (configuration refers to just the positions and not velocities). Are these definitions equivalent because for motion, we are always concerned with the rate of change of each coordinate (describing the position or configuration) and thus motion also ends up involving same number of coordinates to describe the motion?  The book I am reading also mentions a line saying      On occasion, when internal forces are carried as unknowns, the number   of equations exceeds the number of degrees of freedom by the number of   unknown forces.   I am not able to see where would such a need arise; an example of this would be greatly appreciated.

resulted, rather as by-product, the discussion on how to count degrees of freedom (DOF). I extend that question here:   Are necessary1 derivatives such as velocities counted as individual DOFs or together with the respective coordinate2? Should complex valued DOFs be counted twice as in "two real-valued DOFs" or once as in "one complex-valued DOF"? (I mean, when one does not want to specify this explicitly)   Please answer with some reference, unless it turns out this is actually a matter of taste rather than a strictly defined thing.    1) I mean those a value of which is required as an initial condition 2) I count fields in QFT as coordinates as well, while space-time-coordinates are parameters to me, if that matters. I know a field actually has $\infty$ (or rather, $2^\aleph$) DOFs itself, but let's say e.g. "one $\mathbb R^3$ continous DOF" in that case


A directory named ~ appeared in a folder under ~/Projects/myproject/~.  Doing   ls -al ~/Projects/myproject drwxr-xr-x   3 myuser  staff      102 20 Sep 11:32 ~   I don't want to try removing it with rm because I have a feeling it will remove my whole home dir.  Is there any safe way to get rid of it, or any ideas on how it got there in the first place?

I accidentally made a directory "~/" under a subdirectory in my home directory. How to safely remove this directory without affecting my home directory. rm -r ~ obviously won't work... Thanks!


I am working on a research paper where I work with large amounts of data. The data was collected using a python code that I found on someone's Github repository. I was wondering how I would go about citing the repository in an apa style.

I am working on a honours thesis and have developed a Fortran library that I would like to cite in it.  In some places they suggest to quote the documentation of the project but this is something I plan to do in the future and isn't done yet. The only documentation I have right now is the README file and the code itself.   What would be an acceptable way of directing a reader to my work on Github?  (bonus) Is there a BibTeX way to do it?