Wednesday, 19 June 2019

Penrose tiles

6th generation deflated sun pattern
This is a Penrose kite and dart tiling (P2) deflated six generations from a sun pattern. Work in progress. 
Sun

More coming soon!

Monday, 3 June 2019

Windows Defender and Google Drive

Windows Defender and Google Drive (Backup and Sync) seem to be incompatible. When you get a new Windows computer Windows Defender is preinstalled. If you then install Google Backup and Sync it copies all the your Google Drive data onto the new computer but after that synchronisation does not work. You may not notice this! You will notice that there is a Windows Defender pop up menu in File Explorer, but no Google Drive pop up menu. New files and folders that you create in your Google Drive folder are not created in your Google cloud. Updates and deletions are not propagated.

I do not know why this is. Perhaps it's because Microsoft want you to use OneDrive which is their version of Google Drive.

The solution

The solution is very simple: Replace Windows Defender by Avira which is highly recommended free anti-virus software.  (Other anti-virus software may also work).

1. Stop Google Backup and Sync(see below under Read more)
2. Disable Windows Defender in Windows settings. Their are good instructions here.
3. Install Avira.
4. Restart Google Backup and Sync(see below under Read more)
Google Backup and Sync then resyncs your data (which might take a while) and the useful file / folder icons and the Google Drive pop up menu reappear in File Explorer.

I am not even sure that steps 1 and 4 are necessary.

I could not find this very important information about Google Drive and Windows Defender anywhere on the web nor did Google Drive email help (googleone-support@google.com) seem to be aware of it. Many solutions, including those from Google help, suggest deleting all the files in your Google drive folder(s), reinstalling Drive and resyncing from the web. This would be a huge waste of time. Google help suggested doing that twice!

https://windowsreport.com/google-drive-wont-sync-windows-10/ claims to answer the question: "How to fix broken sync with Google Drive in Windows 10". It gives seven solutions. The first suggests reinstalling Google Drive and recopying all your data. That might take days and why would it work at the end? The second invites you to turn off virus protection! Very stupid. Solution 3 is "Install the previous version of Google Drive". Why would that work? The drivel continues.

I was so pleased with Avira (I have used the free version before) that I decided to buy it. It seemed to be 9.95€ which was very fair. But then it turned out to be 9.95€ per month. I cancelled the subscription and will continue with the free version.

Friday, 31 May 2019

When is a point inside a quadrilateral?

This all started because I am playing with four sided tiles (quadrilaterals) and needed to know if a point is inside one of the quadrilaterals. There are two basic shapes: kites and darts which you can see below. I got the (incorrect) answer, but not the proof, by searching on that web. There are other solutions which might be more reliable, but this one is good enough for my needs. There are some videos at the bottom of the post.

Kites

First we look at kites, quadrilaterals all of whose internal angles are less than 180°.

We show three situations with a point P inside (middle) or outside a kite. When P is inside, clearly the four angles add to 360°. If P is outside the tile then one of the angles will be the largest but less than 180° and the other three will add up to be the same as it, also less than 180°. So the total is less than 360°. For a kite this is an infallible test to see if a point is inside it or outside it.

Note: The four angles are always ∠APB, ∠BPC, ∠CPD, ∠APD and they are always measured the 'small' way so that they are less than 180°.

Darts

Sadly this is not an infallible test for dart shaped quadrilaterals when one internal angle is greater that 180° as we see in the three examples below:


Once we get further inside a dart things work better as can be illustrated by the graph below. We have a downward pointing dart (slightly exaggerated) and a horizontal yellow line passing through it. There are four points shown on the line: ##P_1,P_2,P_3,P_4##. A point on the green line shows the total angle (in radians) from the point above it on the yellow line to the four vertices. So
The first point which is outside the dart is ##P_1,total<2π ##
The second which is on the edge of the dart is ##P_2,total=2π ##
The third which is inside the dart is ##P_3,total=2π  ##
The fourth which is on another edge of the dart is ##P_4,=2π   ##

We can easily draw more graphs with the yellow line at different levels:

Our test would say that points inside the wing tips of the dart were not inside it.

For a kite the behaviour is much better:
These are all plotted and animated in Penrose Tile Plotter.xlsm. And here are the videos which demonstrate the limited but adequate validity of the method!

It is instructive to pause the videos at interesting points. The point P and the dashed lines to the vertices are there for illustrative purposes. The yellow and green lines are the important ones.




Wednesday, 24 April 2019

Wolfram Mathworld great circle equation error

According to www.mathworld.wolfram.com/GreatCircle.html (19) the geodesic equation on a sphere (great circle) is given below. It is derived from a somewhat specialised equation for a geodesic on a surface (http://mathworld.wolfram.com/Geodesic.html (30)), which itself is derived by considering a minimised line integral. Wolfram's (19) is given as
\begin{align}
a{\mathrm{cos} u\ }{\mathrm{s}\mathrm{i}\mathrm{n} v\ }{\mathrm{sin} c_2\ }+a{\mathrm{sin} u\ }{\mathrm{s}\mathrm{i}\mathrm{n} v\ }{\mathrm{cos} c_2\ }-\frac{a{\mathrm{c}\mathrm{o}\mathrm{s} v\ }}{\sqrt{{\left(\frac{a}{c_1}\right)}^2-1}}=0 & \phantom {10000}(1) \\
\end{align}where ##a## is the radius of the sphere, ##c_1,c_2## are constants of integration, ##u,v## are respectively longitude and latitude. In the next equation it recasts that in Cartesian coordinates as\begin{align}
x{\mathrm{sin} c_2\ }+y{\mathrm{cos} c_2\ }-\frac{z}{\sqrt{{\left(\frac{a}{c_1}\right)}^2-1}}=0 & \phantom {10000}(2) \\
\end{align}"which shows that the geodesic giving the shortest path between two points on the surface of the equation lies on a plane that passes through the two points in question and also through center of the sphere." (2) is indeed the equation of a plane which contains the origin, but it also implies that\begin{align}
x=a{\mathrm{cos} u\ }{\mathrm{s}\mathrm{i}\mathrm{n} v\ }\ \ ,\ y=a{\mathrm{sin} u\ }{\mathrm{s}\mathrm{i}\mathrm{n} v\ }\ \ ,\ z=\ a{\mathrm{c}\mathrm{o}\mathrm{s} v\ } & \phantom {10000}(3) \\
\end{align}This is very wrong. It would be correct if ##v## was the colatitude (angle measured from the pole). The colatitude is normally called  ##\phi ## and  ##\phi ={\pi }/{2}-v##, as they say in their #7. Alternatively one can swap all ##{\mathrm{sin} v\ },{\mathrm{cos} v\ }##. I guessed that the equation is therefore\begin{align}
a{\mathrm{cos} u\ }{\mathrm{cos} v\ }{\mathrm{sin} c_2\ }+a{\mathrm{sin} u\ }{\mathrm{cos} v\ }{\mathrm{cos} c_2\ }-\frac{a{\mathrm{sin} v\ }}{\sqrt{{\left(\frac{a}{c_1}\right)}^2-1}}=0 & \phantom {10000}(4) \\
\end{align}This is correct as I have proved by other means. (To be revealed). Numerically it can be shown with my great 3-D graph plotter (here and here). The incorrect equation is obviously not a great circle, whereas the correct one looks plausible;

The schematic shows great circles between cities. The right hand one shows the London-Peking great circle according Wolfram Mathworld. Perhaps this is what happened to the British Airways pilot who flew from London to Edinburgh instead of Düsseldorf in a month ago. (On the BBC here)

I have not been able to trace the source of the error in the Wolfram Mathworld proof. It may go as far back as their (7) where they might have intended to introduce ##\phi ##.

This error on Wolfram Mathworld caused me a lot of grief!

And another small error

There is also a typo on http://mathworld.wolfram.com/Geodesic.html between equations (11) and (12). It reads "Starting with equation (##\mathrm{\Diamond }##)" which should be "Starting with equation (5)"

Sunday, 21 April 2019

3-D Graph plotter Version 2

Paul showed me how to write VBA for an Excel spreadsheet. David had also urged me to look at the Timer function in VBA to speed up production of animations on the 3-D Graph plotter. I dedicate this post to Paul and David.

Inspired by both of them I have put an animation feature in the 3-D graph plotter and here are the results.  All the movies had to be adjusted in html to make them bigger. The old method of screenshots into a .gif file is shown. It has some merits. I used the MS-Windows screen recorder to produce the .mp4 file. It is very clunky. It would be nice to be able to delineate the area of the screen one wished to record more precisely.

The geodesic plotter, I am still working on the equations :-(
On youtube here which is bigger 
Original mp4 here which is bigger and clearer.
Excel file here.

The same sphere produced painstakingly from 36 screenshots each 10° apart.


The cube from an .mp4 file loaded directly onto Blogger. Excel file here.

The cube from the.mp4 file first uploaded to Youtube. On Youtube here.
A similar cube produced painstakingly from 44 screenshots.

Saturday, 30 March 2019

Here we meet the covariant divergence and prove a thing or two about it. (Carroll said it was 'easy'.) We also have the curved-space version of Stokes's theorem using the covariant derivative and finally the exterior derivative and commutator, where Carroll seems to have made a very peculiar typo. Sir George Gabriel Stokes, 1st Baronet was a very clever but he did not discover the theorem. He popularised it.



Here's the very impressive Stokes's theorem, which applies to the diagram
$$\int^{\ }_{\mathrm{\Sigma }}{{\mathrm{\nabla }}_{\mu }V^{\mu }\sqrt{\left|g\right|}}d^nx=\int^{\ }_{\mathrm{\partial }\mathrm{\Sigma }}{n_{\mu }V^{\mu }\sqrt{\left|\gamma \right|}}d^{n-1}x
$$
At Carroll's (3.36) he says "if ##\mathrm{\nabla }## is the Christoffel symbol, ##{\omega }_{\mu }## is a one-form, and ##X^{\mu }## and ##Y^{\mu }## are vector fields, we can write
$${\left(\mathrm{d}\omega \right)}_{\mu \nu }=2{\partial }_{[\mu }{\omega }_{\nu ]}=2{\mathrm{\nabla }}_{[\mu }{\omega }_{\nu ]}
$$The phrase "if ##\mathrm{\nabla }## is the Christoffel symbol" is bizarre and it is easy to prove the equation without it, assuming the Christoffel connection is torsion-free (##{\mathrm{\Gamma }}^{\lambda }_{\mu \nu }={\mathrm{\Gamma }}^{\lambda }_{\nu \mu }##). I think our author meant "if the connection is torsion-free".

Read more at Commentary 3.2 Properties of covariant derivative.pdf (7 pages)

Monday, 25 March 2019

Corrections

I have sent this list of eight corrections I have found to date to the author, Sean Carroll. There is one extra (p.148) which I only found by peeking at a reprint of the question.

Chapter 1
p.24 just before equation (1.68) it reads "There is also the Levi-Civita symbol a (0,4) tensor." Surely it is not a tensor.

Chapter 2

p.81 Figure 2.26 fig 2.26 shows a singularity at a point p and the text discusses a point p that is in the future of the singularity. (https://www.general-relativity.net/2018/12/commentary-27-causality.html part 2)

Possible error
p. 82 Equation (2.66) could be much simpler if μ'1 μ'2 ...μ'n = 01...(n-1). (It's more streamlined.)
This is trued but if the simplified for was given, the next equation would not work! (GK)

Chapter 3
p.96 equation (3.10) for the connection transformation law. The + sign should be -. (https://www.general-relativity.net/2019/03/the-christoffel-symbol.html)

Possible error
p.99 definition of torsion-free (connection symmetric in lower indices) given as Γλμν = Γλ(μν). Surely Γλμν = Γλνμ. would be clearer? (https://www.general-relativity.net/2019/03/the-christoffel-symbol.html)

p.148
Exercise 6(a) should end "Which clock ticks faster?" I picked this up from http://web.physics.ucsb.edu/~phys231A/231A/Homework_files/hw4_solutions.pdf.

Appendices
p. 427 equation (A.11) ϕ is used to mean two different things: a map and a polar coordinate. (https://www.general-relativity.net/2018/09/commentary-on-appendix-mapping-s2-and-r3.html)