Poster - should I send the file to all my collaborators?

Question: I'm a PhD student and I prepared a poster for a conference. Do you think I should send the poster file to all the co-authors? The list is quite long so I mailed the draft only to a few of them.
Answer: Yes. Everybody who is listed as an author should see and be able to contribute to the poster. You wouldn't want to be listed as an author of a work that you have never seen either, right?
Comment: To add to this: If some collaborators trusts you or just do not care, they only need to ignore the mail (if it has a proper subject), which only takes a few seconds.
Answer: Completely agree with xLeitix's answer:

Everybody who is listed as an author should see and be able to contribute to the poster.

Also, if it is a big file (assuming your poster is heavy on graphics) perhaps it is best to upload it to dropbox or a similar service and then send the link to all the authors. Depending on their (and your) digital fluency, the team can refine the document right from dropbox without having to send email back and forth.
Comment: Also, this should be a comment (which you cannot make, I know).
Comment: On the other hand, having a huge number of people working on something like a poster does not sound like a good idea to me – even with the best version-control system. Let alone the fact that if the OP was considering not even showing the poster to the collaborators, it is likely that they do not want to edit it.
Comment: I am a bit confused with "This" - are you referring to my comment on the use of dropbox? if so I did agree with xLeitix i.e. people should share. I just wanted to add **how**? If you are referring to @Wrzlprmft's comment I 100% agree with you.


How to specify include directory for configure script

Question: I have a linux system at my workplace with pretty old packages and no root access. I'm compiling packages that I need from source with --prefix=[somewhere in homedir]. My problem is that I just can't find out how to convince configure to look for header files in a specific directory. The source is cpp. I tried with environment variables related to g++ and looking up flags and googling but I had no success. Can someone help me solve this?
Answer: Usually you can pass additional compiler flags inside CXXFLAGS. For gcc you can specify more include directories with -I/some/dir, e.g.
$ ./configure CXXFLAGS="-I/some/dir/"

where /some/dir/ contains your headers.
Comment: CXXFLAGS is for C++ compiler, so CFLAGS for C compiler.
Answer: The normal way to do this is --with-<feature>=.
Comment: @Chara: Whatever `--help` tells you it is.
Comment: what goes in the ?
Answer: CPPFLAGS = C Preprocessor Flags, these flags will be used for C and C++ compilation.

CFLAGS = C Flags, these flags will be used when compiling C.

CXXFLAGS = C++ Flags, these flags will be used when compiling C++.

The -I flag specifies an additional include directory to be used during compilation.
Generally it's a good idea to use CPPFLAGS when specifying include directories, that way you know it will be used even if the project has some source that is compiled as C.
Of course, there might also be circumstances where you only want the include directory to be used by C or C++, but not both. In which case you would obviously be better served by using CFLAGS or CXXFLAGS instead.
Answer: It's better to use CPPFLAGS to specify include directories.
./configure CPPFLAGS="-I/your/whatever/includedir"


ubuntu 18.10 fails to boot

Question: I spent many long hours trying to install Ubuntu 18.10 on AsRock computer. It installs fine even on a Intel NVME ssd that the motherboard's UEFI utility can not use as a boot device. The problem is that after the installation finishes, the operating system will not boot. I tried several different ways, several media devices (hdd, ssd), different partition schemes, but it will not boot properly, no matter what I try. When I use a live USB image, I can mount and use the root partition/s just fine. There's definitely something wrong with the installer.... It could not even boot from an install done on totally empty hard drive with no partitioning done by me, when I let the installer do everything by it's own.... This should not happen.... Ubuntu reputation will suffer if this kind of behavior continues... The question is... Why is this happening ? Also, how can I make it boot after partitioning and installing ?
Answer: After a lot of time spent on this issue I was able to get it resolved by downloading the newest Ubuntu 18.10 image, burn it to an USB stick and going again through the installation process, like I did many times before. It worked from the first try, but at this time I had a totally empty hard disk to use. I went through the custom partitioning myself and even instructed it to put the root partition on the Intel M2 SSD (mounted on a adapter that is connected to a PCIe port on an older motherboard). I made the rest of the Linux partitions on the hard drive, except "/usr" that I did not separate from the root mount point. I tried using swap this time. Also, had about 75 MB for the "bios boot reserved partition" and another 75-100 MB for the "EFI reserved boot partition" that were the first two partitions created on the hard drive, in that order. It worked this time. I suspect there something wrong with the previous installer and/or the handling of the two boot partitions mentioned previously (bios_boot and EFI).

ubuntu 18.10 fails to boot


VMs Missing from Cluster list in DPM 2010

Question: We have a HA Hyper-V cluster with 8 nodes that we are backing up VIA DPM 2010.  As far as I can tell it is up to date with all the latest patches and the like.  Most things seem to run fine, however, when I try to create a new protection group or add members to an existing one several of the VMs do not appear in the list.  Any ideas what might be happening here?
Answer: Are the VMs running as cluster services? Open Failover Cluster Manager and make sure all the VMs are there. If you create a VM in Hyper-V Manager it is not clustered, you must later add it to the cluster with the Failover Manager.
Also have you installed KB975354-v2 on the Hyper-V Servers?
Also are you using the Release Candidate or the RTM? If you have RTM, did you have the RC installed before?


Please help me find the mistake

Question: I'm trying to use Tensorlow on İris dataset using sublime as the text editor. I got this error "TypeError: float() argument must be a string or a number, not 'generator'"when running the session, but I haven't any Idea about it. Please help me out. Attached is the error screenshot.
Comment: try to do np.array(...).tolist()    .. while generating your x1, x2 and y
Answer: I don't know precisely what's happening under the hood, but your list comprehensions on lines 31-33 are wrong and causing numpy to produce some funky arrays.
If you pull each of them out of the np.array calls and attempt to run them, you'll generate a nice SyntaxError (which is nice because it'll loudly tell us what's wrong!).
Right now, the error is getting suppressed by the fact Python is taking that funky list comprehension and creating a generator expression (I'm guessing due to how Python manages argument packing).
I'm unsure of the intent of lines 31 and 32 (are they supposed to be individual records from the data?), but line 33 can be rewritten as:
rand_y = np.array([binary_target[y_i] for y_i in rand_index])

Comment: Thank you, let me try on that

Please help me find the mistake


What happened to Todd the Wraith?

Question: At the end of Stargate Atlantis, after Atlantis lands on Earth, the fate of Todd the Wraith is left open. Last seen, he's a prisoner of Atlantis. What becomes of him?
Comment: Unanswerable — how can we know what happened to him after the series ended? There were no more episodes.
Answer: Wikipedia:

In the series finale, "Enemy at the Gate", Todd seeks the help of Atlantis to destroy a ZPM-powered Hive Ship stolen by one of his underlings (the ZPM having come from the ones he stole from the Asuran homeworld). He provides Atlantis with two additional ZPMs after the initial attack fails, and remains in their custody (in Atlantis on Earth) once the Hive is destroyed. His long term fate is not elaborated upon; however, he was slated to play a part in the upcoming Stargate Atlantis film, however, the project was shelved indefinitely.
Comment: Hah.  Looks like it also annoyed someone else on here. _After_ you posted this answer, someone edited the Wikipedia page with the note "however however however however".
Answer: There was a book series called Stargate Atlantis: Legacy which takes place after series 5.
In the books Todd was put into stasis, and Atlantis returned to Pegasus. There they discovered the Wraith were uniting under a powerful new queen. Todd was revived and gave the team some information in order to fight the new threat.
For his assistance he was eventually set free, or something like that (its been a while since I went through the book series).
Comment: Not bad for a 1st answer :) try to put some link or quotes to where you got these info

What happened to Todd the Wraith?


How thin can I make the wall of a pipe?

Question: For a science project, I'm 3D-printing some custom pipes and tubes to regulate the flow of gas (a combination of ethyl alcohol and water vapor) through an apparatus. They need to be pretty small, as the entire experiment is designed on a small scale. I'd also like the use a little filament as possible.
How thin can I make the walls of these pipes and tubes before either they collapse or gas leaks out? I know that's possibly an engineering issue, but I'd also need to take resolution into consideration. Ideally, the pipes would be about two centimeters in diameter, possibly a little larger or a little smaller in some parts. I'd most likely use ABS, but PLA is my backup in case there's some unforeseen reaction between the gas and the pipes.
The printer I'm using is an FDM printer, a version of the MakerBot Replicator.
Comment: @Jeff Good point. I made it a bit clearer that I'm also concerned about printer resolution, but primarily the strength of the filament.
Comment: What type of printer are we talking about? I suspect from the context (ABS and PLA) it's an FDM machine, but your question doesn't rule out a hypothetical PLA laser sintering machine.
Comment: @TomvanderZanden Ah, yes, it is an FDM machine. I'll specify that.
Comment: This might be a question that'd be better answered on the Engineering SO site, where you're more likely to find users with the specific expertise needed to answer a question like this.
Comment: @Jeff I don't think that's the case. Thin walled cylinders present some unique issues with 3D printing.
Answer: The thinnest wall your printer can print is determined by its nozzle size, and will be a little thicker than that nozzle size.
A great challenge when dealing with thin, hollow cylinders is that the cross-section has very little surface area and it can delaminate easily, especially if the tube is long.
You could try printing the tube with a very thick extrusion with, and using only a single perimeter. That would give better gas-tightness and layer adhesion than two, thinner perimeters, but it may turn out too fragile for your application. In that case, you'll need to print additional perimeters. Sticking to thicker extrusion widths would still be beneficial.
At a two centimeter diameter I'd say the single perimeter has a decent chance of working if you handle them gingerly.
Answer: The thinnest possible will be a single outline, so the best you can possibly do is slightly larger than your nozzle size.
The biggest issues I see in terms of making a thin airtight tubes are:

Complex geometry: anywhere you have overhangs you may need to increase the wall thickness to ensure a sealed overlap.  Bridging will need extra layers to ensure good layer adhesion and any supports will have to be removed carefully to not damage the surface.
Perimeter start/end: The joint where the perimeter starts/ends not only has to seal to the layer below but it has to seal with the now cooling start point.  This could be especially problematic if all of your layers are started at the same point (which visually produces a vertical seam) because you don't have a smooth perimeter on the previous layer and any imperfections in the joint are compounded.

Thoughts:

Print on end where possible: You'll get a higher quality outer perimeter if your layers are full rings instead of printing up both sides of a pipe on its side.
If you can manage a single perimeter when printing on end try using the "spiral vase" setting, which will smoothly raise the z position and print as a spiral instead of printing discrete layers.  This removes any issues related to sealing the start/end of a perimeter.
If you're printing with multiple perimeters increment the wall thickness in multiples of the nozzle size to ensure the perimeters are sealed together.  Having the perimeters not bound together increases the chance of leaks and reduces stiffness.
Do the pipes have to have the same thickness all along them?  You can probably reduce thickness to save material for simple geometry (straight sections) if you change thickness gently.
Answer: When printing thin cylinders vertically,

Slow print speed, to avoid rocking the model.
no shells, just one nozzle thick, so you don't need fill.  Fill can easily rock the print.
Print at least 2 at a time at the smallest layer thickness you can do.  This causes the hot end to have to move away from one cylinder to get to the next.  This gives each cylinder layer some extra time too cool and harden before the next layer goes on.  I generally print .1 or .05 for cylinders.
Your slicer may have a setting that tells it to wait between layers so the plastic has more time to cool.   I think the setting is called ORBIT on mine.

Consider following up with an acetone vapor bath to help seal the pores in the print.
Answer: This is difficult to give a definitive answer, but I have some thoughts.
For a vertical wall, the minimum thickness is determined by your nozzle size, typically 0.4mm. If you are able to print entirely in a vertical orientation (a pipe standing on end), you may consider using "vase mode" with no top or bottom to print. This can help simplify the CAD modeling, as you don't have to model the hollow interior and wall thickness.
For a horizontal wall, in theory this could be a single layer height, about 0.1mm depending on the printer and settings. Realistically, you will probably need 2 to 4 layers to get something "solid". However, this is not likely to have good results for a hollow pipe due to performance of the printer in bridging and overhangs. A thin, round pipe laying on its side is not likely to be successfully printable.
For printing in a horizontal orientation, I'd recommend a non-circular shape; the specific shape would depend on your overall design and goals. A "teardrop" or "flat teardrop shape can help with horizontal holes through parts.
Also, rather than individual pipes, perhaps you could design a block with hollow passages. This could allow thicker walls, make it much stronger, reduce assembly needs, allow for extremely complex routing and internal connections, and may even allow for functional parts like valves or sensors to be installed.
Finally, I would not expect an FDM-printed part to be airtight. There will most likely be some small gaps between layers and where layers start and stop. As an example, I tried making an ice mold, but almost all the water seeped through before it froze.
Another poster recommended an acetone vapor bath, which should help seal any pores. This only works with ABS. Another idea might be to coat the inner surfaces of the pipes with a resin that can seal everything up.

How thin can I make the wall of a pipe?


Are solar cell panels and wind mills worth the money?

Question: Besides being more environmentally friendly is it worth the investment in solar cell panels and wind mills for home use?  Is it possible to be "off the grid" completely?
Comment: By "Off the Grid", do you mean off the POWER grid?  Or do you mean totally self-sufficient (grow your own food, rainwater reclamation, etc)?
Comment: Off the power grid - baby steps first. :-)
Comment: Getting off the power grid is hardly a baby step... there are about 8,000 things you can do, from an environmental standpoint, before you begin producing any of your own power, and then about 8,000 more before you go off-grid.
Comment: I've been looking at this too and I can't see how the math would work in your favor on a short enough timeline for the financial reasons alone to justify it. However, I am curious if you FINANCED it whether you could get a positive ROI from day one (payments on the panels vs. Electricity bill)
Answer: To answer the investment aspect takes a bit of math. First, solar insolation numbers:

This represents the average sun-hours per day for a given area. You can see the range from 4 to 6, or 1460 hrs to about 2190 hrs of sun per year depending on location. I believe electricity also has a range of cost, but 15 cents per KWH is a good average.
So, a 1KW panel will produce as much as $328 per year of electricity in a high sun-hrs area, but only $219 in a lower sun-hrs area.
If we agree to ignore the government subsidies and look for the stable price unaffected by outside influence, an installed price of even $2500 would produce a return of 13% and a reasonable full payback over an 8 year period.
I call this installed price a tipping point, the price where this purchase provides a decent return. Some would accept a lower return, and therefore a higher price. As duff points out, this should be treated as the post rebate/tax credit price. Those help to push the price below this point. At the price point where the energy cost per panel is below, the government intervention may be unnecessary. The power companies may find consumer owned panels are the cheapest way to clip the peak consumption which tends to be the most expensive power demand.)
One can take the insolation numbers and cost of local power to produce a grid showing the return for a 1KW panel in $$/year. (At this point the cost of money kick in. The present value of $100/yr is far higher today than if short term rates were say, 8%)  Once panels drop to where they are compelling for the higher return areas, I'd expect volume to drive continued improvements in cost and better economies of scale. Initially, the need for storage isn't there, as the infrastructure is in place to drive your meter backwards if you produce more than you use. The peek sun coincides with peek demand and the electric companies are happy to have your demand go negative during those times.
Update - the conversation with Duff led me to research 'demand charge' a bit more. You see, the utility company has to have equipment to generate the peak demand, usually occurring in the early afternoon, say 12N-2PM as the sun is brightest and AC use in particular, highest. I found that Austin energy has a PDF describing the fee for this. Simply put, the last kW of demand will cost you $14.03 in summer months and $12.65 in winter. This adds to $160/yr that a 1kW panel might save the owner. Even if one does capture the full power at peak every month, $100 is still non-trivial. This factor alone justifies $1000 worth of panel cost, and as Duff points out, the government may find it cheaper to use this method to clip peak demand than by funding bigger power generators.
To summarize, the question isn't so much "are they worth it" as "what is a xKW panel worth?" (A function of annual savings and time value of money.) The ever decreasing installed cost for a given system makes solar an inevitable part of the future power technology. I am not a green tree hugging guy, but I do like to breathe fresh air as much as anyone. I'm happy with whatever role solar plays in cutting down pollution.
Comment: @JoeTaxpayer The issue is a little more nuanced than that, depending on where you live. Pollution is only one part of it. PV cells in particular generate the most energy during peak periods for electrical demand, reducing that demand. So if a state government invests $100M in subsidies solar and efficiency, (funded by electric ratepayers) it may avoid $300M or more in infrastructure investments.
Comment: Why would you agree to dismiss the government subsidies when discussing the worth of a PV installation? Generating electricity is a cash flow... the government subsidizes solar just about anywhere there is significant growth in electrical use. The subsidy has an impact on the value of the cash flow. Solar subsidies are cheaper than building a $1B power plant.
Comment: Because it's a contentious issue. There are those who claim that if it's only viable when subsidized, then it's not truly viable as you, duff, are paying in part for my panel. So I try to limit the discussion to the full, non-subsidized price. Any are welcome to point out the breakeven is pushed lower by state and federal subsidies or tax credits. That only adds to my position.
Comment: Moreover, government incentives are very unreliable. For an investment on more than twenty years, I wouldn't bet on them.
Comment: Duff - Everything you are saying is very important, no doubt. I see solar as producing a pretty convoluted graph, any given place in the world having a return normalized to a dollar return for a KW panel. Your government or utility co intervention helps push the panel cost down. In other dialog, elsewhere, I've responded to the objection that solar is only viable with that intervention. Instead of saying "so what" I try to show we are fast approaching a 'natural' breakeven. The value of peak demand is high and noted. I'm still researching that cost. I think we agree, though.
Answer: These are two rather distinct questions; only one of which is relevant to a Money web site.
In general, the investment is questionable.  Leaving aside the green feel-good factor, you need to look at a total cost of ownership (TCO) and payback on the asset.  Neither is cheap as such.  There are DIY windmill plans, but you likely still need a commercial battery charger/inverter/controller setup.
Government incentives, depending on where you live, may change the story considerably.  Many jurisdictions around the globe have both incentives to install and then power-feed-in tariffs if you sell back excess power.
Your latitude also has an impact on your total available solar energy, along with regular weather patterns for both cloud cover and wind.
One of the cheapest solar projects can be hot-water.  Particularly if you have a pool, or even for domestic use, if you use a lot.
All that said, given the green feel-good factor, if you want a small set of solar panels and have the space/budget, go ahead!  You can add more later.
For the second question: it is indeed possible to live off grid.  Some remote houses do just this, and the methods to accomplish it vary.  The number one thing you need to do is work on a power budget; and be both ruthless as well as realistic.  Fridge, freezer, AC, furnace, plasma TV, etc.  Depending on your climate and preferences, these may not all be possible for an off-grid lifestyle.  (Of course, if you get a propane fridge and have a truck come by once a month, does that count as off-grid?)
Comment: +1 for hot water. Solar hot water projects have a 18-36 month payback.
Answer: I have personally known a family in the hills of Southern Oregon, US who lived off the electricity grid.
As far as being "possible" yes, but easy is a certain no.  This family was very dedicated to the point of living without grid electricity.  A special built home of native field stones, careful alignment with the sun, location within the valley.  I would assume that making a normal home be off the electric grid is much more difficult.  Not impossible, but pretty darn hard.
Answer: Although this isn't related to homes directly, as an IT professional I know that wind power tends to be cost effective to the point that many data centers (the massive buildings holding the servers that are the backbone of the internet) actually invest in their own wind turbines to slash costs since servers tend to be power hogs.
As far as going "off the grid" that ultimately depends on how much wind/sun you're getting at your residence, but if you look at places like Dallas, PA, CA, and other areas where  the major hosts place centers, they're typically in areas where there's plenty of sunlight or wind.
Going back to small scale thinking however, one of my contacts actually leases a colocation building in PA where he has a few server racks, and while he currently has electric there, he also owns a couple of turbines which have been powering <60% of the demand, and he's actually planning to add solar and also feed that back to the grid at a profit.
So overall wind/solar definitely has the potential for a decent ROI, at both large and small levels, but performance will vary greatly from area to area.  I know that Lowes actually started advertising about carrying solar panels, so going in and asking about the performance and if you can arrange an audit of your home might be a good place to start.
If you Google "green audits" I'm sure you can find a trillion companies "specializing" in green power, but as with any sales rep (including at Lowe's) I'd do some due-diligence so you don't get taken for a ride, and also to check references because I don't think "green audit" companies have any official certifications/standards.
Answer: Solar water heaters are definitely worth the money (if you live in sunny states like South-South-West or Hawaii, at least). In some countries (like Greece, Cyprus and Israel, to name a few) most people use hot water from the solar heaters almost exclusively. I pay $30-$40 a month to PG&E for the privilege.
Unfortunately, in the US these heaters are much more expensive than they are in the more advanced European countries, so all the savings go to drain because of the vast price difference ($300 for a gas heater vs $2000 for a solar heater).
Answer: Solar water heaters are definitely questionable in the Northeast -- the season when you most need them is also the season when they are least effective.
Solar electric isn't a huge moneymaker, but with rebates on installation and carbon-reduction credits (SRECs) -- and a group purchase discount if you can get one, either at a town level or through organizations like One Block Off The Grid -- it can definitely turn a profit. Early estimate was that my setup would pay its initial costs back in 4 years, and the panels are generally considered to be good for a decade before the cells have degraded enough that the panels should be replaced. I haven't had a negative electric bill yet, but I've gotten close, and my setup is a relatively small one (eight panels facing SSE on a 45-degree roof). Admittedly I've also been working to reduce electricity use; I don't think I have an incandescent bulb left in the house.


How to print from a 32-bit 12.04 Ubuntu laptop to a printer on a 64-bit windows 7 pro computer

Question: I have a HP Desk-jet F380 All-in-One printer connected to my Windows 7 Pro 64-bit computer at home. I am trying to print to that printer from my 32-bit 12.04 Ubuntu laptop.The printer is shared by my windows computer and I installed it on my 12.04 Ubuntu laptop and it says it is accessible per the instructions from Ubuntu. I try to send a test print page to the printer and it gets sent ok and the printer starts as though it is going to print the test page but then it stops and the light on the printer stays blinking as though it is going to print.
Most posts I've read on this say that I have to install the 32-bit drivers on my 64-bit systems and I try to do this following the the instructions from this web site http://www.labnol.org/software/share-printer-between-different-windows-computers/9530/. Every time I do this I get a pop up that says the drivers for thing device are not in the folder. I downloaded the 32-bit driver from the HP website.
This is on a home network with 3 Windows 7 computers (2 laptops with home edition(64-Bit) and 1 desktop with pro(64-Bit)) and the 12.04 32-bit Ubuntu laptop. Could it be a RAM issue in the laptop? I have 1.2Gigs in it right now of PC-2700
Comment: I'm voting this question to be closed because it appeared to be a Windows question
Answer: On the windows 7 computer where the printer is connected, go into Devices and Printers
Right click on the printer you want to print to from the Ubuntu machine.
Left click on printer preferences, then in the window that pops up click on the Ports tab for the printer.
Look for bi-directional printing and un-check the box next to it and save. Now you should be able to print to the printer from your Ubuntu machine.


create woocommerce product from the front-end

Question: I am currently trying allow wordpress users to create woocommerce  product  from the front-end using WP User Frontend and woocomerce. I used this link: http://wordpress.org/support/topic/how-to-add-a-product-via-frontend-in-woocommerce/, as a guide followed instructions and I managed to make the form appear on the front-end. The only problem is that after submitting, the product is saved but the user is not redirected to any page and doesn't receive any thank you message. When I go to the back-end the newly created product appears but they are no image saved, no categories and no pricing. Can someone help me please.
Regards
Ted
Answer: You may Try this new plugin which has a Lot of features
Features
Woocommerce front-end Plugin
Comment: Dead link. Not an answer.


Set up DNS name servers for WP Engine

Question: I have set up my blog on WP Engine, and have been given a CNAME. My domain name is registered with CrazyDomains, and currently the name servers are pointing to Linode servers (where the blog was hosted previously). What do I need to do so that my domain name points to the blog on WP Engine?
Answer: Whoops - misread your original question - take 2: According to my co-worker Mike Price -you need to switch your nameservers to crazydomains default ones to change your A record and your A record should point to the IP in the WP Engine User Portal. Then add to domains page in the WP engine User Portal. Finally, Change home/site URL 2. Also, You can also change CNAME instead of A record but still need to change NameServer back to crazydomains. Hope this helps!
Disclosure: I am a WP Engine employee
Comment: I"ve tried this, but still doesn't seem to be working. Possibly an issue on the CrazyDomains side. I'll contact support and post an update here...
Comment: Issue resolved after registrar removed web forwarding

Set up DNS name servers for WP Engine


Why use Monte Carlo method instead of a simple grid?

Question: when integrating a function or in complex simulations, I have seen the Monte Carlo method is widely used. I'm asking myself why one doesn't generate a grid of points to integrate a function instead of drawing random points. Wouldn't that bring more exact results?
Answer: I found chapter 1 and 2 of these lecture notes helpful when I asked the same question myself a few years ago. A short summary: A grid with $N$ points in 20 dimensional space will demand $N^{20}$ function evaluations. That is a lot. By using Monte Carlo simulation, we dodge the curse of dimensionality to some extent. The convergence of a Monte Carlo simulation is $O(N^{-1/2})$ which is, albeit pretty slow, dimensionally independent.
Comment: +1 This reply shines because it offers *quantitative* reasoning in its support.
Comment: But doesn't this dimensionally-independent slower convergence still result in a usable precision when $N$ is far larger than we'd use to get the same precision with a regular-grid method?
Answer: Sure it does; however it comes with much larger CPU usage. The problem increases especially in many dimensions, where grids become effectively unusable.
Answer: Previous comments are right in that simulation is easier to use in multidimensional problems. However, there are ways to address your concern - take a look at http://en.wikipedia.org/wiki/Halton_sequence and
http://en.wikipedia.org/wiki/Sparse_grid.
Answer: While one typically things of rejection sampling when considering Monte Carlo, Markov Chain Monte Carlo allows one to explore a multi-dimensional parameter space more efficiently than with a grid (or rejection sampling for that matter). How MCMC can be used for integration is clearly stated in this tutorial- http://bioinformatics.med.utah.edu/~alun/teach/stats/week09.pdf
Answer: Two things -

Faster convergence by avoiding curse of dimensionality. Because most points in a grid lie on the same hyper plane without contributing significantly extra information. Random points fill the N-dimensional space evenly. LDS is even better.
Sometimes for Monte carlo methods we need statistically random points in no particular order. An ordered sequence of grid points will result in poor statistical properties.
Comment: Could you explain why points lying on the same hyperplane do not contribute "extra information" about an integral?  I am picturing a generic situation in which the domain of a measurable real-valued function on $\mathbb{R}^n$ is sampled and the integral of $f$ is estimated by the mean of $f$ on the samples.  I cannot see any reason in general why such an $f$ couldn't vary substantially on *all* hyperplanes intersecting its domain.  Perhaps you are thinking of Monte Carlo simulation in a different sense?


How to set fast the same customizations that i had in the previus versions of Blender?

Question: I have installed the new version of Blender 2.83, is very cool but now i have lost all customizations that i had in the 2.80 version. For exemple "Quick Favorites" or the layout. So there is a fast way to import/export all  customizations that i had in the previeus versions?
Answer: Just copy the preferences files to the new version.
Look for the userpref.blend of the old version and copy it to the folder of the new one.
In Linux is usually in /home/yourusername/.config/blender/version number/config.
For Windows it should be in \users\ your user name\AppData\Roaming\Blender Foundation\Blender\ version number \config.


Trying to recall old YA Sci-Fi series similar to Animorphs

Question: I recall a young adult book series similar to Animorphs where kids had special abilities to stop an alien invasion. The main difference is instead of turning into animals, they were more normal but enhanced skills. For example, one kid could speak any language including fax noise. Another kid could use any form of martial arts. I believe I also recall something about silver blood.
Comment: You hint at remembering more details. For example, can you remember any of the other powers? What any characters looked like? Can you remember why the aliens were invading? How many books in the series? etc. If you remember anything else please [edit] those details into your question!
Comment: If someone posts the correct answer, you can accept it by clicking on the checkmark by the voting buttons as per the [tour].
Answer: I suspect you're looking for the Mindwarp series by Chris Archer. It's come up a few times on the site.
Alien Terror

As the legend goes, an alien landed in the cornfields of Metier, Wisconsin. After a short while most of the aliens left. But others assimilated and cross-bred with humans. These children have lived ordinary lives--until now. At age 13, these offspring will manifest their alien powers . . . and have been targeted for termination. In "Alien Terror", Ethan Rogers used to be a wimp. But suddenly he knows martial arts, wrestling moves, combat skills and even weaponry. He'd think it was pretty cool--if he wasn't running for his life

Alien Scream

Jack Raynes ignored the anonymous note he got on his 13th birthday saying his life was in danger. That was a big mistake. Since he turned 13, he can suddenly speak several languages fluently--and he overheard someone talking about killing him in a language not even human.

The silver blood is indeed a plot point, as mentioned in other questions on this site. The first six books are largely each centered on the story of one of the children, with the next four involving their combined adventures.
Comment: https://scifi.stackexchange.com/q/105150/23243 and https://scifi.stackexchange.com/q/15847/23243 among others.


Which version(32b or 64b) is good for my system configuration ?

Question: Do I download the 32 bit or 64 bit version?
It has Intel Core2 CPU firstname.lastname@example.com GHz & 2.00 GB RAM.
It is running XP 32 bit.
So will 64 bit version of Ubuntu run on this machine?
Thanks,
Answer: You can install both, because 32-bit OS is compatible with your 64-bit CPU, but to get performance benefits you should install 64-bit OS. For example Ubuntu 14.04 64-bit
Your CPU is 64-bit:
Comment: click here, http://howtoubuntu.org/how-to-decide-if-you-should-use-32bit-or-64bit-ubuntu
Answer: Yep i'm running 64bit 14.04 ubuntu on Q6600 also http://ark.intel.com/products/29765/Intel-Core2-Quad-Processor-Q6600-8M-Cache-2_40-GHz-1066-MHz-FSB says Instruction Set     64-bit
$ sudo lshw -c cpu
  *-cpu
       description: CPU
       product: Intel(R) Core(TM)2 Quad CPU    Q6600  @ 2.40GHz
       vendor: Intel Corp.
       physical id: 4
       bus info: cpu@0
       version: Intel(R) Core(TM)2 Quad CPU Q6600 @ 2.40GHz
       serial: To Be Filled By O.E.M.
       slot: LGA775
       size: 1596MHz
       capacity: 3800MHz
       width: 64 bits
       clock: 266MHz
       capabilities: fpu fpu_exception wp vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx x86-64 constant_tsc arch_perfmon pebs bts rep_good nopl aperfmperf pni dtes64 monitor ds_cpl vmx est tm2 ssse3 cx16 xtpr pdcm lahf_lm dtherm tpr_shadow vnmi flexpriority cpufreq
$ uname -a
Linux Vini 3.13.0-24-generic #47-Ubuntu SMP Fri May 2 23:30:00 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
Answer: As a rule of thumb, any Intel Core CPU released after 2006 (when Intel Core 2 released) is 64-bit. That includes the entire Core i series. There's no reason to install 32-bit Ubuntu unless you know you need an application which has problems in 64-bit environment. If you don't know of any, you're probably fine. Go ahead and install 64-bit. In fact, if you're dual booting with Windows 8 on UEFI, only the 64-bit version supports UEFI.
Answer: With that 2 GB of ram, install a Xubuntu or Lubuntu. This will give you extra RAM, It is recomendable to update ram to run many other applications. Just like an advice.


Deploying Cups printers via MS Group Policy Object

Question: I have Cups installed on a Debian GNU/Linux 9.0 (Stretch) OS. On this server, I've set shared printers which I have to deploy on 80 Windows 7 PCs.
I have no problem for installing a printer on a single PC with the address http://cupsserver:631/printers/foo-printer, but I have no idea of how to do that with GPOs. I tried to create a policy with http://cupsserver:631/printers/foo-printer as sharing path of a GPO but when I try to apply the rule on a PC, the Windows event log returns an "invalid printer name" error and doesn't install the printer on the device.
What is the procedure to solve my problem ?
Answer: Group policy cannot be used to deploy printers that connect over the HTTP protocol. GP requires that the printer be resolveable to an IP addresses, or shared through Windows printer sharing.
Further, the path to the driver specified in group policy cannot use the HTTP protocol. The driver needs to be hosted on an SMB network share.
As a workaround, if you can create your printer connection using a script, you can easily deploy the script via Group Policy.


Roman air force

Question: I need help in figuring out how to form an air force in the roman empire. In my story a time traveller goes back in time to ancient rome and becomes emperor and begins his attempt at modernizing the legions. I would prefer if no magic was involved, other than that all ideas are accepted.
Comment: what has steampunk to do with ancient Rome?
Comment: Why specifically "air force"? Have you resolved all other problems? Has he managed to update the economy, free the slaves, introduce gunpowder, revolutionize trade and industry, develop chemistry and metallurgy, etc. etc. etc. so that all that it's needed is the air force? Note that what he has when the air force is that remaining thing to be done is most definitely what most people would think as the Roman Empire. I would dearly love to read the ten or so books describing how the hero progressed from, say, Vespasian's Rome to the point where an air force makes sense.
Comment: I hate to say it, but this question is likely to get put on hold.  Can you elaborate or add some examples that may have popped up in your mind so we can get more specific?  "I want a roman empire flying Spitfires" kind of thing.  Or maybe just an indication of powered flight, or is any way of getting one's feet off the ground.....
Comment: are you asking for plane design under roman technology? or in how to use this air force in battle? or just how to form or train them to become air force unit?
Comment: @AlexP my first thought as well. Do Romans *need* an air force? What for, to wage war on the eagles? While the legionaries are roaming the skies, the barbarians would still be sacking the lands, so little benefit there. *Maybe* this could just be airdrops for faster transportation but...it needs *serious* investment in time and resources to make a *fast* air transport for significant amount of people. Some sort of zeppelin or balloon might be more likely to show up but it hardly serves a purpose.
Comment: @AlexP why free the slave though? beside the slave can buy back their freedom anyway. i can see air force  help a lot in air bombardment (even if the amunition is just stone) and even help alot in siege warfare at least
Comment: Start with steam engine and modernize from there..
But I do not see how you could ancient rome to airflight (at least heavier-than-air-flight) within a lifetime. They had great craftsmanship, but no scientific approach.
Try with lighter-than-air like in Ballons. Start with Hot-Air-Ballon, later with hydrogen ballons, after that blimps and even later zeppelins
Comment: @LiJun: Free the slaves because to make a modern industrial base you need the corresponding workforce. With half the population in slavery and most of the rest not much better off it won't work. (And yes, I know how slaves were integrated in the Roman society; yes, it was not at all similar with what the Americans had in the 19th century.)
Comment: Aw, just go full [Sky Police](https://www.youtube.com/watch?v=w--VcX3n_7w), and let your powered Legions crush their puny foes.
Comment: Read L. Sprague de Camp's _Lest Darkness Fall_ for an idea what changes a time traveler is likely to effect in the ancient world. (Spoiler: he tries but fails to create a usable cannon, & doesn't even consider building a plane.)
Answer: The only "airforce" that can be plausibly created in a lifetime of time-traveler are incredibly expensive hot air ballons and extremely dangerous human-lifting kites. Both used for reconnaissance and communications. But it's just not worth it. They would be just expensive toys with minimum applications.

Selfpropelled planes - definitely no. There was no light and powerfull power source. Those "steam turbines" were highly inefficient and heavy (made from bronze).
Gliders - maybe, but unlikely: unlike kites, they require stronger, more durable low weight materials, just to not fall apart in a midflight (nothing saying about landing). And, most important, they require extremely high for that time period crafting skills, to make that glider symmetrical and balanced enough to be stable at flight. And even if romans manage it - it will hardly lift one human and will have aerodynamic quality (glide distance divided by start height) less, then modern parachutes. And it can't be used for any military purpose (if not turned into kite)

Roman military mashine was perfect for that time period and region - it had nothing to improve. And the only challenge it had was itself. Civil wars did more damage for Republic and Empire than any enemy did.
Comment: >> But it's just not worth it., It is actually worth it, If I can make humans fly in that period of time, I might not even have to go to war. I can simply show of my magical powers and make the petty humans (of other nations) bow before the incarnation of GOD himself.
Comment: There were so many incarnations of gods at that moment (emperor already was a leader of religion - those "august" title) - it would not make others bow, but provoke another civil war. And penecilin would had much greater effect than any "tech mirracle"
Comment: Even with modern knowledge of fluids and buoyancy, I don't know that the Romans could even make a hot air balloon. I highly doubt they had access to a fuel source with enough energy density (consider hot air balloons that use refined fuels like propane), and I'm not sure they could even make an airtight fabric light enough to use as a balloon.
Comment: Romans had silk from China, and coal is good enough for reconnaissance blum sitting low, tight by the rope (you can always lift up more with another rope). We are not talking here abot crosscountry trips, but battlefield observations.
Comment: I didn't think silk would be suitable due to its low melting point. But apparently the first hot air balloons used it, so I'll concede the point.
Answer: As I have commented on other answers I do not think any traditional form of aircraft is viable for the Romans. They would need to bootstrap hundreds of years of advancement in materials science, metallurgy, mechanical knowledge, tooling and machining, mining etc. to produce any kind of engine, and not much less than that to make a hot air balloon.
That means we have to think outside the box.
Wooden gliders
Very situational, high risk of being shot down or just landing in an inconvenient place. Would require a nearby hill or mountain for a gravity-powered launch. Maybe you could launch one from a ballista or tow it behind a team of horses?
Seems like this is nothing but a liability though - and you might be better off just firing the ballista (or horses) at people.
Well-trained animals
Get pigeons to drop hot coals on the enemy. Bat-bombs. Release a swarm of mosquitoes and give the enemy malaria (biological warfare!) Angry war hornets. Launch rabid squirrels from catapults! Hm, now I think I'm getting off-topic.
Comment: I'd really like to see a wooden glider launched from a ballista!  Seems like something the Romans would do....
Answer: The time traveler shows them how to build steam engines and how to create electrical power. Then he shows them that steam engines are much better than slaves for many applications.
Then the time traveler announces he will sleep for 20 years to restore his godlike powers, and he will come back looking exactly the same.
The time traveler uses his time machine to jump 20 years into the future from his current point. He looks how far the romans have advanced and guides them some more, then he skips time again.
Once the first steam engine was built things moved fast in the real world, there even where steam powered planes: https://en.wikipedia.org/wiki/Steam_aircraft
The hard thing our time traveler has to figure out is how to skip ahead to allow technology to advance and still remain emperor.
Comment: Steam power itself is not sufficient for this. The Ancient Greeks knew about steam power (https://en.wikipedia.org/wiki/Aeolipile). The reason it took so long for steam to become an industrial application was that society did not have the knowledge of mechanics, materials science and machining accuracy required to make a nontrivial engine.
Comment: There was never a steam powered aircraft which actually flew successfully with one or more people on board. The only one which at least came close was [Henri Giffard](https://en.wikipedia.org/wiki/Henri_Giffard)'s steam powered dirigible (1852), but even it was only half-successful -- it was not powerful enough to fly against the wind...
Comment: My point really is that the time traveler can show them how to do stuff and just skip ahead, he/she is a time traveler after all.. After the start of industrialsation things moved incredibly fast.
Answer: Powered flight would be extremely difficult, if not impossible in Roman times even if they had instructions. The primary difficulty would be the power plant which would require precision engineering of a sort that was not present in ancient Rome. Advances could be made but progress would be slow as so many required technologies would be needed the absence of each slowing the overall development down. Things like metallurgy, machine tools and electric power to name few.
It might well be possible to build gliders with detailed instruction, a lightweight wooden frame and stretched fabric skin. And they might even fly given enough time, effort and lives, but it is debatable if this would constitute an "Air Force". Such craft would be very easy to damage and cumbersome to move around. It is unlikely they would be of much use during most battles, but might find some application.
If a city was under siege in a hilly or mountainous area such craft might be used to overfly the city and drop flammable materials or fire bombs. It might even work (although the danger of setting the glider alight would be a significant hazard). That said ballistae would probably be much easier, the real advantage of the glider would be as a brightly painted terror weapon.
Hot air balloons might also be possible made of paper or better still with silk, however paper is relatively heavy and silk was a very rare and expensive luxury item in Rome. Had such a craft been made it might have served as a tethered observation platform, but the practicalities of such an arrangement would have been dubious.
A fire balloon might have been slightly more practical as a terror weapon in some circumstances (although still at the mercy of the wind) perhaps for use inside a city during a siege. Wait for the right wind direction then loft some large paper balloons with highly inflammable payloads and a long cord. Let them drift over the enemy and then ignite and release the payload.
So in summary, a "proper" Air Force would not be a practical proposition, however some air based weapons might be developed. How practical they would be and whether they would constitute an Air Force are debateable.
Answer: Paragliding and Parasailing could be options, especially because most cities (read: most military targets) would be near an ocean or river, where boats (with the right wind conditions) could be enough to get parasailers in the air and steering in the right direction.  For areas near mountains or cliffs - where "near" could be a few miles away - paragliders could be trained.
Working and stable parachutes could be made from animal skins - albeit imperfect and dangerous by modern standards.
Warfare in Roman times often included besieging cities (where gliders could fly over the city walls), or meeting in large groups face-to-face in fields or hills (where gliders could route over bridges, rivers, or even simply group up and throw arrows from the sky).  This would require defenses that were sealed above - digging ditches or building walls would not be enough defense.  Furthermore, calvary would be vulnerable as they could not easily hide from the arrows raining from above, as foot solders had different shields.
This type of basic "air force" would give a significant and plausible advantage simply because of it's asymmetrical tactics.
Answer: The obvious answer is to do hot air balloons.
But if your character is creative and has some historical interest, he could take inspiration from the first human propelled planes which were basically gliding-bikes. Bikes are a must have for your kind of story anyway (revolution of transports for the common people, can be used on Roman roads...), the emperor would just use a special one for his daring friends.
Also, if you aim to modernize Rome, you should seriously consider the invention of the radio. Though the Hertzian waves, the voice of your emperor could spread through the whole empire, protecting the borders from foreign aggressions would also be significantly easier.
Answer: Your best bet for an aerial force would be to use balloons.
The Montgolfier Brothers Figured out how to make balloons out of paper and were able to lift fairly substantial amounts firing them with a variety of fuels.  So you do not necessarily need silk or refined fuels to make them reliable devices to get up in the air.
The best way to use these wonderful things is for observation and for sniping!  Tether the balloons to control where they go and allow them to get high enough out of archer range.  From here, you have some options.  Since you are tethered, you can rig a simple message system to raise and lower messages from the observers and Commanders on the ground.  Use your technology expertise to make sure the balloonist and ground crew have reliable compasses.  That way you can direct fire from Balistae and catapults.  Heck, attach one balloon to each heavy weapon and they can begin firing at an enemy the ground crews can't even see.
Sniping, in a generic sense is another thing your balloonists can do.  Get an excellent archer or crossbowman up there.  They will be high enough that they should get some extra range from the bow.  It's always a good thing when you can hit the enemy from far away.  You might even be able to arrange some other nasty surprises for the enemy, like throwing pots of oil like molotov cocktails across enemy lines.
So even though you probably won't get powered flight, you can still have Roman Aeronauts doing a lot of things for you and they will even be able to shout: Mors Ab Alto

Roman air force


customer register in one website store and how he can place order in another website store?

Question: Generally, if customer register with one store then it's details will not use in another store, for this he must have to register with details in another store. then how he can place order with one store details in another store?
Answer: In the admin view,
under System > Configuration > Customers > Customer Configuration >
Account Sharing Options,
you'll be able to choose between sharing accounts per website or globally.
hope this will sure help you.
Comment: There, per Website option is select, then after this things happen? Why?
Comment: When i am register in one website and after login from other website (Change store from Front Top menu for Change store), it will give error message with No Username or password are wrong.


Dual-boot over two hard drives

Question: I have a Laptop with an SSD and an HDD. It came with Windows installed on SSD and since it is small, I added a HDD to store all my files and install all my games. I would like to install Ubuntu on a part of the HDD (without losing all the data on it. I have about 300GB free and can create an empty partition by "shrinking" the corresponding D: drive, so that should not be a problem) and want to keep using Windows as well as Ubuntu. I have seen several tutorials and questions about installing dual-booting Ubuntu and Windows, but all of them assumed they were installed on same disc. Is something different when it comes to installing Ubuntu on a different hard drive, will it still work and what are the possible problems and solutions?
Comment: UEFI or BIOS install. Are drives gpt or MBR(msdos). Windows requires MBR for BIOS boot and gpt for UEFI boot. But then what is HDD? You do want to partition in advance, but slightly different if UEFI or BIOS, but / (root) partition and optional /home partitions are same. https://help.ubuntu.com/community/DiskSpace  & https://askubuntu.com/questions/343268/how-to-use-manual-partitioning-during-installation
Answer: You can absolutely do this. There are a few things you'll want to do first:

Download ubuntu
Make a bootable usb of ubuntu
Shrink your HDD

Next, you'll want to insert your bootable usb and reboot into BIOS. If you don't know how to do that, EasyUEFI is a nice tool to boot into BIOS and edit the UEFI order (the free trial is fine). To use that tool, install it and click on Power -> Reboot into UEFI.
Once in your BIOS/UEFI, select BOOT and move select the usb or move it to the top and save and exit.
You should then load a screen that has a few options to either try out ubuntu, install it directly, or a few other things. You can do either of the first ones as the live cd version of ubuntu will have a desktop icon to install ubuntu.
Once you start installing you will be asked a variety of settings questions (timezone, name, password, etc). Select whatever settings you want for those, although you probably do want the 3rd party software as that will make your life a bit easier.
Important: don't simply select to install ubuntu alongside the windows bootloader. Instead select the last option to select the custom drive (your HDD). Double click the empty partition you made earlier and set the mount point option to be root (/). Then click install and you should be good to go.
Here's a similar guide with screenshots if you get stuck on that last bit.
Comment: Thank you for your answer. I know how to change boot priority and how to install OS-es separately, I was not sure about Dual-installing them.
Just to clarify: I install it on the selected empty partition and it won't affect the rest of the HDD, right?

And another thing: I've read that there might be complicatiosn with booting after installing ubuntu, so that it loads linux directly, skipping the option of windows totally because GRUB rewrites something on the booting part. Will that be the case with 2 HDDs? And, generally, will it recognize 2 OS-es when they are on 2 different drives?
Comment: Yes, installing on the selected empty partition won't impact the files on the rest of the HDD.

You shouldn't have issues with booting because GRUB can detect where both OS need to boot from. As long as you follow the steps correctly and set the mount point to be root on your second drive you should be ok, even with multiple drives.

Dual-boot over two hard drives


Extending The Width Of main-navigation But Still Keep It Centre Aligned

Question: My website is www.rosstheexplorer.com
I want the navigation menu to be the same length as the header. The header always covers the full width of the page.
I experimented with width, max width and float but I could not achieve the desired result.
Below is one of the experiments I tried.
@media screen and (min-width: 50em)
.main-navigation {
    font-size: .8125em;
    line-height: 2.09231em;
    text-align: center;

width: 100%
        float:left

}

I have been able to get the menu to cover the left or right hand side of the page but not both sides of the page.
Plus when I have been altering the width of the menu I have been unable to keep the text centered under the image.
Does anyone have any ideas?
Answer: You simply need to pull header element out from the page div:

[...]

  // This needs to go up
  [...]
  [...]

Like that:

[...]

[...]

  [...]


Platform Project Financing

Question: I am new to this community and I have been studying ethereum for 1 month now. I have signed up @ ethethereum.org with an abstract concept (potential prototype). I would like people to sign up on my platform to earn ether. The problem is, I don't have any either. Nor am I a miner (or interested in doing do). What other way's are there to finance a project? I do know they have the crowd funding route. Are there any others?
Answer: An interesting approach to fund a community project is outlined here.
This does however come with the limitation that funding will start only once a minimum viable product exists and is being used.
For upfront funding you either need a crowdfunding / ICO or other traditional methods.
Comment: What do you mean by "only once a minimum viable product exists and is being used"  Who says you need a product to earn either.

Platform Project Financing


Is there a way to iterate through lua dictionary in order that it's created?

Question: I need to iterate through Lua dictionary in the order that it's created.
For example:
t = {
['some'] = 'xxx',
['random'] = 'xxx',
['data'] = 'xxx',
['in'] = 'xxx',
['table'] = 'xxx',
}

Normal iterating with pairs gives a random sequence order:
for key, val in pairs(t) do
   print(key.." : "..val)
end

random : xxx
some : xxx
data : xxx
table : xxx
in : xxx

I need:
some : xxx
random : xxx
data : xxx
in : xxx
table : xxx

Answer: EDIT: Changed the answer, the old one is below for reference
-- function definition
function addNewItem(keyTable, myTable, key, value)
    table.insert(keyTable, key)
    myTable[key] = value
end

To add a new pair into the table:
-- you may need to reset keyTable and myTable before using them
keyTable = { }
myTable = { }

-- to add a new item
addNewItem(keyTable, myTable, "key", "value")

Then, to iterate in the order the keys were added:
for _, k in ipairs(keyTable) do
    print(k, myTable[k])
end

OLD ANSWER
Are you the one creating the table (Lua calls these tables and not dictionaries)?? If so, you could try something like the following:
-- tmp is a secondary table
function addNew(A, B, key, value)
  table.insert(A, key)
  B[key] = value
end

-- then, to browse the pairs
for _,key in ipairs(table) do
  print(key, B[key])
done

The idea is that you use two tables. One holds the 'keys' you add (A) and the other (B) the actual values. They look like this:
Since A pairs the keys in a manner like
1 - key1
2 - key2
...

Then ipairs(A) will always return the keys in the order you added them. Then
use these keys to access the data
data = B[key1]

Comment: Ive updated the answer, see if that helps
Comment: Sorry, that's not clear enough for me. I already have a table created and just need to iterate through it. Can you please explain more? How to call your addNew() function on my table "t" ?
Comment: Do you create the table, by adding the 'key-value' pairs by hand? Or do you use something like 'myTable = createATableFromRandomData(data)'??
Comment: Just by hand, it's stored in a separate file and I need to iterate through it.
Comment: That works well, thank you. Not exactly how I was expecting, because there will be a lot of additional code - my tables are pretty big and with this method they will be twice bigger (tables are generated from third-party app, so there is no chance to change their structure). But thank you anyway, your method works.
Comment: I'm glad I helped. Same thing could be done with metatables as well, although it's quite advanced and not worth the fuss. Additionally, myTable and keyTable could actually be the same table, no reason to separate them whatsoever.


Do standard headphones work with the XBox 360 controller?

Question: I want to listen to my games, but not disturb anyone.  I don't have a pair of headphones, so I want to double-check before I go get some: do they work with the XBox 360 controller?
Answer: You can use standard headphones to listen to game sound, but not by connecting them to the controller. You would need to use a television with a headphone jack, and then jack into that.
Some fancier headphones will come with an optical hookup, which can be connected to back of the Xbox itself. I have a Turtle Beach gaming headset. It connects to the controller for the voice communications, and the Xbox for the game audio.
Answer: No.  The xbox 360 controller has a 2.5mm jack but it is used for voice communications only, no game audio. Headsets that carry both game and voice audio require you to plug directly into the TV or the xbox to get the game audio.
Answer: The 360 controller does not have a 3.5mm headphone jack it is a smaller one i think it is a 2.5mm
Answer: I've ordered a little gadet on Wish.com
It has a the same 2.5mm jack with pins on one side, and then two 3.5mm jacks for earphones as well as mic. So yes, it can be done with such an adapter. Otherwise, there is an Xbox 360 headphone set with the exact aux cable needed for the remote, with mic attached.   Image included of the adapter.
(https://i.stack.imgur.com/FtEOJ.jpg)


Is there a way to recycle/use negative half of AC voltage from a rectifier?

Question: Forgive me, as I am far from an electrical engineer, but when rectifiers were explained to me I found that a rectifier allows current only in one direction, which allows it to filter out negative voltage of an AC power source and only output the positive, but where does this negative voltage go? Is it just lost in the conversion process? If so is there a circuit that can "recycle" this "lost" negative voltage?
Comment: Yes. useful search terms: "full wave rectifier", "bridge rectifier".
Comment: You are most likely talking about a single diode (rectifier) half-wave rectifier. The negative voltage or current doesn't "go" anywhere, it simply doesn't flow or pass, it is not allowed to pass by the rectifier, so i's not like it's wasted and needs to be "recycled". It's just that it hasn't been put to use and the circuit after rectifier only gets to use the AC supply current half of the time or during one (positive) half of the AC cycle. You could turn the rectifier around and use only the negative cycle, but I don't want to confuse you any more.
Comment: Your title contradicts your inner question.
Answer: The simple case you describe is a half-wave rectifier circuit, configured for a positive DC voltage output.  In the most basic sense, the rectifier diode acts as a switch, either allowing electrons to flow through it (on) or not (off).  During the negative half-cycles of the AC input, there is no electron flow.  It is the same as you flipping a switch on and off 60 times each second, perfectly timed for the positive half cycles.
Current (electron motion) happens only when caused by external conditions.  A battery, or a wall outlet, sits there with a potential difference (voltage) between its terminals.  If there is no connection between the terminals (an electric load like a light, motor or whatever), no electrons flow; there is no current.
Pedantic note:  "current flow" is not correct; current is the motion (flow) of electrons.  Blah blah x 10^18 electrons per second moving past a point is called 1 ampere.
Comment: Exactly what I hoped for and needed, eloquent in its simplicity. Thank you!
Comment: I'm torn between editting your post directly, and commenting in the hope that you'll modify it. I'm giving you the benefit of the doubt. Bringing in electron flow to noobs is one of the largest conceptual problem we face as engineers trying to undo old wrong habits. To be pedantic, conventional current is **charge** flow, and in metal wires, charge is carried by electrons. We try to emphasise the use of current, because it's the simplest 'lie to children' that works well, it's more correct than you think. 'Electrons' do not work well, even it they look like they do, from your perspective.
Comment: Within the rectifier, charge is carried by electrons and holes, so going to electrons too early is counterproductive. Holes are fully paid-up members of the quantum mechanical particle club, just as real as an electron, they have momentum, energy, mean free paths etc. I think it would complicate an answer about rectifiers to start on the minutiae of the charge carriers. That's why we say charge flow for noobs, and use quantum mechanics when they're ready. I know one model for holes is a 'missing electron', it's a poor model, as poor as [Drude](https://en.wikipedia.org/wiki/Drude_model)


Entity Framework Model builder with conditioanl foreign key

Question: Currently I am working on legacy sytem db which is quite messy
In hotel booking system table we have Reservation table which has one to many relation with different reservation system(e.g hotel reservation, train reservation) based on systemid
Table - Reservation
Column Reservation_id (int) | System_id(int) | Customer_id|
        45432               | can be 1,2,3 etc | 343 |
e.g. system id 1 can be hotel, 2 is train etc.

Table - [System]_Reservation system can be hotel or train or flight
Column Reservation_id (int) |  create_date(datetime) |other columns
        45432               |

Currently to load reservation details, we query the reservation table than based on system id we query respective reservation system table. each reservation can have 0..1* to many relationship with reservation system.
How can i create EF mdel builder around this.
I tried the following
<code>    [Table("Hotel_Reservation")]
    public class HotelReservation
{
    public int Reservation_id { get; set; }
    public Virtual Reservation ReservationInfo { get; set; }
    //other properties etc
}
    [Table("Reservation")]
    public class Reservation
{
    public Reservation()
    {
        HotelReservations  = new HashSet<HotelReservation>();
        TrainReservations  = new HashSet<TrainReservation>();
    }
    public int Reservation_id { get; set; }
    public int SystemID { get; set; }
    public virtual ICollection<HotelReservation> HotelReservations { get; set; }
    public virtual ICollection<TrainReservation> TrainReservations { get; set; }
    //other properties etc
}
//On model builder class contains
        Builder.Entity<TrainReservation>()
            .HasOptional(x => x.ReservationInfo)
            .WithMany(x => x.TrainReservations )
            .HasForeignKey(x => x.Reservation_id);
</code>
but on initialization thros following error
Multiplicity conflicts with the referential constraint in Role .....Because all of the properties in the Dependent Role are non-nullable, multiplicity of the Principal Role must be '1'.
Answer: This looks roughly like an inheritance model using Table-per-Type, however that System_Id looks more like an attempt at Table-per-Hierarchy. If the sub-class tables(Hotel_Reservation etc) hold a Reservation ID then you should be able to map it Table-per-Type and ignore the SystemId all-together in the relationship mapping. Essentially you want to treat Reservation as a base class with the specific reservation types extending it. From there you should be able to query specific reservation types, or the base reservation.
Have a read through: https://weblogs.asp.net/manavi/inheritance-mapping-strategies-with-entity-framework-code-first-ctp5-part-2-table-per-type-tpt
This outlines how the relationships are set up in EF, along with other inheritance data structure mappings including Table-per-Hierarchy.


Use PHP and MySQL DESCRIBE command to build checkbox and radio button menus dynamically

Question: I'm making a data-entry web page in PHP that validates and parses data for entry into a MySQL database.
There are more than 30 columns in the database that consist of MySQL SET or ENUM data.
If you don't know much SQL, an ENUM datatype column can only hold one value from a collection of ENUM variables that you define when you create the database. SET is also a collection of
variables that you define when you create the database, but the SET column can hold one or more of the
SET variables.
This is an ENUM datatype: car_titled_in_state = enum('Alabama','Alaska','Arkansas','California')
You can only title a car in one state. MySQL will not let you enter more than one state in
car_titled_in_state. (The error handling code for titling a car in more state is the function
prison_term(num_years). ;-)
This is a SET datatype: ice_cream_toppings = set('chocolate syrup','marsh mellow cream','cherries','butterscotch').
You can have any number of ice cream toppings, but each member of the set can only be entered and
counted once. (The error handling function for too many ice cream topping is body_weight = body_weight++.)
Radio buttons, which allow only one selection from the group, are suitable for ENUM variables.
Checkboxes, which allow for any number of selections from the group, are suitable for SET variables.
Making these menus line by line in my PHP would be a hassle because the groups of allowed variables
in many of these MySQL columns are going to change during beta and all the way into the early production months;
some of them will probably need to change again in 2011. These changes (lots of changes) would have to
made in the PHP code, plus all those requests would thicken the bandwidth between client and server.
I decided I would use a PHP function that queries the MySQL database and dynamically builds the menus.
This would need to use the MySQL command DESCRIBE, which, when used on ENUM or SET datatype columns,
returns the group of strings allowed in the column. (See above for their format.) Now, I am certain that
somebody, somewhere faced this problem before, but I searched the Internet twice for an hour each time,
and I did not find anything even close, especially not in PHP. So I decided to write my own, which took
me two days. It probably shouldn't have taken me that long, but I was working on my laptop in a van with
my wife and my in-laws, which was not an environment in compliance with Joel Spolsky's rules for
efficient programmer habitats.
I call my function choicemaker. (You will no doubt change this in your code.) It takes three
arguments: a MySQL table name ($table), a MySQL column name ($col_name) and an integer called
$row_length. The $row_length is a convenience. I have some very large SET and ENUM columns in
the database; one of the ENUMs lists every Federal Agency! I limit the number that display on each
line for the sake of neatness.
Choicemaker() inspects the results of the DESCRIBE query and uses them to decide whether to build
radio buttons (ENUM) or checkboxes (SET). This saves you having to put thid decision in code!
function choicemaker($table, $col_name, $row_length)
  #connect to the database
        {db_connect();
  #build the string for the DESCRIBE query -- note the absence of SELECT
         $qry_list="DESCRIBE " . $table . " " . $col_name . ";";
  #submit the query
         $listdisplay=mysql_query( $qry_list );
  #get the query results
         while ($row = mysql_fetch_array( $listdisplay )){
  #there will only be one row of results
            $make_list=$row[1];
  #we need to get rid of some punctuation from the results
            $remove = array("(", ")","'");
           $replace  = array("", "", "","");
  #important -- we inspect the query results to find out if we
  #have SET or ENUM variables and then assign a value to $choice_type and
  #get ready to remove either 'set' or 'enum' from the results string
               if (preg_match("/^set/", $make_list)){
                  array_unshift($remove, 'set');
                  $choice_type="checkbox";}
                    elseif (preg_match("/^enum/", $make_list)){
                           array_unshift($remove, 'enum');
                           $choice_type="radio";}
  #here we clean up the query results
               $arr_list = str_replace($remove, $replace, $make_list);
  #make get redy to loop through the clean results
               $arr_list = explode(',',$arr_list);
               $row_pos=$row_length;
  #finally, we get to make some buttons or boxes
                       foreach ($arr_list as $item) {
                              $str_choice = $item . ' ';
                              $str_choice .= '<input type="' . $choice_type . '" ';
                              $str_choice .= 'name="' . $col_name . '" ';
                              $str_choice .= 'value="' . $item . '" /> ';
  #output our button / box here
                              echo $str_choice;
  #decrement $row_pos to decide if it is time to output a line break
                              $row_pos--;
                              if ($row_pos == 0) {
                                 echo('
');
  #reset $row_pos after every break
                                 $row_pos = $row_length;}}}
  #Help stop connection pollution!  Always close your connections!
           mysql_close(); }

Here's the uncommented version for cut and paste:

            function choicemaker($table, $col_name, $row_length)
                    {db_connect();
                     $qry_list="DESCRIBE " . $table . " " . $col_name . ";";
                     $listdisplay=mysql_query( $qry_list );
                     while ($row = mysql_fetch_array( $listdisplay )){
                           $make_list=$row[1];
                           $remove = array("(", ")", "'");
                           $replace  = array("", "", "","");
                           if (preg_match("/^set/", $make_list)){
                              array_unshift($remove, 'set');
                              $choice_type="checkbox";}
                                elseif (preg_match("/^enum/", $make_list)){
                                       array_unshift($remove, 'enum');
                                       $choice_type="radio";}
                           $arr_list = str_replace($remove, $replace, $make_list);
                           $arr_list = explode(',',$arr_list);
                           $row_pos=$row_length;
                                   foreach ($arr_list as $item) {
                                          $str_choice = $item . ' ';
                                          $str_choice .= '<input type="' . $choice_type . '" ';
                                          $str_choice .= 'name="' . $col_name . '" ';
                                          $str_choice .= 'value="' . $item . '" /> ';
                                          echo $str_choice;
                                          $row_pos--;
                                          if ($row_pos == 0) {
                                             echo('
');
                                             $row_pos = $row_length;}}}
                       mysql_close(); }

Here's my question: given that this code will run about 30 times to build the page, would it really be any quicker
to do this in AJAX? It will take the users about 30 minutes at least, so there is no real performance gain associated
with having the top part built more quickly. I don't think the user experience will be much better. But what would an
AJAX version look like -- get the results back in JSOBN and parse them?
Answer: If I were you I'd cache this into a template or use the php file as a generator, unless there are quite a few table that will be queried.
What is the purpose of dynamically querying enum types?
Ajax won't make it load any faster, probably even slower, but might allow you to load the first 10, then the second 10, etc., so the user sees it actually working, and can interact with it before it is done completely loading.
I wouldn't think loading time would be  a big problem though.
Answer: The reason I need to build the menu from enum and set datatypes is that for at least the first two years of my application, these datatypes will expand, and there are too many of them (more than 30) to make it efficient to keep adding new ones in code. Adding them in the database and letting the code generate the menus dynamically will save LOTS of time.


What are the short commands of Xcode 4?

Question: Code and I like to navigate one class to  another through keyboard,because i used Visual Studio so it has become my habit to use Keyboard instead of mouse.I know it shows short command in menu but there is no such command for navigating one class to another.So please if someone have any idea about the short commands.I shall be very thankful to you for this.
Answer: Did you Google it at least?
My first hit on "XCode 4 shortcuts" is a nice PDF with all shortcuts
here is the 2nd hit:

http://cocoasamurai.blogspot.com/2011/03/xcode-4-keyboard-shortcuts-now.html

The new XCode 4 has a lot of changes, but if you Google a bit, you don't need to ask a non-programming question in this forum.
Answer: The standard link to provide is this one.
The specific combinations you probably want are command+shift+o for "fast open" (into which you can type a class name rather than a file name if you prefer), and command+control+cursors to switch between implementation and interface and back and forth through your recently opened history. Another good one is option-clicking and option+return where you're using the keyboard to open a file in the assistant pane instead of the main one.

What are the short commands of Xcode 4?


How to repeat the last run script in Illustrator?

Question: If I run a script, is there a way to run it again without doing File|Scripts|My_script?
Answer: You can create an action, assign an F-key to the action, then use the F-key.
Use the Insert Menu Item command located in the Action Panel Menu to insert the call to the script.
But be aware, when you quit Illustrator, the action loses the connection to the script. So, each time you launch Illustrator, you have reconfigure the action. This is a long standing bug in Illustrator.
Comment: I can't even get scripts to show up under actions when I'm recording. How do you do that?
Comment: @Johannes You have to use the "Insert Menu Item" option in the Action Panel menu.
Answer: Unfortunately, the answer is no. This has been a requested feature for years now and Adobe has done nothing to address it.
Answer: Ctrl + F12 gets you into the Open Scripts dialog (in Windows, anyways)...It's not an answer to your question but I sometimes find it to be quicker than clicking File and going to Scripts.
Answer: In Windows I use AutoHotkey for things like this.
Example:
To use F1 to run File > Scripts > Script Name it would look like this...
F1::Send !frs

Edit: I forgot to mention if you want this shortcut to be Illustrator specific so it doesn't affect any other programs just add the following...
#IfWinActive, ahk_exe Illustrator.exe
F1::Send !frs
#IfWinActive

Comment: I just put the path to my script there, and it will execute the script file in the appropriate application, as long as within that script the #target directive is used: `#target illustrator`
Answer: I think Ctrl/Cmd+D can do it. I practiced it with general actions in AI and other scripts.


Can I update the id of an existing OptionValue?

Question: I'm trying to update the ID of an existing OptionValue using API v4. I get "Cannot update the id of an existing OptionValue" error. Is there another way to do that?
Comment: `id` is an autoincremented value in DB which should be set by DB itself. Updating the id directly in such a way is not a very good idea. Can you let us know what you are trying to achieve?
Comment: Jitendra I'm trying something to fix this, see https://civicrm.stackexchange.com/q/33833/186
Comment: Are you sure it's the "id" you want to update? For option values it's usually the value in the "value" column that gets used and/or stored in the foreign table, if you're trying to fix something that got out of whack.
Comment: @Demerit yeah it was definitely the ID. I was able to do it using mysql at the command line. I was attempting to fix the problem in the Q linked in the above comment, changing the didn't do the trick. I had deleted the City, County and State/Province option values in Addressing Options, duh on me, then added them back in, but of course they had a new auto-incremented ID number. I thought that restoring to the previous ID would fix the problem with the City, County and State/Province not appearing when editing an Address in the Summary screen.
Answer: As said by Jitendra, you cannot update the id via CiviCRM api. The id in civicrm tables are autoincremented and are referenced at many places. If you still want to take risk than you can run a sql query in mysql to update the id of required row in civicrm_option_value table.


Using AncestryDNA to work out whether mother or father is parent of half sibling?

Question: How do I work out from viewing my shared matches on AncestryDNA which one of my parents is the parent of my half sibling?
Comment: Look for "shared matches", and see who is in that list. Relatives of your mother? Relatives of your father?
Answer: You need to find a known relative on your mother's or father's side that has also done an AncestryDNA test. That relative will presumably match your father or mother. If they also match the half sibling then that indicates which one is their parent. It is not proof because there could be other reasons for the matches. For proof you would need to test your father and your mother.
Comment: Welcome to G&FH SE!  As a new user be sure to take the [Tour] to learn about our focussed Q&A format which is quite different from bulletin boards, discussion forums and other Q&A sites you may be used to.  Thank you for joining and starting to participate in our community.


Can this ceiling box support a 12 lbs ceiling fan?

Question: I live in a house that was built in 1999, this outlet currently mounts a light fixture. I want to replace the lights with a ceiling fan but I am not sure if the current outlet box will support the fan.
Answer: Sorry, but this junction box is not rated, won't support a ceiling fan. You will have to investigate further to determine how the box is mounted and replace it with a box rated for a ceiling. If you have attic access to this box, replacing it will be easier. If not, it will be more difficult and you might have to remove some of the ceiling around the box to cut it out.
Comment: Most of the old work fan rated junction boxes I see let you slip the cross rod into the existing hole and tighten it between joists. There's still a chance of having to hack the ceiling, but I'd say it's unlikely.


Atmega 328 with DS1620 thermometer chip. Why is a pull-up resistor needed on the DQ line

Question: I think understand the purpose of pull up resistors in general but in this particular case the DS1620 datasheet says that in the output mode it sources a current of 1ma (see footnote 5 on the last page).
My understanding was that I would need a pull up resistor on the Atmega's input if the other side didn't source any current in the logical 1 state (high impedance), but in this case it says it sources current, why would I still need a pull up resistor enabled on the Atmega's input pin? (it doesn't work without the pull-up)
Answer: The high output is specified as a minimum of 2.4V. This is enough if the ATmega is running off a supply of 4V or less, otherwise a pullup may be needed to pull it up to 0.6VCC.
Comment: Both atmega and DS1620 are powered from 3.3 V. But I think you're right, Atmega's input high starts at 0.7 Vcc and DS1620 output high also starts at 0.7 Vcc so there's kind of a narrow margin and the Atmega may not detect the high without a pullup. Don't have an oscilloscope to to see what's really happening there.


Show that a set is complete in a generic Hilbert space $H$

Question: Let $\{e_n\}$, $n\geq1$ be an orthonormal base of an hilbert space $H$. Let
$$
f_1=e_1-e_2+e_3,\quad f_2=e_2-e_3+e_4,\quad \ldots\quad f_n=e_n-e_{n+1}+e_{n+2}.
$$
Show that $\{f_n\}$, $n\geq1$ is complete. I think I have to use the definition, that is
$$
(f_n, x)=0,\ \forall n\ \ \Rightarrow \ \ x = 0
$$
but I cannot understand how. Some help?
Comment: What does it mean for a sequence of vectors to be complete?
Comment: what do you mean by "generic?"
Comment: @supinf an hilbert space $H$. The exercise doesn't specify..
Comment: @MatthewLeingang a definition is included, but it looks more like dense instead of complete
Answer: Hint:
By using $f_1+f_2=e_1+e_4$
we get
$$
 0= (f_1,x) + (f_2,x)
 =
 (e_1,x)+(e_4,x)
$$
Doing the same with $f_4,f_5$ and combining with the above, yields
$$
 (e_1,x)=(e_7,x).
$$
This can be generalized, so you have statements about $(e_n,x)$ for $n\in \mathbb N$.
Then you have to use $(e_n,x)\to0$,
which follows from $e_n \rightharpoonup 0$
or Bessels inequality.
After that you will be much closer to the goal.
Comment: It is important that the property you are after is not the same as completeness. supinf has already noted this in their answer. A more appropriate word for the property you are after is that the set generates the Hilbert space.
Comment: edited to adress your questions
Comment: after that, you know the value for each $(e_n,x)$.
Answer: Assume $\langle x, f_n \rangle = 0$, for every $n \in \mathbb{N}$. Notice that for $n \ge 2$ we have:
$$\sum_{k=1}^n f_k = \sum_{k=1}^n e_k-e_{k+1}+e_{k+2} = e_1+e_{n+2}$$
So
$$0 = \sum_{k=1}^n\left\langle x,  f_k\right\rangle = \left\langle x, \sum_{k=1}^n f_k\right\rangle = \langle x, e_1 \rangle + \langle x, e_{n+2} \rangle$$
which implies
$$\langle x, e_1 \rangle =- \langle x, e_{n} \rangle, \quad \forall n \ge 4$$
Now, since $(e_n)_{n=1}^\infty$ is an orthonormal basis we have:
$$\|x\|^2 = \sum_{n=1}^\infty \left|\langle x,e_n\rangle\right|^2 =  \left|\langle x,e_1\rangle\right|^2 + \left|\langle x,e_2\rangle\right|^2 + \left|\langle x,e_3\rangle\right|^2 + \sum_{n=4}^\infty \left|\langle x,e_1\rangle\right|^2$$
For the sum to be finite, it must hold $\langle x, e_1 \rangle = 0$.
Now
$$0 = \langle x,f_3\rangle = \langle x,e_3-e_4+e_5\rangle = \langle x,e_3\rangle - \langle x,e_4\rangle + \langle x,e_5\rangle = \langle x,e_3\rangle$$
so we have $\langle x,e_3\rangle = 0$.
Finally:
$$0 = \langle x,f_1\rangle = \langle x,e_1-e_2+e_3\rangle = \langle x,e_1\rangle - \langle x,e_2\rangle + \langle x,e_3\rangle = -\langle x,e_2\rangle$$
So, $\langle x,e_2\rangle = 0$.
Therefore, we have $\langle x,e_n\rangle = 0$, $\forall n\in\mathbb{N}$.
Now, since $(e_n)_{n=1}^\infty$ is an orthonormal basis:
$$x = \sum_{n=1}^\infty \underbrace{\langle x,e_n}_{=0}\rangle e_n = 0$$
An orthonormal set $\{f_i\}_{i\in I}$ with this property is sometimes called a maximal orthonormal set, and in a Hilbert space this is equivalent to $\{f_i\}_{i\in I}$ being an orthonormal basis. It is maximal in the sense that there does not exist a vector $f \in H$, such that $f \perp f_i, \forall i\in I$ and that $\{f_i\}_{i\in I} \cup \{f\}$ is also an orthonormal set.
Comment: Possible short-cut: Let $H_n$ be the closed linear subspace of $H$ generated by $\{e_j:j\geq n\}$.  Let $F_n$ be the closed linear subspace of $H_n$ generated by $\{f_j:j\geq n\}.$  Your method for showing for $x\in H_1$ that $x\in F_1^{\perp}\implies =0\implies x\in H_2$ can be applied for all $n:$ If $x\in H_n$ and $=0$ for all $y\in F_n$ then $x\in H_{n+1}.$  By induction on $n,$ if $x\in F_1^{\perp}$ then $x\in H_n$ for all $n,$ so $x=0.$.......................+1
Comment: $\{f_i:i\in I\}$ is not orthonormal . $=-2.$


What is the mechanism for when the fed purchases a gov't or corporate bond from a non bank?

Question: My understanding is when the fed buys a bond from a bank they use bank reserves (bank reserves are swapped for a bond). How does the transaction differ when a non bank (ex hedge fund) is involved?
Answer: When the Fed buys a bond as part of a Quantitative easing program, they execute with Primary Dealers through a website interface.  Hedge funds do not execute directly with the Fed, although they could execute with a Primary dealer who executes with the Fed.
When the Fed executes with a primary dealer, it credits the account of the primary dealer using newly created funds.  The dealer deposits the fund in a bank account, which increases bank reserves in the system.
Answer: Roughly speaking, say the central bank wishes to purchase £10 billion worth of bonds from non bank NB. NB will have an account with a bank B. The central bank cannot transfer reserves directly to NB so instead they give the reserves to B and instruct B to create £10 billion of demand deposits in NB's account.
As you can see, and contrary to the belief of many commentators, QE creates inside money in the very first instance and does not require a bank to do any new lending to convert the reserves to inside money.
Answer: Federal Reserve Financial Accounts Guide - All Tables
https://www.federalreserve.gov/apps/fof/FOFTables.aspx
These are also known as the Flow of Funds statistics kept by the Federal Reserve. The Fed assets and liabilities currently appear in Table L.109 Monetary Authority. The bank sector assets and liabilities currently appear in Table L.110 Private Depository Institutions. Reserves are a liability in the Monetary Authority table with matching financial asset in the Private Depository Institutions. Since non-bank units in the Flow of Funds sectors do not transact in Reserves the commercial banks or so-called depository institutions must clear payments between Fed and non-banks when Fed transacts with non-banks.
Coupled Charts of Accounts:

Reserves are liabilities of the Fed or central bank.

Reserves are financial assets of the commercial bank sector.

Deposits are liabilities of the commercial bank sector.

Deposits are financial assets of the non-bank sector.

Marketable securities are financial assets.

Accounting Rules:

Assets increase by a debit and decrease by a credit.

Liabilities and equity decrease by a debit and increase by a credit.

When Fed purchases a security from a non-bank there are three sectors which keep records using double-entry accounting customs.

Fed debits security assets for an increase and credits reserves due to the payment clearing bank(s) for an increase.

The clearing bank(s) debit reserves for an increase and credit deposits due to the security seller for an increase.

The non-bank security seller debits deposits (cash) for an increase and credits marketable securities for a decrease.

Note the Fed and aggregate bank balance sheets expand and the non-bank sector only recognizes a swap of assets of securities for cash.


Explaining Temporary Voluntary or Medical Leave from Prestigious PhD on CV?

Question: I am in a bind. I just decided to take a voluntary leave of absence for medical reasons (also partly financial reasons) from my PhD program and I need to look for a job. I have stupendous credentials and recommendations but most of my recommenders are academics who recommended me two years ago for this doctoral program.  My urgent worry is how to brand and market myself on my CV. If I list that I am enrolled in a PhD program there is always the risk that I will be asked to provide a transcript (which at this time shows failing grades for the last semester)? Also, if I don't list the program on my CV it looks like I have 2 gap years because I took a year to travel between the last employment and the start of the PhD. However, the benefit of listing my program is that because it is very prestigious, it is likely it will push my CV to the top of the applicant pool for interviews.  If I list my PhD program on my CV I am almost guaranteed interviews, but in doing so, I run the risk of  having to go into detail to explain my extraordinary poor performance and decision to suspend my study for a year.  What should I do?
Answer: I recommend you list your PhD studies on your CV. Industry is full of people who have left a PhD program for one reason or another! It's also unlikely anyone will look down on you for your poor grades in one semester.
There are two issues I would give some thought to: (1) how will you describe your reasons for leaving the programme (temporarily), and (2) will you tell them about your intention to return to the PhD programme. It's best if you can describe (1) in a way that won't give potential employers concern that you might not be able to handle the job. Being honest about (2) may discourage some employers from hiring you if they want a long-term employee, but others may be willing to gamble that you'll change your mind and stick around.
Comment: I agree, but I'd go further: leaving the PhD studies off isn't even a viable option.  Surely any employer will ask what you've been up to for the last two years.  Then you've got a choice between lying (and risking being fired when you're found out) or explaining why the PhD studies didn't seem worth listing.  Both options are bad.
Comment: "Surely any employer will ask what you've been up to for the last two years."  Or just reject your application immediately and move on to candidates without suspicious gaps in their resumes.  Figuring out how you will explain those gaps isn't very helpful if you don't get far enough into the interview process to actually explain anything to anyone.  I agree with @AnonymousMathematician that you really must include your studies on the CV; then be ready with an explanation as to why you have suspended them and how/when you plan to resume them.
Comment: Well, the way I am thinking of explaining it is by saying that I've had family and financial responsibilities that were difficult to handle  while being a student. As far as my intentions to return to my program, I also have an explanation for that. On the heels of the financial responsibility and the financial strains of living in New York City, I plan on telling the potential employer that I will be resuming studies but on a part-time basis.  Many folks in my program do so, so I don't think this should be a big obstacle.  What do you think?
Answer: You are only in your first year. By the time you are wrapping up your dissertation, it will likely be five to seven years from now. Ancient history.
Postdocs are more interested in your research, publications, and letters of recommendation than in your grades. Many won't even ask for transcripts.
Same goes for jobs.
Grad school is a marathon not a sprint. Pace yourself and try to keep good energy reserves at all times. Steady Bs with occasional Cs and finishing is better than a semester of As followed by a flameout.
Comment: I think the question is about how to handle the CV right now (e.g. while still on leave), not after finishing.  At this point the OP is presumably applying for short-term industry jobs, not postdocs.
Comment: Thanks, I read it too quickly. Will try to revise when I get a chance.


unite illustrator << need to get way i dont want lose colors

Question: i need help i want to get way to do unite and compound path without losing colors becoz i want uploaded into Circut design SVG FILE . i want to get the logo same as shown in first pic with unite and compound path

Comment: Hi. Welcome to GDSE. Uniting all these elements will result in one solid circle. I'm not sure what you are expecting to happen, but that is what it's supposed to do.
Answer: You do not want to use Unite. Unite means "make everything one object of the same color".
Try using Merge on the Pathfinder Panel. This will combine areas of similar color but not those of different colors.
Possibly helpful: In Pathfinder window, what is the difference between a shape mode and a pathfinder?