Here is my player code.  Rigidbody rb;  Vector3 currMovement; public float jumpSpeed = 10; public float moveSpeed = 10; public float rotSpeed = 180;  float distToGround;  public float smoothTimePos = 0.25f; float currPos; float targetPos; float posVel;  public float smoothTimeRot = 0.25f; float currRot; float targetRot; float rotVel;  void Start() {     rb = GetComponent&lt;Rigidbody&gt;();     distToGround = GetComponent&lt;Collider&gt;().bounds.extents.y; }  bool isGrounded() { return Physics.Raycast(transform.position, Vector3.down, distToGround + 0.1f); }  void Update() {     targetRot = Input.GetAxisRaw("Horizontal") * rotSpeed * Time.smoothDeltaTime;     targetPos = Input.GetAxisRaw("Vertical") * moveSpeed; }  void FixedUpdate() {     Move(); }  void Move() {     if (isGrounded())     {         if (Input.GetButtonDown("Jump"))             rb.velocity += Vector3.up * jumpSpeed;     }      // Rotation smoothing.     if (targetRot &gt; 360)         targetRot -= 360;     if (targetRot &lt; 0)         targetRot += 360;     currRot = Mathf.SmoothDampAngle(currRot, targetRot, ref rotVel, smoothTimeRot);      transform.eulerAngles += new Vector3(0, currRot, 0);      // Movement smoothing.     currPos = Mathf.SmoothDamp(currPos, targetPos, ref posVel, smoothTimePos);     currMovement = new Vector3(0, 0, currPos);     currMovement = transform.rotation * currMovement;      rb.position += currMovement * Time.smoothDeltaTime; }   I have a Rigidbody attached to my player. I think the problem is with my camera script. Here is my camera script.  public Rigidbody player; Quaternion targetLook; Vector3 targetMove, targetMoveRaycast, targetMoveUse; public float smoothLook = 8, smoothMove = 0.25f; public float distFromPlayer = 5, heightFromPlayer = 3; Vector3 moveVel;  void LateUpdate() {     CameraMove(); }  void CameraMove() {     targetMove = player.position + (player.rotation * new Vector3(0, heightFromPlayer, -distFromPlayer));      RaycastHit hit;     if (Physics.Raycast(player.position, targetMove - player.position, out hit, Vector3.Distance(player.position, transform.position)))     {         targetMoveRaycast = hit.point;         targetMoveUse = targetMoveRaycast;     }     else     {         targetMoveUse = targetMove;     }      transform.position = Vector3.SmoothDamp(transform.position, targetMoveUse, ref moveVel, smoothMove);      targetLook = Quaternion.LookRotation(player.position - transform.position);     transform.rotation = Quaternion.Slerp(transform.rotation, targetLook, smoothLook * Time.smoothDeltaTime); }   The player is not an parent of my camera. When I parent the player to my camera the shake stops. But I want a custom smooth camera movement with my custom scirpt, so I can't make the player a parent of the camera.
Here is my player code.  Rigidbody rb;  Vector3 currMovement; public float jumpSpeed = 10; public float moveSpeed = 10; public float rotSpeed = 180;  float distToGround;  public float posSmoothTime = 0.5f; float currPos; float targetPos; float posVel;  public float rotSmoothTime = 0.5f; float currRot; float targetRot; float rotVel;  void Start() {     rb = GetComponent&lt;Rigidbody&gt;();     distToGround = GetComponent&lt;Collider&gt;().bounds.extents.y; }  bool isGrounded() { return Physics.Raycast(transform.position, Vector3.down, distToGround + 0.1f); }  void Update() {     Move(); }  void Move() {     // Rotation smoothing.     targetRot = Input.GetAxisRaw("Horizontal") * rotSpeed * Time.smoothDeltaTime;      if (targetRot &gt; 360)         targetRot -= 360;     if (targetRot &lt; 0)         targetRot += 360;     currRot = Mathf.SmoothDampAngle(currRot, targetRot, ref rotVel, rotSmoothTime * Time.smoothDeltaTime);      transform.eulerAngles += new Vector3(0, currRot, 0);      // Movement smoothing.     targetPos = Input.GetAxisRaw("Vertical") * moveSpeed;      currPos = Mathf.SmoothDamp(currPos, targetPos, ref posVel, posSmoothTime * Time.smoothDeltaTime);     currMovement = new Vector3(0, 0, currPos);     currMovement = transform.rotation * currMovement;      if (isGrounded())     {         if (Input.GetButtonDown("Jump"))             rb.velocity += Vector3.up * jumpSpeed;     }      rb.position += currMovement * Time.smoothDeltaTime; }   I have a Rigidbody attached to my player. I think the problem is with my camera script. Here is my camera script.  public Transform player; Quaternion targetLook; Vector3 targetMove; public float smoothLook = 0.5f; public float smoothMove = 0.5f; public float distFromPlayer = 5, heightFromPlayer = 3; Vector3 moveVel;  void LateUpdate() {     CameraMove(); }  void CameraMove() {     targetMove = player.position + (player.rotation * new Vector3(0, heightFromPlayer, -distFromPlayer));     transform.position = Vector3.SmoothDamp(transform.position, targetMove, ref moveVel, smoothMove);      targetLook = Quaternion.LookRotation(player.position - transform.position);     transform.rotation = Quaternion.Slerp(transform.rotation, targetLook, smoothLook); }   }  The player is not an parent of my camera. When I parent the player to my camera the shake stops. But I want a custom smooth camera movement with my custom scirpt, so I can't make the player a parent of the camera.
Windows & Ubuntu dual boot.No menu to choose OS? I just installed Ubuntu alongside Windows 7. Now I cant boot Windows 7 because it automaticaly boots Ubuntu without displaying boot menu. How can I get menu with options to choose which Os to boot? Can anyone help? "Is there" versus "Are there" Are there any questions I should be asking?   Is there any articles available on the subject?   My instinct is that in the two questions above, it should be 'are' as the subjects of the sentences (questions/articles) are plural.  However I also recall being told that the singular 'is' is valid here too, and of course see it very often in usage online, and this has left me a bit unsure.  Update: I have stumbled upon the reason for the confusion.     Is there any water?   Are there any questions?   The sentence structure is the same but of course water is not plural, although it is not singular either. I've got a couple of URL autocomplete suggestions where Chrome suggests the wrong URL consistently.   How can I delete the incorrect entry from the address bar's suggestion list? The page I want shows up too but it's never the first result. I'm trying to figure out the best way to model the sphere-spiral here:    Is it possible to make this shape directly? Or do you have to make it as a cylinder and wrap it to a sphere? R's lmer cheat sheet There's a lot of discussion going on on this forum about the proper way to specify various hierarchical models using lmer.  I thought it would be great to have all the information in one place. A couple of questions to start:   How to specify multiple levels, where one group is nested within the other: is it (1|group1:group2) or (1+group1|group2)? What's the difference between (~1 + ....) and (1 | ...) and (0 | ...) etc.? How to specify group-level interactions? Getting file names without extensions Calculate $\int_{0}^{1} (x-f(x))^{2016} dx$, given $f(f(x))=x$. Special Relativity - Regarding the Simultaneity of Events During the Train Paradox My questions concerns that classic train paradox, wherein there is a train and a tunnel of equal length, and the train is traveling and some fraction of the speed of light towards the tunnel.  According to the Special Theory of Relativity, an observer outside the tunnel will see the train length contracted (Lorentz Contraction), whereas an observer inside will see the tunnel contracted.   Additionally, suppose that there were doors at the ends of the tunnel and that the observer outside the tunnel closed both doors instantaneously when he/she saw that the train was completely inside the tunnel.  The classic resolution of this paradox invokes the non-simultaneity of events, explaining that the observer in the train sees the far door close first, and then, once the train has begun to exit the tunnel, looks back to see the door at the beginning close. Thus, both observers agree that the train does not touch the door when they are closed for an instant.  Now my questions.  Why is it that the observer on the train sees the far door close first? It seems to me that the information coming from the far door would reach the observer on the train only after the information from the other door is reach.   Under this interpretation, the observer on the train would observe the train getting hit by the doors. What if, by some means, this event can be explained in terms of a stationary observer too? Everyone always concludes that the train remains untouched by the doors, but really the only condition that needs to be met is that both observers must agree. Why can't they both agree that the train was hit?  So, to summarize.   Why is the door that is farther away from the train observed to close first? Why can't the other possible conclusion (both see a hit train) be observed? How do I create a dynamic key to be added to a JavaScript object variable How do you improve Drupal performance? I just installed the lastest version of . I works fine but in order to use it, I have to enter the following in the terminal: cd ugene-1.11.5/ then execute ./ugene -ui to launch UGENE GUI.   This takes too long. I would like to build a .desktop file for UGENE to be used in Ubuntu 12.04 so that I can simply open it from the unity launcher.  Not sure if this is helpful but the website says: By default ugene script launches the command-line version of UGENE.  Here's what I have (not sure if it's right):  [Desktop Entry] Version=1.0 Name=my Unipro UGENE GenericName=Integrated Bioinformatics Suite Comment=Unipro UGENE is a cross-platform visual environment for DNA and protein sequence analysis. MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;text/x-chdr;text/x-csrc;text/x-java;text/x-moc;text/x-pascal;text/x-tcl;text/x-tex;application/x-shellscript;text/x-c;text/x-c++; Exec=/home/samuel/ugene-1.11.5 ./ugene -ui -c %F Icon=/usr/share/icons/hicolor/scalable/apps/ugene.svg Type=Application Terminal=true Categories=Utility;Development; StartupWMClass=UGENE   I added the launcher named my Unipro UGENE to my unity bar and tried opening it but it doesn't appear. I must be missing something. I don't know what the StartWMCClass field is suppose to be nor do I know whether I entered the correct MimeType. Does there exist a matrix $\mathbf{A}\in\mathbb{R}^{3\times3}$ such that $\mathbf{A}^{2}=-\mathbf{I}$? Is it possible for a matrix $\mathbf{A}\in\mathbb{R}^{3\times3}$,  $$\mathbf{A}^2=-\mathbf{I}$$  I know that It is possible for $2\times2$ matrix, but is it possible for $3\times3$ matrix ? Is there a detailed activity log on Mac OS X that lists my recent commands and actions? How can I see what I just did on my computer? For example, an activity log showing that I copied a file from here to there? I'm new to Blender and this site, so I apologize in advance if I'm not following any of the proper etiquette.  I'm no artist, but I'm trying to learn Blender so that I have some programmer art for me to work around in Unity.    I followed a tutorial for making a basic human model, I rigged it with rigify, and now I'm starting to export it following yet another tutorial.  The thing is, when I was trying to rig the model, I couldn't get the model to go transparent so that I could see the bones inside the model.  Eventually, I managed to get it into wireframe mode, but I can't get it back into solid mode.    It's probably just a display thing and not a property of the model itself, but I want to be sure.  I'm looking at the display options under the "Figure" pane in Blender, and none of the Display check boxes are checked, including the one that says "Wire".  I don't want to import a plain wireframe model into Unity, and even if that doesn't happen, this is functionality of Blender that I should really know anyway, so I'd appreciate any help that anyone has to offer.  If necessary, I can upload the .blend file, but I'm not sure what site people would prefer that I upload it to. So, I'm working creating a lamp... yes, newbie here.  After modeling for a bit, I noticed that my point of origin was no longer the center of my object:    How to I reset an object origin point to the center of it's geometry? How can i disable totally the prompts that appear while installing a Debian package, i've used all the options that i've found but there are some packages that are still prompting.  I'm using this command:  apt-get -y --allow-unauthenticated --force-yes -o DPkg::Options::="--force-overwrite" -o DPkg::Options::="--force-confdef" install x11-common   Why the x11-common package is still prompting? how can i get rid of these prompts?  Thanks in advance  --Victor  Edit: just to clarify, the prompts are not "yes/no" prompts, are open questions in a coloured screen (typical two color screen) but i want to set the default option of these questions Time reversal symmetry and T^2 = -1 Although the merits of stepwise model selection has been discussed previously, it is becoming unclear to me what exactly is "stepwise model selection" or "stepwise regression". I thought I understood it, but not so sure anymore.  My understanding is that these two terms are synonymous (at least in a regression context), and that they refer to the selection of the best set of predictor variables in an "optimal" or "best" model, given the data. (You can find the Wikipedia page , and another potentially useful overview .)    Based on several previous threads (for example here: ), it appears that stepwise model selection is considered a cardinal sin. And yet, it seems to be used all the time, including by what seem to be well respected statisticians. Or am I mixing up the terminology?  My main questions are:   By "stepwise model selection" or "stepwise regression", do we mean: A) doing sequential hypothesis testing such as likelihood ratio tests or looking at p-values? (There is a related post here: ) Is this what is meant by it and why it is bad? Or B) do we also consider selection based on AIC (or similar information criterion) to be equally bad? From the answer at , it appears that this too is criticized. On the other hand, Whittingham et al. (2006; )1 seems to suggest that variable selection based on information-theoretic (IT) approach is different from stepwise selection (and seems to be a valid approach)...?  And this is the source of all my confusion.  To follow up, if AIC based selection does fall under "stepwise" and is considered inappropriate, then here are additional questions: If this approach is wrong, why is it taught in textbooks, university courses, etc.? Is all that plain wrong? What are good alternatives for selecting which variables should remain in the model? I have come across recommendations to use cross-validation and training-test datasets, and LASSO.   I think everyone can agree that indiscriminately throwing all possible variables into a model and then doing stepwise selection is problematic. Of course, some sane judgement should guide what goes in initially. But what if we already start with a limited number of possible predictor variables based on some (say biological) knowledge, and all these predictors may well be explaining our response? Would this approach of model selection still be flawed? I also acknowledge that selection of the "best" model might not be appropriate if AIC values among different models are very similar (and multi-model inference may be applied in such cases). But is the underlying issue of using AIC-based stepwise selection still problematic?  If we are looking to see which variables seem to explain the response and in what way, why is  this approach wrong, since we know "all models are wrong, but some are useful"?   1. Whittingham, M.J., Stephens, P.A., Bradbury, R.B., &amp; Freckleton, R.P. (2006). Why do we still use stepwise modelling in ecology and behaviour? Journal of Animal Ecology, 75, pp. 1182–1189. set fontsize for TikZ figure I have made many figures with tikz and want to include them in a template. Unfortunately I used ex as a measure and the template I have to use redefines the font size. THis leads to wrong distances in the figures. is there a way to set the font size for all tikz figures in a document, so I do not have to adjust my figures? Prove that $\lim f(x) =0$ and $\lim (f(2x)-f(x))/x =0$ imply $\lim f(x)/x =0$