CS193p Assignment 4

I started working on Assignment 4 of the CS193 fall 2011 course.

 


Categories: Computingcs193p
PermaLink Comments

CS193p Post Assignment 3 thoughts

I finished assignment 3 now, apart from the content scaling thing.

In course 9 the TableViewController was introduced. I added the instructions as given during the course. It all worked like a charm. I did however a few things a bit different: all buttons were added to the toolbar in the iPad storyboard.

Paul Hegarty was not able to all the relevant things in the course, so extra code was posted on the website. I folded all the posted code into my code. I used a slightly different approach to the iPhone storyboard: I added a toolbar at the bottom of the GraphView and put the formula, switch and add to favorites in there.

I am however left with one problem: the swipe gesture does not work. I still have to find a way to debug this. At the moment I am lost. It seems that the swipe-gesture is not recognized.

 


Categories:
PermaLink Comments

CS193p fall 2011 resources

This post gathers interesting resources I found for the fall 2011 course.

The official material can be found on the course website at Stanford and on iTunesU. These lectures are based on Xcode 4 and iOS 5, so the older solutions are no longer applicable. There can be some help found in a corresponding Google Group.

There are multiple people that I are following the course:

I found various solutions on the web, which work as inspiration.

Assignment 1 (Simple Calculator)

Assignment 2 (Programmable Calculator):

Assignment 3 (Graphing Calculator):

 


Categories: Computingcs193p
PermaLink Comments

CS193p Assignment 2 thoughts

In this post I gather some thoughts on the assignment 2:


Categories: Computingcs193p
PermaLink Comments

IOS programming

And again I started learning IOS-programming. The last time I did finish the book by LaMarche for beginners. However I did not feel confident enough to work on my own. I started with the CS193p course that was then available, but got bogged down in mismatching courses and materials.

So a new year seem to be a good start to begin. I found out that in the mean time Xcode was heavily changed and IOS moved to version 5. This implied that I really had to start from the beginning. I am now up to course 7 and finished assignment 2.

 


Categories: Computingcs193p
PermaLink Comments

Bundle time

It seems that it is the time of the year for all sorts of bundles.

The bundle of Productive Macs looks at productivity apps, such as Fantasical, BusyCal, Home Inventory, NotBook, Folder X, LaunchBar, Cashculator and Tags. They offer also some prize. Anyway the bundle is not for me, I have already enough related apps. I like the prizes though, such as Hype.

The MacUpdate bundle seems more interesting with TechTool Pro, IconBox, TotalFinder, Postbox 3, FontPack pro Master, Labels&Adresses;, Mac DVDRipper Pro 3, Back in Focus, NeverWinter Nights, Hear, iClip 5 and FolderSynchronizer. I like TechTool as I have not really something comparable. TotalFinder looks interesting. A DVDRipper useful (Handbrake?). Back in Focus and iClip (have an old version).


Categories: Computing
PermaLink

Effect of eccentricity

SPH10003247

Simultaneous fitting two transits of an eclipsing binary is not evident. It is not allways clear how the various parameters interact. For SPH10003247 I used this approach:

Thus my current model does not work to explain these observations. I need to have other parameters that I can tune. There seems to be one assumption to many in my model.

This eclipsing binary has an eccenctric orbit as can be seen from the centers of the transits (0.0985 and 0.7561). Thus my assumption of a circular orbit does not hold. There might be a difference in apparent radii due to the orbit. A change from 0.95 to 0.77 is then needed, to explain the observations.

The difference in transit timings reveals at least a minimal eccentricity of 0.25, which corresponds to a relative distance variation between the two stars of 1.6. This might thus explain why my circular orbit does not work. So I need to refine my model to incorporate eccentricity. (Literature used Russell (1912) and Sterne (1939).


Categories: Science
PermaLink • (1) Comments

Tatooine star analysis

This a very interesting object: a double star with a planet circling around it. The excellent analysis of the previous posters seems to be the best solution. I wondered however if I would be able to expand on that by adding some numbers. Unfortunately most of the published formulae do not work here, as they all assume that the occulted star is stationary, which is certainly not the case here. So I had to invent some stuff to get to an extended explanation.

SPH21491066

The first step involves the double star. As the transits have equal depth and are close to 50%, so both stars are assumed to be equal in size and the orbital plane (circular) has an inclination angle of 90 degrees. Thus we see the orbit edge on. The orbital period can be determined from two transits (i and i+1 - the two green transits) and is 2.976 days. Normally the width of a transitcan be used to calculate the half-major axis of the orbit. However formula 3 of Seager&Mallen;-Ornelas (2002) assumes however that the occulted star does not move, which it does in this case. Thus the observed width (0.13 days) must be doubled to get the correct one. From this the hal-major axis can be determined as 11.3 stellar radii.

To determine the movement of the planet, better timings of the transits are needed. In order to make the three extra transits more clear I subtracted the LC of the double star. This was done by shifting and overlaying an adjacent LC and then subtracting the two. The blue and green lines show where the transits were. The dots shows the results of the subtraction. And you as well that the subtraction did not succeed 100%.

Then these three transits were fitted to determine the transit times. The dermined values, such as the width (T) and impact parameter (b) have not much significance, as the formulae assume a static object. Using the start of the ingress of the first transit (day 55023.31) and the end of the egress of the third transit (day 55024.94), we can determined the speed of the planet. The model of the double star indicates where the stars are and by putting the planet next to the star, we set the position of the planet. I used the configuration indicated by @kianjin in his last animation as starting point.

This resulted in the following animation, which confirms @kianjin’s results. The first transit happens just as star 1 is turning prograde. The planet starts the transit and then star 1 speeds up and moves out under the planet. Transit 2 is when the planet passes in front of star 2. Star 2 is then retrograde, which results in a small transit width. Transit 3 happens when star 2 is retrograde.

Interestingly in the animation a fourth transit happens, when the planet transits star 2 again. This fourth transit really isn’t in the data. I checked whether there isn’t any small grazing one. It turns out that this transit only occurs due to the position of the viewer in this 3D-animation. I am not able to undo this perspective (yet) and hence the animation does not allow to read the transit times.

I have a 2D-animation as well, which allows me to put the observer at infinity. In this animation the blue line represents the planet and viewing direction. I can not determine the distance of the planet, as we have no period as yet.

To be continued…

 


Categories: Science
PermaLink Comments

Transit fit evaluation

This object is known under the identification of Kepler ID 6850504, SPH 21522290 and KOI 70. Four planets have been detected around this planet. This is a good object to check my algorithms against the official ones. The official data of the objects found here are:

ID durationdeptht0perioda/R r/R*b
(hr)(ppm)(day)
KOI 70.01 3.798102771.60910.85404220.0000.0300.49
KOI 70.022.47837567.5013.6961256.2000.0210.85
KOI 70.037.23879397.72977.60900083.3900.0260.198
KOI 70.042.7707468.9306.0985216.0000.0080.40

My data (algorithm 8):

ID durationdeptht0perioda/R r/R*b
(hr)(ppm)(day)
KOI 70.014.69990-10.8545-0.0410.93
KOI 70.022.98368-3.6962-0.0250.95
KOI 70.038.753869-77.60-0.0390.94
KOI 70.042.9383-6.09852-0.0120.94

The periods founds are similar to 4 decimal accuracy. Adding 7 quarters of data leads to a better accuracy of 2 extra decimals. The other basic parameter of a transit is its depth. The depth difference is -4%, -2%, 10% and -10%. I regard this as OK for the data that I have.

The other three parameters: r/R*, b and duration are all related, so have to be viewed together. The most remarkable is that my detected radii are systematically to large (37%, 19%, 50% and 50%). But also my values for the impact parameter b are much larger. In fact the radii matches best, where the impact parameters do match (KOI 70.02). Thus the impact parameters seem to be the culprit of this difference. When I use the published impact parameters to calculate the radii, I get much smaller differences (9%, -10%, 12% and 12%). These errors seem reasonable as they are comparable to the related errors in depth.

The problem seems to be related to the impact parameter that I determined and the limb darkening model that I used. For small impact parameters (<0.4), the results are similar. The impact parameter influences the slope of the ingress and egress. This effect is mostly seen at the start and end of the ingress: for low impact parameters the descent starts quickly and is done within 0.2 hours. Limb darkening influences this slope as well, but most of all the roundness of the bottom of a transit. This does not influence the rate of descent/ascent.

So the slope of the model seems to steep compared to the data. For KOI 70.01 however the relation between flat and total duration is 99.9% (using Seager&Mallen;-Ornelas formula 2). Thus the steep parts of the transit seem correct.

Then the culprit must lie in the rounding effects due to the limb darkening model. A linear model with parameters varying from 0 to 1 do not provide the right slope. One can improve the situation somehat with a quadratic limb darkening model, but still the right slope is not reached.

In addition any linear limb darkening model in combination with a large impact parameter requires the size of a planet to be larger in order to get the right depth of the transit. This is logic: as the transit occurs further away from the center of the stellar disk, even at maximum transit, the depth is less deep due to limb darkening

In conclusion, I seem to have reached the limit of the model I used in my calculations. The model can not explain the observed slope without reverting to a large impact parameter. The solution seems to lie in the limb darkeing model that have been used.

A more detailed discussion of the individual transits follows.

This is a very interesting lightcurve as transits of 4 different objects have been discovered. The figure shows part of the light curve where all these transits can be seen. The yellow lines are for an object with a period of 77.6 days, the green have a period of 10.8545 days, the red lines have a period of 6.09852 days and finally the lilac lines have a period of 6.09852 days. The transits of this last object are very difficult to see on the light curve (I’m not sure whether I plotted them right). If you see the transit fit later, you’l see why. I took the period from the one that was published by the Kepler team. The other ones I derived myself.

kplr00685050 transits

The Q1-Q3 data was folded on 10.8545 days. The transit can be fitted with a relative radius of 0.041, an impact parameter of 0.93 and a linar limb darkeing factor of 0.65.

kplr00685050det

The Q1-Q3 data was folded with a period of 77.6 days. In the Q1-Q3 period there are only 3 transits. The transit can be fitted with a relative planet radius of 0.039, impact parameter 0.94 and limb darkening factor of 0.65.

kplr00685050 - transit 2

The Q1-Q3 data was folded with a period of 3.6962 days. Fit (red line) with a relative planet radius of 0.025, an impact parameter of 0.95 and a limb darkening factor of 0.6. Green line is a 21-point smooth.

kplr00685050 - transit 1

The Q1-Q3 data was folded with a published period of 6.09852 days. The fit was made with a relative radius of 0.012. I kept the other parameters the same as the other transits. Total transit time is 2.93 hours.

kplr00685050 transit 3

Categories: Science
PermaLink

Hunting planets

A few ways back I started playing with the Zooniverse websites: doing astronomy at home. I started with hunting for ice planets and then moved to hunting for planet in the Kepler data (planethunters). And I am still working on that.

I like this site, as it allows me to download the corrresponding data and playing with it. I downloaded the Plot application and started writing macro’s in perl for my needs. This results in images such as this one:

SPH22741609
Uploaded with Skitch!

This images shows a folded lightcurve, thus showing the passage of planet.

 


Categories: Science
PermaLink

Visiting Copernic

Last tuesday I visited the Copernic observatory. Every tuesday in july and august they have an open evening when people from the public can use the telescopes and get some xplanation about the heavens. It was some time ago I went, so it ws very to see that they now have a 52 cm reflector.

I used it to look at some open clusters and a globular cluster. Also M51 was nice, but even with such a telescope there is just some fluff. The small telescope was used to look at the the Dumbbell nebula and some close binaries (epsilon Lyrae and gamma (arrow)). I tried gamma later at home and was able to distinguish the two stars at 8 arcsec separation. I did not try epsilon lyrae as it was in the zenith, which is very awkward with my telescope.

Now I have to return to view the comet.

 


Categories: Science
PermaLink

Moving to Lion?

Now that a new version of MacOSX is coming, I have to wonder whether I want to upgrade again. This is unfortunately just a theoretical question as I’m still on PowerPC and I was left behind on Leopard. I use this article by Alex Layne (hmm Leene?) as a guidance to have a look at Lion.

Mission Control / Exposé - I am a big user of Exposé, so I would probably like the subtle changes in Lion.

Mission Control / Dashboard - I use it everyday to check the weather, the activity browser or access the dictionary, but that is it. I never add new widgets. So the addition to Mission Control is not a big deal for me.

MissionControl / Spaces - another feature that I use a lot. I do not get the impression that the changes impact my usage.

MissionControl Launchpad - I do not see that I will use this. Normally I start apps through the Dock or through Spotlight. If I do not remember the name of an app I descend into Finder. Here Launchpad could be a replacement. It reminds me as Finder with an icon view. I guess it comes all down to gesture support, which I do not have anyway.

I do not see how the integration into Mission Control works out. Just a question of gestures as well?

Autosave, versions - sounds like a very interesting development. There were already some applications (Sandvox comes to mind) that had this idea implemented and I liked that.

Resume - sounds like a good idea as well. An application like Omniweb had this already.

All in all this does not sound like an impressive update. The OS just evolves slowly. I will keep up, but I am not under pressure to update.

 


Categories: Computing
PermaLink

Learning iOS

I restarted my activity learing iOS. I bought the book “Beginning iPhone 3 development” by Dave Mark and Jeff LaMarche. This is much easier to follow than the CS193 course. I might pick-up that course once I got some more experience. Current book is mainly geared towards learning the interface libraries for iOS (iPhone). And I miss the library changes for the iPad.

I follow the corresponding forum for the book and created a FAQ for each chapter. So I can more easily see what kind of changes and suggestions have been made.

I am now at Chapter 9, so I am progressing well. Every day I work for several hours. Still some pages to go.

I already notice however that I miss some Objective-C basics. So I might also get a more basic book, before I start on my won project.

 


Categories: Computing
PermaLink Comments

Financial App requirements

After trying several financial applications, I realised that I should formulate my requirements more formally. Several applications seemed to fit my needs, but failed after using them for a while. So with this post I will define my requirements. I might edit this post when I get more details.


Categories: Computing
PermaLink

WebCam Monitor

One of the first experiments is to seen what can be done with the camera through the WebCam Monitor application. The application allows you to record audio and/or video through the menu-bar of the application Also the size of the video can be set in the menu (full, half, quarter size). This menu must also be used to record the video. My settings here are to disable audio and to use full size.

An addition there is a preferences window with multiple sub-screens.

WebCam Monitor Settings Video Adjustments

The first screen is the Adjustments-screen, which allows to change the hue, saturation, brightness, contrast and sharpness. The problem is to know what these sliders do as there is no documentation. Normally hue and saturation refer to colors on a color wheel. I would not want to fiddle with these settings and take what I get as raw input. Brightness is related to the amount of white versus black. As I want to detect weak object, a large brightness seems logic without overexposing the image. I guess that contrast relates to the difference between dark and light. This seems import to see the weaker objects. I am not sure what sharpness exactly is. It gives the impression of smoothing over multiple pixels. I guess I have to experiment with these sliders to see what they do exactly and what are my best settings. I have the impression that this screen relates to the software of the WebCam Monitor application.

The second screen is the Compression screen. For some reason this screen a bit damaged. I might have to do a reinstall.

WebCam Monitor Preferences Video Compression

This screen seems to relate to the output. Whether the video is compressed and how. In fact I do not want any compression and I need only a few frames per second.

The third screen is called the SN9C102 screen, so I guess this is the interface with the chip itself.

WebCamMonitor Settings Video SN9C102 Image

This seems to be the more interesting screen, but still it is unclear what it does. Gamma is about the color, but what is the best setting? Exposure time sounds interesting, but what does it do in context to movie frames. Anyway more seems better. White Balance must be set thuis that there is no difference between colors. Gain must be low for bright objects and high for weak objects. The video format chosen will be close to native, thus CIF (352x288). I have also the possibility to chose VGA or Mpeg, but I rather take the most raw data. I do not know what Flicker frequency does. Rotate 180 is checked as the telescope creates upside-down images.

WebCam Monitor Video Settings SN9C102 Digital Zoom

The SN9C102 Digital Zoom setting is simple. I do not want any.

Webcam Monitor Preferences Video Source

Finally there is the sources screen. I set this one to the TAS5110D WebCam/Camera setting. The macam #0 does not seem to work.

In conclusion there are many unknowns and I must experiment. I would like to find a way to calibrate things.

 


Categories: Science
PermaLink

Page 1 of 38 pages  1 2 3 >  Dernier »