Integration of $|f(x)|$

Question: I would like to learn how to use the sign function $\operatorname{sgn}(x)$ to integrate the absolute value of an arbitrary function. I know that integrating piecewise should give me the same result, but sometimes trigonometric functions can become cumbersome. I have tried searching on the internet, but I can't seem to find anything. Perhaps the theory isn't complete, and the methods for integration aren't known for the absolute value of all functions, but I would appreciate if someone could give me one or two places where I can learn a general approach. What I would like to learn is integration for the absolute value of at least a second degree function, and the "basic" trigonometric functions (sin, cos, tan, csc, sec, cot). Links or references to information on the internet will be a lot more helpful to me than references to books. Thank you.
Comment: The most general advice for integrating $\int|f(x)|\mathrm dx$ is to find where $f(x)$ crosses the horizontal axis, and split your integral accordingly... at least, I know that computing environments with the ability to do this also use this approach.
Comment: The sign function approach not only gives the same result as integrating piecewise, there's also no deep difference between the two approaches, since the sign function, like the absolute value, is defined piecewise using a case distinction; it's basically just $\text{sgn}(x)=|x|/x$ (glossing over the details at $0$). You can express it algebraically e. g. as $\text{sgn}(x)=\sqrt{x^2}/x$ , but you can do the same thing with $|x|=\sqrt{x^2}$ directly.
Comment: @ J.M., joriki: I understand what you mean, but it's just that integration of certain trigonometric functions can become very, very cumbersome. See, if the integral of a trig function has multiple roots, it can be easy to integrate by finding the area under of it it's "humps" and then multiplying that by the number of "humps". However, some trig functions have the property that their "humps" aren't uniform. Then it becomes very time consuming (unless there's an integration method I'm missing). What I mean by "hump" is the area under the curve of a sine function from two successive roots.
Comment: Sure. Sometimes you just have to bite the bullet and do the tear-inducing algebra...
Answer: I looked through some of my stuff last night and found the following references. However, all except one are not "links or references to information on the internet" (unless you have access to a university library), but perhaps by googling some of the titles and names you can come up with some useful items on the internet. I've listed them in the order (highest to lowest) that I'd guess as to how useful they'd be to you (with the exception of the last one, for which I've only seen the Nature summary).
Kenneth O. May, "The calculus of absolute values", American Mathematical Monthly 62 #9 (November 1955), 651-653. (here)
Margaret R. Wiscamb, "A formula for the derivative of the absolute value of a polynomial", Pi Mu Epsilon Journal 4 #9 (Fall 1968), 367-369.
C. Walmsley, "On the area of a square", Mathematical Gazette 38 #325 (September 1954), 210-211. (here)
John L. Spence, "Step function notation", School Science and Mathematics 60 #3 (March 1960), 179-180. (here)
Daryl E. Doan and Joshua Grusd, "Derivative and indefinite integral", Reader Reflections column, Mathematics Teacher 98 #5 (Dec./Jan. 2004/2005), 292.
"prove d|x|/dx = x/|x| without piecewise", MathKB discussion groups, Mathematics - General Topics, 27 January 2006. (here)
Nature (journal) 93 #2315 (12 March 1914), p. 39: Midway down the left column is a brief description of a Russian paper by I. N. Kouchnereff and D. Riabouchinsky that: "...treats this quantity [absolute value operation] as a function of the variable $x$, and shows how this method leads to interesting formulae involving the solution of equations, differentiation, and integration. A number of elegant geometrical applications are also given, such as equations of broken lines [polygonal curves?], and equations of limited portions [bounded?] of planes, such as a square area."
Comment: These references were helpful. Thank you.
Comment: What a beautiful title by Walmsley "On the area of a square"!

Integration of $|f(x)|$


Apex Trigger not recognizing with Start Sync button is clicked

Question: Background:
Our company works in print media and when we sell ads for our magazine, our reps fill the fulfillment information out at the Quote Line Item object.
Our accounting software can only read from the Opportunity Product level.
I have created a trigger that achieves that with one catch, it doesn't recognize when a rep needs to sync the primary quote with the Opportunity.
The button is a standard Salesforce button, meaning it comes with Salesforce and I don't see how to customize it. (Start and Stop Sync button)
If I were to update a record at the Quote Line Item object after syncing the Quote, the trigger works as expected.
Question:
How can I code the trigger to recognize when the Start Sync button is clicked to transfer this information to the Opportunity Product field?
Code
<code>trigger UpdateOpportunityProductMonthsToFulfill on QuoteLineItem (after insert, after update) {
    String monthsToFulfill = '';
    map<String, String> updateMap = new map<String, String>();

    // This is where the text for the Months_To_Fulfill__c field is built
    for(QuoteLineItem qli : Trigger.new){
        // To make a spelled-out list of months & years instead of the older "start through end"

        List<String> yearOneMonths = qli.Months_Served_Y1__c.replaceAll('None(;)?', '').split(';');
        for(String month : yearOneMonths){
            monthsToFulfill += ( monthsToFulfill.length()==0 ? '' : '; ' ) + month + ' ' + qli.Year_Served_First__c;
        }
        if(!(qli.Year_Served_Second__c == null || qli.Year_Served_Second__c.equals('None'))){
            List<String> yearTwoMonths = qli.Months_Served_Y2__c.replaceAll('None(;)?', '').split(';');
            for(String month : yearTwoMonths){
                monthsToFulfill += '; ' + month + ' ' + qli.Year_Served_Second__c;
            }
        }

        updateMap.put(qli.QuoteId, monthsToFulfill);
    }

    for(String quoteID : updateMap.keySet()){
        // This is the calculated value we saved from looping through the Trigger.new Collection
        monthsToFulfill = updateMap.get(quoteID);

        // Get the OpportunityLineItems associated with this QuoteId
        List<OpportunityLineItem> oliList = [Select Id, OpportunityId, Months_To_Fulfill__c
                                             From OpportunityLineItem Where OpportunityId In (Select OpportunityId
                                                                                From Quote Where Id = :quoteID )];

        List<OpportunityLineItem> olisToUpdate = new List<OpportunityLineItem>();

        if(oliList.size() > 0){
            for (OpportunityLineItem oli : oliList){
                // Populate this olisToUpdate list because we may
                // want to get smarter about what's actually updated
                // in the future.  For now, everything is updated.
                oli.Months_To_Fulfill__c = monthsToFulfill;
                olisToUpdate.add(oli);
            }

            // Batch update the OpportunityLineItems we identified earlier
            if(olisToUpdate.size() > 0){
                update olisToUpdate;
            }
        }
    }
}
</code>
Answer: If I understand you correctly, your reps press the button located in the Quote.
Then you should run the trigger on OpportunityLineItem instead of QuoteLineItem.
Because pressing 'Sync' creates/updates OpportunityLineItems identical to your QuoteLineItems, i.e. your QuoteLineItems aren't being updated or insterted, so your trigger won't fire.


How can the charge on a particle be measured remotely (e.g., near a black hole)?

Question: Perhaps I haven't thought through this as long or as deeply as I should, but at the moment it's got me stumped.  How can the absolute charge on a particle be measured remotely? This derives from pondering how it might be possible to prove experimentally the invariance of charge on a particle vs its location relative to a black hole.  I know that charge is considered to be invariant in special relativity and general relativity, but I'm wondering how the invariance might be tested empirically.
Gauss's law can be used to determine the charge within a volume, but it requires measurements of E at every point on a surface that encloses the volume.  That's not a very practical remote measurement.  If we know that a first, very massive, particle has an invariant charge of $Q$, then presumably we can remotely observe a second, very low-mass particle as it passes near the first particle, and deduce the charge on the second particle from its trajectory.
However, if the charge on the second particle changes due to its proximity to a black hole, the charge of the first particle will change similarly.  Moreover, the gravitational mass (and the inertia) of each particle presumably will be a function of its height in the gravitational well of the black hole.
We know that the emission spectrum of, e.g., a hydrogen atom is red-shifted (relative to a distant observer) as the atom goes lower in a gravitational well. Of course that red shift can be calculated using general relativity.  Could that spectrum be used to prove that the value of e is not dependent on gravitational potential?  Maybe, but I suspect that unless we make assumptions about how gravitational mass is affected by height in a gravitational potential, we cannot measure charge remotely.
Millikan directly measured the charge on an oil drop in his famous experiment, but really included measurements of two quantities:  the voltage required to suspend an oil drop, and the mass of the oil drop. In the case of extreme gravitational potential differences, though, we cannot assume that a particle's mass is invariant. Can we even remotely measure the charge-to-mass ratio of the particle without making untested assumptions?
That a free-falling observer will always observe the same laws of physics as any other free-falling observer is an acceptable assumption.  However, I don't think it would work to drop a lab apparatus to the charged particle and measure its charge as the apparatus flies past, then have the apparatus report back to a remote observer.  The charged particle, suspended at a fixed height above the black hole, will be accelerated relative to the apparatus.  Moreover, I suspect the experiment could at best only prove that the apparatus and the particle both change in such a way that the results appear invariant from the perspective of the apparatus.
Maybe if I'd had a better course in general relativity this would seem trivial- but no.  So to repeat the question: How can the absolute charge on a particle be measured remotely?
Answer: One way would be to observe the electromagnetic and/or gravitational waves emitted by the particle as it orbits the black hole. The particle's orbit will decay as it loses energy in EM/GW waves. By analyzing the evolution of the wave signal (similar to the LIGO analysis of GWs), one could determine both the mass and the charge.
(To get an accurate measurement, you might need independent knowledge of the distance to the black hole and/or its mass.)
Comment: That could maybe work if the test particle is a charged black hole orbiting an uncharged black hole.  I'm hoping there is a method that would work on something small like an electron or proton -- or even something with the mass of Millikan's oil drop.


Question about Ranger's Animal Companions

Question: There's a Ranger(Level 4)/Scout(Level 3) in a campaign I'm in, and he tricked me into give him a tiger very very early because I hadn't even read the page yet or knew what I was agreeing to. He currently only has an effective Druid level of 2. My question about this is, how would that work according to the SRD? Is the tiger level 2, or, since there's a -6 Druid Level Modification on having a tiger as a pet, is it level 1 until he gets 16 levels in ranger?
Comment: As written, your questionseems to be a request for a rules citation. However, the only rules-related answer you're likely to get is "He hasn't got a tiger, because he's not a high enough level for that." Essentially, by giving your player an animal companion he doesn't yet qualify for, you've already gone off the beaten path - the rules-as-written don't have an answer for the situation because this situation arose from bending the rules. Are you looking for house rules for this situation? Advice on how to deal with making errors made during play? Or curbing the avarice of power gamers?
Comment: *Especially* tigers.
Comment: I was asking because I didn't understand the rules as written. In my opinion, Wizards wasn't very clear with any of this. Everywhere I see that animals get skill ranks and feats as they level, but I can't find it written in any book. I also couldn't find rules about buying animals, despite people also saying there were rules everywhere in the books. So I come here to ask questions. I was asking how pets level because I wasn't sure how it worked, and the cause of that was the player who tricked me into giving him a tiget, and wouldn't let me change my mind, so I used him as an example.
Comment: Ah, you wanted a rules *clarification*. Fair enough. In that case, here's a few points: i) All creatures get skill points and feats based on level and hit dice, not just animals. ii) The description of the animal companion class feature provides a description of how animal companions advance; This is based on the level of the druid.
Comment: iii) Prices for a limited selection of animals (horses and dogs) are found in the Equipment chapter of the PHB. iv) The general rule for buying things that aren't given a specific price in the books is "If the GM decides that there's an NPC willing and able to sell it for a given price and the player has enough money to pay that price, an exchange can take place." v) That being said, animal companions are not, generally speaking, things you'd get down at the local pet shop; They're ferocious wild beasts that happen to have developed a bond of companionship with a druid or ranger.
Answer: First of all, I want to state that the "Tiger's level" isn't really a thing, or at least nothing relevant. There is the character's "effective Druid level," which determines the Animal Companion's benefits per The Druid's Animal Companion. These include bonus HD, which do wind up increasing the Animal Companion's "level," but that's not really relevant to the question. Animal Companions do not simply "level up" with their masters; they just gain bonuses (including more HD) when their masters level.
How the rules work:
He counts as a Druid 2 for the purposes of his Animal Companion. A Druid 2 cannot have a Tiger; he must be at least Druid 7 so that he "counts as" a Druid 1 (after the −6 penalty) with respect to the Tiger.
As a Ranger, he would not count as an effective Druid 7 until Ranger 14, at which point he would get a regular Tiger and only the 1st-level benefits listed in the table, i.e. Link, Share Spells, and 1 Bonus Trick.
Personal opinion: this is dumb, and it should be the other way around
The Ranger gets an Animal Companion so far behind the Druid that it's basically good for not much more than scouting. Meanwhile, the Druid gets an Animal Companion that can be nearly as good as the Fighter. This is stupid because the Druid without an Animal Companion is stronger than the Ranger and his own, better Animal Companion combined. The Druid is one of the most powerful classes in the game, but even though the Animal Companion is very good, it's not even the primary reason (or even the secondary reason, for that matter) the Druid is so good (it would be #1 spellcasting, #2 Wild Shape, #3 Animal Companion).
So I usually houserule that Ranger's get the better Animal Companion (starting at 1st and at a level equal to what a Druid usually gets, rather than halved), and the Druid gets the weaker version (if he gets an Animal Companion at all, if I can even be convinced to allow Druid; I don't outright ban it but I try to help players who have character concepts based on Druid express that same concept, if possible, with another class).
What you might do in your game
Anyway, back to your Tiger. As a 7th-level character, this is what a single-classed Druid could get; I'd be inclined to just allow it for the sake of not upsetting things. I'd let the character use both Ranger and Scout levels for it, and I'd let him have a "full-level" Animal Companion, so a regular (effective Druid level 1) Tiger is fine for his character.
In a couple of levels, assuming he continues in Ranger or Scout (or something else I felt was appropriate for advancing it), the Tiger might start to get better (i.e. effective Druid level 3, he gets 2 bonus HD, +2 to his Natural Armor bonus, +1 to Str/Dex, another Bonus Trick, and Evasion, and then so on as he continues to level).
I might ask the player to take a feat for the benefit of using any class level, rather than just Ranger or Druid levels, to count for the purposes of his Animal Companion.
If you don't have a Druid in the party (and it sounds like you don't), these are pretty easy changes to make. If you do, you may have to let them both have the "strong" Animal Companion, since the Druid player probably doesn't want to lose his pet. That's probably fine: it's not like you were going to fix the balance problems around the Druid with this change anyway.
Comment: +1 for Animal Companion sucking for classes that should really have better.


why my computer's resource exhausted while has lots of memory?

Question: My computer configuration is : WINDOWS XP, 2G memory,
I had a bad habit, when I browse a webpage I like, I will not close it, just let it live in my IE8, for I may want to read this page later!
So my IE always spend most of my memory. When there's 30 plus tab in my IE, and some word documents open, then if I click 'My Computer' desktop icon, the explorer sometimes don't show menu etc, Seems not enough resource, If I close some documents, the explorer back to normal. But when I use tool to see how much memory left, the tool shows 1G left,
Then what happened to my computer. Does anyone use web browser like my kind?
Comment: There are millions of people who use the same web browser as you.
Comment: Which Processor you using and what is your net speed
Answer: It sounds like you're running out of USER objects.  USER objects represent user interface elements like desktops, windows, menus, cursors and icons.  There are upper limits on the number of USER objects in Windows, and when you reach those limits, you will typically see strange behaviour, similar to what you describe.  You can use the freeware Process Explorer from SysInternals/Microsoft to confirm that this is the problem and definitively identify the offending process.
Mark Russinovich has written an excellent overview of USER and GDI objects and their limits in Windows.
Unfortunately, even after you've confirmed that IE is causing the problem, the only solution will be to close IE, thus freeing up the USER resources, then run IE again.
As a long-term solution, I recommend using IE's Favorites feature to create shortcuts to the web sites you like.  You can organize your Favorites into a tree structure that makes it easy to group sites by task or topic.  That way you don't have to leave your favorite sites open in the browser all the time and you won't deplete your system's resources.
Answer: Your Windows XP might not have enough Virtual Memory.
Press [WIN]+[PAUSE] key combo to get into "System Properties" window, then  select the "Advanced" tab. Then under the "Performance" section press the "Settings Button", the "Performance Options" window will pop up.
On the "Performance Options" Window select the "Advanced" tab... and then click on the button "Change" under the "Virtual memory" section, this will popup the "Virtual Memory" window.
Under the "Virtual Memory" window, in section "Paging file size for selected drive" make sure the option "System managed size" is selected and press the button "set" (if enabled).
Press "OK" buttons to close all the opened windows.
Note: The name of the windows/buttons might vary in your language.
Answer: I am using Firefox and I have 22 websites in my Tab now and I don't face this issue. May be you are temporarily out of cache memory . You may make your IE Pages Work offline and Refresh them When you need them. so that they take less time and resource when you start your IE. Additionally this kind of Windows behavior is seen when you have less space in Windows installed drive. Make sure you have enough space in Windows drive.


Providing multiple shapefiles belonging together in single file with predefined symbology in ArcGIS Desktop?

Question: There are multiple shapefiles which belong together and should be provided in a single file with predefined symbology (see figure). Is there an option to do so? Currently, the shapefiles are bundled in a geodatabase file (red box in figure). However, it seems to be impossible to define a symbology in a geodatabase file. Another option is to produce a layer file (.lyr) which then holds a link between the shapefiles and the desired symbology. The drawback then is, that many files (shapefiles, layer file) have to be kept together.
Comment: Have you tried a layer package? http://desktop.arcgis.com/en/arcmap/10.3/map/working-with-layers/saving-layers-and-layer-packages.htm
Comment: If you look at a "geodatabase file" in Windows Explorer you will see it is really a folder of many files, almost all of which have arcane names.  You could put all your shapefiles in a folder if you wanted to keep them together.  The layer file can be kept anywhere; it points to either those shapefiles or the geodatabase feature classes, as well as supplying the symbology.
Comment: @smiller: please write your comment as a full answer so I can mark it as best answer.
Answer: Create a layer package to share the data and symbolization.
Per Esri documentation:

A layer can be saved with its data as a layer package (.lpk). A layer
  package includes both the layer properties and the dataset referenced
  by the layer. With a layer package, you can save and share everything
  about the layer—its symbolization, labeling, field properties, and the
  data.
Other users will be able to add layer packages directly into their
  maps without having to know how to access the database or classify the
  data. Layer packages can be created in ArcMap, ArcGlobe, and ArcScene
  and can be shared between these applications, including ArcGIS
  Explorer. When using ArcGlobe or ArcScene, 3D properties can be added
  to a map layer and included in a layer package.
While a layer package will be larger in size than a layer file
  (because it includes the data), your users will not need to worry
  about access to your same data sources.

To start the process, Right-click the layer and select Create Layer Package. The Layer Package dialog box will appear.
Answer: You can save your symbology within the geodatbase using representation. This way you can also have many different styles for the same layer without handling many .lyr files or layer packages. Just right click your layer (in table of contents) with your symbology and hit "convert symbology to representation" - and then choose a name. You can later on switch the styles from your symbology-tab. Only works in databases and it will not work with basic license level.


What does the Status column specify in the MobileConnect Demographics and MobilePush Demographics

Question: What does the Status column specify in the MobileConnect Demographics and MobilePush Demographics? I want to build a custom preference management for SMS and Push and for that if some one opts out I want to update the status attribute of the Demographics tables accordingly. How are these tables accessible? Are the "_MobileAddress" and "_PushAddress" data extensions that are accessible via Ampscript/SQL same as the demographics table?
Answer: _MobileAddress._Status

1 = active
-1 = unspecified
2 = bounced
3 = held
4 = unsubscribed

_MobileSubscription._OptOutStatusID

0 = opted-in
1 = opted-out

_MobileSubscription._OptInStatusID

0 = opted-out
1 =  Opt-In Pending
2 = opted-in

Yes _MobileAddress and _PushAddress data views are available via SQL queries
There is API available to update the mobile connect subscription status.
Refer here  You need to send a MO message to you shortcode or long code with the message parameter containing the stop keyword. This will then update the _MobileSubscription data view status columns
There might be similar API for mobile push unsubscribe as well.
Comment: Thanks for the answer...I found the following Ampscript is actually updating : UpdateData('_MobileAddress',1,'_MobileNumber', '91xxxxxxxxxx','_Status',0). Also, what does the status column signify in Mobile Address when we have separate _OptInStatusID/_OptOutStatusID attributes in mobile subscription. Is it some sort of global/master/account level subscription status?
Comment: Also, are these officially documented anywhere?
Comment: @androemedaandroemeda, the _OptInStatusID/_OptOutStatusID attributes at Mobile subscription provides you the opt in and opt out status for each keyword of a long code or short code and the status column in Mobile Address seems to be more like global/master/account-level subscription status. MobileConnect changes the status of a mobile number to held when two messages bounce more than 30 days apart with no successful message delivery in between.
Comment: @androemedaandroemeda No, I didn't find any official documentation for this. I found some of this information from this post https://salesforce.stackexchange.com/questions/36287/accessing-mobileaddress-and-mobilesubscription-data-extensions
Comment: Hey @androemedaandroemeda - hope you were able to achieve the mobileconnect unsubscribe. I have the same requirement and when I use the AMPScript - UpdateData('_MobileAddress',1,'_MobileNumber', '91xxxxxxxxxx','_Status',4), the Subscriber status in my mobile demographics shows as 4. I had expected it to show as the word "Unsubscribed". Does it happen for you as well ? Is the contact actually unsubscribed with the 4 value?
Comment: Hi @Vic, yes for me also it shows 4 instead of 'Unsubscribed'. But whether the contact is actually unsubscribed is not documented anywhere
Comment: @androemedaandroemeda same here, you found any concrete answer to that?
Answer: To answer your question about status, refer to https://help.salesforce.com/articleView?id=sf.mc_as_data_view_sms_subscription_log.htm&type=5.  The opt status values are applicable for both SMS and Push:
OptInStatusID Key

NotOptedIn = 0
OptInPending = 1
OptedIn = 2
DeletingNotOptedIn = 10
DeletingOptInPending = 11
DeletingOptedIn = 12


How accurate is the Sudarsky Scale today?

Question: How accurate is the Sudarsky scale of gas-giant classification today? Do the different classes still exist, and look roughly the same?
Comment: Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking.
Answer: The paper Sudarsky et al., 2003, which the wikipedia article is based on, is probably outdated by now in two important aspects.
1.) They used equilibrium chemistry i.e. a local theory of perfect, uniform mixing in the entire atmosphere and infinitely fast chemistry. This has been by now realized to be important to correct (e.g. Cooper&Showman 2006 or Tsai et al. 2017) and leads to different behaviour in the spectrum of a planet.
2.) The line-lists they used were inaccurate for many molecules for hot worlds (see e.g. Tennyson & Yurchenko 2017), particularly in the infrared. This would mainly be leading to different computations of the P-T profile primarily, but that of course impacts the emission spectrum and hence the 'Sudarsky class'.
While those effects are impactful, I am not aware of any paper that systematically tried to redo the classification work from 2003, hence we don't know how impactful they would be overall.
Comment: Class-3 seems right at least, judging by that one exoplanet whose colour we know: https://exoplanets.nasa.gov/resources/139/nasas-hubble-finds-a-true-blue-planet/


Short story about vampire hunting in a virtual reality game

Question: This short story centers around a virtual reality type game in which the protagonists are hunting a vampire in a medieval setting. The game doesn't go well for most of the story, but the protagonists win after the noob character shoots the vampire with a silver dagger fired from his crossbow. I believe also that the vampire ended up being the jester type character who had joined their party early on.
Comment: Any recollection of when you read this, or where (a magazine, a collection of stories in a book, etc) would be very helpful.
Answer: Could it be "Werewolves of Luna" by R. Garcia Y. Robertson? The story features a group of people and one alien in a virtual reality game where they have to steal a ruby from a vampire's castle. I don't have my copy at hand, but I remember it was a very convoluted plot, beginning with the main character stranded on the moon running out of oxygen and being drafted into the game, and one player is a doglike alien that insists on playing as a werewolf (hence the title).
It was collected in "The Moon Maid and Other Fantastic Adventures" (1998, ISBN 0965590186) and first published in Asimov's Science Fiction in 1994.


is it possible for an attacker to change a csr in x509?

Question: Is it possible for an attacker to forge a certificate signing request so he will be able to impersonate someone else  ? (by stealing the csr before it gets signed and changing it)
Answer: Imagine someone evil is eavesdropping on your communication in the exact moment that you submit the CSR to the CA (signer):
The attacker will attempt to impersonate on you by submitting the CSR and obtaining a certificate for your site. However, the signing entity will perform additional identity checks to assure that you own the site specified on the CSR (i.e: contact by email, challenge-password, upload x file ...). Then the attacker should control more than just the obtained CSR.
Note that the CSR carries a digital signature of the certificate request information, so the attacker can't just embed Google's public key, since it can't create valid signatures, thus CA will know that the public key owner isn't the requester.
Comment: *"...and creating private key plus certificate and sending both to the entity"* You will never send your private key to nobody. Also you don't create the certificate, the entity does it signing your CSR and returning the certificate. In the case someone has your private key then he can impersonate on you, plus breaking key exchange
Comment: This is not a common procedure since if you as CA generate CSR and private keys for the users, then you will be able to impersonate anyone (if you store the private key). As a CA the best way to assure that the CSR comed from that client is by challenging. Then you know that CSR's pubkey is valid.
Comment: i see, so it does not matter whether I send a csr to the rootCa and receive a certificate and creating private key plus  certificate and sending them both to the entity.
Comment: I understand, lets assume that in my company, I have a CA which signs on certificates in the company (of the company's computers). Are there any disadvantages against creating the csr, private key and certificate in the CA and  then sending it to the requester (lets assume there is no private key compromise threat)? Is it possible to create the csr in the issuer itself (given the private key)?


What is the most detailed living-tissue scan available

Question: There are a lot of ways to scan living tissue. What is the most detailed one to date? What kinds of resolutions can it produce? Is there a different answer for 2D vs 3D?
Answer: I assume you are asking what is the most high-resolution in vivo imaging that science has performed to date?
I think the best way to answer such questions is to explain the nature of the question.
This depends a lot on what kind of sample you are interested in for the question to address. It also depends on whether we are talking about time (temporal) or space (spatial) resolution, because there is usually a trade-off for imaging methods. Some things we can image with femtosecond resolution, and other things we can with femtometer precision.
What property do you want to look at? Is it a certain staining, such as a fluorescent marker? The topography of a molecule sitting on a membrane? The force generated by a motor protein?
Do you consider a reconstructed image (in 3D) from 2D slices to be a fair comparison with techniques that aim to directly image in 3D? Microscopy and imaging are quite advanced fields and we're only beginning to scratch the surface.
Some more considerations for the questioner: is your sample moving? Are we talking about imaging insects hovering near flowers, or anesthetized flatworms? What scale of the sample is being imaged? What are the requirements for keeping it alive during imaging? For instance, perfusing nutrients or imaging a microbe growing on a substrate normally requires the modification of your microscope in such a way that may limit your optical resolution. Imaging some things necessarily requires long working distance objectives, while other specimen may be visualized at short working distances. These have tremendous impact on resolution!
As a case study: let's say we are interested in looking at the human brain with high resolution. You can do this with high temporal resolution (using EEG) or with high spatial resolution using magnetic resonance! Or are you interested in the resolution of real time activity of the brain, as measured via oxygen delivery to regions? This is not possible with either of the above; you have to rely on functional imaging, e.g. fMRI!
Comment: Whew. That is a lot more complex than I had thought. I think you have given me enough info to construct a much better question, though. I may open another one here or perhaps take this over to Quora, since my inquiry may be a bit loose for stack.
Comment: Also please know I was a little pendantic in my response, I was hoping others would cover the basics. My two cents: live imaging of cells can go down to single-molecule resolution, if it's a fluorophore. Here's a [review](https://iopscience.iop.org/article/10.1088/2050-6120/4/2/022004/meta) for single-molecule imaging methods in neurons. You have stuff like atomic force microscopy which are also feasible for living tissues. Notice that the 'best' spatial resolutions are achieved with electron microscopy and x-crystallography, but these are not performed on living specimen. Good luck! :-)


How to manage frequently modified production code?

Question: My project invovles me to make a lot of changes on the production code. The requirement keeps coming up and I need to make changes and deploy it as soon as possible. I sometimes end up creating patch work sort of code because some of the requirement would not fit into the overall design of the software. How can this be handled effectively? Any design pattern to handle this?
Comment: Frequently modified production code?!?! DEAR GOD NOOOOOOO!
Comment: There is always other options...
Answer: I've seen this happen many times and it always ends in tears. The last time the customer lost millions of dollars before they improved their process.
Users always want new requirements to be made available "as soon as possible," but they do not understand the risks of making the changes in the same way that you do. They see the cost of not having the feature but they don't anticipate what would happen and how much money would be lost if the change breaks something. (I don't mean to suggest that you're not a good developer, just that in any non-trivial software there will be bugs and that uncontrolled changes are likely to expose them more quickly.)
So, I think you need to take a step back and try to instigate a regular release schedule. There will be resistance but you can be more effective that way. Of course sometimes there will be a change that needs to be made immediately, but if there's a schedule then the onus will be on the user to justify why breaking the release cycle makes sense.
Oh, and as everyone else suggests, you need technical infrastructure like a staging/testing system, one-click release procedure, etc. (See The Joel Test.)
Comment: I totally Agree with you Stephen Darlington, but there are times products meet unexpected situation when they get released, and they need to be fixed fast. Say think about any OS on the market. They follow major releasing but there will always be a need for hot-fixes because its too critical
Comment: @Robert Gould, I'm not sure if you read his whole post but he states that there are times when you might have to release immediately. "Of course sometimes there will be a change that needs to be made immediately"
Comment: @Robert There is absolutely a place for hot-fixes. However these should be very much the exception. You need to make a concious decision to apply one; it should not be the default option.
Answer: Testing, you need a solid testing framework to be sure your fixes don't break anything else.
Edit: Answer to comment's question.
Unfortunately I can't think of a truly sound pattern/solution to keep the architecture intact besides taking your time to refactor the "hacks". But you probably have little time to spare since your in production already. So it's not easy...
However more importantly if the architecture is getting spoiled because you really need to "hack" the solution in, this might actually be a sign that the original design wasn't meeting the product's actual requirements, because if it was, you should be able to fix/patch within the Architecture's current framework.
So trying to be positive about the whole situation you should take note of your fixes, and how the current Architecture isn't helping/complying, so you can later down the road, when the hot-fixes begin to settle, have data and hints as to redesign whatever parts of the Architecture necessitate design now that you have the more accurate requirements you discovered during production.
Comment: Thanks for that suggestion! I am worried about one more thing. I am actually spoiling the whole architecture modifying the code regularly.  Any suggestion regarding that?
Comment: +1: If the change "breaks" the architecture, then usually the architecture wasn't right to begin with.  Rarely does the architecture break because the change is a toweringly bad idea.
Comment: Yeah, I think I need to take a re look at the architecture. I should be taking note of the fixes and try to redesign it down the road. Thanks for the suggestion!
Comment: @Robert - " ... begin to settle, have data and hints as to redesign whatever parts of the Architecture ...".  This can be dangerous, especially if business aren't aware that you're doing this.  In this case, unless you have a safety net of regression tests, you're on a hiding to nothing.
Comment: @Eric that's actually true, one has to ALSO be careful of not breaking bussiness backwards compatibility!
Answer: Everybody here has suggested pretty good things, like testing, etc.  But I think I should point out that you may be asking the wrong question.  You are asking if there's a "pattern" that can help with this situation.  A pattern is a design choice to solve design problems.  What you essentially have is a "process" problem.
I would ask "What process can I use to prevent this?"
Unfortunately, (and it is the same where I work) design is an issue for developers and architects, but process is an issue for managers.  And it really takes leadership to implement good process, and stick to it.  Sadly that is often lacking.
Answer: The may be too basic of an answer, but I think you should do some research on agile software development.
Answer: I'm in the lucky position where my HEAD is almost always releasable. At least once a week, I have code in HEAD that, as a developer, I would be happy to release. That doesn't mean that every releasable version actually gets a release, but it could. In my environment, a weekly release is actually quite practical, and usually gets made...
Immediately before deploying to staging, I promote my code to a Release branch. I always deploy the same code to live that has previously been tested on staging.
Any urgent fixes can then be made in the release branch and tested on Staging, before being deployed. If the fix is good enough, I can merge it back into HEAD. If it was a horrible hack, I can re-implement it properly in HEAD later.
I have a good suite of developer tests that are run automatically on every check-in, which confirm I haven't broken anything important. My application also runs internal tests every time it is deployed, again making me confident.
Actually, luck is less a factor than you might think. This didn't just happen by accident; I had to work to make it possible. I had to commit to writing and maintaining good automated tests, and to getting a continuous integration server and a one-click build-and-deploy capability.
I regularly spend time cleaning up my code, as part of my normal development activities. This has two benefits. First, it means that my code base starts out relatively clean, so the architecture is pretty flexible. Second, it means I'm good at refactoring, since I do it all the time. By this, I mean refactoring in the sense of making a series of individually small transformations to existing code, rather than in the throw-it-all-away-and-re-implement sense (which is somewhat more dangerous).
In my opinion, this "continuous releasability" is the single biggest benefit of Agile methodologies.
Answer: Besides the obvious answers of revision control, unit tests, and an automated build system, it sounds like you also need to do some heavy refactoring.  If your design keeps changing based on changing requirements then you should try to isolate the parts of your code that keep changing in their own modules.
Answer: You need to impose discipline on your requirements backlog.  At the risk of sounding old school and crotchety, tell people no and that they need to sit with you and learn the specific points of pain and effort for drastic design changes.  For databases, explain about cardinality and how this causes heartache.  Throw your hay against the cage and insist on a scheduled release cycle when you will only role into production every Tuesday, but only after user acceptance has take place.  Break each request into segments of 2,4 and 8 weeks and be rigid about what you will include in those time frames.
There are many design patterns that can help you if you have a defined domain of problems and their solutions.  Specifically review the Command Pattern, the Strategy Pattern, and Plug-in architecture, as they will help you extend your solution set more easily.  If you are .Net developer, take a look at Migeul Castro's plugin architecture he reviewed on DNRTV.
Comment: Which doesn't help when the app just isn't working in a critical way, and leaving it until Tuesday after next will cost millions of dollars.
Answer: There are several project lifecycles that you can pattern your approach against. This site lists a few (it sounds like you're using the "Code-And-Fix" one!), but this is by no means a definitive list, a larger list can be found here.
Answer: As Robert Gould pointed out, you really need to have a staging platform to check that you're not going to break anything when deploying to live.
Answer: two obvious tools are version control and testing.  try to integrate the release system with them, so you can commit your changes at every step, and when all tests pass (including those for the new requirements), the release system picks the 'known good' version, that will be the new one.
i don't know about other systems, but monotone has some hooks specifically to make the tests tag the commits, so there's a command to "give me the last version that passes all tests"
Answer: Obviously, testing is important. But for me automation is even more. You should be able to deploy the whole project from the source control to the production server in less than 3 commands. Tools like Maven, Ant, Capistrano, (insert your favorite tool here <...>) can help you a lot. Having a continuous integration system that deploy automagically to a test or integration server every time there is a change in source control can also help.
Putting all that automation in place will take time the first time you do it ...
Answer: This is a process thing, not a design thing.
The first thing you need to do is educate your users so they have some idea of the cost of changing requirements.  This isn't intended to stop them from changing them, but to avoid changing them and requesting implementation ASAP unless there's a definite business need.  (I assume this is a business thing, in which case it's your job to do what the business needs to the best of your ability, and to let people know what the best of your ability is, and what functionality costs in the overall scheme of things.)
The second thing is to establish a two-fix process for fast fixes.  First, you get the patch in place to keep the app running more or less satisfactorily, and then you take some time and come up with the real fix.  This may also require some user education, and you may find the idea of "technical debt" useful in explaining this.
The third thing is to make sure you have the resources.  If you can't keep up with requirements changes like this, you need help, and you need to show why.  If the powers that be decide not to bring in more people, and they understand that limits the amount of modification, that's good too.
Now, it may happen that your users are unteachable, that you can't convince people that quick fixes are very expensive in the long run, and so on.  In that case, I recommend the fourth thing:  polish your resume and start looking for a new job.  Right now, it looks like you're being set up to fail, and that's a very bad place to be.  As the old saying goes, change your job or change your job.


Why do different browsers return different search results at Google and how can I prevent it?

Question: I am running some websites and am constantly checking keywords' rankings on google.com. And it is really important for us to see the organic search result without logging in or setting a specific location. Since this morning my colleague and I have checked the same ranking on both IE and firefox, the result surprisingly is very different (it almost feel like IE was logged in because the ranking is much higher, while in reality it is not). I have changed computer and the same problem occurred. It did not happen before. Can anyone tell me why is it?
Comment: maybe Matt Cutts can ... https://plus.google.com/109412257237874861202/posts
Answer: If Google has any tracking associated with the browser you are using, you can clear it by removing any cookies in each browser.  Without cookies, there is nothing to connect your search session with any previous session.
The chances of Google presenting differing results based on browser user-agent seem fairly low, but you can test this by using a user-agent switcher extension in Firefox.
The other thing to check is the locale information each browser presents to websites.  If one is en_US and one is en_GB for example, this will skew the results.
Comment: +1, though rather than repeatedly nuking your cookies/login session, you might be able to accomplish this more easily by switching into your browser's privacy mode.
Comment: @Su' yeah, good point
Comment: As Su' said Chrome, Safari, and FireFox all have a private browsing features which you can switch to quickly. They do not use cookies so you should see similar results across all browsers. Like @Paul said it's probably displaying personal results even if you're not logged into Google it can display results based on previous searches and click thru's
Answer: In my experience there isn't much you can do. Google uses so many pieces of data from different places that it's virtually impossible to remove personalization. Looking at my own stats from sites I manage people who use different browsers often have different behaviors, I have no proof Google personalizes strictly on browser type but it wouldn't surprise me.
Comment: completely agree.
Answer: Google by default tracks web searched and clicked results if you are not logged in.  The only way to see the true results is to be logged in and opt out of web history.  You can opt out of web history under account settings.
Comment: Thanks a lot, for my company account, I do not seem to have this option. So assume it is originally turned off. From personal account, on top of the web history, we also need to turn of the personal results I guess.
Answer: Use the following search pattern, this is remove the personalization to some extent
http://www.google.com/search?&q=keyword&pws=0
For example if I am have to search micromax tablet, then I will write it as
http://www.google.com/search?&q=micromax+tablet&pws=0
Answer: Its basically customisation, there are three main things that it goes on

Web history
Location
Email account

I created a video for my customers in the UK with more details on how to do this so they can follow their seo campaigns.
Answer: This is an example of how tracking rankings will drive you crazy. It is better to use traffic as a performance indicator. When you do need to track rankings, use the Google-provided tools in Analytics or WMT.
Answer: There are a few ways to attempt to de-personalize results, some of which are listed here by SEOmoz. The basic methods are:

Not logging in to Google
Minimizing "historical" factors by using any privacy/"incognito" modes the browser may have or clearing browser to defaults
Appending the pws=0 parameter to your searches

Note, however, that these and other methods often become less effective over time. Google customizes results as it sees fit.
Answer: Its not only browsers, but devices as well. Such as the use of Google Mobile for smartphones where mobile sites will be featured more prominently versus desktop sites and vice versa.
You can only prevent this on your own site, such as some sites will force the user to go to their mobile site, when viewing on a smartphone.
Its nearly impossible to get the same results every time, even using the same browser, because sites are changing all the time.
Answer: This is an undocumented feature but I think each browser uses a differant cash. Once your search results stabalises they seem to conquer over time.
Comment: Each browser does indeed have a its own _cache_, but this is not what causes different search results between browsers.


How to fix Non-Manifold elements?

Question:
I've made a High to Low poly model, and after using the ctrl+alt+shift+m command to find non-manifold elements, I've found several as shown in the .png which is edges and vertexes across the model as well as the uv wrapping. How do I fix these non-manifold elements? I appreciate anybody's time and effort in helping solve this issue!
Answer: As far as fixing nonmanifold issues are concerned, you don't need to worry about the UV unwrapping at all (except for possibly having to unwrap it again when you change your vertices around).
The problem you have in the middle probably happened after you applied your mirror modifier, but it's an easy fix. Make sure just that section is selected, then scale it to 0 on the x axis. LEAVE IT SELECTED. Next you're going to go to your search bar (space in 2.79) and start typing in 'remove'. A few options should pop up, but what you want is remove doubles. You can also access it from the 'W' menu, but sometimes it just doesn't show up for me, so that's an alternative method.
Your other manifold problem looks like you might have internal faces. To check, go to face mode and see if you see any of those floating dots inside your model. If you do, move back into edge select and only select the edges on the inside (so you won't make holes in your model) and delete them.
I hope this helps!
Answer: Okay, so upon troubleshooting the mesh, my actual underlying issue was to essentially make the mesh workable with a third party program called Quixel Suite 2. However, UV errors led me to believe the non-manifold elements in the mesh was the issue. It turns out that wasn't the issue, so I no longer need to necessarily worry about them as of now.
But, I do want to clarify how I solved the non-manifold errors anyway for anyone else who may have similar problems. I used the retopo-flow addon and a symmetry/mirror modifier for the x-axis, and then I created one side of the mesh which was completed with said modifier.
I simply applied by clicking "apply" for the mirror modifier and that solved the large central manifold line visible in the image above. That contained most of the non-manifold elements.
There were no doubles as there were 0 vertexes deleted after doing as suggested.
There was only one non-manifold element that remained (I guess two if you count the mirroring modifier), which, with elucidation from your post, turned out to not be a internal face, but a hidden edge. Close enough. That'd be the line visible in the image which is the singular yellow line above the mesh's thighs.
Lastly, I installed the Meshlint addon, supposedly "Like Spell-checking for your Meshes", that searches for errors/things-to-note-carefully in a mesh such as the non-manifold elements that plagued mine, tris, n-gons, etc. That should help catch the problem before it begins next time.
Thanks for your help, I hope that this post may help others who have similar issues.
Comment: I appreciate you sharing your solution. Are these addons available directly in Blender, or are they downloaded separately?
Comment: I believe both addons need to be downloaded separately. Here's the link to Retopo-flow, which is time-saving for retopology. [link](https://github.com/CGCookie/retopoflow). And the link to Meshlint [link](https://github.com/rking/meshlint) Both are free full versions. Retopo-flow's retail allows you to get customer support for it, though.

How to fix Non-Manifold elements?


Why value-types are stored onto Stacks?

Question: Why does C# (.Net) prefer stack to store value types? What is the primary reason behind this design? Is it because read/write operations to the stack take better advantage of the machine processor?
Also, maybe you can justify why not others?
Answer: Eric Lippert discusses this here; firstly, it is incorrect that "value types are stored on the stack". They sometimes are, but not as:

fields on a class
captured variables
variables in an iterator block

When they can be stored on the stack it is a convenient way of modelling their lifetime, but it isn't required to store them on the stack. You could write a compiler+CLI that doesn't have a stack, for example.
Comment: https://learn.microsoft.com/en-us/archive/blogs/ericlippert/the-stack-is-an-implementation-detail-part-one updated link
Comment: The article in the link above is brilliant, why doesn't it have more upvotes?
Answer: C# doesn't store anything on the stack. C# is a programming language. Therefore, a more correct version of your question is why does the Microsoft C# compiler emit CIL instructions to allocate value types on the stack?
Well, first, it only does sometimes. The following do not go on the stack:

Value types that are fields in a class
Boxed value types
Local value types that are outer variables of anonymous methods
Local value types that are outer variables of iterator blocks

Second, when it's possible it's done because it's efficient. Basically in the CLR memory model, on the stack deallocation is very cheap relative compared to deallocation on the heap. With locals of value types, you can be sure that no one else except the local will reference the memory so you can get away with using the stack instead of the heap. For details, see Eric Lippert.
Finally, what makes value types special is that they have value-type semantics (copy by value), not that they are sometimes allocated on the stack. There is no requirement in the C# specification that the compiler emit instructions to allocate value types on the stack. What the C# specification does require is that value-types have value-type semantics.
Answer: As @Akash indicates, it mostly has to do with memory. During the design of the CLR, it was noted (my guess was from the experience with Java) that representing small, primitive types as objects with handles subjected to the garbage collector caused a lot of tracking overhead. So the designers wanted a "lightweight" object which didn't need to be tracked.
There is no specific requirement in the CLI specification for primitives to be stack allocated; it's an artifact of the implementation on the machine. The essential bit is that the runtime knows where the instances are due to the construction of well-defined patterns of memory (called frames) rather than in the GC's index of allocated objects. On x86 (and similar) machines, this can be done efficiently using the stack.
Answer: Your statement isn't totally true. A better version: C# stores local variables on the stack.
And this isn't special or new, (almost) all programming languages use the stack for local variables and method return addresses. There is support for this down to the hardware.
Furthermore, Valuetypes can be local variables or fields inside reference types. So valuetypes are not always stored on the stack. A more helpful statement: referencetypes are never stored on the stack.
So don't focus on the stack too muuch, it's an implementation detail. Learn about value- and reference-types.
Answer: Stack operation or Heap operation, they both will be same as you are accessing a memory address which are in two different locations.
Value types are small, int, byte etc, they are small in size and they are referenced very frequently in terms of mathematical computations. Since they are very small in size, 4 to 16 bytes max, (you should not use more then 16 bytes in value type for best performance), alloating such small space on heap and deallocating, garbage collection etc would be very costly.
Every method we enter, on an average we define 10 local value types to use it internally, that will be very costly on heap as reference types.
Stack can grow and shrink easily (not the stack size, but the stack portion used for current Method !!) as the valuetypes are just addressed as offset from stack pointer, and their allocation and deallocation is easy as its simple increment and decrememnt on stackpointer by total size of all valuetypes used.
Where else in reference type, each reference object has its own allocation and sizing, plus CLR has to maintain table of objects which is sort of like index of actual pointers in memory in order to avoid buffer overflows. So one object you use (reference type) actually has two storage, one index entry in CLR's reference table, and actual memory space. Thats why its easy and fast to store value types on stack.
Comment: The stack size can't really grow or shrink once it is set for a thread. Instead, the stack pointer is moved up or down depending on what is present on the stack.

Also, boxing isn't what you describe. Boxing is taking a value type and allocating a handle on the GC heap. This can cause a collection and so on average it is not cheap. Unboxing is faster since it copies the value on the heap to the stack without a memory alloc or any GC pressure added.
Comment: I have clarified, ofcourse stack size doesnt grow or shrink but the part of stack portion used for current method's utilization, which is size of all local variables can grow or shrink. Because this stack is not pure stack it has some reserved spaces for current method.
Answer: For proper program operation, it is important that both value-type and class-type entities outlive any references to them.  When a class-type object is created, a reference is created which may be freely copied into any scope.  Consequently, it's entirely possible that references to the object will continue to exist even after the present scope exits.  By contrast, when a value-type variable is created, the only references that can be created are of a short-lived type that will disappear before the current scope exits.  The fact that no reference can exist to a value-type variable when the present scope exits makes it safe to store such variables on a stack.

Why value-types are stored onto Stacks?


Build replication from backup not publication source

Question: I have an interesting scenario I am trying to find a solution to.
We currently have the current setup.
ProductionDatabase (publisher) is the publication for transnational replication to the following:
  WarehouseDatabase (subscriber)
  NewWarehouseDatabase (subscriber)
My issue is that WarehouseDatabase has had triggers and other SP's added to it.  When I build replication for NewWarehouseDatabase I built it from a backup of ProductionDatabase.  So NewWarehouseDatabase does not have the triggers or SP's that had been added to WarehouseDatabase.
Doing a SQL Compare generated a list that had a lot more things displayed than I really want to manage.
So I thought I can build replication by backing up WarehouseDatabase and restoring to NewWarehouseDatabase and then enabling replication from ProductionDatabase.  Then I thought that will not work as the LSN and other internals that might not sync up for replication to work.
I am wondering if anyone can suggest how I can accomplish this, if you can understand my babbling...
Regards,
GarryB
Answer: If I understand you question correctly you could use a schema compare tool to generate a script that would be used to insert the extra SPs and triggers into the new datawarehouse DB.
Redgate have a tool like this in their DBA bundle and I think data and schema compare are now functionalities of visual studio.
Answer: When I need to do something like this, I just use sys.objects. After you restore the NewWarehouseDatabase databse, create a Linked Server on the instance where you have WarehouseDatabase to point to the instance where you have the NewWarehouseDatabase databse. Then write an EXCEPT query using sys.objects. Something like this:
<code>select o.name, s.name
from WarehouseDatabase.sys.objects o
inner join WarehouseDatabase.sys.schemas s on s.schema_id = o.schema_id
where o.type in ('List the types you're interested in')
except
select o.name, s.name
from <LINKEDSERVER>.NewWarehouseDatabase.sys.objects o
inner join <LINKEDSERVER>.NewWarehouseDatabase.sys.schemas s on s.schema_id = o.schema_id
where o.type in ('List the types you're interested in')
</code>
This should give you a list of the objects that are in the WarehouseDatabase databse but not in the NewWarehouseDatabase database.


Beginning MySQL/Python

Question: I have just begun learning Python. Eventually I will learn Django, as my goal is to able to do web development (video sharing/social networking). At which point should I begin learning MySQL? Do I need to know it before I even begin Django? If so, how much should I look to know before diving into Django? Thank you.
Comment: I started learning Python by learning Django, Although I already had the basics of a few languages under my belt. What I'm saying is that learning python first then Django really doesn't matter and learning to program (well) is much more important.
Answer: Having some ideas of what's going on in ANY database will help you with your web programming endeavours.  You're best bet is to spend some time learning basic SQL just using SQLite (it comes with python) and moving what's known as an ORM (Object Relational Mapper) such as SQLAlchemy
The current trends point towards most web based application using some form of ORM between their application and the database.  The ORM provides a level of abstraction so you don't have to know specific details of how the database works, the ORM handles it for you.   The benefit of this is that you can change databases without having any major impact.
You DO however want to build a foundation in basic SQL statements.  SELECT, INSERT, WHERE, etc.    I've pointed many people to sqlzoo's tutorial as it's excellent.
http://sqlzoo.net/
Comment: He's a beginner. I'm intermediate and I barely know what you are talking about.
Comment: @Mark there is plenty sense in learning, 2 or even 3 orm's.  One main reason is that it's a pain to use django's orm outside of django. in this way SQLAlchemy or Storm are better choices, then there is project compatibility. Not every project/toolset uses django or sqlalchemy for webbased products.
Answer: Django uses its own ORM, so I guess it's not completely necessary to learn MySQL first, but I suspect it would help a fair bit to know what's going on behind the scenes, and it will help you think in the correct way to formulate your queries.
I would start learning MySQL (or any other SQL), after you've got a pretty good grip on Python, but probably before you start learning Django, or perhaps alongside. You won't need a thorough understanding of SQL. At least, not to get started.

Err... ORM/Object Relational Mapper, it hides/abstracts the complexities of SQL and lets you access your data through the simple objects/models you define in Python. For example, you might have a "Person" model with Name, Age, etc. That Name and Age could be stored and retrieved from the database transparently just be accessing the object, without having to write any SQL. (Just a simple .save() and .get())
Answer: I'll second Kurt's reply that it's a good idea to build a foundation in basic SQL.  That skill will come in handy whether you end up using MySQL, Access, Oracle, or another relational database.  My favorite SQL tutorial site is at http://www.1keydata.com/sql/sql.html.
Answer: As Django documents somehow Recommends, It is better to learning PostgreSQL.
PostgreSQL is working pretty with Django, I never had any problem with Django/PostgreSQL.
I all know is sometimes i have weird error when working with MySQL.

Beginning MySQL/Python


Is X-23 considered a mutant?

Question: After years of reading X-Men, I noticed something that I had originally missed: if X-23 was cloned using Wolverine's DNA, does this mean she is not technically a mutant? Or does the fact that she was born with these abilities contradict the cloning?
Answer: Yes, the Earth-616 version of Laura Kinney (aka "X-23") is classified as a mutant.
Laura Kinney was created using a corrupted sample of Wolverine's DNA. The sample was decades old and a few segments - including the Y chromosome - were unrecoverable. To create a viable sample, the DNA was augmented using that of Sarah Kinney, the project director. The resulting viable sample was the 23rd attempt, thus the X-23 designation for Laura. For the most part, she is considered a female duplicate of Wolverine, although there ARE some notable differences due to the process. For instance, she has a different claw configuration than her genetic "father".

In the Marvel universe, the term "mutant" refers to any individual of the Homo sapiens superior sub-species. Since Laura has the "mutant gene" in her genetic makeup - just like Wolverine - she is still classified as a mutant despite her origin as a clone.
Another example of this would be the Cuckoo sisters, who are classified as mutants despite being

 enhanced clones of Emma Frost.
Comment: @Howard8614 - when you get a chance, you can accept this answer by clicking the green check mark icon below its voting arrows. This lets others know that it answered the question to your satisfaction.
Comment: Awesome. The bit about X-23 sharing the same genetics as Wolverine was perfect, and I never knew about the Emma Frost/Cuckoo Sisters bit at the end.

Is X-23 considered a mutant?


Mechanism of three-membered lactone hydrolysis in base

Question: I was reading up on the participation of neighboring functional groups and in the reaction below, I was wondering why hydroxide attacks the C–O bond instead of the carbonyl group of the lactone. Lactones tend to be more electrophilic compared to acyclic esters, as the lone pairs on the ether oxygen are not positioned correctly to participate in conjugation, so I would expect hydroxide to attack the carbonyl. Does it have to do with the angle of attack, given the small ring?
Comment: Apparently Mother Nature has decided otherwise.
Comment: @Zhe: The use of O18 hydroxide may leave O18 in the carboxylate of lactic acid if there is any addition to the carbonyl of the alpha lactone.
Comment: One thing that you cannot rule out here based on the stereochemical outcome is that the hydroxide _does_ attack the carbonyl, but it is the preferred leaving group for stereoelectronic reasons, despite the ring strain. It would be an interesting exercise to devise a mechanistic experiment to test this claim.
Comment: "lone pairs on the ether oxygen are not positioned correctly to participate in conjugation" This statement is not true. Usually, the reactivity is ascribed to donation of the in-plane lone pair into the σ* orbital (or lack thereof for the lactone).
Answer: According to Organic Chemistry: Second Edition,[1, pg 934](from which I assume that the question was taken):

Enantiomerically pure (R)-2-bromopropanoic acid reacts with concentrated sodium hydroxide to give (S)-lactic acid. The reaction goes with inversion and is a typical SN2 reaction—and a good one too, since the reaction centre is adjacent to a carbonyl group. If, on the other hand, the reaction is run using $\ce{Ag2O}$ and a low concentration of sodium hydroxide, (R)-lactic acid is obtained — there is overall retention of stereochemistry.

Therefore this reaction that has been questioned takes place at a low concentration of $\ce{OH-}$ in the presence of $\ce{Ag2O}$.
How do we decide between competing mechanisms?
The next paragraph clearly outlines what we need to look for in order to proceed.

In the first, we have conditions suited to an SN2 reaction: a very good nucleophile ($\ce{OH-}$) and a good leaving group ($\ce{Br-}$). Improve the leaving group by adding $\ce{Ag+}$ ($\ce{Ag+}$ assists $\ce{Br-}$'s departure much as $\ce{H+}$ assists the departure of $\ce{OH-}$ by allowing it to leave as $\ce{H2O}$) and worsen the nucleophile ($\ce{H2O}$ instead of $\ce{OH-}$, of which there is now only a low concentration), and we have the sorts of conditions that would favour an SN1 reaction. The trouble is, without neighbouring group participation, the cation here would be rather unstable — right next to a carbonyl group. The carboxylate saves the day by participating in the departure of the $\ce{Br-}$ and forming the lactone. The key thing to remember is that a reaction always goes by the mechanism with the fastest rate.

From what I have understood the question lies in the step after the lactone is formed. What reacts, $\ce{C-1}$ or $\ce{C-2}$? Let's assume that both are possible and proceed with the two possible cases.
Firstly, the $\ce{OH-}$ attacks the carboxylic carbon($\ce{C-1}$). We get the possible reaction mechanism to be:

In the second case, let's assume that $\ce{OH-}$ attacks $\ce{C-2}$. The possible reaction mechanism would be:

So, now we are faced with the choice of which reaction could take place, attack on
$\ce{C-1}$ or attack on $\ce{C-2}$.
From the second quotation, we can say that if we are able to decide which is faster, that would be the reaction that takes place and so we reach our next question.
Which reaction is faster?
In pathway 1, we are talking about the base hydrolysis of esters. However, esters are not very reactive and the concentration of base in this case is low as well.
In pathway 2, we are talking about an SN2 reaction taking place on the $\ce{C-2}$ carbon which removes the ring strain that is seen in the lactone. Therefore, this would be faster than base hydrolysis that takes place at $\ce{C-1}$
Another way of checking the speed of the reaction would be to use the principle of least motion, (as pointed out by Yusuf Hassan).
According to Advances in Physical Organic Chemistry, the
principle of least motion is defined as:

The principle of least motion, states that those elementary reactions will be favored that involve the least change in atomic position and electronic configuration.

Using this, we can compare the relative rates of the two reactions.
During the base hydrolysis of esters, the hybridisation of the $\ce{C-1}$ carbon changes from $\mathrm{sp^2}$ to $\ce{sp^3}$. This leads to a big change in the atomic arrangements since you go from a trigonal planar configuration to a tetrahedral arrangement.
In case of the SN2 reaction on the $\ce{C-2}$ carbon, the configuration as a whole doesn't change. It remains $\mathrm{sp^3}$ throughout the reaction, so there is less rearrangement taking place.
This implies that according to the principle of least motion, the SN2 reaction is favoured over the the basic hydrolysis of the lactone formed via the anchimeric effect.
Hence, we can say that the reaction that would take place would be the attack on $\ce{C-2}$ and not the basic hydrolysis of the lactone.
Reference:

Organic Chemistry: Second Edition; Jonathan Clayden, Nick Greeves, Stuart Warren, 2014; ISBN 978-0198728719


Can I add unfaced insulation on top of faced insulation which is on top of cellulose?

Question: I want to roll out some additional fiberglass insulation in my attic.  Currently there is loose cellulose with faced fiberglass batts placed on top of the cellulose.  The facing is facing out as in the picture.  My question is, can i just roll the insulation out on top of this without a vapor issue or do i need to remove the facing (if that's even possible).  Thanks for you thoughts.
Comment: Location not established, where do you live? The answer depends on this.
Answer: The facing shouldn't be there in the first place.  The facing/vapor barrier should always be on the inside. ("Warm side")
Having the facing on the outside creates a moisture pocket - moisture that gets between the ceiling below and the facing above becomes trapped, and encourages rot and mold growth.
Remove the facing and then you can pile on more insulation to your hearts content.  Lay it perpendicular to the existing layer.
Comment: +1, the moisture can get in the insulation and travel to the cold side where it condenses or even freezes.
Comment: I've been told that it's sufficient to take a razor knife and cut large X cuts all along the barrier paper.  The theory being that moisture needs a relatively tight seal or it will normalize across both sides of the slashed barrier.  (Moisture seems to always find a way through when we want to seal it out, maybe that behavior works in our favor in this situation.)  I'm about to try it myself - any experience with this approach?
Comment: The facing side depends on where you live. In hot, humid climates like Florida, you will find the vapor barrier on the outside to prevent intrusion of warm, moist air into the insulation. In cold, dry climates, the vapor barrier will be on the inside because the moisture levels required for habitation need to be kept inside the house so they don't penetrate into and condense on the insulation. In cold, wet climates like Oregon west of the Cascades you just deal with it, moisture condenses on anything unheated, but the vapor barrier goes in the inside as well.
Comment: This is in the cold northeast
Comment: Then there should be no vapor barrier covering the external surfaces of the insulation as mentioned, only as a first layer next to the heated living space. And there is never to be any sandwiching of vapor barriers. I've had to deal with a reinsulation where faced insulation was applied over the top of other insulation. That second vapor barrier condenses water and dribbles it down into the bottom layer and wets the ceiling below. It amazingly didn't cause mold, but the plasterboard facing paper wasn't its nice dry gray color. It looked like wet newspaper, probably had the same strength.
Comment: If you can't get unbacked insulation, then yes I think this would effectively eliminate any effectiveness as a vapor barrier.


Can a 1950s floor furnace be removed from below (crawl space)?

Question: Recently demo-ed hallway desk revealed abandoned 1950s floor heater. Living room side had been patched over, hallway side has floor heater exposed. Is it possible to remove the furnace from below in the crawl space? Or will I need to rip out the living room side to get it out from above?
Comment: I believe this might be why the official name of the Sawzall is actually 'the problem solver'.
Comment: How would we know? Look, measure, think it through. No need to ask the internet.
Comment: "Floor furnace"? What's that? Is this an actual stand-alone heater or is it tied, somehow into the houses central HVAC? What's it made of? How far under that wall does it go? What's below it? Not nearly enough info here to be able to answer your question. Please [edit] with more details.
Answer: Given that the furnace is abandoned there's no need to remove it in an intact or functional condition! Feel free to disassemble it.
A quick way to partially collapse a furnace which has a side-entry air return and a blower compartment in the bottom is to remove the blower and then cut the furnace cabinet. Cut horizontally the entire side opposite the return, then cut out the "post" between the return opening and the front cover. The whole furnace will collapse down into itself. You can then put a sheet metal screw into each side to hold it that way so that it can be wrestled, hand trucked, lifted, dragged, etc without those bits of lower cabinet splaying out and catching on things (such as your calves! ouch!).
A more careful and complete disassembly is sometimes called for. Being as old as it is the heat exchanger may be quite heavy. You could remove every screw in sight until the burners, heat exchanger, and whatever else can be removed from the cabinet. This makes for more parts to handle but they're smaller and lighter and perhaps easier to extract from the crawlspace.
For cutting the furnace cabinet use whatever you have at hand. Tin snips work fine on the straight parts; a recip saw or angle grinder is much better for cutting the folded metal around the furnace doors. Even a hack saw will do.
Comment: Just make sure before starting demolition that the furnace has been completely safely disconnected from electrical power and any fuel connections (whether oil, natural gas, or propane).  It's possible they just turned it off without disconnecting anything.


Is it legal to install msttcorefonts package? Is Wine legal?

Question: I'd like to know whether it is legal to install the msttcorefonts package and also whether installing Windows software using Wine is also legal? I currently live in Brazil and I don't know what specific rules apply over here.
Comment: Only a lawyer specialized in brazilian copyright can give you 100% certainty ;)
Comment: and in some countries it would be illegal for non-lawyers to give you legal advice...
Comment: @xubuntix *This* is not legal advice for any country. But in most countries it would probably be illegal for non-lawyers to give you legal advice in the sense of *counseling you in the law*. So long as we are very clear that we're either not lawyers (like me, I'm not a lawyer) or that what we're saying isn't legal advice, most countries respect our right to express our opinions on political issues, like questions of how laws would be interpreted by courts. One must carefully navigate the line between one of the least protected forms of speech and one of the most, but the line is pretty bright.
Comment: Thanks for your comments. I understand the questions regarding law can vary based on where you are, so I guess asking a brazilian lawyer is a good advice for my particular case. Thanks!
Answer: msttcorefonts is considered globally legal for installation because the license for the fonts allow them to be installed and by omission, installed on non-Windows operating systems, without a Windows license.
In short: It's not a case of copyright law because Microsoft allows the redistribution of the font installers and it allows users to install the fonts (regardless of OS).
It does not allow for redistribution of the TTF font files on their own, so, for example, it would not allow for a distribution like Ubuntu to include them by default.
Sidebar: The newer (Vista-era) fonts like Consolas, Segoe, Cambria, Candara have explicit "only for Windows" junk in their licenses, but these fonts aren't included in msttcorefonts so that doesn't matter.

Wine is less black and white.

From a copyright stance, great effort seems to go into making sure that all of the Wine code is completely original (eg people who have seen Windows code are not allowed to contribute) and that helps to keep the copyright side of things fairly clean.
But technology wise, it's aim is essentially to redevelop the core of Windows. I'd be surprised if there weren't more than a couple of Microsoft patents it trod on. Microsoft has been filing patents for every other line of code for 20 years and the USPTO has been more than willing to grant them all sorts of silly, super-obvious patents.
Anyway, this shouldn't affect you directly (yet) because there hasn't been any legal action (AFAIK) and even if there were, it would be likely to happen in the US. I'm not a lawyer so I can't say how this would affect you either.

If you need a bullet-proof legal way to run a Windows application from within Ubuntu, virtualisation is probably the key. A real licensed copy of Windows running will do almost anything you want it to (with a performance hit).
Comment: @prubini87 Adobe probably does not *support* running Adobe Photoshop with Wine, but you should be able to do it. So long as it's properly licensed and not concurrently installed or running anywhere else (unless your license allows that), I doubt there would be any legal problem. http://appdb.winehq.org/ is a good resource to see what works with Wine and how to get stuff to work.
Comment: The unfortunate thing about software patents is that potentially any software could trod on them, and the more complex the software, the more likely this is to be the case. I don't think there's any strong reason to think that virtualization software (FOSS or proprietary) would be more free of patent violation than Wine, as companies that make virtualization software file for lots and lots of software patents. In any case, while this is not legal advice, I think that whether you use Wine or virtualize, you are probably not *personally* liable for a patent claim.
Comment: Thanks for the answer and for you comment @Eliah. This answer reinforces what I think is true about msttcorefonts, but I'll try to read the terms with extra care before I install it futurely - that is, in case I do. I own an Adobe Photoshop's license and I was wondering if I could run it under Linux, but besides the information you've provided about Wine, I'll try to contact Adobe regarding this matter. Thanks a lot!
Answer: I am not a lawyer, but generally speaking packages that are included in the official Ubuntu repositories are not encumbered by any copyright or patent restrictions that would make it a tort or crime to install. A number of useful packages are excluded from the official software sources because it would be unlawful for some users in some places to install them, due to such concerns. One example of such a package is libdvdcss2, which is provided in the unofficial Medibuntu repository. By enabling unofficial repositories and installing packages where you've been warned of possible copyright or patent issues, a user takes full responsibility for determining the legal status of their actions.
However, while msttcorefonts is provided in official Ubuntu software sources, is not free open source software. This package installs proprietary fonts copyrighted by Microsoft. When you install it, you are asked agree to Microsoft's terms of use for these fonts. You would probably incur civil liability if you installed this package and then engaged in acts covered by the copyright laws in your jurisdiction and prohibited by the terms of use.
Comment: I only see a `ttf-mscorefonts-installer` package which does not provide any licensed files, but just downloads them.
Comment: @Lekensteyn Good point. The packages that give Ubuntu users Microsoft-copyrighted fonts for use in Wine don't actually contain the fonts; rather they provide them to the user by downloading them during the installation process. It's the same kind of thing as the `flashplugin-installer` package for getting Adobe Flash.
Comment: Thanks for your answers, it clears out a few doubts I had. Thanks for the comments also - from what you said then, I can install both msttcorefonts and flashplugin-installer without infringing any copyright laws, but these packages can't come with Ubuntu by default, is that it @Eliah?
Comment: @prubini87 Well, like I said, I'm not a lawyer and this isn't legal advice. But yes, the `msttcorefonts`/`ttf-mscorefonts-installer` and `flashplugin-installer` packages exist to enable you to obtain software that the Ubuntu project would be legally restricted from hosting and distributing in some jurisdictions...without anybody breaking the law. These packages don't package the proprietary content with which they are associated, but instead automatically download it from authorized download sites to your computer. So long as you read and abide by any license agreements, you should be OK.
Comment: Another way to install Flash, which is officially endorsed by Adobe, is through the partner repository. You can search for `adobe-flashplugin` in the Software Center. The necessary software source will be enabled automatically if you install it. But you shouldn't have both `adobe-flashplugin` and `flashplugin-installer` installed at the same time.


Meson masses difference

Question: I am reading some group theory applied to QCD and they show how by using the lightest 3 quarks in the $l=0$ state we get 9 pseudoscalar mesons and 9 vector mesons. The difference in masses between the 2 classes is explained by the existence of a spin-spin interaction, which seems like a reasonable argument. However they don't say anything about the fact that the mass of the singlet in each case (the 9 mesons are grouped in an octet and a singlet) is significantly higher than the masses of the mesons in the octet. What is the reason for that? Thank you!
Comment: What does this have to do with muons? Was that a typo in your title?
Comment: It's complicated. The octet of pseudoscalars have smaller than normal mass, due to chiral symmetry breaking, but the singlet is exempt, as its symmetry is anomalous. For the vector mesons, *nobody* is a singlet: the singlet has mixed with the isosinglet octet member to yield two hybrid states, ω and  φ, whose masses reflect the $s\bar s$ content more than anything else.  There is a lot of misleading dross published in vector meson perorations...
Answer: The reason, why $\eta^{'}$ meson is significnatly heavier, that than the mesons in the octet is rather nontrivial and a interesting story, known as $\eta-\eta^{'}$ puzzle.
It is resolved by 't Hooft instanton mechanism https://journals.aps.org/prl/abstract/10.1103/PhysRevLett.37.8, whose $\frac{1}{N}$ realization is also known as the Witten–Veneziano mechanism http://cds.cern.ch/record/133349.
The mass of $\eta^{'}$ is so large due to the $U_A(1)$ axial anomaly.

Meson masses difference


Opening Water Bottle On Shabbath

Question: Can one open a water bottle with a plastic cap on Shabbath? Or would they be violating mechateich?
Comment: Has the water bottle been opened before?
Comment: Is the bottle cap plastic or metal? Due to the way caps are formed, plastic is easier to allow than metal
Answer: This is a very disputed topic. Parts of the machlokes are the understanding of all melachos involved (not only mechatech but also makkeh bepatish). One must also know how the bottle caps are created or if they look the same as they did when various achronim discussed the topic.
The  שמירת שבת כהלכתה פרק ט recommends opening all bottles and packages before shabbos to avoid any issues. He also bring rabbi shlomo Zaman Auerbach opinion that was more lenient (but nor a blanket heter).
See this article that goes into further depth https://din.org.il/2017/01/05/%D7%A4%D7%AA%D7%99%D7%97%D7%AA-%D7%91%D7%A7%D7%91%D7%95%D7%A7%D7%99%D7%9D-%D7%91%D7%A9%D7%91%D7%AA-7/

Opening Water Bottle On Shabbath


How to create square wave circuit

Question:
I wanted to create a square wave that alternates between positive and negative voltage with a full cycle time of 8ms and a 50% duty cycle. So is there a way I could make a circuit that takes in 0V and a voltage V_in (roughly in the voltage range of 1V-7V), and that outputs the square wave as well as the inverse of the square wave. The load I'm going to put on the signal is very minimal (below 10 mA).
Comment: How accurate do your duty cycle and frequency need to be? The solution will vary widely based on this information. Also will this need to run off of a battery or is power not a consideration?
Comment: Also, do you already have a negative supply or does this need to make one?
Comment: Would an H-bridge solution work for you? https://electronics.stackexchange.com/questions/278645/how-to-generate-a-bipolar-waveform-using-mosfet
Answer: You can do it with a dual opamp. The left opamp is a relaxation oscillator - can adjust the frequency with R1 - and the second opamp just inverts.
The AC-coupling at the outputs creates the bipolar output swing you wanted. The total output swing will be a volt or two less than Vin.

Here is a simulation, with Vin = 10V:

LATER
@Reinderien correctly pointed out this solution doesn't swing from Vin to -Vin. For that we need a voltage boost.
The following circuit will do that. It again uses an opamp for the relaxation oscillator: this should be a rail-to-rail type to get maximum voltage swing. The square wave feeds a cheap voltage inverter generating a negative voltage nearly equal to -Vin. A BAT54S does the two diodes in one cheap package. Dual comparator LM393 uses this negative voltage as a reference, the pullup resistor determines the high voltage.

And here is the simulation (using available opamp and comparator in the library but just use an LM393 and any rail-to-rail opamp).
Answer: A CD4047 IC has an RC oscillator, a divide by 2 stage making perfect 50% duty cycles and and direct and inverted outputs. Exactly what you need.
Comment: Are you sure that this is exactly what the OP needs? He is asking for a zero centered output waveform with a negative minimum.
Comment: @mmmm not on its own, because then the voltage maximum would be half of what's needed
Comment: Would an 8ms cycle mean 125hz, and if so, what resistance would c1 need to be? Also, I am kind of a beginner, so what exactly should I connect where in terms of 0V, V_in, signal, and inverse signal?
Comment: @reinderien: with capacitors in series at the outputs, that would work, wouldn't it?
Answer: As Reinderien made a topic that is related to this, I will also share my answer here. Note that this circuit only creates an additional inverted square wave from a unipolar input square wave V1 (without a negative supply), but doesn't create the square wave itself. So it is only part of the solution.

How to create square wave circuit


iOS 4 - How to add table view to a tab bar application

Question: I am new to iPhone programming and am having a really hard time trying to figure out how to add a table view to a tab bar application. There are not many tutorials on this for iOS SDK 4 and the Apple documentation is very light on details. Since I am new I would really like some tutorial that has screenshots (or at least clear instructions) when it comes to things being done in Interface Builder (like making connections between the objects and File Owner, etc), usually lot of tutorials/blogs gloss out these details.
What I am trying to do is create a tab bar based application with 3 tabs (this I am able to do). The first tab needs to display a table view with the header having 2 buttons (one on right and other on left, with the title in middle).The title is actually today's date, obtained from the phone. Clicking either of the header buttons should take you to another table and the title should be yesterday's date (if left button is clicked) and tomorrow's date if right button is clicked.
Can some one please suggest me a good tutorial for this. I am thoroughly confused by the Interface Builder (especially how to create connections).
Comment: I personally hate interface builder.  I think it slows down development time, and it can be a pain to work.  I'm sure others will disagree with me on this, but why don't you try programmatically handling view elements?  Its much easier to conceptualize.
Comment: What goes into the table view? You seem to be describing the UI navigation bar at the top which can control any view including a table view. The links between Interface Builder and code are the IBOutlet and IBAction keywords: http://stackoverflow.com/questions/1643007/iboutlet-and-ibaction. This tutorial might be helpful: http://mobile.tutsplus.com/tutorials/iphone/iphone-sdk-interface-builder-basic-training/.
Comment: Hi Dave, The table view will display items from an array, events from the iPhone calendar to be exact.
Answer: The only page I remember frequenting on the past, is CocoaDevCentral.
Personally, I learnt how to use Xcode through video tutorials, so I recommend you to start searching there. Also, to help you with your search, always look for the full name of the objects involved, for example: instead of searching for "tableView", look for "UITableView", apple's notation is very particular and helps narrowing down the result.
Finally, ignore the nay-sayers about Interface Builder, you should give it a try, and see if it fits your style. For instance, I like being able to get a look at the overall design, as I usually help with the design.
Comment: Thanks guys. I was able to get this working finally. Here is a good tutorial, if someone is interested - http://dblog.com.au/iphone-development/rss-reader-part-4-setting-up-the-uitabbar-and-uitableview-with-delegates/


Correct combination of indirect and direct object pronouns in this sentence?

Question: I have read several of the very helpful articles on pronouns in this forum, but I am still having trouble with the correct indirect vs direct object pronouns to use in the following sentence from my workbook: "Why don't you (Ud.) ask him for them (ellas)?"  I thought it would be "Por que no se lo pide?," treating him as the direct object and ellas as the indirect (and changing les to se, of course).  My workbook gives the opposite answer: "Por que no se las pide?"  Which is correct, and why?  Thank you so much!
Answer: The direct object of "pedir" is the thing you are asking for. If him were the direct object of pedir you would be meaning "ask for him".
Start with a canonical phrase like "pida manzanas a Pedro", where "manzanas" is the direct object and "Pedro" is the indirect object.

Talking about apples, you can simply say "pídalas a Pedro".
Talking about Pedro, you can say "pídale manzanas".
Talking about apples and Pedro: "pídaselas".

Back to the question: ¿Por qué no pide manzanas a Pedro?

Talking about apples (direct object): ¿Por qué no las pide a Pedro?
Talking about apples (direct object) and Pedro (indirect object): ¿Por qué no se las pide?
Comment: Awesome, thank you!
Answer: ¿ Por qué no se lo pide ? Why don't you ask him/her for it?
Whereas: las pide is for them, a plural feminine noun.
¿ Por qué no se las pide ? Why don't you ask him/her for them?
[ where las stands for a plural feminine noun like: las manzanas].