This app won't run unless you update Google Play services error

Question: I'm kind of lost right now.
I'm implementing an Android application using Google maps.
In order to make it work I followed some tutorials which were pretty efficient. However I'm stuck with this ":

To fix, this problem I found some tricks here or here which tell that to solve this issue you have to take a special configuration for the emulator, here is mine:

and to install some .apk on the emulator.

And the magic is supposed to be done and the map is supposed to appear which is not my case.
I checked that my extras were well installed:

Here is my AndroidManifest:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
          package="mypack"
          android:versionCode="1"
          android:versionName="1.0">

    <uses-sdk android:minSdkVersion="16"/>

    <permission android:name="mypack.permission.MAPS_RECEIVE"
                android:protectionLevel="signature"/>
    <uses-permission android:name="mypack.permission.MAPS_receive"/>

    <uses-permission android:name="android.permission.INTERNET" />

    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />

    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
    <uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" />
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

    <uses-feature
            android:glEsVersion="0x00020000"
            android:required="true" />

    <application android:label="@string/app_name" android:icon="@drawable/ic_launcher">
        <meta-data
                android:name="com.google.android.maps.v2.API_KEY"
                android:value="MYKEY" />

        <meta-data android:name="com.google.android.gms.version"
                   android:value="@integer/google_play_services_version" />

        <activity android:name="Home"
                  android:label="@string/app_name">
            <intent-filter>
                <action android:name="android.intent.action.MAIN"/>
                <category android:name="android.intent.category.LAUNCHER"/>
            </intent-filter>
        </activity>
    </application>

</manifest>

Here is my MainActivity
import android.app.Activity;
import android.os.Bundle;
import com.google.android.gms.maps.GoogleMap;
import com.google.android.gms.maps.MapFragment;

public class Home extends Activity {
    /**
     * Called when the activity is first created.
     */
    private GoogleMap map;
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        map = ((MapFragment) getFragmentManager().findFragmentById(R.id.map)).getMap();
    }
}

and the corresponding layout:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
              android:orientation="vertical"
              android:layout_width="fill_parent"
              android:layout_height="fill_parent"
        >
    <fragment xmlns:android="http://schemas.android.com/apk/res/android"
              android:id="@+id/map"
              android:name="com.google.android.gms.maps.MapFragment"
              android:layout_width="match_parent"
              android:layout_height="match_parent" />
</LinearLayout>

Hope to find some fix or what I missed here, thank you in advance.
Comment: possible duplicate of [This app won't run unless you update Google Play Services (via Bazaar)](http://stackoverflow.com/questions/13691943/this-app-wont-run-unless-you-update-google-play-services-via-bazaar)
Comment: The fact is I follow the steps which are supposed to fix this error but nothing worked for me. So I was wondering what I may have missed
Comment: them you question is a bit missleading, since that error is cause it by trying to run a GPS app in the emulator, either way this http://stackoverflow.com/questions/2279647/how-to-emulate-gps-location-in-the-android-emulator it may help you
Comment: Right now I'm not sure that I'm using the GPS just trying to display a random map.
Answer: In the Android SDK Manager, you must install "Google APIs (x86 System Image)" under "Android 4.4.2 (API 19)". Quit Eclipse and restart it.
Then create a new android virtual device in AVD manager and choose "Google APIs x86 (Google Inc.) - API Level 19" as target. Check "Use Host GPU" to ensure the drawing of the map will be accelerated.
That's it, this new emulator will have Play Services preinstalled and it will run faster because it's a x86 image.
Comment: Any idea how to get an emulator with Play installed using the ADK? It should be possible, but I do not see it....
Answer: using android studio, the only thing that helped me was to reduce the google play services version in the gradle file from the last version to this:
compile 'com.google.android.gms:play-services:4.2.+'

(ofcourse,this is a temporary "bypass" to enable you continue running)
Comment: Out of all the things I tried (running different devices with different os images), this is the one that finally worked! thanks
Comment: It runs for Lollipop (Android 5.1.1) but does not for JelliBeans (Android 4.2). Please someone explain the logic behind this code and what if I want to run the app on JellyBeans and even smaller versions of android Apis. Thnaks
Answer: I had a problem getting this error and hitting the 'Update' button did nothing, it was stuck on a loop, what worked is the following (in Android Studio):

Go to Tools > Android > SDK Manager
Check the 'Show Package Details' option
Under the Android version you want (7.1.1 for me right now), check Google Play Intel x86 Atom System Image

Hit Apply/OK and let the image install
Now go to Tools > Android > AVD Manager
Create Virtual Device
Select one of the devices with a Google Play logo:
Run your app in the new emulator. You can now hit 'Update' when you get the error, update Google Play Services via the Play Store on your device, and test your app in peace.
Answer: To save yourself the trouble of configuring an emulator that does not have google play support,always use an emulator with the playicon
as depicted in the image:The play icon present under the Playstore row.

After installing the google play compatible emulator...run your app in the emulator again...and when you get the notification"App wont run unless......"click on the notification and follow the screen prompts:"Signing In using a gmail account...email and password etc",as soon as you agree to the google licence youl get the google play update screen:
update your google play and launch your app again.
Also make sure you have the google dependencies in your app level gradle and gradle:
App level gradle
build.gradle(Module:app)
dependencies {

}

    apply plugin: 'com.google.gms.google-services'

Project level Gradle
"build,gradle(Project:AppName)"
dependencies {
    classpath 'com.google.gms:google-services:3.2.1'
}

Answer: While the provided answers will work for an emulator, this could be a real issue on a real device and these solutions will not work on a real device. This could happen on an old device that has an outdated version of Google Play Services.
To overcome this issue, the Google Play Services library has a set of APIs to check the availability of Google Play Services, mainly the GoogleApiAvailability class provides a few methods to handle availability issues such as an outdated version.
Now, to detect whether a device has Google Play Services available or not, what I normally do is create a helper method to run the check
private boolean checkPlayServices(){
    GoogleApiAvailability gaa = GoogleApiAvailability.getInstance();
    int result = gaa.isGooglePlayServicesAvailable(getApplicationContext());

    if(result != ConnectionResult.SUCCESS){
        if(gaa.isUserResolvableError(result)){
            gaa.getErrorDialog(this,result, REQUEST_PLAY_SERVICES_RESOLUTION).show();
        }

        return false;
    }

    return true;
}

This helper method checks whether Google Play Services is available or not by inspecting the error code returned from isGooglePlayServicesAvailable. Then it calls isUserResolvableError to determine if the error is resolvable by the user (e.g. by updating Google Play Services). If it is resolvable, then a dialog is displayed for the user to confirm he wants the system to resolve the error. Then call it on the Activity's onCreate method, I run that check as below
//I normally assume Google Play services is available
private boolean playServicesAvailable = true;

@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_map_selector);

    //check for rare case where Google Play Services is not available
    playServicesAvailable = checkPlayServices();

    if(!playServicesAvailable){
        //hide UI elements and turn off features that rely on Google Play Services
    }
}

Hope it helps some out there
Answer: I got this problem only when I am using android emulator from Android Studio.
I solved the problem by adding google-services plugin to gradle:app
apply plugin: 'com.google.gms.google-services'

then on the dependencies
add
compile 'com.google.android.gms:play-services:9.0.0'

previously I was using
compile 'com.google.android.gms:play-services:9.4.0'

but it gives error that there is a version mismatch and it suggest to use com.android.gms version 9.0.0
Comment: If you want to compile with this version compile 'com.google.android.gms:play-services:9.4.0' then you should use emulator with API level 24
Answer: I had the same error. Fixed it by updating Android Studio along with its related Android SDK Tools.
Answer: In Android Studio 3, go to Tools -> SDK Manager and install Google Play services
Answer: I encountered this same error trying to build on Android 7.0. I rebuilt under 6.0 and didn't have any issues. Reverting back 1 API level may help you as well.
Answer: I Solved this problem by:
1- Make sure "Google Play Services" is installed in SDK tools, Like this image:

2- Make sure AndroidManifest.xml file contain this lines:
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />

3- In dependencies of build.gradle add this line:
classpath 'com.google.android.gms:play-services-maps:17.0.0'

Note: you may need change version of play-services-maps from 17 to latest, but 17 is latest in Aug 2019 ...
As this image:

Don not forget to rebuild the project (if you use flutter do this command in terminal flutter clean)
Then you will see the map is working on emulator:


How to map dynamically created table in Hibernate?

Question: I am working on a web application. We are using Hibernate as ORM in our project. Actually, our application creates some tables dynamically based on user selection. The user can select table name, column name and then s/he can import data from a csv file. So my question is: how to map this dynamically created table with Hibernate and Java objects?
Answer: It can be done dynamically, but it's somewhat messy:
You'll need to dynamically alter Hibernate's Configuration object before SessionFactory is built. If you're using Spring, this can be done by overriding postProcessAnnotationConfiguration() method of AnnotationSessionFactoryBean; otherwise you'll just need to do it using your Configuration object prior to invoking buildSessionFactory() on it.
If you need to do this without application restart, you're looking at either rebuilding your SessionFactory (which means your users will have to wait until that's done) or using a separate SessionFactory instance specifically dedicated to your custom classes (which is next to impossible if your custom classes need to reference your built-in classes).
You can get access to class / table mappings via configuration.getMappings(). You will then need to create a new table mapping via Table API and add it to configuration via addTable(). Same thing will have to be done with PersistentClass which represents a class mapping. If you're using the same class to represent multiple entities (e.g. map multiple tables) make sure to use unique entity names for each. You'll have to do this (alter the configuration) on every app restart.
Answer: How much of the tables are dynamically created? Are the tables similar and you just change the database name?
Here is a discussion of changing the table name:
http://www.experts-exchange.com/Programming/Languages/Java/J2EE/Frameworks/Spring/Q_24237099.html
If you are completely building a new table, can you use a view, and just direct people to a view?
Why are you using Hibernate for this, rather than just dynamically creating queries in JDBC?
Answer: The database solution - you can create a view and point it to one table or another (assuming the structure is identical).
CREATE VIEW HIBERNATE_NAME
as
SELECT * FROM TABLE_A
or
CREATE VIEW HIBERNATE_NAME
as
SELECT * FROM TABLE_B
You would need you application to execute native SQL (DDL),
however this should be easier than Hibernate hacks


Why isn't the Recipient field available for Email Alert List Views?

Question: I am trying to create a List View for our Email Alerts & the Recipient field is not available to display as a Column. Why is that?
Answer: In Email Alerts Recipients need not be always a single user or contact. It can have multiple users, Group, Role, Related User or Account team, thus it is not possible to display multiple details in list view.
That's only reason Salesforce designed to not keep recipient in list view columns of Email Alert.
Thank You.


Expand Appearance in Adobe Illustrator

Question: I made a polygon shape in illustrator through stroke options and made it into a dotted line shape. I've applied some transform controls and want to expand the whole shape into individual dots. But whenever i expand the shape, it changes the stroke into fill which prevents me to further expanding the shape. Any one experienced a similar problem. I can't seem to find the fix for it.
Comment: Hi. Welcome to GDSE. What you describe is what expanding is supposed to do. It turns strokes into filled paths.  Why are you actually trying to expand the strokes? Do you really need to expand them? What problem are you trying to solve by expanding?
Comment: You can not actually expand dashed lines to multiple segmented lines. There is just no mechanism for doing this. Instead use a dash you manually made and then use a pattern brush this can be expanded.
Answer: Rather than expanding via the Expand menu items, try using Object > Flatten Transparency and move the slider all the way to the right (vector).
Dashed strokes, at times, don't "expand" properly in Illustrator. Most often they will. But there can be some "voodoo" which takes place based on some (unknown) combination of appearance options that can prevent them from actually expanding to individual dashes/shapes. I've seen it often, but have never been able to nail down what the actual voodoo combo is (haven't earnestly looked though... I just undo and use flatten transparency.)
Flatten Transparency does pretty much the same thing as expanding and will avoid the "voodoo" often seen when expanding dashed strokes.
Answer: Not really clear what you're trying to achieve, but try to experiment with both the Expand and Expand Appearance under the Object menu. Also, this could be useful:

https://community.adobe.com/t5/illustrator-discussions/difference-between-expand-and-expand-appearance-in-ai/m-p/2870068

Expand Appearance in Adobe Illustrator


can I vape 40 days before ramadan?

Question: I know vaping is haram already and I shouldn't be doing it anyway but i jut want to know if it invalidates my fast if i do it in the 40 days beforehand. People keep saying that for fasts to be accepted you have to be toxin free for 40 days before Ramadan so does that include vaping? Does vaping count as intoxicating yourself as your not getting high or drunk, your in a state of knowing what you are doing. I also know that your not allowed to vape during fasts but i really just want to know the ruling outside of fasts. Please help me out by letting me know, jzk
Answer:
I don't know about the before 40 days of fast, but just don't vape at all
Almost all scholars will tell you that vapes are haram at all times

Ibn 'Umar narrated that the Messenger of Allah(s.a.w) said:
'Indeed Allah will not gather my Ummah " - or he said: "[Muhammad's]Ummah upon deviation, and Allah's Hand is over the Jama'ah, and whoever deviates, he deviates to the Fire."
Sunan al-Tirmidhī 2167

Also there are over 2000 chemicals in a vape, they are extremely bad
Vape side effects:

coughing
dry mouth and throat
shortness of breath
mouth and throat irritation
headaches

can I vape 40 days before ramadan?


Where are the locations Clarke has listed in 'Heavy Lies The Crown'?

Question: In the episode titled, 'Heavy Lies the Crown' Clarke has a list of unknown locations that includes: Rendon, Doah, Reva, Rappahan, Mana, Drom, Woodstock, Rockburn, Xandria, Beda, Nadal, Bowie, Dalk, Aldo, and Nopar. Where are they located?
Answer: It appears most of these are corruptions/abbreviations of current cities/locations in and around the Eastern seaboard such as Virginia and D.C. Others are likely new names that emerged. E.g. The most likely explanation of the TonDC placename is Washington D.C.  Other names would possibly be as listed below. The likelihood of these being correct is reinforced if one looks at the listing seeing that it starts with those in Virginia and ends with those in Maryland.  While there are a couple of names I could not identify, if my theory is correct, there should be place names in the respective states which correspond do the names I could not immediately identify.
In particular if one traces a line starting at Dundalk, MD and draws a line Southwest through Washington D.D. to the Shenandoah park/river area, one can see how the place names are in a rough scatter pattern around that line.
VIRGINIA NAMES:
Rendon      - Herndon, VA
Doah        - Shenandoah River Valley, VA
Reva        - Reva, VA
Rappahan    - Rappahannock River & Rappahannock County, VA
Mana        - Manassas, VA
Drom        - ??
Woodstock   - Woodstock (likely the VA or MD location, not the original NY.  But based on the theory above, likely VA given proximity to other VA cities.)
Rockburn    - Rockburn Farm, VA
Xandria     - Alexandria, VA
MARYLAND NAMES
Beda        - Bethesda, MD
Nadal       - Ananndale, MD?
Bowie       - Bowie, MD
Dalk        - Dundalk, MD
Aldo        - Waldorf, MD
Nopar       - North Potomac, MD?
Comment: Nadal = Annandale, perhaps?
Comment: @hobbs.  An excellent suggestion. I have updated with that as an option.
Comment: TonDC we know is Washington DC. What about the actual location of Polis which we know actually stands for Polaris, the name on the pod Becca came down in?
Comment: @Michael.  Nobody is sure on that one.  The following question discusses the issue with trying to locate the tower in Polis. So far, nothing has been confirmed.  https://scifi.stackexchange.com/questions/122351/in-the-100-where-is-the-round-skyscraper-located/154214#154214
Comment: Yes, I saw that question as well. They seem to be trying to find the building. I just want to know the location.
Comment: @Michael. To a large extent I would think they would be one and the same.  I.e. if they find the building, they find the town. Conversely if we knew the town, it could be confirmed by seeing the existing tower in it.  Unless of course, the writers decide to go with the claim that even if the town of Polis is near some current location/city the tower does not exist yet. As the link suggests that might be a deliberate step as the series creator/writers may not want to tie themselves too closely to an existing city as it might constrain future story lines.
Comment: The reality is that it is all filmed in Vancouver, Canada: you are not going to find the building...


Back-up a Coinbase wallet?

Question: Yes I am a newbie trying to get started with Coinbase. I have created a wallet and it seems there is no way to back-up that wallet for safety reasons. I am still confused, can I send an amount from that wallet to a offline wallet and what would the steps be? Thank you.
Answer: You will want to get the address to send it to and it's always good to have multiple wallets but you should be able to contact the wallet company and they can tell how back up the wallet
Comment: Thank you much. So the address is what is needed. Now I understand better. Still trying to understand the nuts and bolts of how this works at the simplest level. So I can create a wallet anywhere and move coin to it? Right now I have Armory wallets but didn't understand how I was going to utilize them.
Answer: Coinbase is an exchange, the least secure way to store your coin. They own the wallet and therefore have ultimate control of your funds. The next best option is to secure your coin on a 'hot wallet' dedicated online wallet (you can use blockchain.info). The next best would be a software wallet which allows you to store your coin on your phone or computer (you could use jaxx, mycelium or electrum), the benefits of these is that you have more control and have control over you private key & recovery seed. The ultimate in security is a 'cold wallet' such as ledger & trezor which gives you complete control over your private keys and recovery see but has added benefits of being offline until required and avoids other cyber security risks such as keyjacking.
Some of the wallets are free, others you have to buy (usually the hardware wallets). Once you have set up your new wallet you can easily transfer your coin from whatever exchange (including coinbase) and backup your new wallet.
Comment: Thank you I understand most of what you have wrote. I have established some other wallets using Blockchain and Armory but have not used any wallets or bought/sold anything yet. . . . Some of my confusion lies in the fact a Coinbase wallet is only identified by an address . . Blockchain is called "wallet ID" and Armory wallet has a ID with a password and rootkeys to recover the wallet.

Back-up a Coinbase wallet?


PN532 + libnfc + linux

Question: Hi i bought a PN532 breakout board, I did install my cable FTDI, i did install NFC, nfc-list recognized my PN532, i did start the nfc-poll, its in listening mode, i've got my mifare card tag that came together and I did try to read, but it didn't read. So where could be the problem? I did solder the pin-heads to the FTDI cable, I connected it to my USB (linux ubuntu 10.04), i downloaded the last stable libnfc, compiled with the options ./configure --with-drivers=pn532_uart --enable-serial-autoprobe, as i wrote, the nfc-list recognized but now i cannot read a card with nfc-pool (but nfc-pool recognized as well my reader, it is in listening).Anything else to debug?
Answer: i found the answer:
PN532 + UART just works with libnfc unstable (1.5.x).
Answer: Was the card a mifare card?
We have build pn532 breakout and we can use nfc-list, nfc-poll and other tools in examples directory.
here is the result:
http://www.xfpga.com/P_view.asp?pid=379

PN532 + libnfc + linux


Where are PHP errors logged to if the error_log directive simply says "error_log"?

Question: I ran phpinfo() and the error_log directive simply says error_log. What file is that referring to? i.e. what would the full path to the error_log be?
Comment: The canonical is *[Where does PHP store the error log? (PHP 5, Apache, FastCGI, and cPanel)](https://stackoverflow.com/questions/5127838/)* (despite the over-specific title).
Answer: Quote from the documentation:

error_log string
Name of the file where script errors should be
  logged. The file should be writable by the web server's user. If the
  special value syslog is used, the errors are sent to the system logger
  instead. On Unix, this means syslog(3) and on Windows NT it means the
  event log. The system logger is not supported on Windows 95. See also:
  syslog(). If this directive is not set, errors are sent to the SAPI
  error logger. For example, it is an error log in Apache or stderr in
  CLI.

So, when the value is not set (which is the default) it will be sent to the parent error logger, which is apache (if run via it) or stderr if you run the script on the command line.
If you use the script via apache you will have to look at the apache error log, usually in /var/log/apache or /var/log/httpd, depending on your distribution. You can check the apache configuration file for the exact location.
Edit:
I just noticed I misread your question, I guess you mean error_log has the actual value error_log?
I just did some testing. When I set error_log to a value like php_errors.log PHP still writes the error messages to the apache error log. It behaves as if the value was empty. When I set the value to a full path (e.g. /tmp/php_errors.log) then it writes the errors to the specified file.
So I guess in your case it writes the errors to the apache error log file.
Of course you can set your own log file be adding
ini_set("error_log", "/tmp/php_errors.log");

to your PHP files where you need it (if it hasn't been disabled by an administrator).
Comment: there's no `/apache` in `/var/log`. but there is an `error_log` in `/usr/local/apache/logs` but it doesn't seem to show any PHP errors. when i run my PHP page I'm getting a blank screen and i want to know the syntax error. `display_errors` is turned off in `php.ini`.
Comment: I believe that `ini_set("display_errors", 1);` tells PHP to echo error messages to the screen via the output HTML.
Comment: you should be able to turn on `display_errors` in your php file itself. Just add `ini_set("display_errors", 1);` at the beginning.
Comment: Another location is `/var/log/apache2` (extra "2") (observed on a [fairly standard LAMP installation](https://www.osradar.com/install-lamp-ubuntu-20-04/) on [Ubuntu MATE 20.04](https://en.wikipedia.org/wiki/Ubuntu_MATE#Releases) (Focal Fossa))).
Comment: in php.ini check APACHE_LOG_DIR
Answer: When the value simply says error_log (or error_log = error_log in your php.ini file), that means the errors will be written to a file called error_log in the same directory that the error occurs.
So, if you have a file called index.php in /home/user/public_html/ that throws an error, the error will be written to: /home/user/public_html/error_log.
If you have file called resize.php in /home/user/public_html/admin/images/ that throws an error, then the errors will be written to: /home/user/public_html/admin/images/error_log

Source: Display and log errors for PHP
Comment: It is probably not wise to keep error_log = error_log, because you don't want random people reading your error_log by visiting your website foobar.com/admin/images/error_log. this is a security concern. (unless you set your server settings to not serve error_log files, however)
Answer: Open your php.ini file.
Check the path against error_log.
Comment: I agree with voting this down for the simple reason that it doesn't explain anything clearly.
Comment: This should not have gotten downvoted, because this is proper usage as intended. People should use the tools provided the way they were intended and only spin their own solution up if it is inaccessible or not supplied. There's too many people on this site that assume that just because it didn't solve their specific issue (and all of it's related but unreported issues) that it's automatically wrong. This is not wrong, and if it doesn't work, then your server is set up poorly, which is your real problem.
Comment: I would add though that logs can also be defined in the apache.conf or vhost.conf as well.
Comment: What do you mean *"Check the path against error_log."* (seems incomprehensible)? Can you elaborate? Please respond by [editing (changing) your answer](https://stackoverflow.com/posts/23286129/edit), not here in comments (***without*** "Edit:", "Update:", or similar - the answer should appear as if it was written today).
Answer: On Windows 10, IIS 10.0.18362.1, I set this in file php\php.ini:
error_log = "C:\tmp\php_errors.log"

or
error_log = C:\tmp\php_errors.log

or
error_log = \tmp\php_errors.log

phpinfo() shows:

error_log    C:\tmp\php_errors.log or  \tmp\php_errors.log

Sometimes directly, but always after iisreset (recycling the application pool).
That is where the file is saved.
Without pad: error_log = php_errors.log it will be written where the error occurs. It has already been mentioned.
Comment: What do you mean by *"Without pad"*? Can you elaborate?


Dual Boot Windows 10 with Ubuntu

Question: I recently bought a new SSD drive for my PC and would like to install a version of ubuntu on it. I installed the drive and managed to get the OS on the SSD but when I boot the PC I'm given no option to choose which OS to use. My boot manager is called ASROCK Boot UEFI
Answer: If no bootloader shows up in the boot process, this could be because you installed the bootloader on your ssd. Go into bios and tell bios to boot into your ssd instead of booting into your other harddrive where windows is installed.
Answer: you can try
sudo update-grub

and see if windows is detected
Comment: Hi @Guillaume, Thanks for replying, At the moment i cant access elementary OS. I can only boot into windows
Comment: In this case you want to boot with [boot-repair](https://help.ubuntu.com/community/Boot-Repair) (boot via usb or cd), and choose: Recommanded Repair.
Answer: You can always modify windows so that it loads the ubuntu bootloader instead of it's own. In windows, just open up cmd as admin, then enter:
bcdedit /set {bootmgr} path \EFI\ubuntu\shimx64.efi

Make sure that this is actually the right path for the elementary OS bootloader, otherwise your system might not boot at all anymore.
Comment: Hi @Nordic can you tell me first how to check in windows the path? I just want to be 100% sure i don't brick the system
Comment: No idea unfortunately, I'm not too familiar with windows when it comes to lowlevel stuff. If I were you I'd just go and ask someone in an elementary OS forum if they can find out if that's the correct file for elementary or not. Good luck!
Answer: You must type msconfig in the command prompt, start tab, choose "normal boot". Reboot and there you can access the secure boot options normally, which are otherwise grayed out. From there you can choose shimx64 or grubx64. Then the boot will be possible.
I had a hard time finding but I got there.

Dual Boot Windows 10 with Ubuntu


What is IPKVM and why would I need that to install SQL Server on my Web Server?

Question: I have a dedicated server, and will be installing SQL Server. However, my hosting company said they can connect an external CD ROM drive and give me KVM over IP to install SQL Server. My question is, what is IPKVM, and how does it work? Do I need special hardware or software on my side to use it....or do I just connect via remote desktop? Also, why can't I remote into my server through remote desktop instead of using KVM over IP?
Comment: This is really more server/system related than programming related.
Answer: KVM switch is a hardware solution for switching one set of input and output devices (keyboard, mouse and monitor) between multiple machines. IP KVM is a KVM solution that allows remote connection over TCP/IP protocol to a KVM switch.
The benefits of using IP KVM vs. Remote Desktop is that there is no direct network connection between the client and the server machine. The client is connected over the network to the KVM switch, which is connected physically to the keyboard, mouse and display ports of the server machine.
You should need only a KVM/IP client software to access the server machine. However, i am not sure what software can be found out there. Your host will probably have instructions and recommended software you could install.
Comment: most IPKVM devices use VNC protocol
Comment: Ah, that makes sense. Then UltraVnc (http://www.uvnc.com/download) is a quite good client the OP can use.
Comment: +1. Also, most IPKVM units I've used implemented JAVA so the only requirement on the client side was a browser that supported JAVA.
Answer: Technology like HP's Integrated Lights Out basically allows you to see the machine's output from boot.
It's more like sitting at the server (or at a KVM switch directly connected to the rack) than a remote desktop which often is not available until the machine boots.
It's almost always supported with dedicated hardware - either external or on a card.
Answer: If you have Remote Desktop access to the server, then you don't need an IPKVM to install SQL Server.
An IPKVM comes in very useful when you have to do actions that are outside of the Operating System (such as make changes to the BIOS) or actions inside of the Operating System that will break your network connection (Changing the system's IP address although can sometimes be done on the fly, having the safety of an IPKVM is invaluable).
I would suggest when connecting via RDP to connect to the main console session of the server for doing activities such as software install.
From a command prompt run: mstsc /v:SERVERIPADDRESS /admin
(or if your RDP client is older, it is /console instead of /admin, you can check which by running mstsc /?)
This connects you to the same session you would get as if you were physically logging in at the server.
Regarding the external cd-rom, that just depends on if you have the media or they do.
If they do, let them connect an external cd-rom and put the CD in, but I'd suggest copying the contents of the CD to a folder on the server for later usage so you don't have to have them connect it any time you need the disc.
If you have the media, just zip up the contents and upload it to your server and extract it to a folder.  SQL Server installation doesn't require to be run from the disc, you can run the setup from a folder on the hard drive.


How to discriminate neutrons and anti-neutrons

Question: I found a question on a test asking how one could distinguish among neutrons and anti-neutrons, and I imagined at a first glance that this could be accomplished by looking at the decay products. But, since the question is not so clear, are there others, more direct ways to see the difference?
Answer: To start of with lets take a neutron. The neutron is made of three quarks. A neutron is neutral overall, however each of those quarks have a charge. This means the neutron has a magnetic moment. This is going to be reversed for antimatter. Antineutrons will have a neutral charge just like a neutron. However its quarks are going to have a charge opposite of those of the quarks of the neutron. This means its magnetic moment will be reversed. Another way could be to check out beta decay for the neutron and anti neutron. If an electron is ejected it can be said that its a neutron. However if a positron is ejected then it can be said it is the antineutron. Also the antineutron will annihilate a proton or neutron and in its place there will be pions. Positive or neutral depending on which nucleon the antineutron annihilated.


What methodologies, processes, and tools are available for designing and modeling non-object-oriented applications?

Question: I'm quite familiar with UML for modeling object-oriented applications. However, I'm not familiar with anything specifically designed for designing and/or modeling procedural, functional, or any other paradigm. How do you design or model applications written in a non-object-oriented language?
Answer: Oh golly, there's a blast from the past.
We used to use flowcharts, pseudocode, data flow diagrams, structure charts, Hierarchy-IPO, "coathanger charts" (which are really a variant of flowcharts), Nassi-Schneiderman diagrams.  Among others.
Oh, SADT is another one.
Answer: SSADM - I think I've still got my certification in a box somewhere...
Answer: UML can be used for modeling non-OO languages as well.  I use UML for modeling just about anything.  To be fair the core of UML is OO focused, but much of the behavior, instance level, and less common structural types work for non-OO languages.  However, UML is for design in OO not implementation, your building blocks/objects are just different, modules, or whatnot.
Many of the diagram types mentioned by Charlie Martin have analogous UML representations.  Even better it is a model not just a diagram/view.
Example:  LISP is not OO based.  So create a keyword or stereo type for classes that is function.  The attributes are the arguments as it has no state.  This is not perfect, but it is the most approachable.
Example: COBOL/JCL is not OO based.  Have each PACBASE package be a component and have structural components as your COBOL.  Artifacts can be your JCL.
Let fact that UML is broad and loosely defined to your benefit and re-purpose UML parts.  You can always formalize it with a UML profile.  Where I work this has been a point of discussion for some time.  Mainframe programmers do not see OO design and OO-UML as relevant, but it is only partially true in that the core or how far most people go with it is just to the class/structural stuff and use cases, which is OO focused.


How can I repair damaged shower enamel?

Question: I used liftoff sealant remover on my fiberglass shower and where it pooled in the corners it has eaten away the enamel. Is there anything I can coat it with to seal it again?
Answer: You could put enamel right back down again.  One common brand of alkyd enamel paint is Rustoleum, commonly referred to as an "oil paint".   You'd want to keep it dry days before and after the repair.
For a more durble repair, use a 2-part epoxy paint.   Those paint systems have a fairly high entry cost, so I wouldn't do it for that job alone.  But if you already have access to it relating to something else you do, it can't be beat.

How can I repair damaged shower enamel?


Kol Isha and transgender people

Question: Does the Halachic prohibition of Kol Isha apply to transgender people? So if a woman underwent operations to present as a man, can you listen to her sing? And what about a man who visibly looks like a woman? The reason I ask is because although gender in Halacha starts at birth, Kol Isha (to my understanding) is only Derabbanan so many opinions say the prohibition applies when you see the opposite gender person, not merely hear them.
Answer: Following our discussion in comments, I discussed your question with R Binyamin Tabady, a posek halacha in Israel, who confirmed my initial thoughts.
The obligation of kol isha is on the listener. Since halakha doesn't recognize gender changes, a man remains forbidden to listen to the voice of a biological woman, even if that person calls herself a man, or had surgery to look more like a man.
Similarly, a man who looks like a woman would not create an issue of kol isha is other men listened to that person sing.
The issue might theoretically be different if the transgender person had vocal cord surgery which resulted in his voice being different, although that requires further study.
For further sources see here, here and here.
Comment: @MosesSupposes sure, but that would likely be lifnei iver and lo taturu respectively, not kol isha
Comment: What happens if the listener thinks he is listening to a biological woman when he isn't?  Does that make any difference?
Comment: Vocal cord surgery isn't always necessary for a person to change their voice from female-sounding to male-sounding or vice versa. A person with a female-sounding voice who takes testosterone as a medication will generally end up having a male-sounding voice as a result. A person with a male-sounding voice can perform training techniques which result in the ability to sing or speak with a female-sounding voice.
Comment: @MosesSupposes the answer takes the route that kol Isha is objective not subjective
Comment: @RabbiKaii It might not technically be kol ishah then, but surely even then it is a problem for a person to do an action that they believe is an aveirah, and surely it is even more of a problem then if the listener is attracted as a result!?

Kol Isha and transgender people


Would the Rutherford gold-foil experiment work inside of an alcohol cloud chamber?

Question: Basically as the question asks, if you set up an alcohol vapor cloud chamber with the gold foil inside, wouldn't you be able to "see" the alpha particle's path the entire time? It just seems like the demonstration would be way cooler (pun not intended) and visually interesting. I'm just wondering if any issues would arise that would cause the two experiments to interfere.
Comment: Which is a neat story in and of itself, PMS Blackett searching through 400,000+ tracks in 23,000 pictures to find the 8 nuclear reactions. Never let students complain about the tedium of data analysis...
Comment: Sure it would work, but there would be many more tracks heading to the foil than backscattering. Cloud chamber pictures did reveal alpha-induced nuclear reactions in the 1920s.
Comment: Look at Figure 1 in the Wikipedia article [Rutherford scattering](https://en.wikipedia.org/wiki/Rutherford_scattering).
Comment: @Farcher So not only is it possible, it's been done. I couldn't find it before, so thank you!
Answer: It seems that Rutherford himself saw the tracks of alpha particles in a cloud chamber,

Cloud formed on ions due to α-Rays (Image: CTR Wilson Roy, Proceedings of the Royal Society A, Volume 85, Plate 9)

. . .

The tracks of the particles become visible as trails of droplets, which can be photographed.

You ask:

I'm just wondering if any issues would arise that would cause the two experiments to interfere.

I do not think there  is a problem of interference. The original experiment was in a cloud chamber after all. See a video here.
Comment: Awesome, thanks!


How close are we to fabricating a Germanium IC?

Question: I am not actually talking here about SiGe(Silicon-Germanium hybrids) but an integrated circuit that uses entirely Germanium(doped of course in certain areas)? It is my understanding that even though Germanium was used to make the first discrete transistors, there are many problems with using it as a substrate for IC fabrication. Such as the fact that Germanium Dioxide is water soluble.
Comment: What would be the advantage of Ge semiconductors? I fail to see that.
Comment: @MarcusMüller - Lower characteristic voltages means less power. Note that Ge was popular for some power products for quite a while, but the development of Schottky diodes effectively killed the class. Intrinsic electron mobility is higher as well, so Ge was faster.
Comment: I have access to germanium wafers that we use for power applications.  It's direct bandgap, so that's nice for as you do not have that lattice vibration when due to the shift.  Generally, all of these are cost considerations.  It's 1k for a Si wafer, and 10k for a sapphire wafer.   I have no idea how expensive the Germanium wafers are.
Comment: Interesting Question +1 .When I was a teenager there were Si and Ge transistors in about equal numbers .All the ICs were Si .I asked the same question then .Ge had lower VCE sat and VBE and more gain .I was told by people long dead that thermal drift would be really bad .This seemed believable because you had to be careful when designing direct coupled amplifiers .I was also told that there was a limited amount of Ge and an abundance of Si and that in the future everything would be electronic .
Comment: @Mr X .Ge does have some downsides so there must be a compelling upside to make this a runner .
Answer: We are not close to making pure Ge ICs, and likely never will be. The odd diode or power device where the low voltage wins, yes, but the process technology for significant integration, no.
The technology to be able to process silicon into ICs as we do today has been won over 40 to 60 years (depending on your start date) of painstaking incremental investment. Given a choice between a tweak that uses the existing silicon processes (continue to reduce dimensions, alloy Ge with it, put it on an insulating sapphire substrate) and a totally new material to learn how to process and handle the chemistry, the choice will be for silicon, unless there is some huge advantage for the new material.
A big, big drawback for straight Ge is the low temperature performance of the material. You can't solder ICs by bringing the whole board up to temperature as you can with silicon, it's hand solder leads or clamp only, and then use excellent heatsinking. What the market wants in higher temperature performance, that's one of the things driving SiC for instance.
IC require much more than discretes, every aspect of the physics and chemistry, the resistors, the well capacitance, the oxide stability, the interconnect metals, the lattice sizes to mention a few from a long list, all form part of a system within which the IC designers work.
Discretes are a little more forgiving, and here new materials do get used at a low level of integration. GaN is making higher speed FETs, SiC is making higher voltage higher temperature transistors, SiGe first appeared in discretes for a decade or two where the teething troubles were sorted out, then there's InGaP, and AlGaAs, and a host of others, and Ge too for some specialist diodes and power transistors.
Given how long Ge has been around, it's obvious that there is not a sufficient performance advantage to make it worth trying to work with the material's problems on any significant scale.
Comment: @MrX My answer left out one of the most important drawbacks of Ge which is the low temperature, I can toast a germanium device at lower than 100C (ask me how I know!) So germanium devices are unusable on modern boards, only working when you can clamp them, like power diodes, or use hand assembly with leaded devices. So still no incentive. Germanium as a component material yes, look at SiGe, but it runs through a silicon process.
Comment: So what you're saying is there is no incentive to learn how to fabricate Germanium ICs. But that it is not impossible.
Comment: Good point. Germanium is only useful for low voltage devices but it's greater electron mobility and low barrier potential might make it very useful for high GHz/THz applications. So a Germanium IC would need more extensive shielding.


Did Goddess Manasa live in Bengal?

Question: I have heard that Goddess Manasa lived in Bengal. Is this true or false?
Comment: You mean Mount Kailas?Actually God's plane of existence is quite different from our concept of planes.They actually don't literally live on earth.Martya loka is for only those beings to live upon who have "mrityu" or death & Gods don't have it.Lord Shiva actually resides in Shiva Loka & it would not be entirely correct to say that that loka is on the earth itself. ;)
Comment: Gods don't live on earth.Earth is for we humans.Gods have their respective Lokas where they reside. :).In short Devas reside in Deva Loka,Asuras in Patal Loka and Humans in Martya Loka (i.e earth).
Comment: @Rickross,but why Lord Shiva lived in Earth?
Comment: @Rickross,your answer is not true because everyone knows that Lord Shiva live in Mt.Kailash which is in China!!!
Comment: @Rickross,why Lord Rama,Lord Krishna and Hanuman were lived in Ayodhya,Vrindavan and Mathura? Now answer!!!
Comment: All of them are incarnations of Gods.And they were born on earth from human yonis.So,they are bound to live on earth.:)But is Goddess Manasa a human incarnation born of a human yoni?Don't think so.
Comment: You should ask some chinese people then if they know about someone called Lord Shiva living in their country.:)
Answer: I don't think Goddess Manasa(মনসা) lives in bengal! because she is a goddess.God or Goddess don't live in earth. you might know goddess Manasa has 12 major names, one of them is Vaishnavi. though Surasa is the name of kashyap muni's wife one of the dahsha putriee. Goddess Manasa is also called Surasa. such like Padmavati is the name of goddess Lakshmi, but Goddess Manasa is also called Padma or Padmavati too. Manasa devi is a form of Shakti.as mata saraswati is power of knowledge, mata Lakshmi is power of wealth, mata parvati is power of stamina or kriya shakti. same to same Mata Manasa devi is the power of will that means ishsha shakti or chinta shakti. In Adya strotram it is said that,  adi parashakti lives in nether world in the form of vaishnavi.and she lives in manidweepam in the form of Surasa.  so it is clear that Mata Manasa devi maybe  lives in manidweepam or she lives in nether world ( patal lok). By the way, goddess Manasa is not a just bengali devi! She is also worshiped entire Indian subcontinent in many forms,,,,, such south Indian people worship her by the names Karumariamman( Not Mariamman), Nagathamman,Nagamma, Nageswari amman etc.
so i think You got your answer my friend  :-)
Answer: Yes, Goddess Manasa lived in Bengal. That's why she is mainly worshiped in the Bengal region. Behula and Lakshmichandra also lived in the Bengal region and that's why Manasa could disturb them. Manasa's actual name is 'Monosha' which is a Bengali name. Believe my answer and this is truth!
Comment: You mean if Goddess Manasa lived on some other planet or in some other parts of India(other than bengal) then she could not have disturbed Behula & Lakshindar ? :)
Comment: @Rickross,are you sure that your answer is true?
Comment: I don't know exactly if what you are saying is true or not.Incarnations of Gods as humans can only live on earth,Gods don't live on earth so to speak.Anyways,you should try to post citations for your answer as well.:)

Did Goddess Manasa live in Bengal?


what is the difference between the usb booting mechanism and optical disk booting mechanism?

Question: Many distributions of linux/bsd have separate usb and dvd images and writing the dvd image doesn't seem to work. What is fundamentally different between these two mechanisms?
Answer: First of all, USB means Universal Serial Bus.  It is a standard for a control and data bus, just like PCIe, PCI, EISA and ISA are all buses.  USB is not a device, like a CD or DVD drive.  (Optical drives typically use SATA or IDE buses with the ATA protocol.)  When you use or refer to USB, there is probably an attached device (aka USB gadget) that you are actually referring to.
In this case you are probably referring to USB flash drives, which essentially emulate a typical hard disk drive.  If the PC's BIOS supports booting from a USB device, then that means that the BIOS has embedded firmware that includes a USB protocol stack, and can control a target device like a flash drive over the Universal Serial Bus.  After the USB handshake protocol is established between the USB host (the PC that needs to boot) and the USB gadget (the flash drive), the control and data mechanism provided by USB can be abstracted away, and upper layers of the BIOS boot code can treat the flash drive just like a HDD.  That is, the first sector of the "disk drive" has to be read in order to obtain its Master Boot Record (MBR).
Optical discs do not conform to the PC hard disk layout (there is no MBR at sector zero).  In fact there are several formats for optical disks, but the data layout in common use with PCs is the ISO 9660 format for CDs.  The requirements for booting from CD/DVD are spelled out in the ISO 9660 standard.
The data transfer rate and physical capacity difference between different boot devices essentially become irrelevant if the BIOS supports the device.  The I/O characteristics of each supported boot device has to be accounted for, and are handled in the low-level device driver code of the BIOS.  Note that most PCs can also boot from the Ethernet network interface card (NIC), and that interface is far more different than CD/DVD versus HDD.  Yet the layered approach to software implementation delegates all that low-level I/O and protocol handling to lower layers, and the BIOS can proceed to load & execute the next stage of boot loader.  Note that some device differences are parameterized.  That is, the device's number of cylinders, heads, sectors/track and sector size are not hard coded in the device drivers, but rather are read from the device, e.g. the BPB in the MBR.

... writing the dvd image (to the USB flash drive) doesn't seem to work.

The difference between these two media layouts can be dissolved by combining the two into a merged image file that can be copied to either a CD/DVD or a HDD/flash drive.  An ISO image (for burning to a CD or DVD to make a bootable disc) can be modified for straight copying to a HDD or USB flash drive to produce a Hybrid ISO/IMG image:

The Hybrid ISO/IMG format is a modification of the standard ISO format to make the image compatible with the expectations of hard drive booting
A standard ISO image typically includes the ISOLINUX boot loader which is loaded by the BIOS using the El Torito booting standard. The Hybrid image replaces the first 512 bytes of the ISO format (which is all binary zeros) with a PC hard drive Master Boot Record (MBR) containing: The stage 1 loader image from GRUB version 0.97, and a partition table with 1 partition that ends at the end of the hybrid image. The remainder of the ISO image is not modified.
Additional sectors are added at the end of the ISO image.
Comment: Great answer. And there is a linux tool to make an iso image a hybrid image: `isohybrid`.
Comment: That means a hybrid will still use a UDF filesystem?
Answer: DVD has it's own mechanical properties and 2K block size.
Older joliet boot mechanism involved adding extra 2.88MB bootloader floppy to install CD (like NT4 did)
In theory you can have same image bootable using the new CD/DVD boot protocol (without floppy image) and USB stick (and CF card, IDE disk etc etc). Most vendor images work like that BUT some BIOSes are programmed to prefer one or other boot mechanism.
Answer: Actually, theorically there is no difference, a DVD or a flash will have the same boot mechanism, the difference will be the transfer rate from DVD to a flash device(USB 2.0 have higher transfer rate than a DVD). What maybe is being your problem on booting from flash or DVD is that your flash haven't a bootable partition active on it. On a DVD image you don't need to set it as bootable if the iso/img that your written on it was already set to be bootable(on a flash you will need to set it manually). Take a look here to know how to make a flash bootable device.
Answer: The boot mechanism is not different because the same way USB boots as the DVD does, but there is a lots of difference between the read/write speed of the DVD v/s USB.
USB 2.0 spec has a max speed of 480 Megabits per second. So you're talking 60 Megabytes per second.
DVD - Lets go with a 16X DVD reader = 21 Megabytes per second.
But the CD/DVD speeds are all MAX speeds, which means they wont be transferring data at this speed until the very outer of the disc is reached in a lot of cases. You might have a CD Reader that starts off at 24x at the start of the disc, and only reaches 40x when it gets near the end. Same kinda deal with DVD readers. Might start at 8x, then go through to 16.
You have make USB disk bootable with some tricks because normally they are not bootable by default while when you burn an iso/nrg image on DVD which has the Windows or Ubuntu installation files it will automatically become bootable.
WintoFlash is a tool which make USB stick to bootable. There are some other software too and also you can make bootable stick through cmd on Windows.


Where is sculpt paint data stored (Blender 3.2)

Question: When the new sculpt paint brush (new ver 3.2) is used to paint on the object, where is the paint data saved? How can it be accessed from python code?
Answer: The paint brush writes to color attributes of the mesh. You can access it like so:
<code>import bpy

mesh = bpy.data.objects['Cube'].data
color_data = mesh.color_attributes['Color'].data

# Color data is a per-vertex array, these two have the same size
print("Vertices: ", len(mesh.vertices))
print("Colors: ", len(color_data))

print(color_data[100].color[:])
color_data[200].color = (0.6, 0.2, 0.1, 1)
</code>
There seems to be experimental support in the latest alpha for texture-based painting but not in 3.2.


Merge tags on superuser [virtualmachine], [virtual-machine], and [virtualization]

Question: I noticed a similar question here, but it seems nothing has been done...  On superuser there are tags for virtualmachine and virtual-machine.  I think these two at the least should be merged, if not also merge virtualization with it.  I mean first of all, virtualization is not a word haha... and second, it doesn't make sense to have two or three tags for the same thing.  Redundant and inefficient.  Please merge them.
Comment: Add `vm` to the mix, as well.
Answer: I have done the following merges. I used the latter since it is the most commonly used.
virtual-machine --> vitualmachine
vm --> virtualmachine
However I am not merging virtualization since it has a different meaning to virtualmachine.
Comment: Normally names in tags are separated by hyphen on SOFU, aren't they? So [virtual-machine] would be correct.
Comment: @John Normally yes. However in this case I went with the tag most used since this is the tag the community is using and this is what was used during the previous re-tag.


Is there any material capable of cancelling low frequencies sounds like a thunder (60Hz)?

Question: I was thinking in materials for a Dog Kennel, to prect it during storms and also fireworks.
I know there are a lot of materials to reduce noise, but I've also read is very difficult to reduce low frequencies, so I'm not sure if this is even possible.
Comment: why do you think that the sound of thunder has a frequency of 60 Hz? ... sound of thunder is caused by a shock wave similar to an explosion or a hand clap
Comment: You can see the spectrum here: https://en.wikibooks.org/wiki/Engineering_Acoustics/Thunder_acoustics there are high frequencies too, but them are reduced much more by materials, the problem is the low frequencies
Answer: Acoustic foam could be used to dampen all noise and create some insulation, thunder & fireworks contain broad band noise everything from low frequencies to high frequencies, 60hz is the noise you hear around transformers.
If you insulate and have a dead airspace that will also provide some shelter from the noise. I have trained hunting dogs and use a starter pistol and after the noise treat them with a cookie (dog treat like the tiny milk bones) within a few days they are not bothered by the noise and we change from food treats to toys to chase this has been great for young dogs,
For dogs that are noise shy I have only found getting mild tranquilizers was the only thing that worked well. I had an Australian Shepard that went through several windows trying to get out of the house so we would put her in her kennel inside and give her a pill in some cheese to keep her from getting heft and breaking more windows.


is there any c++ compiler for ipad2?

Question: I am a student in college and just started to learn C++. I have an iPad 2 and no computer (it broke and I will not buy another one). So I want to find an app that seems like codeblock for Windows. The ability to run code and maybe can fix it is a big plus. Thanks a lot!
Comment: Many/most(?) colleges offer computers for students to use.  You could install an SSH or VNC client on your iPad, and connect to a networked computer which has a C++ compiler.
Answer: No fully functional IDE exists on iOS to make runnable apps without jailbreaking  but you can sign up for a free Amazon Web service account and get an ssh client and program "on the iPad" assuming you have a network account.
An app like nimbus or textastic would be an ideal companion once you were clear how compiling elsewhere fit your desire to learn.
Xcode is currently only available for Mac OS X to develop programs that run iOS and cocoa touch (not which is very much not C++ - even though Xcode can be used for C++).
Have a look at this question on learning C which will apply almost entirely to C++ on iOS.
Is there a C compiler for iPad?
Answer: Is your iPad jailbroken? If yes, download mobile terminal (a commandline) , vim (the text editor) and the gnu c compiler from cydia, and google for a file "iosgcc.zip", download, unzip, and enter the terminal and install the package of g++.
The way to jailbreak depends on the version of your iOS, visit www.jailbreakme.com as a reference.
Answer: There is no compiler that runs on the iPad. There are numerous web apps that will accomplish what you're probably looking for.  This of course assumes that you are not hoping to use an iPad as a development environment.
Have a look at:

CompileOnline: Has C++ and many other languages. It's simple with no account necessary.
CodePad: Very simple. For short snippets only.
Compilr: Requires registration, but is more like a full-blown Web-ide app with storage available for your code.

Google searches will get you further.  If you are looking for short, snippet based online compiler / interpreters abound.  Compilr works with the iPad and is looks to be sufficient enough to support small projects or college-level coursework.
Answer: The development environment for iPad is called XCode and runs on Macs only.
I would suggest you should look into anything that will allow you to enter code,compile it and run it in a browser window instead.
Answer: Try CppCode ios app - http://www.cppcode.info. No jailbreak required, no internet required, free(mium)
Answer: If it helps, there is Java for iPad on App Store but you will have to pay to compile
Comment: Not sure if these apps are all that useful, but for completeness, it should be added that there is also a C++ for iPad app by the same author: https://itunes.apple.com/us/app/c++-programming-language/id461327665?mt=8

is there any c++ compiler for ipad2?


Programmatically save coordinates

Question: I have read in a lot of sources that I should use the geofield_compute_values() when trying to programmatically save coordinates in Drupal, but it does not work for me. That function doesn't exist in Drupal 8.5.2.
I've installed the Geofield module using Composer and I can use it as usual in the admin area. There are no problems with saving.
This is the code I tried, which returns an error about a not existing function (geofield_compute_values()).
$geofield_data = geofield_compute_values(['lat' => $lat, 'lon' => $lon    ], GEOFIELD_INPUT_LAT_LON);
$cbisProduct->set('field_koordinater', $geofield_data);

I have also tried this out with no successful result and no errors.
$geofield = [
  'geom' => "POINT (" . $lon . " " . $lat . ")",
  'geo_type' => 'point',
  'lat' => $lat,
  'lon' => $lon,
  'left' => $lon,
  'top' => $lat,
  'right' => $lon,
  'bottom' => $lat,
];
$cbisProduct->set('field_koordinater', $geofield);

I also tried the solution given in How to save LNG and LAT progamatically in a geofield, but it didn't work either.
How can I programmatically save coordinates?
Answer: Try this:
$entity->set('field_geofield_name', [sprintf("'POINT (%s %s)'", $longitude, $latitude)]);

Cheers!

Programmatically save coordinates


Using NAS as ESXi Datastore?

Question: Is there a way to add an external USB HDD that is connected to my Netgear Rangemax router via USB to ESXi 4.0 as a datastore? The external is formatted as NTFS and I have data on it already.
Comment: does the rangemax support nfs?
Answer: Can the NAS expose the drive via either iSCSI or NFS? If so, yes. Be prepared for awful performance, though. You'll be using a desktop-class hard drive, connected via USB to an underpowered router that isn't intended to ship around the amounts of data you'll be throwing at it.
Comment: NTFS and "existing data" will also be a problem, but as Erik said, the main problem is going to be... everything else.
Comment: Agreed! I guess it's fair enough if you're just having a play but don't even contemplate it in production!
Answer: I have done this!
Successfully or not, that is the question..
We connected a Buffalo TeraStation over USB to one of the ESX hosts, then connected the device to a Fedora Linux VM, and served up the (pre-existing NTFS contents) as a NAS datastore.
We used it only for VM backups and archives, since the performance was ABYSMAL.
I don't remember exact performance numbers, but it was around 20x slower than the local RAID5  disks in the host, and maybe 100x slower than the FibreChannel SAN.
(I'm vaguely remembering 3MB/sec vs 60MB/sec vs 300MB/sec??)
But it was incredibly useful as a place to stash temporary backups off the SAN during any kind of risky maintenance, and also to transfer VMs between the data center and the office.
(A 2TB disk in a taxi can provide better throughput than a 100Mbit WAN!)
Comment: Obligatory A.S. Tanenbaum quote (the second one from the top): http://en.wikiquote.org/wiki/Andrew_S._Tanenbaum.
Comment: I remember seeing somebody once calculate the bandwidth of a 747 cargo container filled with DVDs...
Comment: 2TB hard disks are the way to go.

Using NAS as ESXi Datastore?


Can heat travel up an airflow

Question: I know heat travel from hot to cold places and natural airflow (e.g. wind) travel from high pressure to low pressure. But, if a forced airflow is blowing toward a hotter place, would the heat travel upstream and warm up the source of the airflow?
Answer: Heat can be transported by heat conduction, convection and heat radiation. Heat can definitely be transferred by heat radiation against an air stream.
Answer: Yes, This phenomena is apparent in forest fires, in which the fire travels DOWN the hill against the updraft. The reason is that thermal radiation goes up as the 4th power of absolute temperature, so thermal radiation dominates at high temperatures as seen in fires. (Stefan-Boltzmann law.)
At room temperature, convection and radiation are about equal. But if the temperature of the radiant object is, say, 1200C (1500 K), that's 5X the 300K room temperature. So 5 x 5 x 5 x 5, or the thermal transfer by radiation is now 625 times stronger! This can explain the rapid advance of forest fires as well as the ability of fires to flash ignite entire buildings rapidly.
Your question seems to be asking an engineering question about a particular geometry. More details would be needed for that specificity.
Answer: If you are talking about (a) heat conduction and (b) heat convection by fluid flow in the opposite direction, then this can definitely be modeled to help answer your question.  Consider heat conduction in the positive x-direction combined with fluid flow in the negative x-direction with speed V.  Let's focus on the region from $x = 0$ to $x =\infty$, and let the temperature at x = 0 be maintained at $T_1$, while the temperature at large x is equal to $T_0$.  The heat transport equation for this situation with combined conduction and convection is described by:  $$-\rho CV \frac{dT}{dx}=k\frac{d^2T}{dx^2}$$where the left hand side represents the convection back toward x = 0, and the right hand side represents conduction.  $\rho$ is the fluid density, C is the fluid heat capacity, and k is the fluid thermal conductivity.  The solution to this equation, subject to the prescribed boundary conditions is given by:  $$T=(T_1-T_0)e^{-\frac{Vx}{\alpha}}+T_0\tag{1}$$where $\alpha$ is the thermal diffusivity:  $$\alpha=\frac{k}{\rho C}$$According to Eqn. 1, the length scale for the temperature variation near x = 0 is on the order $\alpha/V$.  The thermal diffusivity of water at room temperature is $0.143 \times 10^{-6}\ \frac{m^2}{s}$, so even for a small fluid velocity of 0.1 m/s, the temperature disturbance at x = 0 would only propagate upstream a few microns in x.  Even for air, which has a thermal diffusivity at room temperature and 1 atm a little over 100 times that of water, the disturbance would still only propagate upstream on the order of a few tenths of a millimeter.

Can heat travel up an airflow


Is a ceremony needed before fasting, like with Shabbat?

Question: Is a ceremony needed before fasting, like with Shabbat? I have never heard of it, but if we do it for Shabbat, both to end and to start, it wouldn't be strange to have some kind of ceremony before fasting. (I'm not referring to Yom Kippur).
Comment: I think the important point here is that fasting is about what you do with the time off from eating (read: repent, pray, study Torah, and do good deeds), not defining a "holy zone" of time. Fasting without doing anything productive is a waste of time. cf [Isaiah 58](http://www.mechon-mamre.org/p/pt/pt1058.htm)
Comment: What kind of ceremony are you thinking of?
Comment: I dunno.Candels or prayer maybe.To start and to end the fasting before Hashem.
Comment: @DoubleAA "Fasting without doing anything productive is a waste of time." Yes and no. Certainly the point of a fast is to repent, etc., and not to fast. But someone who fasts fulfills the requirement to fast and someone who doesn't doesn't. If someone is, _chas v'shalom_, going to not repent on the fast, to also break _halacha_ and eat would be compounding his error.
Answer: Without calling it a ceremony, you are actually correct that there is a declaration that an individual who wishes to fast says during the minha amida of the day before a voluntary fast

Master of all the worlds, I come before you to accept a voluntary fast
  voluntary for tomorrow. May it be your will, Hashem
  my God and the God of my forefathers that you accept me with love and
  favor, that my prayer shall come before You and that you answer my
  entreaty in your abundant mercy. For You hear the prayer of
  every mouth.

On Mincha of the fast itself, he recites a similar statement (see siddur for more details or Shulchan Aruch Orach Haim 565:4).
On official fast days (e.g., 10 Tevet, 9 Av) there are of course similar prayers. What is special on voluntary fast days is a statement before the fast to "announce" it.
Comment: Thank you,good answer. I was going to ask as well"Why do we fast?"in another question,but the question is so big,I dunno if I would get a good answer.But its a great topic,fasting
Answer: The fast days of Yom Kippur and Tisha B'av have a ritual meal before the fast (seudah hamafseket, the separation meal), which is a ceremony of sorts. (I know you say not Yom Kippur, but i'll address it anyways.)
The meal before Tisha B'av is a sad, mourning style meal, eaten on the floor in solitude. Many people have the custom to just have a piece of bread and hard-boiled egg. See Wikipedia or OU for a quick summary.
The erev-Yom Kippur meal is a festive one, a la a Yom Tov meal. People sit together and have normal food. See, for example, Chabad.org.
Comment: The same is true of the post-fast meals, there. Post Tisha b'Av we don't have meat or wine, while post-YK is a quasi-Yom-Tov.


Curved glass reflections in Glass material

Question: Why is Glass material displayed fine on one object, but material with exactly the same settings shows some kind of nonsense on another? For example, glass of car. The one shown above has transparent glass, while the one below is black & has curved glass reflections.
I tried to add Subsurf, tried changing Light path settings, turned off Auto smooth, tried different glass settings, but nothing helped.
And this happens often. Please tell me what it depends on & how to fix it?
Comment: Your Glass material behaviour the same for me. Clear Custom Split Normal Data and add Solidify modifier.
Answer: The simulation of refraction depends on light rays being bent twice. Once on the way into the glass, via a front-facing surface, and once on the way out, through a back-facing surface. Your 'good' glass has thickness, so it works. Your 'bad' glass doesn't.
No thickness:

With a Solidify modifier: (No rim. 'Fill' unchecked, so as not to bother with normals interpolating over the rim walls)

If you want a rim on your glass, you will have to bevel it too, to sharpen the interpolation of normals from rim to surface.
Comment: I know ... I just that both answers are speaking in general about same thing ... I wanted to keep it cleaner, but OK. I still live in an illusion we are creating a "cookbook" where people can find solutions for their repetitive issues ... but it is an illusion ... we are still answering the same questions. Even for me (after a few years here) it is almost impossible to find same (already asked) question ... so instead of spending time on searching of dupli, we creates new one. Grrr
Comment: It worked! Now glass looks like it should. Thank you so much!
Comment: @Robin Betts Since your images are more illustrative ... if you extend your answer about Clear Normal Data info ... I'm ready to delete my answer :)
Comment: @vklidu IMO your answer is just fine! (UV'd). I didn't clear the normals, because the only distortion I got was from the interpolation to the rim of the _Solidify_ modifier. So my way was just to solidify without the rim, which can't be seen, until the OP rolls down the windows :)
Comment: Yup. maybe I should just have left the 'rim' point as a comment on your answer, and not posted. You were first, and accepted. I'll look out more carefully in future.
Comment: Forget it :) Leave it as it is. I like your screens here :)
Answer: In provided blend both materials behaves the same for me.
Anyway ... bottom one seems to be correct from material setup perspective. Glass needs a thickness otherwise cycles thinks it is an "endless" glass volume.

Since you add s thickness like Solidify modifier, Cycles know where glass begins and where ends its depth. But as you can see there is some issue with normal orientation.

Go to Data Properties > Geometry Data > Clear Custom Split Normal Data

I guess, this is result you are expecting from glass material.
Comment: I hadn't noticed the custom normals .. I guess they might be a Data Transfer from a more heavily subdivided mesh, for economy?
Comment: Yes, this is exactly what I need. Thank you very much for your help!
Comment: @RobinBetts Probably ... I'm not such experienced with Normals, I just saw the "crazy" reaction of Solidify, that didnt react on Auto Smooth :)


neon effect to textures libgdx

Question: I am working on a live wallpaper with Libgdx .
I am wondering if I can give neon glow to my textures , at runtime .
Is this possible? If yes can anybody give me any pointers?
Comment: There's nothing particularly "libgdx-specific" about this question; glow effects can be implemented in basically the same way across many engines/platforms. Tweaking the result to be more like a neon sign versus a glowing fireball is primarily down to tweaking the art asset representing the glow's blur.
Comment: Hi, and welcome to the site. This site is for questions that are more like "well I tried this and got stuck here, how do I fix it?" -- your question will (sadly) probably be closed.
Comment: There's a lot of [related questions](http://gamedev.stackexchange.com/search?q=glow) here already, as well.
Answer: Theoretically, sure. Two approaches come to mind:

Write a shader
Fake it

For faking it, you could draw four copies of the sprite (offsetting horizontally and vertically by 1px above/below/right/left of the main image) and tinting that to your neon colour.
I haven't tried it, so your mileage may vary.

neon effect to textures libgdx


Can residents of another state(say WA) have a driving license in California?

Question: Asking for my girlfriend. She lives in WA where we do not have a car there but visits me in CA frequently. And we have our car in CA, which she needs to drive. She does not have a WA license and does not plan to have one for WA. Since she does not need one.
Comment: She won't be able to get a California driver's license unless she's a resident of California.
Answer: You have to reside in California to hold a California driver's licence
Since your girlfriend lives in Washington she can't get a California licence. The good news is she can get a Washington licence and use it in California.
More generally, most places in the world allow "foreigners" (interstate OR international) to use their foreign licence to drive.
Comment: and related, if you are a resident of CA, you need to have a CA driver's license (there are exceptions).


Like Vishnu and Shiva, any other deities take form of animals?

Question: We know about Vishnu's animal forms (Matsya, Kurma and etc.) and Shiva's animal forms (Vrishabha and Sharabha). But does any other deities incarnated in the form of animals like Vishnu and Shiva?
Comment: Can't say about being incarnated, but Ramayana Uttarakanda narrates about the Indra, Yama, Varuna & Kuvera assuming the forms of animals out of fear of Ravana. Since they were able to avoid further humiliation at the hands of Ravana through their disguises, the Devas blessed the animals of whose appearances they took. Indra blessed the peacock with their trademark mesmerizing feathers. Yama blessed the crow with a powerful immunity & to intercede between hungry dead & their living relatives. Varuna blessed the swan with beauty & white feathers. Kuvera blessed the lizard with golden colour.
Answer: Radhe Radhe
In Mahabharat, even Yamraj has become an animal by being a dog and accompanying Maharaj Yudishtra above the mountain to heaven.
"Vaishampayana continued: "Hearing these words of king Yudhishthira the just, (the dog became transformed into) the deity of Righteousness, who, well pleased, said these words unto him in a sweet voice fraught with praise" - Mahabharata Mahaprasthanika Parva - Translation by KM Ganguly
Answer: Though not incarnations. Many devās took forms of animals, birds, insects, etc etc.
For example.:
Valmiki Ramayana.:

putraH kila sa shakrasya vaayasaH patataam varaH || 5-38-28
dharaa antara caraH shiighram pavanasya gatau samaH |
"That crow, the best among birds, seems to be the son of Indra the Lord of celestials (Jayanta), staying in mountains and moving with a peed equal to the wind."

Mahabharata Karna Parva Section 42.:

On that occasion, O Salya, the chief of the gods (Indra), wishing to benefit Phalguna, caused an obstacle, by approaching my (Karna's) thigh and piercing it, having assumed the dire form of a worm. When my preceptor slept, having laid his head thereon, that worm, approaching my thigh, began to pierce it through. In consequence of the piercing of my thigh.

And So on.
I hope this helps.
Answer: Brahma assumed the Kurma Matsya and Varaha (tortoise, fish and boar) forms which were later appropriated to Vishnu in the itihasa-puranas:
Kurma (tortoise)
Is Sri Kurma an avatar of Lord BrahmA (Prajapati)?
Matsya (fish)
Was matsya of Lord brahma transferred to Lord vishnu?
Varaha(boar)
http://valmikiramayan.net/utf8/ayodhya/sarga110/ayodhya_110_frame.htm

सर्वम् सलिलम् एव आसीत् पृथिवी यत्र निर्मिता |
ततः समभवद् ब्रह्मा स्वयम्भूर् दैवतैः सह || २-११०-३

"All was water only in the beginning" from which element the earth was formed. After that, the self-existent Brahma with all the gods came into existence."

स वराहः ततो भूत्वा प्रोज्जहार वसुंधराम् |
असृजच् च जगत् सर्वम् सह पुत्रैः कृत आत्मभिः || २-११०-४

"Thereafter, that Brahma, assuming the form of boar, caused the earth to rise from water and with his sons of pure soul, created the entire world."

Hamsa (swan)
https://www.wisdomlib.org/hinduism/book/shiva-purana-english/d/doc225552.html
16-18.
Thsi happens when vishnu and brahma seek the bottom and top of the infinite Linga form of siva:

"Nothing will turn up if we are together". Saying this, Viṣṇu assumed the form of a Boar and went in search of the root. Brahmā in the form of a swan went up in search of the top. Piercing through the netherworlds and going very far below, Viṣṇu could not see the root of the fiery column. Utterly exhausted, Viṣṇu in the form of a Boar returned to the former battle-ground.
Comment: So, only trimurtis assumed form of animals.
Answer: There is Varahi Devi. She is in the form of wild boar.
Goddess Bagalamukhi is often depicted with the Crane like appearance.
Pratyangira is like Narasimha. Half Lion.
and Vinayaki is like Ganesha.
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).


PLSQL :NEW and :OLD

Question: Can anyone help me understand when to use :NEW and :OLD in PLSQL blocks, I'm finding it very difficult to understand their usage.
Answer: You normally use the terms in a trigger  using :old to reference the old value and :new to reference the new value.
Here is an example from the Oracle documentation linked to above
CREATE OR REPLACE TRIGGER Print_salary_changes
  BEFORE DELETE OR INSERT OR UPDATE ON Emp_tab
  FOR EACH ROW
WHEN (new.Empno > 0)
DECLARE
    sal_diff number;
BEGIN
    sal_diff  := :new.sal  - :old.sal;
    dbms_output.put('Old salary: ' || :old.sal);
    dbms_output.put('  New salary: ' || :new.sal);
    dbms_output.put_line('  Difference ' || sal_diff);
END;

In this example the trigger fires BEFORE DELETE OR INSERT OR UPDATE :old.sal will contain the salary prior to the trigger firing and :new.sal will contain the new value.
Comment: @Pravin common use cases are validation and auditing. Using the above example imagine the requirement was to track an employees salary history, in this case we could insert the old salary, modification date and user name into a history table.  In the application I'm working on ATM a trigger is used to update a records elevation when the coordinates are edited
Comment: And they are not just for reference too: in a before insert or update trigger a value could be assigned to the :new values. A common use is to provide a primary key with a value from a sequence in a before-insert trigger.
Comment: Are they just useful to display values after and before trigger is fired or is their any other usage?
Answer: :New and :Old Value can be differentiated in DML Statements .
Insert      --    :Old = NULL       :New= Inserted new value
Update  --     :Old = Value present in table before the Update statement Triggered     :New = Given new value to Update
Delete   --    :Old = Value before deletion   :New = NULL
Answer: :old and :new are pseudorecords referred to access row level data when using row level trigger.

:old - refers to Old Value
:new - refers to New value

For Below operation, respective old and new values:

INSERT- :old.value= NULL, :new value= post insert value
DELETE- :old.value= Pre Delete value, :new value= null
UPDATE- :old.value= Pre update value, :new value= Post Update
value

Eg:
CREATE OR REPLACE TRIGGER get_dept
  BEFORE DELETE OR INSERT OR UPDATE ON employees
  FOR EACH ROW
BEGIN
    DBMS_OUTPUT.PUT('Old Dept= ' || :OLD.dept|| ', ');
  DBMS_OUTPUT.PUT('New Dept= ' || :NEW.dept );
END;

Triggering Statement:
UPDATE employees
SET dept ='Accounts'
WHERE empno IN (101 ,105);

Comment: This behavior of OLD being null in insert and NEW being null in delete changes if the statement is using AFTER instead of BEFORE?
Comment: @Sawd No it does not. In BEFORE (insert or update) triggers you are allowed to modify the values, though, and the modifications will end up in the saved record.
Answer: :new means the new value your are trying to insert
:old means the existing value in database
Answer: :old is your old value
:new is your new value,
it is used alot in triggers for example with Creation_Date & Modified_By fields
Answer: :old and :new are pseudo records referred to access row level data when using row level trigger.
•:old - refers to Old Value
•:new - refers to New value
for example:
CREATE OR REPLACE TRIGGER mytrig BEFORE
  INSERT OR
  UPDATE
    ON mytab FOR EACH ROW
BEGIN
  IF INSERTING THEN
    SELECT trunc(sysdate), trunc(sysdate) INTO :new.created, :NEW.last_updated FROM DUAL;
  END IF; --INSERTING

  IF UPDATING THEN

      SELECT trunc(sysdate) INTO :NEW.last_updated FROM DUAL;

  END IF; --UPDATING

END;

Hope this explains the concept of old and new.
Answer: :new is the new value - After the trigger is fired this is the value of the column
:old is the old value - After the trigger is fired this value is replaced with
                       :new value
Answer: New and Old more relevant for update operation inside a trigger, to fetch old value of field use old and for recent value use new
Answer: In simple way,
Trigger will fire when you manipulate data into table. so while trigger invoke, you have both value. one is referring to old data value and one is the new data value which you recently update/delete/insert.
in-case of
insert- old value would be null and new value contain some value
update - old and new both have some value
delete - old has value but new will not contain value.
so by using :OLD and :NEW, you can insert/update other table where you want to maintain your history or based on :OLD or :NEW value you can insert/update some other dependent table.
Hopefully this helps you..
Answer: It's very simple
If Insert :old = NULL and :New = New Inserted Value
If Update  :Old = Value already in the table  :New = Updated Value in the Table
If Delete :Old = Value before deletion :New = NULL

IN other Words

For an INSERT trigger, OLD contains no values, and NEW contains the
new values.
For an UPDATE trigger, OLD contains the old values, and NEW contains
the new values.
For a DELETE trigger, OLD contains the old values, and NEW contains
no values.

Example:
CREATE OR REPLACE TRIGGER update_name_view_trigger
INSTEAD OF UPDATE ON emp_locations
BEGIN
  UPDATE employees SET
    first_name = substr( :NEW.name, instr( :new.name, ',' )+2),
    last_name = substr( :NEW.name, 1, instr( :new.name, ',')-1)
  WHERE employee_id = :OLD.employee_id;
END;

Answer: :OLD and :NEW are variables of type Record and is identical in columns to the table row on which the trigger is fired. They are only available for row level triggers. Since triggers are fired on a predefined event automatically so :OLD and :NEW also get their value automatically . As the name suggests , :OLD will have the complete row values existing in table ( i.e has the existing values in case of update and delete ) and :NEW will have new values for that rows ( i.e. has the row value in case of update and insert ).
Answer: A simple example that shows the use of old and new using triggers

CREATE TABLE emp_log(
emp_id NUMBER;
updated_by DATE,
new_salary VARCHAR2(15),
Action VARCHAR2(20));

CREATE OR REPLACE TRIGGER log_sal
AFTER UPDATE OF sal on emp
FOR EACH ROW
BEGIN
INSERT INTO emp_log( emp_id, updated_by, new_salary, Action)
VALUES(:NEW.empno, USER, :NEW.sal, 'New salary');
END;
/

Answer: You can use :OLD while working on after/before update 100% of time
:NEW is a record of the new value added  by (insert or update)
:OLD is for old values.
Without them, triggers are useless
Answer: Mainly here is the words refers
:old refer to the old value before trigger fire.
:new contain the value of after trigger fire.
Answer: You may get this when trying to do any database modifications(Updates). When you're inserting(adding/new) data :New will appear. Since you don't any existing data nothing is showing as :Old. When you're updating existing details through the code you will see the existing data as :Old and the updated details as :New.
Answer: Within the trigger body, the :OLD and :NEW keywords enable you to access columns in the rows affected by a trigger
:OLD is used to get the old value of the column before it gets updated or deleted. Therefore OLD is used only with delete or update statements triggers
:NEW is used to get the value that is updated or just inserted in the database. Therefore NEW is used with the only update and insert statements triggers
Answer:
The restrictions on pseudorecords are:

A pseudorecord cannot appear in a record-level operation.

For example, the trigger cannot include this statement:
:NEW := NULL;

A pseudorecord cannot be an actual subprogram parameter.

(A pseudorecord field can be an actual subprogram parameter.)

The trigger cannot change OLD field values.

Trying to do so raises ORA-04085.

If the triggering statement is DELETE, then the trigger cannot change
NEW field values.

Trying to do so raises ORA-04084.

An AFTER trigger cannot change NEW field values, because the
triggering statement runs before the trigger fires.

Trying to do so raises ORA-04084.

A BEFORE trigger can change NEW field values before a triggering
INSERT or UPDATE statement puts them in the table.
If a statement triggers both a BEFORE trigger and an AFTER trigger,
and the BEFORE trigger changes a NEW field value, then the AFTER
trigger "sees" that change.

PLSQL :NEW and :OLD


Why are preambles repeated in communication systems

Question: Many modern digital communication systems repeat a preamble at the start of a frame/burst which is used by the receiver for timing and frequency synchronization. One example is 802.11a. Why are the preambles repeated versus using a non-repeating synchronization sequence? I can see how the repetition aids in a larger carrier frequency offset estimation, but it also adds ambiguity in the detector at the output of the cross correlation.
Answer: In case of IEEE802.11a, that's Schmidl&Cox synchronization. I go into a few effects of having that in this answer; and as I say there,

If in doubt, read the original Schmidl&Cox Paper Robust Frequency and Timing
Synchronization for OFDM. It's actually a good read, and a good paper with respect to demonstration of state of the art, proposed algorithm, theory, and simulation. I highly recommend it.

But let's address a few things:

but it also adds ambiguity in the detector at the output of the cross correlation.

Not really; you correlate with the whole first training symbol, not just with half of it. Ideally, you correlate with the both. No downside to it, these are known at the receiver. Sure, you get side lobes at half a symbol shift, but that will be robustly lower than the main cross-correlation peak.

I can see how the repetition aids in a larger carrier frequency offset estimation

Ah, but it's actually used to implement a fine frequency offset correction! Do a fixed lag correlation of your RX signal: take a vector half a symbol worth of time samples, and another one of the same length taken from directly behind that. Dot product: you get a correlation coefficient for a lag of half a symbol. That coefficient

will be high if your signal, at the point where you do that correlation, contains a repeated sequence of half a symbol length
will have a phase that's proportional to frequency, because every sample in
the second half has the same value, but a phase shift of $f_\text{offset}\cdot \,l_\text{symbol}/2\mod 2\pi$, due to an unknown frequency offset. That actually gives you a very robust frequency estimate, because you're using so many samples for a correlation – but it comes with ambiguities depending on the symbol duration $l_\text{symbol}$. So, it's a good fractional, and not a useful coarse frequency estimate.

The second symbol now isn't repetitive, so that indeed makes your timing metric more robust, and more precise.
Comment: I agree that with the example I provided, 802.11a, you would correlate with the entire preamble to resolve any correlation ambiguity. But what about if the preamble only contained N repeats of the same sequence? The output of the correlator would have ambiguous spikes for each repetition.
Comment: For the fixed lag correlation, do you mean to say autocorrelation (i.e., received signal dot product with itself)? Or do you mean with the preamble sequence?
Comment: with itself, as I described!
Comment: but you don't do that repeated halves all over again. The whole point of doing it once is using Schmidl&Cox. No system that does not exploit the repetition would do the repetition.
Comment: The dot product with half a symbol period delay to resolve frequency error is a great idea!


Fast way to isolate 4-nitrophenol from 4-aminophenol

Question: I'm working in the lab with a very old (like 30 years old) sample of 4-nitrophenol, wich of course has been reduced with the time to 4-aminophenol. I need to isolate both reagents and work only with the nitrophenol, is there any quick way to do that?
Comment: There are various products of reduction of nitrophenol. Best way would be to cast it aside and buy fresh one.
Comment: @Mithoron, I'm screwed, I'm in Cuba, there are no such things in here. I'm trying to get a fresh one, but that's really difficult here :)
Comment: One has to ask if the container of 4-nitrophenol was left open during the 30 year period and was it stored in plastic or glassy bottle? Another thinking is that, what was the expiring date for 4-nitrophenol? Like drugs which are also chemicals have expiring date labelled on the container before it goes into the market. Then what taught brought the question raised, however, if you are just assuming, the answers given by Mathew Mahindaratne may be useful. Omar A.Wafudu
Answer: I would use solvent extraction. Dissolve the mixture of phenols in an organic solvent. Next shake the organic solution with dilute hydrochloric acid in a separation funnel. Do this several times to wash all of the 4-hydroxyaniline out of the organic phase.
Next shake the organic phase with concentrated sodium chloride solution (brine) and then add anhydrous sodium sulfate. Shake the mixture up in a sealed conical flask. Now decant or filter it to give you a solution of 4-nitrophenol which you can now evapourate down to give you the phenol.
I would like to know how the nitrophenol was reduced into the amine over the years it was in storage. This is a more interesting question to my mind is how did the nitro compound get converted on storage into the amine.
Comment: It is a very good question you brought up here. It's usually other way around. Aryl amines air-oxidize. I never heard of nitro to amine reduction by air.
Comment: @MathewMahindaratne, thats a good point, I checked the compound by UV-vis, and there is a strong band from 250 nm - 400 nm. I expected only to see the signal around 400 nm. The p-amminophenol absorbs around 250 nm, that's why I conclude that it's the impurity. Of course further analysis is needed, but that's all I can say by now. Again, is a 30 years old reagent stored in very, very bad conditions, anything could have happened to it. Air is the just the tip of the iceberg
Comment: @Marange Like everything absorbs around 250. I'm afraid wild guessing isn't good idea.
Answer: I would expect 4-nitrophenol to be relatively stable, even when stored for a long time under air, and as Nuclear Chemist says I would certainly not expect any reduction of the nitro group over time.
Have you tried simply recrystallizing the material you have. In Armarego and Chai it has been purified by recrystallization from aq. HCl (0.5N), aq. H2SO4 (1N), EtOH, aqueous MeOH, CHCl3, benzene and Pet Ether. Give any (or all) of the above a go. The expected melting point is 113-114 C so you can check your material for purity without access to any expensive analytical equipment.


ANdorid Lock Out

Question: I have a S5 but I forgot the password thinking that if I locked it using android device manager the new password would allow me access but it didn't. my question is if I wipe my phone using ADM will it open the phone or would it still be locked after I wipe.
Answer: If you factory reset your phone, the lock will be gone. But all of your Data will be lost as well.
You could probably try it this way to avoid loosing all your data:
Android lock screen password not being recognized

ANdorid Lock Out