LED bulb dims and flickers when turned up to max position on sliding dimmer switch

Question: Older house(1973).  Hanging ceiling light fixture in den has dimmer switch and light would flicker periodically.  During renovations I installed new LED dimmer switch and put in new dimmable LED bulb.  Flickering seems to have stopped except when dimmer slider on switch is raised to max position the bulb dims and flickers.  Everything is fine up to about 75% power on switch.  Thanks for the help.
Comment: I am in NZ. My experience has been that the dimmer flashes when on solar power which is at 240V. Whereas supply is at 220V. It was also causing premature failure. So I  ended up replacing the dimmer with a switch and everything works fine. I  had to do that on all 8 such circuits.  So try testing with a switch without a dimmer.
Comment: Dimming on LEDs is a black art.  The LEDs are hit and miss and so are the dimmers. Old legacy "non-LED-rated" dimmers even more so.
Answer: I've had this exact problem. I wound up using a different brand of dimmer switch. First I would try a different brand of light bulb. When it comes to LED components quality matters.


Shortcut for clearing a column on Tweetdeck

Question: I like to keep the queue of my tweetdeck columns clear, so I can quickly see what's new. So I clear each column after I've read it off. But it always takes three clicks on each column to clear it (1. open column settings, 2. clear, 3. close column settings).
So it would be extremely handy, if there would be a better way:

Is there a keyboard shortcut to clear a selected column?
Is there a short to clear the whole tweetdeck (that'd also be nice!)?
Or is there any other way to clear a column (the deck) with less than three clicks?

Update
It's not about a temporary clearing of the column (e.g. a JavaScript workaround where you empty() the column, but when you reload the page the column is filled again). The workaround shall permanently remove the items as if clicked on "Clear".
Answer: I write a user script for clear Tweetdeck Tweet https://openuserjs.org/scripts/b1nj/TweetDeck_Clear
for use this script you must install an extension specific to your browser.


DNA question on %.

Question: My mom is 30% Spanish my dad doesn't have any Spanish.  I'm 29% Spanish. ( (We all took the DNA test) how can I be just as Spanish as my mom if my dad wasn't  at all? shouldn't I only be 15%?
Answer: Your logic is totally correct, and you should be 15% in that scenario.
However, that is assuming the percentages are totally accurate, which they are not. The percentages are likely plus or minus 20%. So your 29% could mean you're anywhere from about 10% to 50%.
It is unfortunate that the DNA testing companies are implying precision in saying that you are 29% instead of giving the range to indicate the level of uncertainty.
Similarly bad, they show you small percentages such as 3% Irish or 1% Eskimo that are more likely than not to really be zero.
Comment: Absolutely. There can be serious deficiencies in the models correlating DNA sequences to ancestral populations. A relative took an FTDNA test last year which said she was 30% Scandinavian - exciting, but an unlikely result for an n-th generation Londoner (and she has no childhood memories of helping Uncle Ragnar clean his battleaxe). A few months later, FTDNA changed their model and the analysis dropped to 2% Scandinavian. I doubt many ancestral populations are yet sufficiently well defined in the DNA models to allow any real confidence in these analyses.
Comment: I totally agree that percentage is treated incorrectly. What does mean that you are "29% Spanish"? There is no thing like pure "Spanish" DNA. Also we need to count that all people have two sets of chromosomes and it makes thing more difficult. What if only one half "is Spanish" - will it be count as 100% or just 50%? The system counting the distances to reference populations is more reliable, but it uses absolute coordinates, nor relative :-( The n-dimensional model can be converted into relative proportions, but they will be difficult to understand....
Comment: And there is no reason for companies like FTDNA make clear guides how to interpret their results. They make their business in muddying the waters
Answer: Ancestry doesn't give you a Haplogroup. My daughter in law shows 100% east Asian, thats maybe 3 billion people. 23andme breaks it way down to small amounts of Chinese and Korean, which her matches support what we are seeing. A lot of the Ancestry matches do not appear on GEDmatch as good matches. She has only 11 5th cousin matches on FTDNA, I don't think they have a very large database, well thats not their fault, but if you spend money and end up with nothing its disappointing. My feeling is if you are white and looking for you mother or father Ancestry is OK. If your are not white and looking at trying to figure out who you are or clues about your family then 23andme seems to make more sense. Maybe FTDNA will better in twenty years.
Answer: Test at 23andme if your looking for ethnic make up. Test at Ancestry if your looking for random close matches. Then transfer you 23andme results to GEDmatch to see your matches Haplogroups.
Comment: I didn't minus you, but yor answer is non-sense. 23andMe is just one lab. No better, no worse than others. It really has it's own advantages. More - it is better to obtain test in FTDNA lab because of (1) it's growing family finder matches database (2) ethnic make up calculator of competitive quality (3) better number of tested SNPs with FF chip than 23andMe (because 23andMe also tests for Y and mtDNA with the same chip, so it tests lesset number of autosomal SNPs). And GEDMatch is free service and it accepts many types of raw files - including 23andMe, FTDNA, Ancestry and others.

DNA question on %.


What is the correct way to present the disks to ASM?

Question: Hello I would like to know which is the correct way ... or the most recommended way to present the disks to ASM, for example: I have 3 disks mapped to a server (rhel7) orasys, orafra, oradata, with dm-multipath I configure the multipath and I put aliases (orasys, orafra and oradata respectively). The doubt I have from there, I have read in the guides, that the disks are formatted, leaving for examples: orasys1, orafra1, oradata1 and these are the ones that are presented to ASM as /dev/mapper/* and with the respective permissions ... but when I do it that way it gives an error finishing the installation of the grid because it cannot create the diskgroup, however if I do not format them, that is, I present them directly as orasys, orafra and oradata I have no problem.
The database is oracle 19c and I don't use asmlib but udev rules.
Thanks.
Answer: How did you "format" them? Oracle expect them to be block devices, not formatted with a file system. Did you read this documentation?

https://docs.oracle.com/en/database/oracle/oracle-database/12.2/ladbi/configuring-device-persistence-manually-for-oracle-asm.html#GUID-70D50812-CCB2-41E4-AA3B-4689E1DA934E
https://oracle-base.com/articles/linux/udev-scsi-rules-configuration-in-oracle-linux#load_updated_block_device_partitions"
https://dba010.com/2019/07/22/udev-rules-for-configuring-asm-disks/
https://www.thegeekdiary.com/centos-rhel-7-how-to-set-udev-rules-for-asm-on-multipath-disks/


Part identification: [CSC2822]

Question: I took apart this old, white alarm clock and there's a small, DIP-8 IC in there with "HWCAT 714C6A CSC2822" written on it. I've tried searching for a datasheet, but I can't find one. I can find some references to the part itself (on some Chinese parts sources), but nothing about what it is or how it can be used.
Answer: Using the site in the other answer I discovered its an opamp for audio. Here is the information I got:

HWD02 CSC 2822P/2822m 双声道功率放大
  TDA2822P/TDA2822M DIP8/SOP8

Then I recognised the TDA2822 to be some form of audio opamp and you can pull a datasheet from another manufacturer. Here is the datasheet from STs version.
双声道功率放大 translates to: Two-channel power amplifier this just confirms that its a reproduction of the original part.
Comment: @voithos It seems quite natural to me that the power amplifier outputs (1 and 3) are connected directly to the speakers. Could you explain why do you find it confusing?
Comment: Interesting. What still has me confused, though, is that pins 1 and 3 of the TDA2822 are the outputs, but in this circuit those lines go directly to the positive and negative pins of the speakers...
Comment: @Voithos That could be to do with that part so they don't have to pay royalties. Check other manufactures see if they have the the same pin layout.
Answer: HWCAT seems to have a web site and have a contact us section there. You could try contacting them for a datasheet. http://www.hwcat.com/EN/ProductsList.aspx?id=21&cid=2
Looking at their product nomenclature, I am tempted to think of the 8 pin DIP IC as a clone of the uA741 operational amplifier.
What part of the circuit did you find the IC? What other components was it connected to. Does the circuit make sens if you assume it's pinout to be that of uA741?
Comment: I looked up the UA741, and it seems that pin 1 is Offset null and pin 3 is a non-inverting input. I don't think this would make sense here, as pins 1 and 3 are connected to the negative and positive lines of the speakers. But I may just be stupid.
Comment: @voithos - It was just a guess. Did the TDA2822P/TDA2822M solution posted by @Dean work?
Comment: Sorry, I wasn't trying to be condescending. As for Dean's reply, see my comment.

Part identification: [CSC2822]


Single continuous Mesh Line that intersects Empty Objects (Geometry Nodes)?

Question: I was wondering if it's possible to create a single continuous line with Geometry Nodes. I want to make a cable that intersects predefined Empty objects but as you can see the line is broken.
Comment: It's a bit of a brute forced setup which I wouldn't recommend, but you took some of your time to offer knowledge to others for free, so I'll just mark it solved.
Comment: Have you considered using hook modifier and just a simple mesh line + skin modifier?
Comment: Oh, this is not exactly what I needed. Geometry nodes was definitely required for the task, this was merely a simplified example to hopefully get more responses, but I got zero for 9 months XD. No worries, I figured it out a long time ago. Thanks either way :D
Comment: You can add an answer to your own question for future visitors. :)
Comment: I understand ;-) ...I wish it would work differently, but you can't join several segments of a curve into one in any other way. The only other way would be to create two *Mesh Lines*, merge the points, and then convert to a curve. But that doesn't seem any more practical, does it?
Answer: Yes, this is possible, but actually not very practical.
The hurdle is that an "Empty" is empty, as the name suggests.
You get the position of the object directly with the node Object Info, but you can't use Instance on Points or Realize Instances or similar with this object, because it's empty and doesn't return anything during an evaluation.
The only possibility you have is to process the locations directly and transfer them to a curve.
In this example I transfer the start point and end point to the curve, subdivide it and then set the center point.


Semisimple Lie algebra modules with $1$-dimensional weight spaces

Question: Given a semisimple complex Lie algebra $\frak{g}$ of rank $r$, with Chevally generators $E_i,F_i,K_i$. Let $V$ be a finite dimensional representation of $\mathfrak{g}$ such that each weight space of $V$ is $1$-dimensional. Let $(i_1,\dots,i_k)$ be an ordered set of elements of $\{1,\dots,r\}$ (allowing repeats), and let $\{j_1,\dots,j_k\}$ be some permutation of $\{1,\dots,r\}$. For $v$ a highest weight of $V$, the   elements
$$
F_{i_1}  F_{i_2} \cdots  F_{i_k}(v),\quad \text { and } \quad F_{j_1} F_{j_2} \cdots F_{j_k}(v),
$$
must have the same weight. Thus by our assumption they must differ by a scalar multiple. Will this scalar multiple always be an element of $\mathbb{Q}$?
Comment: By a rational is much weaker than by an integer up to inversion. Then it's certainly true, since the Lie algebra can be defined over $\mathbf{Q}$ with the given Cartan subalgebra as split Cartan subalgebra, and the representation is then split too.
Comment: This is true with integer replaced by rational since all irreducible representations of a Chevalley LIe algebra  over the rationals are defined over the rationals (JIm Humphreys book on semisimple lie algebras has a construction, I think).
Comment: What do you mean by "two (vectors) differ by a scalar multiple"? multiplicatively, $1$ and $2$ differ by $2$, and also by $1/2$. That is, the scalar multiple is only defined up to inversion. Are you asking whether it is always integer up to inversion?
Comment: @YCor: thanks for the edit, and yes, I mean integer up inversion, so I guess I should write an element of $\mathbb{Q}$ . . .
Comment: could you explain "since all irreducible representations of a Chevalley LIe algebra over the rationals are defined over the rationals"
Comment: in some more detail please
Answer: Let me flesh out the answer suggested in the comments. Any complex simple Lie algebra can be obtained as a complexification of a (split) Lie algebra $\mathfrak{g}_{\mathbb{Q}}$ defined over the field of rational numbers. The  irreducible finite dimensional representations of $\mathfrak{g}$ are complexifications of representations of $\mathfrak{g}_{\mathbb{Q}}$ which in turn can be constructed as quotients of Verma modules. That is
$$
V_\lambda = \mathfrak{U}(\mathfrak{g}_\mathbb{Q}) \otimes_{ \mathfrak{U}(\mathfrak{b}_\mathbb{Q})} \mathbb{Q}_\lambda / \text{maximal submodule},
$$
where $\mathbb{Q}_\lambda$ is the one dimensional representation on which the (split) Cartan subalgebra of $\mathfrak{g}_\mathbb{Q}$ acts by character $\lambda.$
I am not sure about integrality results which were the subject of the original question.
Comment: @LSpice I've tried to clarify. I don't have any experience over $\matbb{Z}$.
Comment: Do you mean any *split* simple Lie algebra?  (Otherwise, I am not sure what to make of "the split Cartan subalgebra of $\mathfrak g_{\mathbb Q}$".)  If so, then doesn't Chevalley show that we can even define any such over $\mathbb Z$?  (I don't know about finite-dimensional representations.)


How do I completely reset network settings?

Question: When I first installed Ubuntu, all networking worked perfectly. After messing with the settings every so often, it slowly became unusable. I would really like to know if there is a way to completely reset network settings without re-installing Ubuntu, DNS settings, proxy settings, everything. I'm running 12.04.
Answer: It depends what sort of connection you have and whether you have had to manually tweak some settings for it, as sometimes you need to do in the case of a wireless connection.
If you have a wired connection and have simply been altering the settings with Network Manager, you can unplug your Ethernet cable, go into Network Manager and delete all the wired connections (eth0, autoethernet, etc) and then reboot. This has worked for me before. On restart, your wired network will be detected and automatically configured with DHCP to set up ip addresses and DNS settings. This assumes, however, you have a dynamic ip address: you will still have to specify some settings manually if not.
If you have manually altered any settings such as disabling DNSmasq or manually specifying nameservers by creating a fixed resolv.conf, or even changing firewall settings, then you will need to reverse these first and then remove your connections from network manager and reboot.
If none of these approaches are successful, you may need to login to your router and check the settings there.
Answer: You can flush your iptables which firestarter has changed with
sudo iptables -F

Source: Post on Ubuntu forums
Comment: This may fix a few problems but certainly does not answer the question.
Comment: That fixed some of the problems I had earlier this week, but it still fails to stream video or times out when loading certain sites  19 out of 20 times (just an approximation). Any idea what could be causing these issues? It works fine on other computers on my network, or if I wire directly into the modem. Yes, I've tried resetting the router.
Comment: Sorry, I don't know to fix this problem, but may find some help on http://www.ubuntuforums.org/
Answer: Warning: I don't really know what this recovery option does and I tried to find some info on it but was unsuccessful. While searching however, I found a more detailed description of the steps I took to fix my issue:
https://www.osradar.com/enable-network-ubuntu-recovery-mode/
I was having an issue where I was not being issued an IPV4 address on some networks, this prevented me from using most sites other than Google, and also KDE was also not functioning on some networks. I am using Ubuntu 22.04. This is what seemed to help with me:

Reboot
Press space bar while rebooting to access grub, or whatever key it may be for you.
Go down to "Advanced options for Ubuntu" hit enter
A new menu should popup, there should be a few options, one being "Ubuntu, with Linux some kernel version (recovery mode)" The important option here being (recovery mode). Select this one and hit enter.
This opened a new window with various options, one being "network .... Enable networking" Choose this
It'll ask you if you want to mount your system in read/write mode, select yes.
After this a small terminal popped up, some commands seemed to run, and that was it, then I rebooted and my networking issues were fixed.
Comment: I don't see how just only enabling networking on recovery mode could fix any issue. Are you sure you didn't run any extra commands?


Meaning of surface expressions

Question: Reading this paper I came across term "surface expression". What does it mean?
Answer: Surface expression = surface form = input form = the token as it appeared in the text (no stemming, no lemmatization, etc.).
For example, the tokens sang, sung, and sings are all surface expressions of the verb sing.

(Figure from Martin, James H., and Daniel Jurafsky. "Speech and language processing." 2nd Edition (2008))
Comment: I don't think the term 'surface expression' is common in non-computational linguistics?
Comment: @GastonÜmlaut unsure I mostly read nlp literature, not linguistics.
Comment: @GastonÜmlaut how would a linguist call a surface expression?
Comment: I think your example is a bit misleading. 'sang' is not the surface form or 'sing' but rather of 'sing+past'. That's what makes it different from just lemma - because it is not limited just to lexical items. The attached figure explains it better.
Answer: Surface expression basically means the form you see. It is the result of applying a rule to some (hypothetical) underlying form of a word (or phrase). So the deep structure would be something like 'dog+plural' and the surface form of that would be 'dogs' or 'I+direct object' and 'me'.
It is largely used in generative contexts and even then only historically since the original deep vs. surface structure distinction has been mostly abandoned. It can be a useful shortcut when talking about the results of rules but few people believe that there is actually any such thing as deep structure.

Meaning of surface expressions


Backing up a custom VirtualBox image before upgrading disk

Question: I want to upgrade my HDD to an SSD.  Before I do that, I was wondering if I have an Ubuntu VirtualBox image with tools, etc. and files that I have been using. Before I install the SSD could I export the image to a USB stick or something so that when I install the new SSD I have the image as is? I don't lose anything.
Comment: Are you speaking about your actual whole system or only about a single virtual machine that is working below your system? Because if it is the second case, you can do easily copying the directory with the `.vbox` and `.vdi` files (in case of  problem fixing the UUID of the disk after.  There was even a procedure to export a (stopped) virtual machine in a single file that you can import later.
Answer: There are a number of potential scenarios here, but the short answer is yes.  Shut down the virtual and you can move its image anywhere you need to.  Once you change the drives you can move the image back over and set it up in VirtualBox.


Can I make a separate use case and class diagram for each module?

Question: I'm working on a project with 5 different modules. Should I make separate use case diagrams and class diagrams for each module or should I make all-in-one use case diagram and all-in-one class diagram? Your help will be highly appreciated.
Answer: Use case diagrams describe the whole systems behavior of how it interacts with the outside actors. These are documents1 made during the requirement analysis phase, and done independently (and before) any architectural and technical descisions are made about the concrete implementation.
Modules and classes are architectural and technical aspects of an implementation.   So no, it doesn't make sense to create use case diagrams per module2 or class.
At Visual Paradigm is a good introductory description of What is Use Case Diagram?
There's also a nice diagram how the Use Case diagrams fit into the whole software development analysis:

1)Please note, that the detailed textual step by step descriptions of every Use Case are the even more important part, rather than the diagram itself.
2)Unless your modules can be considered as standalone systems, which are each useful on their own, and just interact automated in a bigger overall system.
Answer: πάντα ῥεῖ's answer is correct concerning Use Case diagrams. Use Case diagrams exist at a system level, not a component level. If your system is composed of multiple subsystems (consider a web application and a mobile application with different users and capabilities), then two Use Case diagrams may make sense. Generally speaking, though, one diagram for one system.
Class diagrams, on the other hand, can be decomposed into smaller parts of the system. There are different ways to approach this. One way may be to have a diagram that shows classes from other modules, but leave off attributes and methods while showing class names and relevant relationships. Others may opt not to show classes that are not relevant to the part of the structural design being shown.


How can I construct my objects allocated through std::allocator::allocate()?

Question: C++20 removed the construct() and destruct() members from std::allocator. How am I supposed to construct my objects allocated through std::allocator<T>::allocate()? I found std::uninitialized_fill() and std::uninitialized_copy(), but as far as I understood they are not allocator-aware, and they do copies, which I think would hurt performance a lot for non-POD types.
Answer: You can do it using std::allocator_traits.
The point of removing the construct method is because the allocator traits already has that method, and the STL containers use std::allocator_traits::construct anyway.
Documentation in cppreference
And here is a little example: (Alloc is any allocator)
Alloc a{};
std::allocator_traits<Alloc>::pointer i = std::allocator_traits<Alloc>::allocate(a, allocated_size);

// You use the construct and destroy methods from the allocator traits
std::allocator_traits<Alloc>::construct(a, i, value_to_construt);
std::allocator_traits<Alloc>::destroy(a, i);

std::allocator_traits<Alloc>::deallocate(a, i, allocated_size);

Comment: If you want to construct multimple elements, you will have to iterate. This is how [I did it](https://github.com/Polo123456789/contenedoresSTL/blob/main/include/psg/vector/constructors.hpp#L22). Just look at the construction, and ignore the clean up in case the defautl construction throws, I currently in the reworks for that.
Comment: `Alloc::pointer` is also removed in C++20. Just use the trait throughout, or better yet `auto`: `extern Alloc a; using AT = std::allocator_traits; auto p = AT::allocate(a, count); AT::construct(a, p + i, constructor_arguments); AT::destroy(a, p + i); AT::deallocate(a, p, count);`
Comment: @Deduplicator Thanks. I forgot that `::pointer` was removed too.
Comment: Also, I believe you're supposed to pass `std::to_address(i)` to `construct`, not `i`. `construct` takes a pointer; `i` is whatever the allocator wants it to be.
Comment: Thanks. It seems to work. How am I supposed to construct multiple elements at once?
Currently, Im reimplementing a vector container. I am using this static construct member function to construct 5 elements to their default value, after the user passed the vector's size.
Answer: It looks like a static form of construct still exists in C++20. Maybe that is intended to replace the original form of construct?
https://en.cppreference.com/w/cpp/memory/allocator_traits/construct
I have not really done much with custom allocation so I don't have personal experience using these functions, but it seems reasonable that they might prefer a static function in an effort to break dependencies.
There is also a construct_at function that is added with C++20.
https://en.cppreference.com/w/cpp/memory/construct_at
Comment: `allocator_traits::construct` is the correct (also backwards-compatible) answer. When writing any code consuming standard allocators, its almost always expected that functionality is used via `allocator_traits` rather than the allocator type itself -- which allows for allocators to effectively be given statically defined "default" implementations of some functions (such as `construct`, etc). Technically C++20 onward, `construct_at` and `allocator_traits::construct` would be synonymous though
Comment: @Human-Compiler Equivalence for `std::allocator` is not that interesting in the context of using allocators. Not every allocator is `std::allocator`.
Comment: @deduplicator You appear to misunderstand; I am referring to the standard allocator *concept*, not `std::allocator`. The expected way to interact with any allocator generically is  to use `allocator_traits` because certain functions or features need not be explicitly defined, and `allocator_traits` provides these defaults.
Comment: @Human-Compiler I was referring to your last sentence. [`std::construct_at`](//en.cppreference.com/w/cpp/memory/construct_at) is only equivalent to [`std::allocator_traits::construct()`](//en.cppreference.com/w/cpp/memory/allocator_traits/construct) for [`std::allocator`](//en.cppreference.com/w/cpp/memory/allocator).
Comment: @Deduplicator Ah I see what you are getting at -- fair enough


Wanhao Duplicator i3 ABS settings

Question: I am looking to others who have successfully printed in ABS using a Wanhao Duplicator i3.
I have tried and get a lot of warping and delamination. I tried putting a large box over the printer which did help with the warping some but I am still getting some layer separation. I used 235 °C for the extruder and 100 °C for the bed. I am printing at 40 mm/s and 0.2 mm layer height.
If someone has ABS and PETG settings for this printer, your help would be appreciated.
Comment: What kind of models are you experiencing these warping problems with? Some things (large and flat models) just can't be printed in ABS regardless of settings, and you should just use a different material. There's a lot more at play than just your settings.
Comment: They were corner brackets for an acrylic enclosure, maybe 1.5 inch square with slots for the acrylic to slide into. The other was an L bracket about 1.5 inches long printed on end. This is where I got the separating layers. I am pretty new to 3d printing and have done well with PLA but want to learn other filaments as well.
Comment: I had the same issue and fixed it by printing a little slower (25mm/s IIRC) and using some kapton tape on the bed. You might also want to lower the bed temperature over time, like described in https://filaments.ca/pages/temperature-guide#abs. I printed at 90 with a longish model and lowering the bed temp stopped my separation.
Comment: I just tried ABS for the first time. I was having issues and I don't have a glass bed. My first four prints failed at the start, so I used Scotch wrinkle free glue stick and my print is working just fine. lol. Thank you Scotch Wrinkle-Free glue stick.
Answer: I am an official Wanhao Distributor
By experience I can recommend you to print with this settings:

Extruder 230 °C
Heated Bed 65 °C
Have a glass surface
Use hairspray over the glass
Continue to enclose the printer or at least put it where there is almost no wind
Print at 45 mm/s

Note that this settings vary a lot depending on humidity and other factors related to where you are printing, so it would be very useful to know where in the globe are you experimenting.
Also note that humidity is very very bad for 3D Printing Filaments so keep them sealed while not using them.
Please do  comment if you have any more doubts.
Answer: I've had hit and miss success, but nothing I would consider great. I was using Hatchbox ABS with the extruder at 230 °C and the bed at 65 °C and a homemade enclosure.
One thing that did help was making sure the HVAC vents near the printer were closed.

Wanhao Duplicator i3 ABS settings


What are the support windows for SQL Server 2012 SP3 and SP4 respectively?

Question: I am hearing two different rumors. One is that SQL Server 2012 SP3 loses support June 2017. I am also hearing SQL Server 2012 SP4 is due out in June 2017. Is SP4 just a rumor? Or is it true? If true, when does SP4 lose support?
Answer: SP4 for 2012 was announced recently and is due out next month.
See Microsoft's Support Lifecycle Policy documentation for end-of-support dates.  According to that document, SQL Server 2012 Service Pack 3 "mainstream support" ends on July 11, 2017.  Extended support for SQL Server 2012, including service pack 4, ends July 12, 2022.
Answer: The lifecycle policy for Microsoft products is generally that the support for the previous Service Pack expires 12 months after the new Service Pack was released to the public.
So if the SQL Server 2012 Service Pack 4 is due in June 2017, then the Service Pack 3 will lose its support approx. June 2018.
Microsoft Support Lifecycle Site
If you search for SQL Server 2012 on the Lifecycle Support page you will see the results for the previous service pack Service Pack 2 and the following information for the current Service Pack 3:
<code>                | Life Cycle Start Date | Mainstream Support | Service Pack Support End Date
----------------+-----------------------+--------------------+-------------------------------
Service Pack 2: | 10/06/2014            | Not Applicable     | 10/01/2017
Service Pack 3: | 01/12/2015            | 11/07/2017         |
</code>
As you can see the newer Service Pack 3 limits the support of the previous Service Pack 2 to approx. 1 year after the newer Service Pack was introduced.
This is normally what happens with each newer Service Pack. Microsoft gives you a grace period of a year to upgrade to the newer Service Pack.
So you can expect (no guarantees from Microsoft) that the support for the older Service Pack 3 will expire one year after the introduction of Service Pack 4 (which would be June 2018).
Answer: As SP3 is the latest SQL Server 2012 "release" it follows the main product's support dates so drops out of its mainstream support on 2017-07-11, but from there it entered extended support so at very least still gets timely updates for security issues and other serious problems. That period ends in 2022, so you are safe to keep using 2012sp3 for some time to come.
With the expected release of SP4, SP3 will no longer be be latest so it may not be supported that long, but of course you will have the option of keeping the 2022 EOL date by installing SP4. The usual policy is "support ends 12 months after the next service pack releases or at the end of the product's support lifecycle, whichever comes first" so if SP4 is released on the 1st of July it is likely that SP3 will be supported until 2018-07-01 - this hopefully gives you plenty of time to verify your applications against the new update and upgrade accordingly.
You can check product lifecycles directly with MS via https://support.microsoft.com/en-gb/lifecycle (i.e. https://support.microsoft.com/en-gb/lifecycle/search?alpha=sql%20server%202012), with the caveat that this only lists released versions so, for instance, does not yet account for SQL 2012 SP4.
Answer: Yes SP4 is coming, here is some info https://blogs.msdn.microsoft.com/sqlreleaseservices/announcing-sql-server-2012-service-pack-4/


Is there a way to maximize a NetMeeting shared screen on a second, larger monitor?

Question: My primary monitor is 1280x800, and my secondary monitor is 1280*1024.  When somebody shares their screen in NetMeeting, it'd be nice to be able to drag the shared screen onto my larger monitor and maximize it.  But, NetMeeting seems to limit the window size to the resolution of my primary monitor.  Is there a way to fix this?
Answer: I believe NetMeeting is actually sizing the window to the originator's screen size.  You can move the NetMeeting window to your other monitor, but you'll only be able to see a screen as large as they have their screen resolution set.
Answer: I am a training instructor for a major telecommunications company and I use net meeting to share my desktop with the students. Since the desktop I'm using and their PCs are the same size and screen resolution, usually a scroll bar is at the top and sides of the window. If one selects ALT & Enter at the same time, the window will maiximize and the scroll bar will not be needed. Make sure they maiximize the window that being shared first then select ALT & Enter at the same time.


Number of distinct Arrays formed from swapping pairs

Question: Given an Array $A$ as a permutation of first $N$ natural numbers and an integer $m$, how can we find the number of distinct arrays that we can generate from $A$ by performing exactly $m$ swap operations.
Eg : $A =\{1,2,3\}$  and $m=1$
Then possible resulting arrays can be $\{2,1,3\}, \{1,3,2\}, \{3,2,1\}$.  So answer is $3$.
Comment: There are $\binom{N}{2}$ ways of performing a swap, for any given swap, and $N!$ possible permutations in total... perhaps one could use inclusion-exclusion?
Comment: Let $x=C(n,2)$ For $k$ swaps, you have $C(x,k)$ ways to select swaps, then $k!$ ways to perform these swaps.
Answer: Duplicate but also unanswered
Here's a piece of c++ code i just wrote to help find and answer to this.
<code>#include <vector>
#include <iostream>
#include <algorithm>
using namespace std;

int main() {
    int n, m;
    cout << "Enter number of distinct numbers in array: ";
    cin >> n;
    vector<int> startNumbers;
    startNumbers.reserve(n);
    for (int i = 1; i < n + 1; ++i)
        startNumbers.push_back(i);
    vector<vector<int>> permutations;
    permutations.push_back(startNumbers);
    cout << "Enter number of swaps: ";
    cin >> m;
    for (int i = 0; i < m; ++i){
        vector<vector<int>> newPermutations;
        newPermutations.reserve(n*permutations.size());
        for (auto vec : permutations){
            for (int j = 0; j < n; ++j){
                for (int k = 0; k < n; ++k){
                    if (j != k){
                        auto tempVec = vec;
                        iter_swap(tempVec.begin() + j, tempVec.begin() + k);
                        newPermutations.push_back(tempVec);
                    }

                }

            }
        }
        sort(newPermutations.begin(), newPermutations.end());
        newPermutations.erase(unique(newPermutations.begin(), newPermutations.end()), newPermutations.end());
        newPermutations.shrink_to_fit();
        permutations = newPermutations;
    }
    cout <<"Number of distinct arrays: " << permutations.size() <<"\n";
    cout << "Distinct arrays: ";
    for (auto& p : permutations){
        cout << "[ ";
        for (auto& n : p){
            cout << n << " ";
        }
        cout << "] ";
    }
    cout << "\n";

    system("pause");
    return 0;
}
</code>
Notice this gets slow really fast.
Things to note for $N =$ numbers in array, $m =$ number of swaps:

maximum number of distinct arrays seems to be $\frac{N!}{2}$ and is reached at $m = N-2$ and stays at that value for bigger $m \geq N-2$
the corresponding OEIS-sequence

By checking out the paper mentioned in the OEIS article, you can find that the formula for calculating the number of half of the linearly inducible orderings of points in d-space is (Quote):

$$\frac{Q(n, d)}{2}= \sum_{k=0}^{d-1} \hspace{2pt}{}_{n}S_{k} = 1 + \sum_{2 \leq i \leq >d-1}{i} + \sum_{2 \leq i \leq j \leq d-1}ij + \text{ }... \text{ (d Terms)}$$
where ${}_{n}S_{k}$ is the sum of the possible products of numbers taken k at a time without repetition from the set $\{2, 3, ... ,n - 1 \}$.

I wrote a short program to calculate that formula:
<code>#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;

int nSk(int n, int k){
    if (n < 2)
        return 1;
    if (k > n-2)
        return 0;
    vector<int> numbers;
    numbers.reserve(n - 2);
    for (int i = 0; i < n - 2; ++i){
        numbers.push_back(i + 2);
    }

    std::vector<bool> v(numbers.size());
    std::fill(v.end() - k, v.end(), true);
    int ret = 0;
    do {
        int tmpnum = 1;
        for (int j = 0; j < numbers.size(); ++j) {
            if (v[j])
            {
                tmpnum *= numbers[j];
            }
        }
        ret += tmpnum;
    } while (std::next_permutation(v.begin(), v.end()));
    return ret;
}

int main(){
    int n, d;
    cout << "enter n: ";
    cin >> n;
    cout << "ender d: ";
    cin >> d;
    int sum = 0;
    for (int k = 0; k < d; ++k){
        sum += nSk(n, k);
    }
    //sum *= 2;
    cout << "Q(n, d) =  "<< sum << endl;
    system("pause");
}
</code>
Entering $n=$ number of arrays and $d=$ number of swaps $+ 1$ gives you what you are looking for.
I have not figured out yet why the number of distinct arrays which can be formed by swapping exactly m times is related to the number of linearly inducible orderings of n points in d-space precisely, but will update as soon as i do.
Comment: Let $f(n,m)$ be the number of permutations of that can be obtained by exactly $m$ transpositions. Then $f(n+1,m)=f(n,m)+nf(n,m-1)$: there are $f(n,m)$ permutations that can be obtained by transpositions not involving $n+1$, and there are $nf(n,m-1)$ that can be obtained by applying $m-1$ transpositions to $12\ldots n$ and then one transposition interchanging $n+1$ and the desired last element. This is the same recurrence as the one for $Q(n,d)$, but where that has initial conditions $Q(n,1)=2$ for $n\ge 2$ and $Q(2,d)=2$ for $d\ge 1$, this one has $f(n,0)=1$ for $n\ge 1$ and ...
Comment: ... $f(2,m)=1$ for $m\ge 0$. It follows immediately that $f(n,m)=\frac12Q(n,m+1)$.


How can I make an animation using importing several x3d files to Blender by scripting?

Question: I have some x3d files made by ParaView. I need to write a script to import these objects sequentially to Blender and make an animation. When each object is imported to 3D View Editor, a keyframe should be created. Then this object is deleted and the next object needs to be imported to make the next keyframe.
After doing the same for all objects, the made animation will be played.
There are some scripts to make jpeg files as each frame of animation and save it as mpeg or avi format. But,I need to export the above made animation as an Alembic file and import it to Unity.
I would be grateful if anybody can help.
Thank you so much.
Comment: Method suggested looks unsound. Please add more detail, eg are imported objects different or could they be considered shapekeys of each other.  ... are you mixing keyframe with shapekey above?
Comment: The imported objects are the time dependent CFD simulation results. They are velocity vectors at different time steps which have been post processed using ParaView and exported as x3d files to Blender. They are different and cannot be shapekeys of each other.
Answer: I have the same problem. I somehow managed importing the .x3d files. However I couldn't animate it. Here is my detail information: I have 11 .x3d files representing a simulation at time of 0 second, 10 seconds up to 100 seconds. I want to set frame 0 to the file at 0 seconds, frame 1 for the file at 10 seconds and so on. I hope the importing scripts will help. My importing script is:
<code>    import bpy
    import os
    import sys
    from mathutils import Vector

    importFolder = "./x3d" #the relative path of the folder containing the files
   # Fixed parameters
    geoName = "imported_geometry1"
    blenderVersion = bpy.app.version
    if blenderVersion[1] >= 79:
      x3dImportString = 'Shape_IndexedFaceSet'
   else:
       x3dImportString = 'ShapeIndexedFaceSet'
      #--------------------------------------------------------------------------#

      # Turn relative into absolute paths
      importFolder=os.path.join(os.getcwd(), importFolder)
       # Get a list of all files in this directory - these are going to be the files we
       #import and visualize
      importFiles = os.listdir(importFolder)
      importFiles.sort()
      # Start the rendering loop over all import files
      for frame in range(len(importFiles)):
    importFile = os.path.join(importFolder,importFiles[frame])
    print("Processing frame ",frame+1," importing ",importFile)

    bpy.context.scene.frame_set(frame+1)

    # Import the current object, either supplied as a .ply or a .x3d file
    # The geometry will always be renamed so it can be easily used later on
    bpy.ops.import_scene.x3d(filepath=importFile, filter_glob="*.x3d;*.wrl", axis_forward='Y', axis_up='Z')
     # check for geometries / meshes, lamps and cameras
    imported_geo_exists = [item.name for item in bpy.data.objects if x3dImportString in item.name]
    nImportedGeo = len(imported_geo_exists)
    imported_lights_exists = [item.name for item in bpy.data.objects if ("TODO" in item.name or "DirectLight" in item.name)]
    imported_cameras_exists = [item.name for item in bpy.data.objects if "Viewpoint" in item.name]
    # rename geometry
    if imported_geo_exists:
        for i in range(0,nImportedGeo):
              bpy.data.objects[imported_geo_exists[i]].name=geoName+str(i)
        bpy.ops.object.select_all(action='DESELECT')
        # delete lights and cameras that blender creates after import
        if imported_lights_exists:
            #bpy.ops.object.mode_set(mode='OBJECT')
            bpy.ops.object.select_pattern(pattern="TODO*")
            bpy.ops.object.delete(use_global=False)
            bpy.ops.object.select_pattern(pattern="DirectLight*")
            bpy.ops.object.delete(use_global=False)
        if imported_cameras_exists:
            #bpy.ops.object.mode_set(mode='OBJECT')
            bpy.ops.object.select_pattern(pattern="Viewpoint*")
            bpy.ops.object.delete(use_global=False)

```
</code>
Comment: Thank you for the script, but I had imported the files but I still have the animation problem.


How can I get a bunch of 1-UPs in New Super Mario Bros(DS)?

Question: I need to rack up a bunch of free lives in New Super Mario Bros (Nintendo DS).  What is the fastest technique to get a bunch of 1ups / free lives?  (Will the staircase + koopa trick work in NSMB?  Where's the best staircase for this?)
Comment: It sure will! Don't remember the game offhand to tell you where to go for it, though.
Answer: It's been a while, but I liked playing the first level over and over. It has a Mega Mushroom in it. What you do is let the mushroom out, but don't get it immediately - let it scroll right until it almost falls into a pit. Then pick it up and run like crazy to the right. You'll get a bunch of 1-Ups, including when you smash through the ending flag.
Repeat!


When Was Google Analytics Last Accessed?

Question: We gave our SEO company access to our Google Analytics. We want to check when was the last time they logged in to view our statistics (and possibly a complete log). Is there a way to check this?
Comment: Have you contacted google and your SEO company?
Comment: We have not contacted the SEO company. The reason for this inquiry is that we think they aren't doing anything. So, knowing if they have been accessing Analytics would confirm or refute our suspicions.
Answer: You can only see if there were changes made on a specific account/profile/view. Go to Admin->look under Account for "Change History".  But you can not see if they logged in.
Even if you could see a list of people who logged in, some SEO companies connect the user's Google Analytics account to their own tools where they use the data more effectively combined with other data they gather or, even more, they use exclusively their own tools. Therefore, there is a big chance they actually don't login into Google Analytics platform.


Faulty hard-drive?

Question: I just purchased a brand new laptop, and I believe the hard drive to be faulty. Here are the symptoms:

It's a 500gb 7200 rpm hard drive, the relevant part formatted to ext4 and running Gentoo
Every so often, an audible "click" will emanate from the hard drive
For the next 1 or 2 seconds, the system freezes up (although the mouse still moves)
This happens most frequently when compiling / moving lots of data (4-5 times every 15-20 seconds)
It happens during non-hard-drive intensive use with a much lower frequency (although is particularly annoying while watching movies as while the audio picks back up when the system does, generally the picture stays constant until the next keyframe)
The system picks itself back up without any problems afterwards, no errors are logged to dmesg

I brought this up with customer service and they said they can ship me a new hard drive, because apparently no other users have complained of similar symptoms. Does this sound like a faulty hard drive to you? My worry is that:

I'm not 100% convinced it's a hardware issue
I can't reinstall Gentoo or any other OS on it while for the next month as my internet connection is limited to about 100 megabytes per week
Transferring everything between 500gb hard drives is a major pain in the butt with a 4gb flash drive, especially if this does not fix the problem.

Thanks,
Mala
Comment: when you hear the 'click of death' backup your files while you still can!
Comment: Check `dmesg` for possible error messages.
Comment: Any chance of knowing the drive manufacturer?  Most manufacturers supply drive fitness testing software that can diagnose most faults...
Comment: @Molly: It's brand new so my files are already backed up on my old computer. Thanks for the tip though :)
@Bobby: check the last bullet point of the symptoms list: no errors are logged to dmesg
@Mokubai: I have no idea what it is, but I'll look into doing that. Thanks :)
Answer: If it's clicking in the middle of disc actions, I'd definitely be worried and make sure anything important is backed up.  Then run any and all diagnostics you can on the drive and record the evidence in case the manufacturer gives you any flack about replacing the drive under warranty.
Comment: + 1 -> clicking = death... when you hear that hope you have backed up all you need, or at least try backing up then
Answer: It might just be the power management getting in your way.  The drive may be going to sleep and parking the heads, then when you do something that requires a disk access, the whole system stalls while the hard drive spins back up.  You can tweak your hard drive's power management parameters and other features with hdparm.
However, you shouldn't count out the possibility that it is a defective drive.  I've received several brand-new drives in the past that were defective.
The clicking is probably the armature for the read/write heads seeking back and forth when a data access fails, in an attempt to retry the read/write operation.
First I'd suggest running badblocks -sv on the drive.  This should do a sequential bad block scan, so there shouldn't be any clicking unless there is an unreadable sector or some faulty sectors have already been detected and relocated.
If you don't care about the data, you can also do a destructive read/write test by running badblocks -wsv, which should give the drive a more thorough workout.
Answer: You could check drive's SMART status - it is not always indicative, but if it shows e.g. growing numbers of reallocated sectors then this is a definite sign of HDD's malfunctioning. To be sure, monitor SMART status changes over a day or two.
sudo smartctl -H -A /dev/sd? will show you overall drive health status, and values of individual attributes. Also, you may run some internal drive tests with smartctl (you may have to emerge or otherwise install it first).
Disk Utility (Palimpsest) will allow you to do almost the same from the comfort of your desktop environment.

Faulty hard-drive?


does adding water to wort to top off for fermentation raise the original gravity?

Question: My extract/partial grain kit calls for a OG of 1.057 - 1.061. After topping off in the fermentor, my OG was 1.074. Is this close enough? Did the addition of water raise the OG?
Comment: That's probably right, and your a touch heavy, but don't worry too much about it
Answer: Adding water to something will lower its gravity.
When adding water to wort from a concentrated extract brew process its not uncommon for the two to not mix completely.  When you added the water you turned over some of the wort and took a sample of something that was more dense than intended.  No big deal.  It will equilibrate and the fermentation action of the yeast will stir it up once it gets going too.
Next time, add your top up water and either stir with a sanitized spoon or seal the fermentor and shake it.  Then take your sample for gravity readings.
Happens to everyone at this stage in the hobby.
Comment: Whether you stir or shake to homogenize your wort, do it vigorously. This will aerate the wort, adding oxygen for the yeast. Don't do it after fermentation has started, though, as it can cause the beer to oxidize.
Answer: Adding water post boil will dilute and lower the OG, not raise it.
It's possible your readings were off.
Hydrometer If using a hydrometer make sure the wort is cool and follow the temp correction values for your hydrometer.
Refractometer Make sure your refractometer is zeroed out using distilled water.
1.074 is the ball park low end gravity for many "big" beers. The added sugars require more yeast for fermentation. Double check your readings and pitch accordingly. If you do it right, the only down side of higher OG is more alcohol, if done wrong you may get an underattenuated beer that is sweet.
Comment: Oh, yeah, I added a pound of dry LME outside of the recipe, that would account for the higher OG.....
Comment: That would do it. :-)


Should I cite every study that supports my point?

Question: Suppose I'm writing a paper and at some point in the paper (e.g. the background section), I write that "Vanilla ice cream is healthier than chocolate ice cream." I search EBSCO and find check all research studies that tested this and find and skim through 15 papers all supporting this claim, including the earliest pioneer research in the area up to the most recent. Is it then appropriate to affix in-text citations for all 15 of those studies to that sentence? What about if I find 50 studies?
Comment: Would you be writing "Vanilla ice cream is healthier than chocolate ice cream" *before* you had some reason to make that claim?
Answer: It depends on the purpose of the paper.
If it is a review article on the effects of different flavor of ice cream, it may well be appropriate to cite far more papers than it would be if you are merely establishing the point in a paper containing your original research on the subject. In the latter case you may even be able to cite someone else's review.
Generally speaking, new papers in a field only get published if there is an element of novelty to them. Thus it is unlikely to find 50 different papers saying exactly the same thing. If you need the citation to support your own project, you should be able to find a small subset of those that are most relevant to the question at hand (e.g. if I am using mouse models, I should probably cite prior work in mice over prior work in rabbit models). If you are reviewing a topic, you should be able to find the most important papers out of the group (e.g. the ones that were transformative to our understanding of ice cream health effects).
Additionally some papers will vary in quality or scope. Citing an initial, limited scope paper might be appropriate if you are discussing the history of a topic, but if you are just trying to establish a basis for a claim you may want to go with a later, more definitive study.
Many publications will give you a citation limit when writing for them. So you often won't have a chance to cite an entire library of previous work. You need to be able to pin down the papers that are best suited for your specific need.
Answer: The purpose of a citation is twofold:

It prevents you from taking credit for other person's work.
It can serve as an "external appendix" (the interested reader can read more in ...)

Neither requires that you cite everybody. If there is a large body of work done already, then typically one or more overview articles have already appeared. You can cite those, and combine both purposes: you indicate that it is not your finding and the interested reader can find a complete list of references in the overview article.
Comment: In case there aren't overview articles, you can always cite a few you like, and say something like "see these and the references therein."
Answer: In my field (particle physics), at least, when you give a citation for a result, it's traditional to cite the original result. Many papers that come later might also give the same result, some with the original derivation, some with updated derivations, some with experimental evidence (though that is really considered a separate result from the theoretical discovery in its own right), but they don't all get cited for that one result.
So it probably depends somewhat on the conventions of your field.
Comment: @IlmariKaronen I haven't read most of the papers where I am listed as a _coauthor_, let alone all of the papers that I put in the references section of my master's thesis. (Particle physics papers tend to list as coauthors everyone even tangentially related to the paper, in my very limited experience.) And I am as close to a nobody as you can be in the world of coauthors of particle physics papers.
Comment: @yellowantphil: It may happen all too often, but most publication style codes do consider it improper to cite a paper *none* of the authors have ever read, at least unless the citation is clearly marked as indirect (e.g. "Lomonosov 1759, qtd. in Shiltsev 2014").
Comment: Of course, this practice also has its problems, especially when the original paper is very old, in an obscure journal and/or written in a language you don't understand. After all, you're also *supposed* to have read and (more or less) understood any articles you cite.
Comment: It's mostly the large experimental collaborations which have long lists of authors that appear on every paper. In any case, I have gotten the sense people in particle physics don't always hold citations to that standard. For example if you cite an experimental result in a theory paper, the authors (who are theorists) would not be expected to understand the details of how the experimental apparatus works.
Answer: It depends on how important is that point to your paper. If you are studying the consistency of ice cream, and you find that vanilla has a better consistency, and furthermore, is healthier, you just need one good reference.
On the other hand, if that is a central point of your article (you are researching how to condition children into choosing vanilla instead of chocolate), you should make a strong point. In this case, is beneficial to put things in perspective:

The first work by Jones in 1976 suggested that Chocolate was not so healthy...

If there is a review, it can mostly replace all the older papers:

The fact was well established since the work by Marks, "Ice cream flavours, health, and little humans", 1998.

and possibly special mention mention those papers that are a substantial breakthrough or strength:

Smith 2003 followed the ice cream preferences of 10 000 white children...
Answer: +1 to Maarten's answer.
In addition: likely enough, the more recent of the 50 studies you mention already cite most of the earlier ones, so the reader can just follow the breadcrumbs back - no need for you to essentially repeat the literature survey that was already done in the papers you cite. Stick (mostly) with the recent literature.
Of course, you should cite papers that are most relevant to your study (e.g., similar protocols, similar questions etc.), and if you manage to find a relevant study that everyone else has overlooked, by all means include it.
Comment: This makes sense, unless there's a seminal paper.  A think a huge problem is that not enough people actually follow the breadcrumbs back before writing.
Answer: Usually one reference is best; sometimes you want more.
In general a single, well-chosen, citation is all that is needed. Select a paper that (a) you've read (b) clearly supports your assertion and (c) is well written and the job is done.
However, sometimes you may wish to include more than one references. The appropriate time to do this is if there is historical reason to do so (e.g. you may wish to cite the original paper and a more recent update), if you wish to emphasize the breadth of support for the point, if the point is - in your view - controversial or if you're giving a historical view and want to cite multiple papers to give the historical perspective on the point.


Trying to Publish a Workflow From SharePoint Designer 2010 to SharePoint 2010

Question: Let me start off by saying that I am not a SharePoint guru, nor an administrator for this site.  I have enough rights to build my site.  I have taken on the task of creating a site at work to make things better since it has gone through several people's hands and I take it as a challenge that I can do it.
So I have a workflow I created in SPD 2010 to send an email out based on an kickoff action in List A that references email addresses in List B since I am sending this email to people outside the organization.  I have even tried to make a simple workflow to send an email to my name in the To: field and TEST in the Subject and Body.  No Luck.
The issue lies in the fact that when I try to publish the workflow to the site, after checking for any errors (none I might add), I get back a "Workflow Error" that says "Errors were found when compiling the workflow.  The workflow files were saved but cannot be run" and if I hit the Advanced button it says "Unexpected error on server associating the workflow."
I am looking to this forum to determine if this error is related in some way to an incorrect setting in the SharePoint Server that I don't know about, if it has anything to do with a lack of permissions from the overall SharePoint Server administrator to upload workflows or something else that I know nothing about.
I have asked the SharePoint administrator and he won't be able to get back to me until next week as he is at a conference, but I would like to try the workflow out and see if it works or I need to go back and work on it more.
If the consensus is I need more rights and I will have to wait until next week, is there a way to run the workflow in SPD or can I download my site as a sandbox and just play with it there?
Any and all help is gratefully appreciated.
Answer: For others who have this issue, it was a rights issue.  The company did not install SPD as an admin, hence I could not create work flows.


setxkbmap conflicting with xmodmap

Question: So initially I had the following in my ~/.Xmodmap which mapped CapsLock+HJKL to left/down/up/right like in vim:
keycode 66 = Mode_switch
keysym h = h H Left
keysym j = j J Down
keysym k = k K Up
keysym l = l L Right

Everything worked just fine until I finally figured out how to get multi-language support working:
setxkbmap -option 'grp:rctrl_rshift_toggle' -layout us,fr,pt -variant ,azerty,mac

Now it's a little messed up: The CapsLock+HJKL only work in us mode, but not in fr (french) or pt (portuguese).
In fact, with fr mode, it's all reversed: HJKL act as up/down/etc and CapsLock+hjkl show the actual key values.
In pt it's different again...
I just want consistent vim-like navigation using CapsLock as the meta key throughout all languages.
(I know there's a caps:hyper option in setxkbmap and I'm happy to use that if anyone has a solution along that path.)
Note that I'm using Ubuntu 18.10 with i3 as my desktop.
Comment: Tip - if you want to reset all changes made by setxkbmap and xmodmap, use the command "$ setxkbmap -option".
Answer: setxkbmap not only alters the alphanumeric keys to the values given in the map; it also resets all other keys to the startup default.
If you have assigned values to CapsLock + HJKL keys, these settings may be lost.
For further information, look at: Configuring keyboards

setxkbmap conflicting with xmodmap


Move element inside a list

Question: I need to change the position of a single element in a list. Example: I start with:
{a,b,c,d,e,f}

I want to move the a before the d to get:
{b,c,a,d,e,f}

How would I do this? Thank you!
Answer: data = {a, b, c, d, e, f};
Permute[data, {3, 1, 2}]

or
Permute[data, Cycles[{{1, 3, 2}}]]

Both give

{b, c, a, d, e, f}

Edit
It occurred to me that it would be good to be able to move an element to a lower position in the list as well as a higher one. Together the following two functions give both capabilities.
Upward movement -- move an element at position m to position n, where m < n:
moveElementUp[data_List, m_Integer /; m > 0, n__Integer /; n > 0] /; m < n :=
  Permute[data, Join[Range[m - 1], {n}, Range[m, n - 1]]]

moveElementUp[data, 1, 3]

{b, c, a, d, e, f}

moveElementUp[data, 2, 5]

{a, c, d, e, b, f}

moveElementUp[data, 1, 6]

{b, c, d, e, f, a}

Downward movement -- move an element at position m to position n, where m > n:
moveElementDown[data_List, m_Integer /; m > 0, n__Integer /; n > 0] /; m > n :=
  Permute[data, Join[Range[n - 1], 1 + Range[n, m - 1], {n}]]

moveElementDown[data, 3, 1]

{c, a, b, d, e, f}

moveElementDown[data, 5, 3]

{a, b, e, c, d, f}

moveElementDown[data, 6, 1]

{f, a, b, c, d, e}

Note
Although I found it interesting to attack this problem with permutations, I suspect there is a better solution.
Answer: The following answer is effectively equivalent to m_goldberg's answer, except that the distinction between the two directions of movement has been eliminated:
moveElement[l_List, m_Integer?Positive, n_Integer?Positive] :=
   Module[{idx},
                idx = Range @@ Sort[{m, n}];
                ReplacePart[l, Thread[idx -> l[[RotateLeft[idx, Sign[n - m]]]]]]]

Both moveElementUp[] and moveElementDown[] in his answer can be replaced with this unified function.
Answer: Probably not the most elegant way but...
swap[list_, from_, to_] :=
 Module[{ele = list[[from]], modlist = list},
  modlist[[from]] = Sequence[]; modlist = Insert[modlist, ele, to];
  modlist]

swap[list, 1, 3]

{b, c, a, d, e, f}

If you always want the moving element in front of d...
swap[list, 1, FirstPosition[list, d] - 1]

Note, in 10.2 you can use Nothing instead of Sequence[].
Or, if you insist on using patterns...
from = 1;
to = 3;
list /. {a___, list[[from]], b___, list[[to + 1]], c___} :> {a, b,
 list[[from]], list[[to + 1]], c}

Answer: Or you could just
moveElement[l_, from_, to_] := Insert[Delete[l, from], l[[from]], to]

Works up and down.
Answer:
list = {a, b, c, d, e, f};
SubsetMap[RotateLeft, list, {1, 2, 3}]

{b, c, a, d, e, f}
Answer: ClearAll[move]
move[lst_, from_, to_] :=  Module[{a = lst, p = Sort[{from, to}]},
  a[[p[[1]] ;; p[[2]]]] =  RotateRight[a[[p[[1]] ;; p[[2]]]], to - from]; a]

move[{a, b, c, d, e, f}, 1, 3]

{b, c, a, d, e, f}

move[{a, b, c, d, e, f}, 3, 1]

{c, a, b, d, e, f}

Move element inside a list


Error recovery implementation in a micro service architecture

Question: We have a system that people can use to create new "Folders", a folder will have metadata about it (creation date, permissions, owner, etc.). The folder name is the unique key because there are automatic jobs that links to them by name.
Those jobs are created when the user defines a new folder. We are very explicit about how the creation of a folder instantly create a workflow in other systems and that the name is super important and ask the users to confirm their create action.
Every now and then, a user will not properly read, or will want to try something then message the support group to be able to rename or delete a folder, which can't be done in our system. A folder could be archived, but not deleted.
I have a manual process that can be done to delete or rename a folder, but it is very tedious and could impact live workflow. I was wondering if anyone knows a good recovery mechanism for an architecture like that ?
Answer: Try implementing an input mask as the name of the folder with very clear instructions next to it about how to name the folder. Do not allow the user to confirm the name until all conditions in the input mask have been met.


Private key generation method

Question: How was bitcoin private/public key created in 2009, I observed in the blockchain some bitcoin transaction took place early 2009 Feb - April.
In the original bitcoin core in github the first bitcoin core was released September 2009.
My confusion how were the users able to generate the address ?
Answer: Prior to BIP32, most wallets simply generated keys from random data provided by the operating system (or some other entropy source).
A handful of wallets implemented a brainwallet system, in which keys were derived from some kind of password, but they quickly fell out of use after it was discovered that most people selected easily guessable passwords which resulted in excessive loss of funds to theft.
Answer: The first version of Bitcoin (0.1.0) was released on January 9th 2009. You can find all versions of the software at the Satoshi Nakamoto Institute. Bitcoin Core as a project didn't emerge later, after more contributors started writing code. The name "Bitcoin Core" wasn't used until version 0.9 of the project, which was released in 2014. The project didn't use GitHub in the beginning either, but Sourceforge.
To summarize: the code that Satoshi released in early 2009 had functionality for generating private keys and signing transactions. Bitcoin Core is a later project, and GitHub does not have the complete history.
Answer: The procedure to generate bitcoin addresses and their corresponding private keys is fairly simple, as can be seen at https://en.bitcoin.it/wiki/Technical_background_of_version_1_Bitcoin_addresses.  Early bitcoin addresses and keys could easily have been generated using a series of command-line commands or simple scripts that performed these steps.

Private key generation method


Do PHP frameworks such as Zend, symfony and CakePHP provide default protection against cross site scripting?

Question: ASP.NET MVC provides default protection against cross site scripting. Just wondering, if PHP frameworks do the same?
Answer:
Zend Framework offers an Escaper component to escape output and defend from XSS
Symfony provides an automatic output escaping feature
CakePHP before version 2.4 provided a sanitization class

I recommend you the following lectures for further information:
Secure Application Development with Zend framework
Comment: Your symfony link points to the obsolete 1.x version's docs. Here's the current one: http://symfony.com/doc/current/book/templating.html#output-escaping


what is the definition of out degree and in degree in computer networks?

Question: in wikipedia we have a good definition for in degree and out degree in a graph: " The degree of a node is the number of connections or edges the node has to other nodes. in-degree is the number of incoming edges and out-degree is the number of outgoing edges". so what is the definition of out-degree and in-degree in computer networks? is the number of unique ip addresses that a host send packets to that? or is the number of tcp connections that a host establish to other hosts (number of SYN packets that the host sends to other hosts) plus the number of udp packets that the host send to other hosts? or is the number of flows that originate from one host (flow= same destination ip address, same source ip address, same destination port and same source port)? or ....
Comment: Did any answer help you? If so, you should accept the answer so that the question doesn't keep popping up forever, looking for an answer. Alternatively, you can provide and accept your own answer.
Answer: See the linked WP article:

If a network is directed, meaning that edges point in one direction from one node to another node, then nodes have two different degrees, the in-degree, which is the number of incoming edges, and the out-degree, which is the number of outgoing edges.

That refers to network (or graph) theory - a network can be of directed nature, ie. links only work in one direction (network theory also applies to things like power distribution or road traffic).
Practical computer networks work in both directions simultaneously, links are bidirectional. Hence, there's no in-degree vs out-degree.


Connecting 1/2 copper to 1/8 pex?

Question: Water line to fridge had a saddle valve, saddle valve started leaking so took it out and repaired pipe. Now trying to figure out how to reconnect fridge line. I have 1/2 inch copper under the sink and the pex line at the fridge says 1/8 on it. I can't find any adapters that go from 1/2 to 1/8,or even 1/4 to 1/8. Any help would be appreciated, thanks!
Comment: That is why they make saddle valves. You could pit a T in line and get several adapters to make it down to 1/8. Are you sure of the size most of the ones I have installed are 1/4"
Comment: @EdBeal saddle valves are no good. They usually just end up leaking. In many areas, licensed plumbers are not even allowed to install them.
Comment: Ed beal, the pex coming out of the fridge has 1/8" printed on it. Maybe the actual connection at the fridge is 1/4, but the line currently connected is 1/8.
Comment: What is the make and model of the fridge? What does the shutoff valve for the sink look like (what size is the outlet)?
Answer: If you want to tee off the 1/2" copper line, then you can start with something like this.

Once you get down to 1/4" copper tube, you can reduce further to 1/8" tube as follows.

If you want to tee off after the sink shutoff valve, we'll need to know what size the outlet is on the valve.
Answer: Dont use plastic water lines going to fridge  I see them leak all the time. Use 1/4 flexible copper with compression fittings or 1/4 flexible braided stainless steel supply line(like going to your faucet) I have seen them up to 20' long.
The easiest ways is to install a compression nut T. You unscrew your supply line from your sink to the shut off valve and screw in the compression nut T. Your water line from sink and icemaker will both screw into this.
Just take a trip your local hardware store and ask for help this is a very common issue.
Comment: OP states that the line to the fridge is 1/8", not 1/4".
Comment: Refridgetors  uses 1/4 compression for water maker.
Comment: I agree that that's the common convention, however, the OP specifically said that it's 1/8".
Comment: Pex tub says 1/8 on it  but that is inside diameter. The line comes with a 1/4 compression fitting on ends just like a stainless steel braided line. Your not suppose to cut the line if he did he needs new line.
Comment: A pex water line is  strong and safe to use. I was thinking of cheap plastic lines.
Answer: I ended up getting a 1/2 to 1/4 SharkBite adapter, then a 1/4 to 1/4 stainless steel line to connect to the adapter on the pex.  The pex does say 1/8 on it, but one of the posters correctly pointed out that's an inside diameter. Thanks all!

Connecting 1/2 copper to 1/8 pex?


git pull List all errors

Question: I'm trying to do a git pull and I'm getting error: Your local changes to 'someDir/someFile' would be overwritten by merge.  Aborting. this is fine since I need to check these changes and decide whether these need committed or not.
However doing the above, checking that file and committing/rolling back is laborious if I have to do it each time. Is there a way I can get git pull to list all merge errors rather than one each time?
Comment: A very similar question: Is there in git "git pull --dry-run" option? (http://stackoverflow.com/questions/17222440/is-there-in-git-git-pull-dry-run-option). The accepted answer is the answer you are seeking.
Answer: Using git status -vs will show you a list of tracked changes.
If you want to store them to deal with after the pull you can use git stash, pull your repo, then git stash pop to restore the changes. Keep in mind there may be conflicts you have to resolve.
Another way of doing this is don't pull unless you are going to commit the changes you have made. Then just use git pull --rebase which will place your commit on top of the pulled commits.

git pull List all errors


Can't remove black square with white A symbol from menu bar on macOS

Question: I have this symbol in my menu bar, I don't know where it came from. I can't remove it by using Cmd drag, whenever I move the mouse over it the mouse turns into the spinning rainbow wheel. Can anyone help please?
Comment: Have you tried Force Quit to see if any apps show up in red?
Comment: You can remove an icon by holding Command and dragging it off the bar.
Answer: This is the icon for an old version of Adobe Application Manager or Adobe Updater. It wouldn't show up in the standard Force Quit dialog, so I would recommend the following steps:

Open Activity Monitor, either by searching in Spotlight (Command-Space) or opening it from /Applications/Utilities/Activity Monitor.
Search for "adobe".
Select each relevant result and click the "X" octagon in the top left, then confirm with the Force Quit option.
Reopen Adobe Application Manager or Adobe Updater, and use it to update or uninstall the two pieces of Adobe software which need to be updated.
Answer: You can disable Adobe Application Manager using these steps:
Turn off automatic updates on Mac OS
If your computer is connected to the internet, then you can change the Adobe Updater preferences to not check for updates.
To Change the Adobe Updater preferences, do the following:

Start the Adobe Updater application from /Applications/Utilities/Adobe Utilities/Adobe Updater5/.
When the update screen appears, click the Preferences link.
Uncheck the Automatically Check for updates checkbox and click OK.

If your computer does not have an internet connection, then you can manually edit the AdobeUpdaterPreferences.dat file.
To manually edit the AdobeUpdaterPreferences.dat file, do the following:

Start the Adobe Updater application from /Applications/Utilities/Adobe Utilities/Adobe Updater5/.
When the Adobe Updater dialog appears, stating that there is no Internet connection, click Cancel.
Navigate to "/Users/[username]/Library/Application Support/Adobe/Updater5/" and open the AdobeUpdaterPrefs.dat file in TextEdit.
If the 1 tag already exists, then change the value from 1 to 0. Otherwise, add the line 0 anywhere between the  tags.
Close and save the AdobeUpdaterPrefs.dat file.

Steps copied verbatim from Adobe Support
Answer: The general  solution to this problem is to review each and every item that starts up when you log into your Mac. That involves looking in several locations so I use a tool that is free to try like BarTender to identify and manage the menu bar.

https://www.macbartender.com/

You do need to pay for it if you keep using it. That icon looks like Adobe, but who knows what you installed and who may have copied an Adobe icon if you have malware or just things you didn't realize were modifying your system installed.
Now the spinning wheel gives you another free tool tool - start Activity Monitor and then see which apps or processes are not responding. If you don't see anything, use the view menu to show all processes.
Here are other relevant threads:

Cannot delete icon on menu bar
How do I remove the WD Quick view icon in menu bar?
How to forcefully remove status bar icon?
Two strange icons in my menu bar
How can I remove this icon from the menu bar?
Answer: I'd start by going to the Apple menu and selecting "Force Quit". Apps that are hung up or unresponsive usually show up in red when it lists the running apps. If an app does show up, select it and hit "Force Quit". This method will tell you the name of the app and stop the beach balling...
Comment: Why the downvote on my answer?  I actually used this and it worked fine!


Workbook Protection is unprotected regardless of password (VBA Excel 2010)

Question: I searched about the said problem with various keywords but all results were either related to how to protect a workbook or unprotect it without knowing the password.
My current problem is not really a big problem but it feels so weird that I want to know if other people had/is experiencing it.
I am currently making Excel 2010 VBA Macros to automate data processing. I am adding workbook protection so that users cannot move the position of worksheets. I have done this via VBA 'thisworkbook.protect' or through the traditional Excel menu.
When I run the following code, the workbook protection completely disappears regardless of passwords, structure/window settings.
Sub test()
        ThisWorkbook.Worksheets(1).Cells(1, 1).Value(11) = ThisWorkbook.Worksheets(3).Cells(1, 1).Value(11)
End Sub

Just adding 'thisworkbook.protect' at the end of the code relocks the workbook and solves the problem, which is why this isn't a big problem. But the phenomenon is completely incomprehensible to me.
I appreciate anyone who would give feedback. Thanks.
edit 1
I believe this is not a worksheet.protect problem. My problem occurs regardless of whether worksheets and cells are protected, and I am specifically concerned about worksheet positions and names, which fall into the workbook.protect command.
Edit 2:
So the issue is in following and doesn't concern the difference between Workbook.Protect and Worksheet.Protect methods:
1. I open a protected workbook;
2. Run provided code snippet without unprotecting the workbook, as it doesn't affect worksheet's protection;
3. Workbook protection is cancelled by previous action despite my intentions. Have to protect the workbook again.
Comment: Well, it does, I can confirm this. It looks like a bug and it works in the newest Excel 2019 exactly the same. I mean this should be reportet to Microsoft as it breaks workbook protection completely.
Comment: As I know, the `Workbook.Protect` Method protects the workbook from user interaction - overall workbook related actions (e.g. adding/deleting/moving sheets) **which are sent from UI**, but not from code. In order to protect sheets you have to use a `Worksheet.Protect` Method which works as it should for code raised changes as well.
Comment: @valefore Apologies, I've misunderstood the issue. I've deleted my answer as not relevant and suggested an edit to original post for issue to look clearer.
Comment: @valefore I'm going to report this bug to Microsoft.
Comment: [Here](https://support.office.com/en-us/article/protect-a-workbook-7e365a4d-3e89-4616-84ca-1931257c1517) here is the source link for my comment.
Comment: @Pᴇʜ Thanks for confirming. It's good to know I'm not the only one experiencing this problem.
Answer: OK, the answer from Microsoft was this:

If I am interpreting your findings correctly, this report is
  predicated on the attacker having copied and accessed an Excel file
  that contained password protected workbook/sheets/fields that had not
  been encrypted.  In this case this is an expected function.

My report was immediately closed so I had no chance to insist in this beeing a bug.
So they literally say it is a "feature" (expected function) not a bug. Obviously they consider the workbook protection not a security feature, the only secure protection is encrypting the workbook with a password that you actually need to enter before you can view it.
IMHO this is still a bug and a non expected behavior. But Microsoft obviously doesn't care which is very arguable since this bug means that workbook protection is useless and only stops users from accidentally destroying something.
So either you find a workaround since you know that you can re-protect it after you run that type of code, or you don't use that "feature" causing the bug.
But still anyone who knows about this bug, can use it to remove the workbook protection from any workbook. I see no way to prevent the removal. And since this bug is already working in Excel 2010 as well as in recent versions it is very unlikely that Microsoft will fix that in the near future.


Why is my well behaved cat suddenly start to attack

Question: My cat is usually calm and well behaved. He usually just ignores everyone and isn't that affectionate but recently he started to be nicer and even nudged his head against me for pets.I thought it was different since he usually isn't like that but when petting him for a while he just bit me and wouldn't let go. Whilst that he was meowing as if he was hurt but I checked and he wasn't. It was like when touching a harmed cat and they go to bite but stop because they no better and don't really want to hurt you.
Answer: This change of behavior can indicate that your cat isn't feeling well. He might have asked for pets to comfort him and he might have bitten you because you caused him pain without realizing it.
You should make an appointment at a vet to get his health checked. Tell the vet all of the changes you noticed. They know best what tests to do.
Answer: It is the nature of cats to hide illness. Since
He is behaving strangely, so it would be good to contact a veterinarian. Is your cat urinates regularly?
Comment: welcome to pets, this answer is a bit too short, please add some more information.


If I upload parts of a movie to Google Drive, will I be able to watch the movie in Google Drive?

Question: Recently I came up with the idea to upload ZIP files of movies by splitting a 400 MB movie into 100 MB parts.
Answer: You would be able to upload the files that way, but in order to watch them you would have to download all the parts and rejoin them.  You can't watch a video straight out of a zip file on Google Drive.
I'm not sure why you would even want to do this, as Google Drive will allow you to upload whole videos up to 10GB in size.  Because most videos are already highly compressed, putting them in a zip file would not help either as there would be no space savings by changing formats.
I suggest you just try uploading your videos and see if they will play.  Google is quite picky about the codecs and formats... none of the ones I tested would play, even when in a fairly common format.
More details about videos in Google Drive.


Running several PdfTeX processes in parallel from within PdfTeX

Question: I have a complex document setup where I have to produce several document versions. I want to start these runs in parallel to speed things up - and I want to control this from within PdfTeX. For this purpose I start these runs with a macro from within PdfTeX, as in
\immediate\write18{/Users/xyz/TEX/makeParallel \jobname \space  #1 \space }

This works nicely but produces a sequential execution, which is not what I want. So I tried
\immediate\write18{/Users/xyz/TEX/makeParallel \jobname \space  #1 \space & }

However, this leads to a truncated log file just in the middle of nowhere and a 2K byte PDF file which the PDF reader refuses to open.
Initially I had some suspicions that certain things have problems with reentering PdfTeX again while it is running. A candidate was minted, for example. So I made a complete duplication of all source files and the build directory to separate the instances. NOW, which means 30 hours later, I am starting to get a bit desparate. No matter what I do, sequential executions always work, parallelized versions consistently crash. I already tried all kinds of tricks, such as sending PdfTeX into the background in the shell script and not in \write18 and other stuff. It is still the same. It looks like some process in my build chain (comprising makeindex, BibTeX etc) take offense in my idea and are not cleanly reentrant.
Any ideas what this could be?!?
More details: Commenters correctly point out that I am not giving enough information - which is due to the fact that I simply have tried out too many different variants which did not work.
Initially I did not use a script but started PdfTeX directly in \immediate\write18 which did worked (but only when it was running in the foreground, i.e. without an & at the end). I then switched to the shell version as this makes it easier to change the commands and get them right  as - for me - the TeX escapements needed are less well known than shell.
The different runs do not share any files at all: The shell script first generates a complete copy of all files used in the tex run. In fact: minted and its cache system posed quite some problems so I decided to be that radical and just duplicate the entire environment.
I am running them from write18 and not as parallel jobs at the end: I run this from TeXStudio and it is there that I preview and edit and make my checks. My use case requires to have all the other 6 versions ready by the time the TeXStudio foreground job has completed. So I have to start them early.
\jobname is the first shell parameter, which I need to access the correct filename in the copied environment. #1 is the second shell parameter, which is filled in by a macro such as \backJob{shortVersion}. The shell script then uses this information to make a suitably named directory with all required source files and then start the PdfTeX run there. If I manually start the run: Everything is fine and no other files are touched afaik. If I start the script in the foreground: Just the same. If I start the tex run in the background (either by backgrounding the script or by backgrounding pdftex inside of the script): It breaks.
The must be some file which gets reused somewhere. Maybe some fancy /tmp or some /hidden/somewhere/in/the/system which I missed. But currently my brain seems to run out of suggestions here. I also tried -recorder as command line option to catch any overlapping files, but there is none.
What makes debugging even more problematic is the Heisenbug nature of the phenomenon. Only when I run this from within \write18 with shell backgrounding somewhere turned on does the problem show up.
Comment: Also remember that if any of these documents share files that are being written to then this should not be run in parallel.
Comment: You haven't really given enough information what is the script doing? Do the different runs share any file names (eg `\include ` files) also why run them from write18 you could just use the main tex run to generate a script that runs all the jobs in parallel at the end.
Comment: Are they all using `\jobname`?  I don't see how you're getting different commands.  And if you always have the same `\jobname`, then of course they're going to be writing to the same files and stepping on each others toes.
Answer: Found it! :-)
The problem seems to be connected with the way \immediate\write18 deals with output from the started process in the particular case of background activity.
\immediate\write18{/Users/cap/TEX/makeParallel \jobname \space  #1 \space  > OUTPUT 2>ERROR &}
works fine.
The problem shows up with
    \immediate\write18{/Users/cap/TEX/makeParallel \jobname \space  #1 \space &}
So far the therapy. Wrt diagnosis I suspect: The shell process wants to produce content on stdout and/or stderr and has no place to do so; as result of the backgrounding there is no reasonable terminal connection for this as well - and so somebody just decides to crash the process. This leads to the unpredictable end, corrupted pdf file, log file terminating in the middle of an output line etc.


List of SEO rules for HTML tags?

Question: I know there are some rules related to specific attributes that some tags should have. For example, input, select and textareas should have aria-label on them. I'd like to have a full list of these rules. My goal with this is to produce a tool such as Meyer's Diagnostic CSS Tool, but I'd like it more advanced.
Comment: The tool you want to create would be useful. There are a lot of sites producing cheat sheets, and https://www.w3.org/TR/html-aria/#examples-of-incorrect-usage has a list of incorrect usage of tags.
Comment: Just FYI, you shouldn't use aria-label on form elements, you should have a `` element with a for= attribute pointing to the input.
Answer: I don't think there is a comprehensive list.  As I have discovered when coding my site that it's a moving target and everyone has their own recommendations.  And Readers are not consistent in their approach.
I think that this is a good website ARIA Authoring Practices Guide (APG) Home
Example of Content

Naming with a String Attribute Via aria-label
The aria-label property enables authors to name an element with a string that is not visually rendered. For example, the name of the following button is "Close".
<button type="button" aria-label="Close">X</button>
The aria-label property is useful when there is no visible text content that will serve as an appropriate accessible name.
The aria-label property affects assistive technology users in one of two different ways, depending on the role of the element to which it is applied. When applied to an element with one of the roles that supports naming from child content, aria-label hides descendant content from assistive technology users and replaces it with the value of aria-label. However, when applied to nearly any other type of element, assistive technologies will render both the value of aria-label and the content of the element. For example, the name of the following navigation region is "Product".
Answer: There certainly are SEO rules for HTML tags but what you've highlighted are aria attributes. To the best of public knowledge, these do not have an impact on SEO and Google has stated that this form of accessibility is not one of their ranking factors.

List of SEO rules for HTML tags?


What's the use of subsection directive in the assembler

Question: I did't find so much explanation about subsection directive in GNU Assembler doc, after doing some test i find after compilation there will mot have individual subsection section, if we have the section .test, than define .subsection 1, no .test.1 section in the object file, only test section int the obj, so what's the use of subsection, Can anyone help?
Answer: From what I can see it allows you to go back and forth between subsections with the .next and .previous instructions. In most cases, if you just write your code in assembly, you probably won't need them. That's probably a lot more useful to compilers, making it easier to deal with some situations where you do not yet have all the data at hand.


Why didn't NASA simulate the conditions leading to the 1202 alarm during Apollo 11?

Question: If I understand it, the alarm during the first Lunar descent was due to the computer being overloaded by too much RADAR data.  That sounds like something that they would have thought to simulate, but it seems that everyone was surprised by it.  Why didn't they simulate that particular type of failure (computer overflow in general, and RADAR-caused overflow in particular?)
Comment: Anyone who's tried to bomb-proof their software only to find a problem 3 months later knows the answer here :-(
Comment: istr they did pretty much that exact failure in a sim. Will look for reference.
Comment: You are assuming they didn't have a plan for it, that's not a good assumption.
Comment: @CarlWitthoft And had to write software to meet some high ranking executive's arbitrary deadline. "*If Kennedy wants to get to the Moon before the decade is out, he can come down here and debug the cursed thing himself!*" -- Probably some Apollo software engineer.
Comment: Stanislav Lem's Pilot Pirx story [Ananke](https://de.wikipedia.org/wiki/Pilot_Pirx#Ananke) is about this case. It may provide fictitious reasons.
Comment: You might find this long video interesting: [Light Years Ahead | The 1969 Apollo Guidance Computer](https://www.youtube.com/watch?v=B1J2RMorJXM).
Comment: @OrganicMarble Yeah, looks like they ran into it in a sim on July 5, which prompted the Guidance controllers to put together a list of how to handle the various alarms. (Source is Apollo: The Race to the Moon). Want to put together an answer, or should I?
Comment: @DylanSp go for it!
Comment: The search space is simply too big
Comment: @CarlWitthoft Or had someone suggest "we could (manually) test more" as a response to how bugs made it to production. You're telling me you wanted a tester to test (stupidly obscure long chain of circumstances) because we added in one field elsewhere on the page that was completely unrelated? (Literally unrelated, we just had an unlucky choice of what data we used to validate with in production that lead to discovering a existing bug that was ~2+ years old.)
Answer: They did simulate the debugging alarms, such as the 1201 and 1202. From Apollo: The Race to the Moon*:

On July 5, just eleven days before the launch, [...] the scenario included one of the computer alarms that [Jay] Honeycutt (one of the simulation supervisors) had discovered. When the alarm went off, the controllers didn't know what to do with it.

The Guidance controllers subsequently put together a list of the different alarms and how they should be handled. When the 1202 and 1201 alarms occurred on Apollo 11, Steve Bales (Guidance controller) and Jack Garman (in the Guidance back room) knew how to handle the alarms; as long as they weren't continuously firing, the descent was still ok to proceed.
As for why the general issue of executive overflow (the guidance computer being overloaded) wasn't more thoroughly tested: as much as the Apollo program simulated and tested, there was still a limit to the number of different scenarios they could test in the time they had. Again from Apollo:

[Identifying and learning how to handle the computer alarms] was a pain in the ass, many of [the Guidance controllers] thought, because there were so many failure modes on a descent that were much more likely to happen.

* Chapter 24, end of section 3
Comment: Simulating real radar data in a realistic way must have been a real challenge, if it was even possible.
Answer: As DylanSp's answer notes, the 1201/1202 alarms were simulated, but the details of the computer overload that caused them on the Apollo 11 flight were complex, and were not specifically simulated prior to the mission.
According to Mindell's Digital Apollo:

The trouble was that the rendezvous radar and the rest of the guidance system had different electrical power supplies. They both ran on alternating current of the same frequency, but had different phases (i.e. their alternating sine waves were out of sync). When the change in the [rendezvous radar mode] switch procedure was tested in the lab, technicians connected both to the same power supply, which caused them to run in phase, even though they would be out of phase in the spacecraft...

On Apollo 11, the power supplies on the LM fell into a particularly unfortunate phase angle. Hence the computer and radar were not in sync, causing the angle counters on the rendezvous radar to constantly increment or decrement in response to random electrical noise, sending nearly the maximum rate of data to the computer. The computer struggled to increment or decrement its counters for tracking the radar angles, which used up about 15 percent of its processing time.

More details can be found in Don Eyles' paper titled Tales From The Lunar Module Guidance Computer.
NASA went to great lengths to realistically test and simulate as much as they were able, but a few issues like this did slip through the cracks.
Answer: The lack of phase synchronizing of the two power supplies in the Rendezvous computer wasn't simulated or anticipated because the engineering documentation was in error. It did not require phase synchronization, only frequency locking.
You don't simulate a problem that isn't defined as a problem :-)
Comment: Do you have a reference to back up your assertions? Specifically, that "the engineering documentation was in error." Also, as stated elsewhere on this site, the problem was found twice independently prior to launch https://space.stackexchange.com/a/37372/6944
Comment: Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer).
Answer: The story of the simulation - the last before Apollo 11 - where Mission Control learned about Program Alarms is beautifully told in Gene Kranz's "Failure Is Not an Option", Chapter 15, the best example I know of the supremacy of preparation and training against other more expedite ways of doing stuff. In the simulation they aborted the mission because of the alarm. That would probably be what would happen to Apollo 11 if the simulation would not have happened.


Linear discriminant analysis with $p\gg n$

Question: I am studying Linear Discriminant Analysis (LDA). According to the formula for LDA, we are supposed to get the inverse of within group covariance. However, if $p\gg n$ (i.e., the dimension is much larger than the number of samples), what should I do?
Answer: One possibility is to regularize your estimate of the covariance matrix. See Regularization parameter to generate inverse covariance matrix.
Regularization uses assumed prior-information to turn the covariance inversion into a well-posed problem (this is also mentioned in the wikipedia article)
In practice, you can use a shrinkage estimator of the covariance matrix, such that:
$$\Sigma \rightarrow (\lambda-1)\Sigma+\lambda I_m$$
Where $\lambda$ is a hyperparameter that must be set in advance (and possibly optimized).
Comment: Thank you! That is a good strategy to get the inverse of a matrix. But in LDA, do people also use this method to solve this problem?
Comment: @coolcat Yes, it's even mentioned in the article linked. There are other ways to achieve regularization though. I only presented an alternative.