Install OrbFit on My Mac

So far I have not yet fully successful with the software. But the problem may well be intrinsic in the codes, rather than mistakes during my installation. I have reported a bug to the OrbFit consortium. But anyway I think I need to record my steps of installing it, which may benefit me in the future if I want to reinstall the software.

Step 1: Download the software from the website and unzip it.

Step 2: Change the terminal to tcsh.

Step 3: Type config -O gfortran, Since I’m using gfortran. Other modes will flag -static which leads to errors of ld: library not found for -lcrt0.o.

Step 4: Type make. It should take seconds to finish.

Step 5: Download ASCII formatted of JPL DExxx to directory src/jpleph. I downloaded DE431. Edit makefile if necessary.

Step 6: Type make ephemerides. It is then converting the DExxx from ASCII to binary, which takes about 20 sec on my computer. After it completes a file called jpleph will appear.

Step 7: Copy that file to lib under the main directory of OrbFit, or goto that directory by cd ../../lib, and then type ln -s ../src/jpleph/jpleph jpleph to create an alias.

Step 8: Goto the main directory and test the installation:
make tests
where I am confronted with errors about segmentation, with the latest version OrbFit5.0.

Advertisements
Install OrbFit on My Mac

乙未仲冬既朔觀星

斗轉參橫已五更,

飛星寂寂動欃槍。

夜闌天市無時歇,

萬里平沙太白生。

 

 

IMG_0185

Zodiacal light and me at Joshua Tree National Park. I was observing C/2013 US10. 2015 Dec 13, Canon 5D2, 16-35 mm f2.8 @ 16mm f2.8, ISO 3200, 15-sec exposure.

乙未仲冬既朔觀星

Weird Function TRIANGULATE in IDL

Time to update my blog again. It’s been more than a year since my last update after all. Today I encountered with a weird error in IDL when trying to improve computation precision of own polar transform image routines. The source was traced back to function TRIANGULATE. So far I really have no idea about why it occurs. The example is as follows:

IDL> theta=dindgen(360L)
IDL> rad=dindgen(500L)
IDL> xpol=rad#cos(theta/1.8d2*!dpi)
IDL> ypol=rad#sin(theta/1.8d2*!dpi)
IDL> triangulate,xpol,ypol,tri
% TRIANGULATE: Points are co-linear, no solution.
% Execution halted at: $MAIN$

However, if I type the following TRIANGULATE works flawlessly:

IDL> xpol=rad#cos(float(theta/1.8d2*!dpi))
IDL> ypol=rad#sin(float(theta/1.8d2*!dpi))
IDL> triangulate,xpol,ypol,tri
IDL> help,tri
TRI             LONG      = Array[3, 358920]

This is really annoying, as I can’t figure out how come co-linearity can be related to float or double precision whatsoever. Not sure if anyone could help this for me, but I just throw this problem here and see if there’s anyone else faced with the same encounter so that we can potentially sigh together…

Weird Function TRIANGULATE in IDL

My Record of Installing IDL, SSW and SSWDB on My New Mac OS X

I got a new laptop Mac OS X from Dave and needed to install IDL, SSW and SSWDB on it. The following are the main steps how I installed it successfully.

 

Basic Steps of installation of IDL 8.3 on my Mac OS X

1. Download the installation package from the EXELIS.

2. Click on the icon and follow the instructions of the installation wizard.

3. Put the license into the following directory: Applications/exelis/license.

4. The license wizard pops out automatically after the installation completes. Now select the license file in the panel.

5. Now IDL should be successfully launched by double clicking on the workbench icon, however, if you type idl in the terminal, you will be informed that idl: Command not found. Environment has to be set.

6. Type the following commands in the terminal:

vi .tcshrc

7. See if there is the following lines within the file, insert them otherwise.

setenv IDL_DIR /Applications/exelis/idl83
setenv OS darwin.

In Tshell command line, typing idl will now successfully run IDL.

 

Steps of installation of SSW

1. Fill out and submit the form at http://www.mssl.ucl.ac.uk/surf/sswdoc/solarsoft/ssw_install.html.

2. Follow the instructions in that website and the links therein.

3. Type sswidl in the terminal, but fails, so insert the following lines into the .tcshrc file:

set path=(/usr/local/bin /sw/bin /sw/sbin /usr/local /usr/local/ssw/gen/mirror /usr/X11R6/bin /Applications/exelis/idl83/bin $path .)
setenv SSW_INSTR "lasco secchi"
setenv SSW ssw
setenv SSWDB sswdb
setenv ssw_quiet 1
source $SSW/gen/setup/setup.ssw
source $SSW/soho/lasco/setup/setup.lasco_envsetenv SSWDB /usr/local/ssw/sswdb

Installation of SSWDB

1. Anyway I am not able to generate a configuration file from http://www.lmsal.com/solarsoft/sswdb_configure.html, but there is a file called setup.sswdb_upgrade_template in directory of ssw/site/setup. Add lines indicating the packages in need, or, if there are packages already listed in the template, remove the corresponding “#” at the beginning. Root is required:

sudo vi setup.sswdb_upgrade

2. Follow the steps listed at http://www.mssl.ucl.ac.uk/surf/sswdoc/solarsoft/sswdb_install.html.

3. If Perl is installed in a non-default directory, type
ln -s /usr/bin/perl /usr/local/bin/perl
in the terminal.

4.IDL> sswdb_upgrade, /spawn, /passive_ftp

5. Be patient about Step 4, and it took me rather long.

6. Done!

My Record of Installing IDL, SSW and SSWDB on My New Mac OS X

詩數首

春日葳蕤百越東,棹歌聲裏木棉紅。

回看無數詩和畫,盡在一谿煙雨中。

*********************************************************************************

風斜雲淡月幽冥,耿耿銀河點點星。

夜色惹人眠不得,憑軒醉臥數流螢。

*********************************************************************************

學書廿年有感

佳致何曾經歲失?長臨南帖北碑文。

及今池水還無染,更以孜孜學右軍。

*********************************************************************************

夜來弄墨足風騷,神入中山紫兎毫。

沉醉不知天欲曙,忽驚窗外啓明高。

*********************************************************************************

玉魄西欹藏海波,星槎飛急渡天河。

夜深露重行人絕,織女牽牛相盪摩。

*********************************************************************************

愁思縈懷細雨天,北邙一帶草芊芊。

想來往事還如昨,物換星移又十年。

詩數首

小白,走好!

  我家的小白,走了……
  自元宵走出後,已是三日未歸。直到昨天下午,阿公想去蕉林看看,結果卻在蕉林的草叢中發現了小白的遺體。雙眼緊閉,已是渾身冰涼,四肢僵硬了。看來已是亡去多時了。
  家裏養小白應該是有四五年了吧。它雖說叫小白,但頭卻是黑色的,背部也有幾塊黑色的斑點。眼睛固然小小的,但卻是炯炯有神。當初還是舅父不知從何處帶回來的,才幾個月大。這隻小狗不同以往養過的,不用教太多便非常聽話了。我能想起它唯一做過的一件壞事是把我晾在階前的波鞋的鞋帶給咬斷了,真是個淘氣鬼!
  夜晚它是非常警醒的,每每聽到異響,便以洪亮而清澈的聲響吠之。還記得有次晚飯後,見它伏在臺階上,表情甚是可愛,於是輕輕撫摸着它的頭。想必它正在熟睡中,被我的舉動嚇壞了,倏地下躥了起來逃走,驚恐地吠了幾聲,回頭見原來是我,便又搖着尾巴匆匆跑來舐我的腳。
  每次回家,無論是深夜,還是日頭,只要聽到響聲,它總是第一時間衝向我奔來。我也總是摸摸它烏黑的腦袋予以回報,這樣它的尾巴搖得更快了,似乎都要把屁股摔出去了。它在白天喜歡曬太陽,若是見我來逗它,它便四肢朝天地示意叫我幫它撓撓它的肚子。看着它的樣子,很是享受呢!
  可是到如今,一切戛然皆是夢了,徒留回憶矣,滿腹心事,又可與胡訴說?唯聽窗外瀟瀟冷雨。我所能做的,便是願它在天堂安好,那裏或無嚴寒酷暑,一切都美好於人間。來世有緣者,我們再相見吧!我會十分想念你的,小白!

小白,走好!