My material nodes aren't applying to the whole object

Question: I can't seem to figure out why the sides of my object aren't being wrapped by my material. Here's a photo of my node setup, and the finished result. Does anyone have any ideas? Thanks.
Comment: This could be either due to the uv unwrapping, or you haven't assigned the material to the whole mesh.  (to assign, just select the material, enter edit mode, select the vertices you want to assign to, and press the **assign** button under the material)
Comment: @Millard that doesn't seem to do anything :/
Comment: Have you uv unwrapped the object?
Answer: Some things in your Node setup don't appear to be doing much (eg the bottom half Voronoi looks like it's cancelled out by the white ColorRamp and then just adds white to the top part?). But - never mind that, the problem is that you're using Generated Coordinates. As a result, the Mapping nodes are probably not doing what you expect.
Generated Coordinates treat one corner of the object's bounding box as (0,0,0) and the diagonally opposite corner as (1,1,1). You can see the effect of this if you momentarily set the Mapping Node to 'Normal' - you should see the Voronoi spanning out from one corner in a radial burst pattern.
To fix it how you want, you just need to UV unwrap the object, and use UV coordinates for the shader input instead. There are other fancier methods, such as blended box mapping, but the quickest/easiest way to get to the result you want is to go into edit mode on your object, select all faces, then hit U > Smart UV Project.
This should do a decent job keeping all faces scaled and aligned properly.
After doing this, change that Texture Coordinate node to feed 'UV' output into the Mapping node instead.
This will mess up the scaling values you have already set, but setting those back to 1,1,1 should give you a correct baseline from which to set proper texture stretching and expand the Y direction as desired.
If the Smart Project doesn't perfectly fix all the mapping areas, you may need to do some further reading on UV mapping/editing and fix some areas manually.
Comment: I tried the method you suggested, but for some reason, the "sides" are still appearing separate. Any other ideas? Was I supposed to adjust the Smart UV project settings? Angle limit: 66, Island Margin 0, Area Weight 0. Correct Aspect was checked, Stretch to UV Bounds was checked.
Comment: Yes those are the same settings I used in the test file shown in the screenshots uploaded. I'm not sure what else to suggest... can you upload the blend file and share a link on here? https://blend-exchange.giantcowfilms.com


cannot do playback in iMacro: element not found

Question: Excuse me, I have tried to use iMacro in FireFox to do playback.
However, it seems that during the playback, it try to click a button before the page finish loading such that the playback stop and iMacro complains that the element (i.e. the button )cannot be found.
I have encountered similar problem in Selenium and have used "clickAndWait" command to solve such kind of problem in Selenium.
May I ask in iMacro, does it also have command such as the "clickAndWait" in selenium for us to prevent the problem?
Or should we use any other method to deal with it in iMacro?
THank you very much
Answer: You can use
<code>WAIT SECONDS=x
</code>


Switch: port and NIC relation

Question: I wonder if a switch has one NIC per port? for example, does a switch with 24 ports has 24 NIC?
Many thanks in advance for your help.
Comment: Sometimes, but other times there may be something like one ASIC for every three interfaces. It depends on the switch model.
Answer: A "NIC" (Network Interface Card) is an old term created back when there was an actual circuit board that you plugged into your PC motherboard. Today, all that circuitry is built into the PC/Laptop, but we still use the term to generally describe the circuitry for the network interface (usually some form of Ethernet).  For a switch, I'll use the term "interface components."
Depending on the model, the switch can have individual interface components per port, or several ports can share components.
When the components are shared, we say the ports are oversubscribed -- meaning the shared ports (typically 3 or 4) share the available bandwidth. this is done to reduce the number of components and therefore the cost of the switch.
High end switches, used in data centers for example, have individual components for every port. Consequently, every port can run at the maximum interface bandwidth.
Comment: I don't think it matters.  Call it what you like.
Comment: Is it alright to pretend NIC stands for Network Interface Controller? As device controller is a component on a motherboard, using the term "controller" sounds ok to a novice like me.
Answer: A switch is usually built with port modules[*1] (depending on generation and class for each four, eight, twelve, ... ports) and one or more switching ASICs connected into a fabric.
The ASICs' interconnects may actually be running (hopefully higher-speed) Ethernet - just cascaded switching chips in a box - or use something completely different altogether.
Something like this:

https://www.recabuk.com/backplanes/compactpci/ethernet-wlan/aitech-c660-6u-compactpci-24-port-gigabit-4-10gbe-ethernet-switch/
Although a switch port's functionality can be very similar to a NIC (for L3 switches with routed ports), there isn't really anything you would recognize as such.
[*1] Note that port module doesn't necessarily refer to anything field-replaceable or upgradable. I'm referring to port and fabric ASICs in a modular chipset plus the necessary PHY components including magnetics and jacks for twisted pair, SFP cages, all more or less integrated.
Answer: NIC? No. That would be something like a 1970's era bridge. A NIC is a totally independent processing unit -- memory, interrupts, etc. You can build such a switch yourself with a stack of network cards and any OS that supports software bridging, but it will be slow.
Today (and for the last several decades) a switch is a highly integrated system-on-chip. (SoC) Each port is made up of one or more lanes. In most cases, each lane runs to a PHY that creates the common ethernet electrical (or optical) interface. (i.e. the RJ45 everyone associates with ethernet.) However, direct chassis interconnects (chip-to-chip) can skip the PHY. A switch with SFP interfaces can run "PHY-less" as most of the electrical signaling is done by the module. (passive DAC cables many not work)

Switch: port and NIC relation


unix email server with gui interface

Question: I am running unix CentOS 5 and looking for free mail server that has GUI web interface for managing accounts.
It be used with windows based clients on outlook express.
Answer: The Zimbra communication suite is apparently pretty popular - I've been investigating it for use at my company, and it pretty much meets all the standard Outlook/Exchange work-alike requirements.
Answer: Maybe have a look at Proxmox Mail Gateway: http://www.proxmox.com/products/proxmox-mail-gateway
They have a Free license which appears to restrict to one domain.
Lots of people, including myself, use their free Proxmox VE (Virtualization Environment) product which provides a similar looking GUI web interface. If the quality of that product is any indication, it is probably worth your while to check out the Mail Gateway.
Their datasheet includes a table that shows what the Free version does not include.
Cheers

unix email server with gui interface


Is "landlord" used for female as well?

Question: I hear that the term "landlord" is used mostly for male. But is it also used for female? If not, what is a better word for expressing female owner?
Answer: While you can certainly use the feminine form "landlady" if you want to be specific about their gender, this is an example of a word that's generally used regardless of the person's gender, that is to say, "landlord" no longer implies "male landowner". From Wikipedia:

A landlord is the owner of a house, apartment, condominium, land or real estate which is rented or leased to an individual or business, who is called a tenant (also a lessee or renter). When a juristic person is in this position, the term landlord is used. Other terms include lessor and owner. The term landlady may be used for women owners, and lessor applies to both genders.

From Vocabulary.com:

Men and women can both be landlords, although you can also call a female landlord a landlady. The concept of a landlord goes back to feudalism — the lord part comes from "Lord of the Manor."
Comment: I don't think there's a politeness element, @Blaszard  it depends. In general, English tends to be moving away from gendered terms towards either non-gendered versions (stewardess --> flight attendant) or towards using the same term for both genders (actor/actress --> actor or performer). Some of it is also a matter of personal preference.
Comment: @Blaszard You can avoid the issue entirely by using the term _"property owner"_ or _"landowner"_. In a legal document, _"lessor"_ will suffice.
Comment: Thanks. So then which is more polite or less rude for female?

Is "landlord" used for female as well?


How to sync 2 dedicated servers?

Question: I am launching my website next month and getting two dedicated servers. One the main server and the second is a backup incase the first goes down as I need 100% uptime. I will be using php/mysql and linux OS with apache webserver. Also adding a CDN for static content. So for the setup, what do i need? I read about load balancing, is this the same thing or is that seperate from keeping 2 servers? Are there any hosting providers that do all this setup for me including the backups, etc so all i have to do it worry about the website?
Comment: you might want to read the responses in [this question](http://serverfault.com/questions/130300/reaching-99-9999-uptime) about *only* 99.9999% uptime and weep. Please make sure you're sitting down when you do.
Comment: if you're asking this kind of question at this stage in development, you're going live on kit you've not even got yet, then you're out of your depth. Sorry but you need to call in a professional sysadmin or builder/integrator. They'll start with questioning the 'need' and drilling down whoever says 100% on cost-to-the-business etc. - I'm surprised that's not happened yet.
Answer: Load balancing is when you have two active web servers, both serving traffic from the production website, and either a software or a hardware "load balancer" in front of the web server (Apache). It "balances" out the traffic so that each get an equal share - when 1 server gets too busy, it will send traffic to the other one, and vice-versa.
This is NOT the same thing as having a backup server or a hot spare, as you're talking about doing.
My suggestion for keeping the server synchronized is to run "rsync" as a cron job every 24 hours or so for the files (or more often, like 1 hour, if you thing files will be changing a lot in a given day), and doing MySQL database replication over to the "backup" server using MySQL bin logs.
As for hosting providers, I've heard good things about Rackspace services bundled with their dedicated servers. You might want to contact them and see if they can provide this for you.
Comment: Ok 1 more thing: If i install SVN for source control, does that get installed on the same server as the live webapp/database or do i need a seperate server for this?
Comment: If you're using SVN, then I would suggest using your live server as the "host" and then making your backup server a client. You can even set the "client" to check out on a regular basis using cron, so forget about my rsync suggestion earlier. Before you proceed with all of this, however, I want to give a word of warning. You should really head what Chopper3 said earlier - if you are planning on going "live" by next month, you need some help. Asking these types of questions at this point in the game indicates to me you'll need it. I think you'd be happier that way.

How to sync 2 dedicated servers?


Calculating Android TextView's text capacity

Question: I have TextView with height and width as fill parent. Is it possible to find out how many characters can this layout hold?
Answer: Do you mean how many characters can be entered into the textview and still be fully visible without scrolling? For proportional fonts, that will depend on the specific characters typed, including where the line break opportunities are. I don't think there's a simple way to compute that.


how to find the device type whether is it a computer or mobile or router etc.,

Question: i have under gone a project in that i have to  know the device which use my lan ,this can have better use of my project ,instead my project is fully based on java code can any one help to find the device type in java code. i have ip address of all the system connected in my LAN with their mac address.
Answer: This is not a very easy and straight forward issues you are having. You'll have to come up with some basic idea based on the resources you have and the platform you wish to use, and then build around that idea. You can go through the links below. Basically, the links will take you to a "How to detect mobile devices" page and this can get you some basic idea about the method and procedures you'll have to take.
These links may help:
Detecting mobile devices in a network
Detecting mobile devices in a network
Comment: sorry , i have to find the wired connected systems. event though it is not establish any network
Comment: Then it is next to impossible to know the status of a device if is not connected or rather, associated with a network that you are able to monitor or a network which you are a part of.
Answer: 1. You can do it in client side from userAgent String.
String userAgent=request.getHeader("User-Agent");
//Check it matches to respective user agents or not.

Like:
if( /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) ) {
 // some code..
}

See this : What is the best way to detect a mobile device in jQuery?
2. Free API are available here : http://detectmobilebrowsers.com/
3. Here you can find different ways of doing it:
http://lotusmediacentre.com/find-http-request-source-computer-mobile-phones-or-tablets/
Comment: sorry , i have to find the wired connected systems. event though it is not establish any network


3x2 solder pad connector

Question: What would be the best way to connect to a 3x2 group of solder pads? I created my own 3x2 connector (pardon the poor soldering), but there must be a more off the shelf way? I haven't been able to find anything. Anybody have any ideas? Images below
Comment: Well ... The 1st answer is to learn to solder. Sorry. But that's just awful ... I've seen many right-angle SMD connectors soldered to commercial boards with a very similar layout and it works just fine.
Comment: You go to the website of one of the larger dealers and search for right angle smd headers.  There's more versionsvof what you are looking for than you can shake a stick at.
Answer: SMT Header
Search all the likely distributors.  They all have them.  The vertical versions are easier to solder by hand.
Answer: Or a right angle SMD header.

Also available in female header types.

3x2 solder pad connector


Can we use SOSL to search content libraries

Question: We are in the process of building a custom visual force page whose requirement is to search content libraries and files related to it based on a text entered on a search box. The requirement is to search 100,000 characters inside a file which is associated to a content library based on search text entered in a text box. Can we use SOSL queries to search files inside a content library? Can you guys share custom code or blogs related to custom search within a content library?
Thanks
Buyan
Answer: Here is little experiment that I did for this ,
Uploaded a word document(14 pages long) in the Content Object .

The next thing I did was to pick a very random word thats there in the document .
Ran the below SOSL to see if the query searches inside the file
<code>FIND {ITW*} IN ALL FIELDS RETURNING ContentVersion(Title)
</code>
Observe the results below

Looked into docs to find limitations and here is what I gathered

The search engine looks for matches to the search term across a maximum of 2,000 records (this limit starts with API version 28.0).
The search term cannot be greater than 10000 characters
Searching document content supports multiple file types and has file size limits. The contents of documents that exceed the maximum sizes are not searched; however, the document fields are still searched. Only the first 1,000,000 characters of text are searched. Text beyond this limit is not included in the search.


What should I do If I want to maintain session between HTTP and HTTPS - Asp.Net

Question: What should I do If I want to maintain session between HTTP and HTTPS.. In my site's public area some pages are HTTP and some are HTTPS but I want to keep common session for both..
Comment: IF that's what you do, wouldn't that mean you're actually voiding any validity your https has?
Answer: Once your user's have authenticated they will continue to have the same session cookie until it expires whether they are accessing pages with HTTP or HTTPS.  Make sure that you are using encryption on your session cookie to make it more difficult to crack if you are passing it over an insecure protocol.  You might want to look at the wikipedia article on session hijacking for more information.
Answer: There are a number of session state modes in ASP.NET you can use (which can be configured in web.config) apart from the default "In Proc":
StateServer mode, which stores session state in a separate process called the ASP.NET state service. This ensures that session state is preserved if the Web application is restarted and also makes session state available to multiple Web servers in a Web farm.
SQLServer mode stores session state in a SQL Server database. This ensures that session state is preserved if the Web application is restarted and also makes session state available to multiple Web servers in a Web farm.
Custom mode, which enables you to specify a custom storage provider.
See ASP.NET Session-State Modes on MSDN. I haven't tested this for HTTPS, but hopefully StateServer or SQLServer should facilitate this.
Answer: One session is maintained per application per user. So if you have one application which has some pages served over https and some over http, you do not have to worry about a new session being created when moving from https to http and vice-versa.


How to Remove Specialized OSBB Aluminum Inner Shell

Question: I have a 2014 Specialized Tarmac that uses press-in aluminum inner shell cups to hold the bottom bracket BB30 bearings.  These cups are affixed to the carbon frame with 2 part epoxy.  (see page 2 of this tech guide:  https://media.specialized.com/support/0000003319/0000003319_IG0338_revC.pdf).  I would like to replace the cups.  How can they be removed without damaging the carbon fiber frame?  (for a picture of the shells, go to page 3 of this link, and view the 2014 alum. inner shell to the 2014 SBC Road Frame:  https://praxiscycles.com/wp-content/uploads/PRAXIS-FRAME-GUIDE.pdf)
Comment: From the bottom of page 2: "To remove the cups from the frame, pull the bearings out as shown on page 5, then lightly tap the backside of the cups in a circular pattern with a large flat surface. Do not use a screwdriver, as it may damage the cups."

You may want to let your shop do this, given the other tools required unless you have them for some reason.
Comment: Batman, where did you find the quoted language?
Comment: Its footnote 9 on page 2 of the specialized tech guide.
Answer: I have a carbon framed bike with a press fit BB. Recently the non-drive side bearing disintegrated, and having the Park tool to remove/install the cups I thought I'd be good to go.
The drive side cups popped out no problem, but the non-drive one had frozen solid in the way that aluminium seatposts can in carbon frames. Despite hammering it like all bezoomny, to the point where bits of metal were breaking off the inside of the shell where the tool rests against, it would not budge.
In the end I got a dremel and very very carefully cut through the remaining bearing shell and then the BB cup, and it still took some pretty good whacks with a hammer against a wooden drift for it to finally give up.
So, get the right tool, or take it to an LBS/mechanic who does. Its surprising how easy the cups can pop out when done properly. Failing that, and as a total last resort, you can cut them out with a steady hand.


Can I replace a fan timer with one having duration options beyond one hour?

Question: We have a dial that only goes up to an hour to control our fan so we are continuously getting up and turning it for another hour. Can this be replaced with a longer timer dial, like 12 hours?
Comment: Seems like you'd want to tell us something about what the current timer is and where it's installed. Of course other timers exist. The answer to your question requires more information, however.
Comment: If the timer is specific to the particular model of fan than there may be other issues. But if it is a generic "instead of a toggle switch" timer then replacing it should be fine. Model # of fan would be helpful, plus if you can (safely) open up the junction box holding the timer and post a picture of the wires in the box (both going out of the box and going into the timer) that would be very helpful.
Comment: you can install a switch and then it can run as long as you like
Answer: If this is a standard fan (i.e. no smart switch), Intermatic does make a 12-hour mechanical timer (no neutral required). If you want a programmable switch, you'll need a neutral wire in your switch box.
Answer: Yes.  If you mean a standard spring-wound timer that doesn't require a neutral wire, those are made in a variety of ranges.  15 minutes, 30 minutes, 1 hour, 2 hours, 4 hours, 8 hours, 12 hours, or values in that general area.  With, or without, an "always hold on" function.
Just buy a different one, they are under $20.


How to teach programming to underprivilege kids who are not having access to laptop?

Question: Many developing countries are having a large population that does not have access to computers/laptops. In such cases, what are the innovative ideas to teach and select students who like to study computer science and programming further?
Comment: What equipment is typically available to them? And when?
Comment: Are these kids normally in urban or rural environments?
Comment: @GuyCoder I have Raspberry PI but did not know about its history. My target audience is a low-income family which does not yet have the resources to buy a laptop/computer. Even making them purchase a $50 items which additionally would need a monitor, mouse keyboard to work upon. For a medium-income group, especially for Tinkering, I am sure Respberry PI is a great idea. Thanks for your input

Based on this discussion, 1. I am seeing that some paper-pen puzzles that can set the foundation for computer programming 2. A mobile app might lead us to some solution.
Comment: Is the goal for them to be able to write software professionally or to teach the fundamentals of computer science? Teaching how a Turing machine works would be possible with very minimal resources. https://teachinglondoncomputing.org/turingmachine/
Comment: I'm not going to make this an "answer" because I am not actually an educator, but I would search for ways in which students can _share_ work stations. When I was learning the basics, back in the 1970s, I did a lot of design and debugging on paper, and then I waited my turn to sit down in front of a keyboard for ten or fifteen minutes to type my program in, and give it a try.
Comment: Also, consider having students work in pairs—have them "walk-through" each other's paper programs before taking them to the work station. But, IMO, you can't do it without _some_ computer hardware. Computer programming is an art form. You can't become skilled at it just by reading. You need to practice it. And finally, don't forget the printer: If each student can't have their own screen, then they're going to want a print-out to take back to their desk after they get their turn to try their luck at the keyboard.
Comment: Thanks, @SolomonSlow, I understand that sharing resources could be one way. But that may be the next stage. I agree that the computer is like learning to cycle which can't be done without a bicycle. Though looking for some ways to reach out to kids who don't have access to computers also.
Comment: @Buffy, Kids do not have access to computers. They can be urban and rural. I am currently looking for solutions for rural. Currently, they don't have access to laptops/computers. But they may have access to "Smartphones" of their parents.
Answer: I am not experienced in this area so these may be naive ideas so take this with a grain of salt:

Study the limits of computers: "What can computers do? what can't they do?" We need citizens to understand the difference between what Hollywood movies say computers can do and what they actually can do (myths vs. reality).

Teach algorithmic thinking: When I was little I helped my mother with the laundry.  I learned to match socks using various algorithms: linear search, grouping by size then searching within groups, etc.  I feel this experience helped me greatly when I was old enough to have access to a computer and needed to be able to describe tasks algorithmically.

Teach that computers are literal: "do what I say, not what I want".  An exercise like "the exact instructions challenge" can help younger students : https://www.youtube.com/watch?v=Ct-lOOUqmyY

Share the computers they do have: When I learned to code my school could only afford 1 computer for every 3 students in the class. The teacher created instructions based around this. We had to take turns, time how long we were using the computer, etc.

Do it on the phone: Maybe there are programming assignments that can be done on their phones?  They might not have laptops but they might have Android or iPhones.
Answer: I have two suggestions. The first is open to everyone, but the second depends on some local conditions and doesn't scale.
First learn about Computational Thinking and especially CS Unplugged. Quite a lot of educators have been thinking about this for a while, though mostly about teaching young students some principles with the expectation that they might be involved with programming at a later time.
Second, though it requires a lot of work. I was once involved in social service projects (student days) in poor areas in Mexico. The group I was involved with had some success in exploiting local resources on behalf of poor people in the local area. Quite frankly we put a guilt trip on some of the rich folks around about doing more to advance conditions in their own community. We didn't do it quite like that sounds, but by giving example as well as talking to people with resources about the work we were doing they just, sort of naturally, decided to help. Our own "sacrifice" of working with the poor helped those who could help see that they, too, could do something.
Perhaps someone local would donate some equipment when they upgrade. Perhaps local business would be willing to assist your students.
Note, however, that this doesn't always work. One project I was part of was much less successful than another in this, but it was mostly due to local demographic features. Some places just don't have any resources beyond sweat.
Along with local wealthy individuals, we also explored what governmental resources were available and taught the local poorer people how to effectively exploit them. Quite a lot was available if you only knew how to find it. So, we acted as a resource for finding resources.

On Dec. 8, 2021, the New York Times published an article on how some people in the tech industry are starting to address this: https://www.nytimes.com/2021/12/08/us/politics/safety-net-apps-tech.html (may be paywalled)
Answer: Here is a possible solution.  The school can put up a Linux server, which supports a multiuser environment. In fact, it's the best environment in which to learn to program.  Ubuntu Server is free software.  A wireless network in a lab equipped with Chromebooks could be set. up for a relatively small expense.  A package manager can be used to obtain all of the compilers you need.
Then students could shell in with an inexpensive Chromebook.  The server would hold their work and accounts are protected via login authentication.  While it's not ideal, it cuts the cost a lot.
Comment: If they could have computers as powerful as a chromebook, then there would be no need for the Linux server.
Comment: Chromebooks are inexpensive but the cheap ones have limited memory.


Mixture of water, methanol and dichloromethane

Question: If I have a mixture of 25 vol% methanol in water and I mix it with an equal volume of dichloromethane (which is miscible with methanol but not water) can I roughly say that both phases (i.e. water and dichloromethane) will have the same methanol concentration upon reaching equilibrium? Or will it vary significantly based on the activity of each mixture?
Comment: When you have two phases they is always some of each component in both phases.  // (solubility of dichloromethane in pure water is 17.5 g/L @ 25 °C) // I'd expect the dichloromethane to contain both water and methanol, and the methanol/water phase will contain a small amount of dichloromethane. In certain proportions I'd expect one phase.
Comment: I doubt it. I would expect the MeOH to go into the water phase
Comment: What is needed is the ternary phase diagram for the methanol/water/dichloromethane system. // I looked and couldn't find one. But there must have been studies on this.
Answer: This is a partial phase diagram. That seems to indicate that systems with roughly 50% methanol are miscible.
Source: http://shodhganga.inflibnet.ac.in/bitstream/10603/9995/11/11_chapter%206.pdf


Which are the most energetic events in the Universe?

Question: That's the question. I know about gamma ray bursts, is there anything more energetic?
Comment: This question makes no sense unless "events" are somehow localized in space and time. Otherwise the obvious winners are global events like stellar evolution and cosmic speed-up.
Comment: @DmitryGrigoryev Are global events so energetic, tho'?
Comment: @WillihamTotland Since dark energy (responsible for the speed-up) constitutes 68% of the universe, I'd say cosmic speed-up is the most energetic by definition.
Comment: @DmitryGrigoryev There's a lot of gravity involved, tho', and also a _lot_ of space. It might have the most _total_ energy, but per unit volume?
Comment: @WillihamTotland This is exactly the issue my first comment states. The question has little meaning unless constraints on time and space are defined.
Comment: @DmitryGrigoryev While I agree that the question could be refined, I feel as if an even moderately charitable reading of the question as stated can give an answer (probably 'Hypernovae', but I digress). Global events are processes that are so slow and so large scale that a novice could hardly be blamed for failing to take them into account.
Answer: Wikipedia has a page on this:
https://en.wikipedia.org/wiki/Orders_of_magnitude_(energy)
I would have guessed the recently observed merging of 2 black holes, which, while just hard to detect gravity waves, in terms of energy it was about the equivalent of the entire rest mass of our sun.  Two large (but not super-massive) black holes each about 30 solar masses, merged and released about 3 solar masses in energy in gravity waves.   That's a huge amount of energy.
I'd have guessed wrong though, as an observed gamma ray burst was bigger.  (see link above for precise estimates).
In theory, since I assume you're talking about localized events, when 2 galaxies merge and their super-massive black holes collide, that's probably, hands down, the most energetic local event, far surpassing the largest gamma-ray bursts.  Gravity waves might not be what people think of as energetic, but they can be enormously so.    If you're talking more typical "bright flash", photons and accelerated particles, then the winner would be the largest gamma ray bursts.    Hypernova's are up there, but not as large as the largest Gamma-ray Bursts.
Now if you want to get flexible on what "local" means.  The gravitational energy of two large galaxies falling towards each other might get you a larger number, but I'm a little fuzzy on whether that qualifies as a local event", which I've built this answer on.
Answer: It depends on the gamma ray burst, but it is possible for some quasars and some high end super/hypernovae to produce an equal or greater amount of energy (this is from the perspective of those that involve single stars or stellar remnants-we are leaving galaxies, galaxy clusters, etc. out of it)


Passing Variables to a CFM form in PHP

Question: I am working with a partner site to embed a form onto my site where users can login to a portal. The portal developer has granted me access to a web-login service in order for me to pass variables from my site to his.
This is the information given How can I make this work in PHP, I have a form with a checkbox, and username and password but don't quite know how to make it pass variables I am not seeing any connection on my end. And I don't know how to set it up where they are redirected to a page on my site when the reset their password any ideas?
I have done this before using a WordPress login and adding it to my main site so I know most of the basics to make it work but what I have applied so far has not worked for me. I guess I need a little nudge in the right direction to get the brain working again.
Thanks in advance.
From the Developer
<code>I am working on a web login service that you could use and have enough done that I can
send you the requirements.

Form Post URL: http://portal.blank.com/services/formlogin.cfm
Form variables:
portallogin - can be any value if present the following form variables are required:

errorurl - URL to be redirected to if an error occured. There will be an "error" url variable present with a human readable error string.
portalurl - (optional) URL to be redirected to if successfully logged in. if not present will be redirected to http://portal.blank.com
username - username of user
password - password of user
agreeterms - can be any value just needs to be present to authenticate

fogotpassword - can be any value if present will lookup password based on email address and password will be emailed
email - email address associated with user
returnurl - URL to be redirected to after running password lookup
</code>
Answer: An easy method would be to use Snoopy, a PHP class.  A harder method (but no less effective) would be to use PHP's cURL functions to post your data to the form.  This is assuming you're trying to keep your link to your partner's site hidden from your users.
Alternatively, you could just make a simple HTML form and set the form action to "http://portal.blank.com/services/formlogin.cfm" if you don't care that your users know you're authenticating them against some other site.  I'd use https if available.

Passing Variables to a CFM form in PHP


I was asked to leave a store for no reason,then employee snatched item out my hand that belonged to me, I was the ordered out of the store,legal?

Question: I went to the store to return a item but I didn't have the correct receipt,so continued into the store to purchase other items.The Mgr came up to me and told me to leave the store, I asked him why?He told me he didn't need a reason.as I'm exiting the store store I explained to him that the item in my hand was my property (the item I came to return).He said it was not .I told him to check the camera, or ask the lady at customer service,which he refuses, then another employee physically snatched my property out of my hand.the Mgr. then said that he would physically remove me out of the store,if I didn't leave, I then exited the store.what are my legal options if any ?
Answer: You do have the option to let it go, but presumably you want the item returned. You claim it is your property, they claim it is theirs, you have a simple ownership dispute that could be resolved in small claims court. What you do there is basically explain the circumstances and bring the receipt as evidence that it is you property. You may have a cause of action regarding the forceful grabbing of the item and the threat of force (the legal alternative would be for them to detail you until the police arrive), so hire a lawyer to deal with this situation.


How to get the content type in the zone/region tpl files?

Question: How would I get the node type from within a zone/region or section (using omega theme) template file.  I know how to override templates at the page/node level for specific content types - but I can't seem to find a variable or anything that points to what type of single, node page content type is currently being displayed.
Comment: Can you outline what you are trying to accomplish with this?  The node templates should carry enough classes on the outer div to do just about anything you want one you get into your region/zone/page templates.
Answer: If you are visiting some node then arg(1) call would return node id.
$nid = arg(1);
$node = node_load($nid);
$node->type

Answer: In your subtheme preprocess template, create a zone or region preprocess file. Let's do an example for region, where you would create the file (example for Omega 3 theme):
{your subtheme directory}/preprocess/preprocess-region.inc
In that file, create your preprocess function that gets the node and adds type to $vars.
<?php
function {theme_name}_alpha_preprocess_region(&$vars) {
  // get the node
  $menu_object = menu_get_object();
  if (isset($menu_object->type)) {
    $vars['node_type'] = $menu_object->type;
  }
}
?>

{theme_name} would be the name of your subtheme. At this point, you can access the variable node_type in your region--content.tpl.php file.


Truck won't crank; no sound from starter relays

Question: I have a 1997 Expedition, which badly needed a tune up: the motor was shaking. I changed the  plugs, which stopped the shaking; two days later the truck won't start. The battery is hot and the lights work, but it won't even make the clicking sounds. Where do I go from here?
Comment: A hot battery?  'Hot' as in 'higher temperature than ambient environment' or 'has power'?  No clicking while having power would point to starter solenoid (solenoid itself or just bad wires going to it).
Comment: Have you TRIED a different battery or a jump start? Car batteries have a number of (seemingly) peculiar failure modes and I've had batteries putting out 12v that won't turn a car - the starter motor requires a huge amount of current (Several hundred amps, normally) compared to comparatively tiny amounts for everything else (Measured in single digits for lights)
Answer: As Dan says in the comments, have you tried a different battery? If you have power to the lights, you should have power to the starter, but a poor battery may not give enough power to fire the solenoid.
The other possibility is that the shaking you have mentioned has caused one of the leads going to the starter to fail. There should be two cables attached to the starter, a big one from the battery and a small one from the ignition switch. The latter is often quite thin and so could possibly fatigue and snap at the connector. You can test this by disconnecting it at the starter end and using a multimeter to see if it gets 12v when an assistant turns the switch to 'start' (or by the not-recommended method of shorting the connections on the starter together so it gets power from the main battery feed.)


What's the difference between "to confirm" and "to verify"?

Question: What's the difference between "to confirm" and "to verify"?
Comment: We have confirmed that he made an unverified statement.
Answer: I don't think that these words can be used interchangeably.  These words are similar, but are usually used in different ways.  To verify something usually means being able to provide convincing evidence that it is true.  When something is to be verified, there is usually some doubt as to whether it is actually true.  To confirm something usually means providing some additional evidence that it is true.  When something is to be confirmed, it is usually already believed to be true.
Comment: To add to that, I think that confirmation can only come from an authoritative source on the subject, whereas verification can come from anyone. Or am I mistaken?
Answer: Confirm means that the truth is there and you double check. Verify means that you doubt something is 100% true, so you double check.
Answer: Verification requires external evidence.
Confirmation requires a re-issuance of a believed statement.
Sometimes, one may trust a third party to obtain and review the evidence required for a verification, which could lead to both word choices being valid.
Comment: Actually what You are saying here was also my guess. But I am a little bit confused about this sentence: "Confirmation requires a re-issuance of a believed statement" - Isn't it like the re-issuance of a believed statement should also proceed from a third party (in other words, also be external)? Otherwise, it would be merely an act of repeating a statement by the same person (the one who issued it), but that would nullify the very essence of the word "confirmation" as repeating things doesn't amount to confirming them.
Answer: These are synonyms that can mostly be used interchangeably to mean "establish the truth of a thing." Nevertheless, confirm also has the additional meanings of to affirm and to ratify or authorize. Verify can also mean to test something's validity.
Comment: Let's say I am coroner and I have one suspect who claims he has an alibi - he was at the "Orange Juice" cafe while the murder was being carried out. So, would it be correct to say in this situation that I need to VERIFY this alibi by going to the "Orange Juice" and finding a waiter or any other staff in that cafe who could CONFIRM that the suspect indeed was in there at the time of the murder?
Comment: It would be correct to say either. I would say in this instance that *verify* may suggest, very slightly, that the speaker doubts or mistrusts the contention, and that *confirm* may carry a slight overtone suggesting that the speaker may think it likely the contention will be borne out. But either would be equally valid to use in this instance.
Answer: Pretty much same.  It is matter of personal history of how the word has been received. Confirm sounds more official to me.


can not get the oil plug out

Question: I was going to change my oil on a 2000 Chrysler Town and Country van. When I loosen the plug it just keep turning and turning, and I can not get it out. So is it stripped out and if it is, how do I remove it?
Answer: If you can tighten it, there are some threads there which are gripping, so this would probably be a case of the threads on the plug being stripped. If it doesn't tighten back up,  this would probably be a case of either the threads on the pan or on the plug being stripped. I don't have any real good news for you here in either case, but could possibly help you to get the plug out in either.
What you'll need is the wrench or socket/ratchet you were using to loosen the plug, plus a fairly broad flat tip screwdriver. Loosen the plug so you have a gap between the pan and the plug head. Place the flat of the screwdriver between the pan and the plug head. While continuing to unscrew the bolt with the wrench or socket, turn the screwdriver with a bit of force, whatever is needed to keep the bolt coming out. Once the bolt starts biting again and continues to come out, you can stop applying force with the screwdriver. If it appears to be stalled again at any point, put the screwdriver back in there an apply some more pressure. This should allow you to get it out and assess the damage.
With all of this said, you are going to have a major problem if the issue lies in the pan ... I mean if you don't have the means with which to fix the issue. If you do not have the means, take it to a shop and have them fix it. The actual fix depends on how much damage actually has occurred. Also, if you have an aluminum oil pan, this adds a whole new dimension to the mix (I'm pretty sure the T&C has a steel pan, but not sure). In most cases, you will have damage on both the bolt and the pan. Replacing the bolt is easy ... fixing the threads in the pan may not be. Just be aware it is going to cost a few dollars to get it fixed, depending on the damage.

can not get the oil plug out


I can't select my camera and i can't find it in Scene Collection

Question: it looks like my camera is missed but I still could use it by num 0 or ctrl+alt+num0.i just can't select it or select it under Scene Collection.
Comment: @MikoCG _Pose Mode_ does not hide cameras in the _Outliner_, if filtering for "camera" does not show anything this means either there is no camera object in the scene or if there is, both the object and the inherent object data have been renamed so that they are filtered out. If there is no camera object but a camera view, he has made a different object the active camera.
Comment: Maybe you have no more camera object in your scene and you've made another camera? Check what object is selected as camera in the Scene panel > Scene > Camera
Comment: You cannot select camera because you are in Pose Mode
Comment: Open the filter menu (icon funnel) in the outliner and enable `Cameras` and/or `Objects:all` ?
Comment: Same as my case. Camera not shown in Scene Collection but numpad 0 still work. Any solution? Thanks
Answer: If there still is a camera object in your scene and filtering in the Outliner for "camera" does not show anything, then maybe you have changed both the name in the Object Properties and the Object Data Properties:

But maybe you accidentally deleted the camera object. The reason you can still switch to camera view with Numpad 0 or align the camera to the current viewport with Ctrl+Alt+Numpad 0 is most likely that you accidentally made a different object the active camera. This works by having any object selected and pressing Ctrl+Numpad 0 (this might have happened when you tried to align the view).
Now first of all go into Object Mode. To find out which object is the active camera, you can choose Select > Select Active Camera from the viewport menu. Now that the camera is selected, you can see the name of the object in the top left corner of the viewport - the name of the active object is always shown there when Overlays are enabled:

If you still have no idea where the object is in the Viewport or in the Outliner, you can hit Numpad . in either of them to Frame Selected, which means the viewport gets centered and zoomed in on the selected object or in the Outliner, the hierarchy gets expanded to reveal where the selected object is located and jumps to the entry if the list is long.


Finding possible values for dimension of image and kernel

Question: Say I have a 3x5 matrix that represents a linear transformation from $R^5$ to $R^3$. I want to find possible values of the dimension of the kernel, and the possible values for dimension of the image. I know that the maximum possible rank is 5, and I know the rank-nullity theorem, but I'm not sure how exactly to apply it here. Thanks!
Answer: Actually, you're wrong when you say that the maximum possible rank is $5$. Since the rank is the dimension of the image and since the image is a subspace of $\mathbb{R}^3$, the maximum possible rank is $3$. And, by the rank-nullity theorem, and since the dimension of the domain is $5$, the dimension of the kernel is $5$ minus the rank. So, in principle, there are $4$ possibilities:

rank $3$ and dimension of the kernel $2$;
rank $2$ and dimension of the kernel $3$;
rank $1$ and dimension of the kernel $4$;
rank $0$ and dimension of the kernel $5$.

Now, find an example for each case (Hint: for the last case, there is just one possible example.)


edit to answer looks like spam

Question: I see an edit on my answer.
The anonymous user has added many urls to my answer and deleted most of my post.
Should I reject this edit?
Question in gis stack exchange
Comment: The record shows that two users rejected this attempted edit about an hour after you posted this question: the community is doing its job!
Answer: If it feels like vandalism then reject it. I cannot see any suggested edits though - so you probably already did reject it.
Comment: hmm strange. I didn't know how an anonimous user could have edited  first. Now there is no sign of an edit! I did "skip" it but thought that would just leave it for investigation.

edit to answer looks like spam


Starting Android emulator failed: QXcbConnection: Could not connect to display

Question: I would like to do some debugging(Android native program without GUI) on a remote server which doesn't have display.
The command is:
./emulator -writable-system -avd Pixel_XL_API_25 -no-snapshot-load -qemu -no-skin -no-audio -no-window  -v

Error msg:
emulator: WARNING: System image is writable
QXcbConnection: Could not connect to display
Aborted

I have the -no-window option why it still tried to connect to display?
I searched through Internet. It looks like it's a QT bug. Any idea to walk around it?
I tried to set the DISPLAY env var by export DISPLAY=:0. It doesn't work out.
Comment: were you able to find a solution ? having the same problem
Answer: export DISPLAY=:0

Works for me on Ubuntu 18.04
Removing android studio and reinstall from Ubuntu Software Store also resolved for me.


How can a charged hollow sphere induce charge on a neutral conducting sphere kept inside it?

Question: In case of a charged conducting hollow sphere charge resides on the surface and the field is radially outwards or inwards depending on the charge.Due to the symmetric consideration field inside the hollow sphere is zero.Now if I placed a neutral sphere inside the hollow sphere how does the neutral sphere accqiures induced charges with out the presence of electric fied.This is the situation given in my textbook about a spherical capacitor with outer shell charged and inner shell earthed.Its given that outer shell induces charge on inner shell.How is this possible?
Answer: Electric field does not give you the entire picture. You also have to consider electric potential.
You are correct in observing that electric field inside the hollow sphere is zero throughout. However the electric potential is constant. And its value is given by - $$V = \frac{kQ}{R}$$ where V is the potential, R is the radius of the charged sphere and k is the constant from Coulomb's equation.
If the inner sphere is not grounded, there would be no charge induced on the inner sphere. Note that in this case, the potential is given by the formula shown above.
But as soon as you ground the inner sphere, you are ensuring that its potential is always zero(The Earth is always taken as zero potential and therefore when you ground or earth something, you are setting its potential to be zero).
If there are no charges induced on the smaller sphere, the potential would not be zero but would be V as described above.
With this information you can calculate the charge on the inner sphere. If the radius of the inner sphere is r and the charge on the inner sphere is q then - $$\frac{kQ}{R} - \frac{kq}{r} = 0$$ which gives $$q = -\frac{rQ}{R}$$.
Where is this charge coming from? From the Earth! The Earth is considered a source of infinite charge at zero potential for all practical purposes.


starting openvpn server fails with Options error: --client-config-dir fails

Question: I'm working on setting up an openvpn server. I'm using the standard sources of debian jessie and easy-rsa as an CA.
Everything worked fine until I've tried to start openvpn via init script. When I'm running /etc/init.d/openvpn start
following error comes up in /var/log/daemon.log
Options error: --client-config-dir fails with "/etc/openvpn/easy-rsa/keys/crl.jail//etc/openvpn/server.ccd": No such file or directory

Has someone of you a idea where this mess with the paths comes from?
The directory what is set in the config file exists.
The server.conf file:
port 1194
proto udp
dev tun

comp-lzo
keepalive 10 120

persist-key
persist-tun
user nobody
group nogroup

chroot /etc/openvpn/easy-rsa/keys/crl.jail
crl-verify crl.pem

ca /etc/openvpn/easy-rsa/keys/ca.crt
dh /etc/openvpn/easy-rsa/keys/dh2048.pem
tls-auth /etc/openvpn/easy-rsa/keys/ta.key 0
key /etc/openvpn/easy-rsa/keys/server.key
cert /etc/openvpn/easy-rsa/keys/server.crt

ifconfig-pool-persist /var/lib/openvpn/server.ipp
client-config-dir /etc/openvpn/server.ccd
status /var/log/openvpn/server.log
verb 4

# virtual subnet unique for openvpn to draw client addresses from
# the server will be configured with x.x.x.1
# important: must not be used on your network
server 10.254.1.0 255.255.255.0

# push routes to clients to allow them to reach private subnets
push "route 10.0.0.0 255.0.0.0"

THX for your help.
Comment: Copy the script `cp -r /usr/share/easy-rsa/ /etc/openvpn` then restart the service `/etc/init.d/openvpn restart`
Comment: The easy-rsa folder is at place. I've allready used easy-rsa to generate certificates.
Answer: I found the bug. The server.ccd has to be in the crl.jail directory. I've changed the config like this:
...
chroot /etc/openvpn/easy-rsa/keys/crl.jail
crl-verify crl.pem

ca /etc/openvpn/easy-rsa/keys/ca.crt
dh /etc/openvpn/easy-rsa/keys/dh2048.pem
tls-auth /etc/openvpn/easy-rsa/keys/ta.key 0
key /etc/openvpn/easy-rsa/keys/server.key
cert /etc/openvpn/easy-rsa/keys/server.crt

ifconfig-pool-persist /var/lib/openvpn/server.ipp
client-config-dir server.ccd

...


What is this Tom Pam Britanny in this context?

Question: What is this in Google slides page? I tried checking the meaning of Tom, Pam, etc using Google but the meanings could not be understood, is it idiomatic?
Answer: When using Google Docs, Sheets and Slides to edit documents, several people can edit at once. You can see the cursors of other users as a coloured cursor (or, in sheets, a coloured box around the selected cell) with that user's name attached to it - just as shown in the animation.
This is showing how the hypothetical Tom, Pam and Brittany can all edit at once. That is all. It's just names of people.


Is it typical to experience zoom creep with the Canon EF 24-105mm F/4 L IS USM?

Question: I noticed this more than once. Whenever I'm in the range from 24mm to somewhere between 35mm and 50mm, the lens starts moving if I'm fixing it vertically with its front element facing the ceiling or the floor, is this a problem with my own lens or it's a general problem with this lens?
Comment: You have to look into a company called Lens Band. They provide a silicone band that fits the barrel of the zoom lens. Here is a link: http://lensband.com
Comment: I also have this trouble with a recent lens (less than a year old)...
Comment: Common problem on this lens. I have two, purchased 2012 and 2009. The older one creeps, the newer one doesn't.
Comment: How to fix it: https://photo.stackexchange.com/questions/109398/how-to-fix-zoom-creep-in-canon-ef-24-105mm-f-4l-is-usm-lens
Answer: A quick search shows that you're not alone with this problem for that lens. (I don't have that lens myself, so I can't comment from experience). Since it is an L-series lens, you might want to just take it to Canon for them to service it.
Alternatively, if you want a DIY solution, the simplest fix might just be a thick rubber band or a piece of gaffer tape. Here's a collection of different DIY methods people have attempted for fixing the problem.
Answer: My 24-105 does not have creep.  I just tried mine in a vertical position looking up and down.  I wiggled it around to try to induce a bit of creep.  None.
Answer: I have two of these lenses and have never experienced this. I would expect them to be stable, as L series lenses are expected to perform well. They are not the same though. One works with all my autofocus systems and the other only works on my 1DsMIII. I only bring this up to point out that not every lens is the same.
Answer: In my case, yes. Very typical. My EF 24-105 f/4L IS USM developed zoom creep after about four or five years.  It's probably one of my most-used lenses.  I did attempt peeling back the rubber on the zoom ring and using the screws to adjust the tension, but the creep returned pretty quickly.  While a big flat rubber band, like the lensband, can be used to add enough friction to stop the ring from turning on its own when the zoom is "pulled" out by gravity, I found it enough of an irritation in use, that I just live with the creep.
Answer: Most not-top-of-the-line zoom lenses have this problem, as far as i know.
This is a guess, but i am assuming lenses which have no external moving parts might minimize this issue...but then again, this might have to do with the fact that these kinds of lenses are usually nearer to the top of the line.
To counteract it, fixing the lens on place with tape might be a quick and dirty solution (if the lens is retrofocal, which yours seems to be, and nothing moves externally while focusing).
Comment: oh well...you can always buy a prime lens and all these troubles will be gone! additionally, i think my cheap nikon 18-55 kit lens doesn't have zoom creep...it has too little glass to weigh it down :D
Comment: I thought that this lens is _luxurious_ since it belongs to the Canon's _Luxury _ series :(
Comment: A agree with JoseNunFerreira. I've never seen a low-end lens with zoom creep. Only heavy lenses do that and some of those even have a zoom lock button.
Comment: Does that button allow for stopping anywhere in the zoom range, or just on the shortest focal distance (for transport, etc)?


Testing whether an element of a tensor product of modules is zero

Question: Let $A$ be a commutative ring and let $F$, $E$ be $A$-modules.
Then $E$ is the direct limit of its finitely generated submodules.
Serge Lang, in his Algebra, p. 604, remarks that a technique to
test whether an element of $F \otimes E$ is zero, is to examine
its image in $F \otimes N$, as $N$ varies over the finitely generated
submodules of $E$. Could somebody please explain why this is a valid
technique? What is the image of an element of $F \otimes E$ in
$F \otimes N$?
Comment: Related (for a particular case): https://math.stackexchange.com/questions/542214
Answer: There is the following (quite unknown ...) criterion when an element of the tensor product $M \otimes_A N$ of two $A$-modules $M,N$ vanishes:

Choose generating sets $E$ of $M$ and $F$ of $N$. Every element of $M \otimes_A N$ can be written as $\sum_{e \in E} e \otimes n(e)$, where $n : E \to N$ is a function with finite support. It vanishes if and only if there is a map $\lambda : E \times F \to A$ with finite support such that
$$\forall e \in E ~: ~ n(e) = \sum_{f \in F} \lambda(e,f) \cdot f$$
$$\forall f \in F~ : ~ 0 = \sum_{e \in E} \lambda(e,f) \cdot e$$

You should think $\lambda$ as a finite matrix which gives a reason why $\sum_{e \in E} e \otimes n(e)$ vanishes, namely why it is optained from $0 \otimes 0$ by applying bilinear relations.
There is a nice proof for this using the general properties of the tensor product, appearing in Pierre Mazet, Caracterisation des epimorphismes par relations et generateurs. There it is also used to give a full characterization of epimorphisms in the category of commutative rings (which, however, is useless in practice; in my opinion only the corollary about the cardinality is interesting).
As for the question about Lang's comment: It is already explained very well, so I don't really know what I should add. Since $M$ is the directed colimit of its finitely generated submodules $M_i$, it follows that $M \otimes_A N$ is the directed colimit of the $M_i \otimes_A N$ (which are, however, not submodules in general!). This means that every element of $M \otimes_A N$ lies in the image of $M_i \otimes_A N \to M \otimes_A N$ for some $i$, and that two elements of $M_i \otimes_A N$ and $M_j \otimes_A N$ become equal in $M \otimes_A N$ iff they become equal in $M_k \otimes_A N$ for some $k \geq i,j$. In particular, an element of $M \otimes N$, which vanishes, already vanishes in some $M_i \otimes N$ for $i$ large enough. This is often used for establishing general results in homological algebra which reduce something concerning tensor products for the finitely generated case. For example, $M$ is flat if and only if $\mathrm{Tor}_{>0}(M,N)=0$ for all finitely generated $N$. And $M$ is flat as soon as every finitely generated submodule of $M$ is flat. For example, this implies that torsionfree $\mathbb{Z}$-modules are flat (try to prove this directly). But note that Lang does not give any criterion when an element in the tensor product precisely vanishes.
Comment: How is this not well-known? This is Lemma 6.4 in Eisenbud. Am I missing something?
Comment: Oh, thank you. Meanwhile I've also found it in Bourbaki's Algèbre. So let's just say that this criterion is not used very often. Ok?
Comment: @AlexYoucis You are right. However Eisenbud's proof is too messy: he only consider generators for the module $N$, and he uses additional, unnecessary subscripts.


How to put a copied command in a command block?

Question: If you have copied a zombie herobrine command what do you press on your computer to put the command in the command block?
Comment: if you have a awnser that worked then you can click the cheak mark on that awnswer
Answer: You can use Copy and Paste.
Highlight the text you want to copy and press Ctrl-C (Command-C on a Mac). To paste it, press Ctrl-V (or Command-V).
Answer: You basically click a command block and you copy a link and then click ctrl-v on your key board if you don't have ctrl key do command-v on Mac
Answer: 1.highlight the command
2.copy the command
3.open minecraft
4.open the world
5.do /give  username minecraft:command_block then press enter
6.place it down open the command block
7.do ctrl+v in the box
8.do /give username minecraft:redstone_block then press enter
9.place the redstoneblock next to the command block
10.then you are done
Answer: You press this possible combination at the GUI of the Command block :

Ctrl + V
Strg + V
Cmd  + V

Strg is for german keyboard.
Cmd is for Mac keyboard.


Visiting Netherlands with Italian Schengen visa without visiting Italy

Question: I had a plan to visit Italy on a company trip. Got the visa from the Italian embassy but unfortunately, the company has now changed plans to visit the Netherlands. The company says I can travel to the Netherlands with this visa but won't be visiting Italy at all. But my visa also mentions that I need to report back to the embassy after travel. I am confused as in what to do as I don't have time to apply for the Netherlands visa also. Will this have any issue for my next visas?
Answer:
This "report back" thing indicates that they considered you a high risk of overstay, but not quite risky enough to deny a visa. The key thing is that you show up in the Italian embassy in your homeland to prove that you are no longer in Italy (or anywhere else in Schengen).
You could travel to Italy via the Netherlands and get exactly the same stamps in your passport as for a visit to the Netherlands only.
However, it would be a breach of the rules. You should have the current visa cancelled and apply for a new one. This will cost money and take time you may not have, but your company is gambling with your visa history. A black mark could last for a long time.


Ubuntu GNOME 17.04 - Graphics problems on kernel 4.10.0-37-generic

Question: I'm currently using a HP Notebook 14-am089tu laptop, with a Quad Core Intel Pentium N3710 Processor (2.5GHz), Intel HD Graphics 405 Graphics Card, 8GB RAM, and it's running Ubuntu GNOME 17.04. Right from the start, I've noticed that graphics and animations haven't been that smooth. (The Show Applications animation is laggy, Window animations, etc.). I was running the 4.10.0-35-generic kernel right up till today. But today (October 10th, 2017), I got an update to 4.10.0-37-generic. I updated and rebooted. But when logging in, I noticed that the login animation was jumpy. In fact, none of the animations worked. At all. I rebooted, selected kernel 4.10.0-35-generic from the grub menu, purged the new kernel, and rebooted. Things were back to normal. Does this mean that I can't use new kernels after this? (SIDE NOTES: Tested Ubuntu 17.04 with Unity from a LiveUSB. Animations were perfect on Unity. And, I tried updating to the latest drivers using the Intel Drivers software from 01.org. But the tool wasn't available for 17.04. I just installed the 16.04 version).
Comment: just means gnome isn't working well with 4.10.0-37 modules for your graphics card. This does not mean that future releases will also have problems.
Comment: @ravery Oh, alright. Thank you. I guess I'll wait for 17.10 and see if the 4.13 kernel works for me :)
Comment: or wait for 4.10.0-39 see if it is fixed there. filing a bug report would help get the process rolling
Comment: @ravery Oh, okay. Sorry to keep bothering you. But where can I file the report?
Comment: there should be an app in your menu. or https://help.ubuntu.com/community/ReportingBugs
Comment: There is already a bug reported here: https://bugs.launchpad.net/ubuntu/+source/apport/+bug/1723174
Answer: I had the same problem with a Asus UX360UA i7-6500U (Intel® HD Graphics 520), ubuntu (with unity) boot on low graphic with the 4.10.0-37-generic and the intel-graphics-update-tool makes no updates.
My solution was simple, switch back to the 4.10.0-35-generic and wait for the next kernel....
Comment: I did the same, and to prevent this thing to annoying me. I just removed and blacklisted the 4.10.0-37-generic kernel.


fails installing node package using npm on debian

Question: I have just built a server and installed NodeJS (compiled from source). I can install global packages using npm but can't install anything locally:
<code>$ npm install restify
npm ERR! Error: Attempt to unlock restify@~2.6.2, which hasn't been locked
npm ERR!     at unlock (/usr/local/lib/node_modules/npm/lib/cache.js:1304:11)
npm ERR!     at cb (/usr/local/lib/node_modules/npm/lib/cache.js:646:5)
npm ERR!     at /usr/local/lib/node_modules/npm/lib/cache.js:655:20
npm ERR!     at /usr/local/lib/node_modules/npm/lib/cache.js:1290:7
npm ERR!     at /usr/local/lib/node_modules/npm/node_modules/lockfile/lockfile.js:167:38
npm ERR!     at OpenReq.Req.done (/usr/local/lib/node_modules/npm/node_modules/graceful-fs/graceful-fs.js:144:5)
npm ERR!     at OpenReq.done (/usr/local/lib/node_modules/npm/node_modules/graceful-fs/graceful-fs.js:64:22)
npm ERR!     at Object.oncomplete (fs.js:107:15)
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR!     <http://github.com/npm/npm/issues>

npm ERR! System Linux 3.5.0-23-generic
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "restify"
npm ERR! cwd /home/likewise-open/COVENTRY/aa7401/bookshop
npm ERR! node -v v0.10.26
npm ERR! npm -v 1.4.3
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     /home/likewise-open/.../npm-debug.log
npm ERR! not ok code 0
$
</code>
I am running the current versions of node and npm:
<code>$ node -v
v0.10.26
$ npm -v
1.4.3
$
</code>
I am having the same issues with the request package as well.
I am the owner of the folder and all the files int contains.
Does anyone know what is going on?
Answer: The issue may be the permissions on the .npm directory in the home directory. I belatedly found this post:
NPM cannot install dependencies - Attempt to unlock something which hasn't been locked
Unfortunately until I get into work tomorrow I have no way to confirm this.


How probable is a sybil attack?

Question: I'd like to know what's the probability of a sybil attack and if there are mechanisms built in to prevent this kind of attack?
Answer: It is impossible to say what the probability of a sybil attack is as (as far as I'm aware) there are no public data sources on how many users/nodes have been subject to sybil attacks and no reliable reporting when occurrences happen.
However, I think it is safe to say the probability of a normal user being subject to a sybil attack is pretty low as it is hard for the attacker to prevent you connecting to a single honest node and there is very little for an attacker to gain unless they have significant hash power and can compete in the mining of blocks. Without significant hash power all they can do is prevent you from receiving the latest blocks and latest transactions. There is more to gain from sybil attacking mining pools as in theory the attacker could prevent mined blocks from being propagated across the network and prevent them from receiving block reward(s).
With regards to mechanisms in say Bitcoin Core, it is impossible to identify ahead of time which peers are malicious and controlled by the same party. All nodes are treated the same on the network unless and until they start misbehaving (e.g. propagate invalid transactions, blocks). There is some ongoing work (asmap) to ensure greater diversification of peer selection through stronger bucketing. There are also various things you can do proactively as a user. If there is a node you trust you can connect to this peer manually. If you haven't been receiving blocks for a number of hours (and you have peers) you can check a block explorer (mempool.space, blockstream.info etc) to see if there have been blocks mined in this time. Although you generally shouldn't need to, doing out of band checks can give you the assurance that your node isn't subject to a sybil attack.
Comment: Probability is the wrong thing to ask about. Attacks don't happen randomly; they happen deliberately. The question to ask is what the attack costs, and what someone stands to gain from it (this is more a comment on the question than on the answer, just pointing out that it's inherently unanswerable).
Comment: @PieterWuille: I agree the attack costs are highly relevant. The higher the cost the more out of reach the attack is from most potential perpetuators. I'm skeptical on trying to assess "what someone stands to gain from it". It could be anyone from a Western state actor to a rogue state actor to an altcoin advocate to just a well resourced bored hacker. If an attack is possible and affordable it could be carried out for multiple reasons. That's why I think probability factors in. If you just want to cause disruption you are going to pick the lowest hanging (most probable to succeed) fruit first
Comment: Admittedly this isn't an exact science and you may have given this much more thought than me! But that's my current thinking anyway :)
Answer: One cool thing about Bitcoin is that coins are inherently scarse and this is by itself a huge protection from sybil attacks. In other P2P systems, sybil attacks are much harder to prevent because there's no such concept of scarcity. In Bitcoin, a sybil attack would be achieved if one has lot of coins, by sending tons of transactions, and therefore spending such coins.
There are other types of sybil attacks such as overloading nodes connections, and the recent one of filling up the memory pool of specific nodes with really tiny transactions. A way to prevent these would be for example to increase the fees.
Comment: How does coin distribution have anything to do with a Sybil attack?
Comment: because the transaction, which is what might be sent across the network to produce a sybil attack, represents a transfer of value and therefore cannot be simulated by a gazillion simulated peers to disrupt such network: the size of his attack is always proportional to the amount of transferable coins he owns.

How probable is a sybil attack?


Is this quote by Goethe, and what is the source?

Question: Is this a real quote?

Few people have the imagination for reality

I have seen it attributed to Goethe in 1815, but I cannot find the source..
Comment: Quote Investigator is a great resource for this type of question, but [seems to have nothing on this one](https://www.google.com/search?client=firefox-b-d&ei=M0_QXLfaFMGlkwXrubp4&q=goethe+imagination+reality+site%3Aquoteinvestigator.com).
Answer: The earliest appearance of this quote that I can find is here:

For a short while she [Diane Arbus] studied with Berenice Abbott, who photographed New York and James Joyce and collected [Eugène] Atget. Abbott thought photography was the ultimate art form of the twentieth century because it demands speed and science, and she was fond of quoting Goethe: "Few people have the imagination for reality."
Patricia Bosworth (1984). Diana Arbus: A Biography, p. 67. New York: Alfred A. Knopf.

The quote does not seem to come from any translation of Goethe, nor does it resemble Goethe's style, but possibly it is Abbott's own paraphrase or summary of a passage by Goethe. It has something of the flavour of maxim number 592:

Es gehört eine eigene Geisteswendung dazu, um das gestaltlose Wirkliche in seiner eigensten Art zu fassen und es von Hirngespinnsten zu unterscheiden, die sich denn auch mit einer gewissen Wirklichkeit lebhaft aufdringen.
It takes a special turn of mind to grasp formless reality in its essential nature and to distinguish it from the figments of the imagination which, all the same, thrust themselves urgently on our attention with a certain semblance of reality.
Johann Wolfgang von Goethe (1907). Maximen und Reflexionen, p. 128. Weimar: Verlag der Goethe-Gesellschaft. Translated by Elisabeth Stopp (1998). Maxims and Reflections, p. 84. Penguin.


Unable to write to WD external hard drive from centos 6.1 system

Question: I have a WD 2.5 T My passport ultra external USB drive. I attach it to centos 6.1 system on lenovo E430 laptop. The centos has the latest ntfs-3g packages.
The external drive is recognized and its contents displayed when I connect. However, when I try to write, the result of the operation is successful but no content seems to be written.
I then tried copying using a windows XP VM on the centos6.1 system and then copying from centos drive -> external hard drive via windows XP. That works but the transfer speed is of the order of a 16 - 20 bytes. I have > 2 G to copy and this will take more than a day.
How do I troubleshoot either of these problems.
I looked aroudn but could not find anything. Western digital site says that only windows and mac os are supported but given that centos supports NTFS which is what the drive is formatted with, I should be able to transfer.
Thanks for any inputs.
Answer: Ignore the windows-and-macosx-only mantra, the usb drive should work fine with linux.
Just run
<code>sudo tail -f /var/log/messages
</code>
then

connect the drive to machine
mount it
copy some data to it
unmnount it

to get any technical info what's going on down there.


Is it still possible to play Warcraft 2 on Battle.net?

Question: Warcraft 2 isn't for sale anymore on Blizzard's store, but I would like to play the Battle.net version. Is it still playable on Battle.net, or is online play no longer supported?
Answer: Yes, it is still possible. Blizzard has re-released Warcraft II Battle.net Edition, with support for Windows 10, in the GOG store. It still includes support for the classic Battle.net multiplayer servers.
Before playing online with this version, you'll need to manually enter your "CD key" under the "Change CD Key" menu in the launcher. You can find your CD key by opening your GOG account page in your browser, clicking on "Warcraft II Battle.net Edition", and selecting "Serial Keys" from the "More" menu. It also asks for your name, but you don't need to use your real name and probably shouldn't for privacy reasons: it can be displayed to another user if they somehow try to use your CD key.

To play on Battle.net you must use the "Warcraft II (Classic)" option in the launcher. This ignores your choices under the Video Settings menu, but the other "WarCraft II" option doesn't even have Battle.net in its multiplayer menu. You will also need to create a Battle.net Classic account in the game. Battle.net Classic accounts are not connected to GOG accounts or modern Battle.net accounts.

You may also need to manually configure your router to forward ports 6112-6119 TCP/UDP to your computer. Modern games can often automatically configure ports using UPnP, but that hasn't been added to Warcraft II.

Outside of Battle.net, there also exists an unofficial multiplayer server and community called War2.ru, who provide an unofficial modified client called War2Combat. Unlike Battle.net, War2Combat does support UPnP, and War2.ru has a rudimentary online match history.
Answer: The battle.net version still works online.  You might have issues finding people to play with but you are still able to connect.  You won't be able to join a chat room however (probably just thevoid - which if you remember is the channel you went to when kicked or banned out of a channel) which happened when bots were emulate Warcraft II and Diablo I.  Such fun.  But I did play a game of Warcraft II online on Battle.net about a year ago.  But had a decent wait to find someone!
Comment: If it's the same as Diablo 1 you can still create custom channels, they just have to start with the usual blabber. So I could join "Diablo Retail LE" for example, or probably "Warcraft II High School" or whatever.
Answer: While Blizzard's tech support info is sometimes out-of-date, playing on Battle.net and resolving issues with it is mentioned repeatedly in their tech support docs for Warcraft II.  Due to this, I would expect that it can still be played on Battle.net.


When to check and when not to check ModelState.IsValid

Question: I'm using ASP.NET MVC2.
I love how I can annotate my model's fields and check ModelState.IsValid.
The obvious reason to check it is when doing validation, but should you always check it in case new validation rules are applied to the model?
That way you don't forget / need to check whether the controller checks IsValid.
Is there some reason not to do this check in all cases? Maybe just when the controller action has side-effects (DB-writing etc)?
Answer:
but should you always check it in case new validation rules are
  applied to the model?

You should do this check always else you end up persisting models that don't have valid state.
Answer: Generally, in asp.net-mvc, models passed to actions are view models, and they contain all and only data needed for action to act. If that data is invalid, theoretically it should be impossible for action to do its job.
ModelState.IsValid ensures that all data needed for action is in good state, ready to be acted on. I do not see reason where you would not want to validate that data.
Answer: You should always check if the model is valid immediately before attempting to use the data collected in the model to do something.  That's the purpose of validation in the first place.
Answer: It looks obvious to mention, but i will give it a shot.
There is NO need to check model state when you are NOT posting your model. The common scenarios are when you are getting your data from service and displaying on a get action.


Is it bad etiquette to answer a question you've voted to close?

Question: Just because a question isn't good for the website's format doesn't mean the asker doesn't deserve an answer if one can be squeezed in before the question is closed IMO. What is the general opinion of this situation?
Comment: This depends on the close reason. If the question is good but off-topic and it is migrated, your answer will be migrated too.
Answer: In the case that it's a question that you can answer, but the question is not suitable for the site, I'd advise inviting the asker into a chat room where you can help them. This way the wrong behaviour isn't rewarded, but the asker gets help anyway, and learns where to go in future if they have off-topic queries.
Comment: Well i think this would be a good solution but 90% of the Off-Topic questions are asked by (one time) askers with only 1 rep. And you need 20 rep to talk in chat. Also off topic questions usually don't get 4 upvotes.
Comment: @Scribblenautical IMO = In My Oppinion
Comment: @Scribblenautical also there is imho (In my honest opinion)
Comment: This is great advice for this and all of SE.
Comment: @Halfwarr I might be in a minority here, but I've always considered imho to be in my *humble* opinion.
Comment: @Jutschge Yeah, this won't work all the time, but IMO it's the best course of action when possible.
Comment: What is IMO? .-.
Answer: I can see both sides of the argument. We exist to try to help people, and we're not doing that if we're not answering their questions. On the other side, we also want to help the site grow, and the best way to do that is to encourage quality contributions from all of its participants.
If you answer a question that should clearly be closed, you're rewarding the wrong kind of behavior on the site. You're not going to get in trouble for it, and I think I've even done it once or twice, but overall I think that it might be better to just cast a close vote without an answer.
Comment: StrixVaria for mod... wait..
Answer: People come to SE to ask questions.  They come back because they got a good answer.  They learn how to ask good questions because they were encouraged to when they asked.
As others have pointed out though, bad questions are supposed to be discouraged. At best, they pollute the SE with bad questions, and at worst they encourage askers to ask more bad questions when they get an answer.
Therefore, I would encourage you to not answer a question you vote to close, but to also recommend that they read the FAQ and explain why you're voting to close, especially for a 1-rep user who may not even be aware of the FAQ.
A bad user who is shown how to be good can eventually become a good user.  But a bad user who is turned away from the site is gone (and bad) forever.
Comment: This approach ensures an asker will ask whatever they want, even if they know it's off-topic, in the hopes it will get answered prior to closing.  That's *exactly* the reason we close questions; to prevent answers.  Don't enable those users.
Comment: As much as I hate to say it, @Frank has a pretty dam good point.
Comment: the general consensus seems to be against this but I approve of this approach
Comment: Even I have to agree with that point.  I would still recommend always pointing new users towards the FAQ and explaining your close vote though, so that if they do want to stick around, they at least know now why it was voted to close.
Comment: @Zibbobz On closed Questions there is usually a Big yellow block with a description of the close reason and why it's not welcome here...


Proof of Sets involving the Cartesian Product

Question: The question goes:
Let $A,B,C,D$ be sets. Prove that $\big(A\times B\big)\bigcup \big(C\times D\big)=\big(A\bigcap C\big)\times \big(B\bigcap D\big)$
I started with the definition of the cartesian product $A \times B=\left\{\big(a,b\big): a\in A \wedge b \in B\right\}$
The union of $A\times B$ and $C \times D$ would be a set of coordinates where $\big(x,y\big): x\in A\bigcup C \wedge y\in B\bigcup D$
I am stuck here because the union of the two cartesian products on the left doesn't seem to imply that $x\in A\bigcap C$ and $y \in B\bigcap D$. Could anyone give me a hint or a possible step I might not be seeing? Please and thank you.
Answer: You are going to have a bad time proving that.
Consider A={0}, B={0}, C={1}, D={1}.
Then $A\times B=\{(0,0)\}$, $C\times D = \{(1,1)\}$,
$\big(A\times B\big)\bigcup \big(C\times D\big)=\{(0,0),(1,1)\}\ne \big(A\bigcap C\big)\times \big(B\bigcap D\big)=\emptyset$
Comment: Thank you, I did not even consider finding counter examples before starting to prove it.
Answer: Yet you can actually show that
$$
(A\times B)\cup(C\times D)\subset(A\cup C)\times(B\cup D)
$$
or in other words:
$$
(x,y)\in(A\times B)\cup(C\times D)\implies(x,y)\in(A\cup C)\times(B\cup D).
$$
Perhaps you confused $\cap$ with $\cup$ ?


options creation for plugins

Question: I am new to wordpress and learning to create plugins.
I want to know how wordpress itself create options in 'wp_options' table for plugin during plugin installation or activation?
How wordpress decide about these option values, which is sometimes serialized data?
Answer: There are some functions associated with manipulating the variables found in the wp_options table.
add_option(): Create a new value in the table. Example add_option('var_name', 'value') will store  option_name = 'var_name' and option_value =  'value'. add_option() is used only when saving a value for the first time. Has an autoload parameter.
get_option(): Retrieve that value. Example: get_option('var_name') will return the string value.
update_option(). Will update the value of an option. Can also be used instead of add_option(), but it lacks the autoload parameter.
As for serializing data, Wordpress will do it automatically if you use the above options with an array.
Answer: WordPress includes a Settings API, that handles all aspects of registering and updating options. I would strongly recommend using the Settings API rather than using add_option()/update_option() directly.
I've written a tutorial on implementing the Settings API in Themes; Plugins would be almost identical, except they would use add_options_page() instead of add_appearance_page().
More specific answers would require a more specific question.
Comment: Sir, thanks for your reply. My specific question is, when I created one small plugin 'The Wall' given in book 'WordPress Plugin Development Beginner's Guide' by 'Vladimir Prelovac' and activated it, I found 'wp_wall' option get created in 'wp_options' table. I want to know, how wordpress created this option itself and how it decide about content of 'wp_wall' option?

options creation for plugins


Restricting access to a video file on the network

Question: I have an MP4 file on our Windows 2008R2 fileserver that I want people to be able to view, but not to create copies of.  Is there a security permission configuration that would allow this?
Comment: This is like saying "I want people to see my website, but they're not allowed to save the text."
Answer: This is not possible in Windows. When you grant user "Read" permission, then copying is possible. You can always enable Folders/Files auditing and review log to check who copied data and when to track this issue.
Answer: To my knowledge, there can be no permissions that would permit a user from viewing the file and at the same time prevent that user from copying the file.
Answer: This is exactly what DRM is for. Whether you can effectively wrap MP4 into a DRM scheme, I have no idea - now you have the terminology to allow you to try yourself! Remember how effective most DRM schemes are, though.


Word detectives needed: "Ananyzapata"

Question: I'm trying to decode the mysterious word Ananyzapata. Unfortunately I don't have the original source, just its appearance on a slide from a presentation. From the context (words on good luck charms/amulets in Medieval England) it may be a word like Abracadabra, or the name of a god, or angel, or even demon? It might even be a phrase mistakenly rendered as one word. Any ideas?
Comment: Can you show us the slide?
Comment: The slide was a modern powerpoint one, it didn't show the word in situ. Thanks to your solution below I now think that the speaker made a mistake in transcribing "zapta" as "zapata".
Answer: According to Etymonline, ananizapta is a magical word from the mid-15th century, which is around the end of the medieval period.
On Google Books I came across this passage:

For the falling sickness the charm was the following:

Ananizapta, ferit mortem dum læder querit,
    Est mala mors capta dum dictus, Ananizapta;
    Ananizapta Dei nunc miserere mei.

There are several other results where the word is used in a similar way.
Explanation and picture from Harder Gate in Ingolstadt

Dr. Karl thinks that the meaning of the whole formula is:
  Jesus Christ defeated death (the devil)
  by being baptized by John
  and by dying on the cross ("chiasmus").
Answer: Could it be a name?
A search on Google reveals two people whose names contain "Anany Zapata", and one whose name is listed as "Anany Zapata", however that may not be his entire name.
Answer: There was a movie Anazapta showing the plague killing a city but the whole meaning of the movie can be transcribed as "a revenge". Also in the TV series "the Vikings" this word is engraved on the sword and shown right at the end of the 20 serie of the forth season.
Comment: Welcome to English Language & Usage! Please [explain your answer](//english.stackexchange.com/help/how-to-answer), preferably with some supporting statements and [references](//english.stackexchange.com/help/referencing).

Word detectives needed: "Ananyzapata"


Custom User model or User Profile model with one to one relationship to the user model

Question: I am a newbie to web developmnet. I'm using django and lately I have been realy confused and undecided on wether I should use a Custom user model with additional fields I need or create a seperate User profile model with one to one relationship with the user model. What is the best practice?. In which ever case is best I would like to aslo add the fields like 'followers', 'following', 'likes', 'connections' and users should be able to easily edit some details on their accounts after creating, which method is the best?
Answer: I would suggest you go for a Profile model. Depending on your requirements, make a little research, if Django's AbstractUser class has all the fields you want, Use that, it will allow you to add more fields as well as you continue to build and it's a good practice. But if AbstractUser has more fields than required, use Django's AbstractBaseUser to specify only the fields you want.
Then create a Profile model with the details you listed above, "likes", "connections", "followers", "following," and you can keep on adding more if you  like. Use the models.OneToOneField to specify that a user model can have just one Profile model.
This should make everything a bit easier for you.


2005 VW Golf battery/PCM

Question: I was replacing the PCM in my golf, and 'someone' forgot to disconnect the battery. So after I pulled out the pcm and put the other one in. My car will not start. Are there any solutions to get it back up and driving
Answer: Removing the pcm with out disconnecting battery is not really a big deal. Your car will not start because your immobilizer is active from switching the PCM.
You will need to have the immobilizer data cloned over, the replacement PCM programmed properly or have the immobilizer tuned out of it.

2005 VW Golf battery/PCM


Would federal copyright be constitutional without the Copyright Clause?

Question: If the Constitution did not contain the Copyright Clause, would Congress still be able to implement copyright under the Commerce Clause or another part of the Constitution? Assume that the Constitution never contained the Copyright Clause, rather than the clause being repealed.
Answer: Eventually. This was a state matter prior to the enactment of the Constitution. Without the Copyright Clause, it would have been up to each state to enact such a law (apparently Delaware did not bother). This would have quickly led to inter-state disputes (a New York author being infringed by a New Jersey party), therefore the matter would have been heard by the federal courts.
The current understanding of the Commerce Clause easily allows Congress to enact a copyright law, because copyright is quite commercial and potentially crosses state lines. It took a while for that clause to be interpreted by the courts the way it is now. This is a brief summary of historically shifting views on the Commerce Clause.
Comment: I think I'd agree that the federal copyright protections would be within the scope of powers authorized by the Commerce Clause, but I wonder whether they would nonetheless be forbidden by the First Amendment.


Can someone tell me how does this work ? (C programming)

Question: int m, n, j;
n=16;
j=15;
m = n++ -j+10;
printf("%d", m);

Output: 11.
Here, first, the old value of n is given to m and then it is incremented so the new value i get is 17 and then the expression is solved i.e. j+10 = 25 then the new value of n is subtracted by 25 i.e 17-25.
Am i right ? but the answer doesn't match the output 11.
Then how does this work ?
And also, i am new to programming and started learning C. Which book will you suggest is the best for me ? As I've no programming experience.
Thank you.
Comment: no value is asigned to m unless the complete calculation on the right side (that's why we talk about a R-Value, R stands for right) has been finished. here m is L-Value (L for left).
Comment: `m` is `16-15+10`, because `n++ == 16`.
Answer: m = n++ -j+10; is same as
m = n -j+10;
n = n + 1; // m is 11.

If it was ++n It would be
n = n + 1;
m = n -j+10; //m is 12.

then the expression is solved i.e. j+10 = 25

No. It would  be -j+10 = -5
My suggestion is, dont write complex expression unless you are completely sure what you are writing.
Comment: I understood. Helped alot. Thank you.
Answer: You've got a few things wrong there.

n++ will increment n and return the original result, so you've then got m = 16 ....
-j so you've got m = 16 - 15 ....
+10 so you've got m = 16 - 15 + 10.

Now the last time I did maths that would come out as m = 11 like you're seeing.
If you wanted it to be m = 17 - (15 + 10) then you wanted:
int m, n, j;
n=16;
j=15;
m = ++n -(j+10);
printf("%d", m);

Comment: I understood. Helped alot. Thank you.
Answer: in fact the post increment operation is done on n after the operation...
you have 16-15+10 = 11
but if you print n you should have 17.
to begin, you can read some book on basics but this example is not simple; it include the precedence of operator which can be tricky.
begin simple... it's quite simple to write unreadable code in c.
http://www.cs.cf.ac.uk/Dave/C/node4.html
hope it helps
Comment: I understood. Helped alot. Thank you.
Answer: n++ first returns the value of n and then increments it.
 so, the actual computation that takes place is m = 16 - 15 + 10 which is 11
i think what you want is:
m = (n+1) - (j+10);

the use of the ++ operator is to increment the value of n for future use after you use it's current value to compute m.
Comment: But where is the incrementation done ?
The value of `n=16` and `j=15`. Then what is the use of `++` here ?
Comment: n++ increments n not m, if your print the value of n you'll see that it's 17
Comment: I understood. Helped alot. Thank you.
Answer: for m, first of all calculate n - j + 10 and assign it to m. After that n++ is executed.
at the end n = 17, m = 11
Comment: I understood. Helped alot. Thank you.
Answer: You're making two incorrect interpretations.
Firstly, as indicated in other answers, n++ only increments n after the entire expression has been evaluated.
Secondly, you have -j+10.  This is not equal to -(j+10), so it is wrong to say that j+10 is 25 and you are looking a something - 25.  Another way of view -j+10 is 10-j.
Comment: I understood. Helped alot. Thank you.
Answer: In answer to your question about a good book - you probably want to consider learning C++ instead of just plain old C, since C++ is a superset of C.  And for C++ you need to get Bjarne Stroustrup's 'The C++ Programming Language'.  It's easy enough to read and will last a long time on your bookshelf as a good reference.
Answer: In the expression m = n++ -j+10;
The compiler treats  the expression as m=  n++ ((-j)+10)
As the intialized values of n and j are n = 16 and j = 15.  We have m = 16++ ((-15)+10).         We  get output as 11.
After the expression is executed n will be incremented.
Answer: n is incremented after its value is used in the expression which ends up in m.
Answer: n++ is post incrementation. It only increments the value of n after doing: m = n++ -j+10;
++n is pre incrementation. It increments the value of n before calculing m. m = ++n -j+10;