2010年10月27日星期三

Run Matlab in Linux

@ Ubuntu

You can use the matlab by using "ssh -X nam@lion.cs.uh.edu".
After logging in, you can type "matlab" to activate the program.

@ Window

Install PuTTY and Xming

Setting up X11 tunneling

First of all make sure that you have a recent version of PuTTY which supports X11 tunneling. You can get it from this page.

It is now time to bring up PuTTY, so do so! Select the category "Connection/SSH/Tunnels". Check the "Enable X11 forwarding" box and fill out the text field below with the address of your X11 server. The format is either "IP address:display" or "host name:display". You will most likely be using display 0 (zero), but you will probably know if not. If your X11 server is not running on the local computer, you must be able to trust the network between your local machine and your X11 server. If your X11 server runs on the same computer as PuTTY, put "127.0.0.1:0" in the text box.

2010年10月26日星期二

Debian networking setup ZZ

http://www.debian-administration.org/articles/254

An introduction to Debian networking setup

Posted by Steve on Sun 25 Sep 2005 at 13:32

Under Debian networking is pretty comparable to other distributions of GNU/Linux, especially in areas such as DNS setup. However if you're new to the distribution you might not know where things are set. This brief introduction to networking will show you how it works.

Most likely there are only four things you will care about:

  • Setting up your hostname
  • Setting up DNS.
  • Setting up your IP address.
  • Setting your default gateway.
Setting your hostname

Setting up your hostname upon a Debian installation is very straightforward. You can directly query, or set, the hostname with the hostname command.

As an user you can see your current hostname with:

skx@lappy:~$ /bin/hostname
lappy

To set the hostname directly you can become root and run:

/bin/hostname newname

When your system boots it will automatically read the hostname from the file /etc/hostname - so if you wish to make a permanent change then you should edit that file, and your change will then be made at bootup time automatically.

Setting up DNS

When it comes to DNS setup Debian doesn't differ from other distributions. You can add hostname and IP addresses to the file /etc/hosts for static lokups.

To cause your machine to consult with a particular server for name lookups you simply add their addresses to /etc/resolv.conf.

For example a machine which should perform lookups from the DNS server at IP address 192.168.1.1 would have a resolv.conf file looking like this:

search my.flat
nameserver 192.168.1.1

(Here the search my.flat causes lookups of hostnames to have my.flat appended to them. So lappy would be looked up as lappy.my.flat)

Setting up your IP address.

The IP addresses associated with any network cards you might have are read from the file /etc/network/interfaces. This file has documentation you can read with:

man interfaces

A sample entry for a machine with a static address would look something like this:

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
iface eth0 inet static
address 192.168.1.90
gateway 192.168.1.1
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255

Here we've setup the IP addresss (192.168.1.90), the default gateway (192.168.1.1), and the netmask.

For a machine running DHCP the setup would look much simpler:

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface - use DHCP to find our address
auto eth0
iface eth0 inet dhcp

(If you're using a DHCP based setup you must have a DHCP client package installed - usually one of pump or dhcp-client.)

If you make changes to this file you can cause them to take effect by running:

/etc/init.d/networking restart
Setting your default gateway.

If you read the previous section then you'll see that the default route for a host with a static IP address can be set in /etc/network/interfaces.

If you wish to view your current default route/gateway then you can run:

lappy:~# netstat -nr
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
0.0.0.0 192.168.1.1 0.0.0.0 UG 0 0 0 eth0

Alternatively you can use the route command:

lappy:~# /sbin/route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.1.0 * 255.255.255.0 U 0 0 0 eth0
default router 0.0.0.0 UG 0 0 0 eth0

(Here the see the hostname router instead of the IP address 192.168.1.1 - to avoid that run "/sbin/route -n").

To change your default route you must first remove the current one:

/sbin/route del default gw 192.168.1.1

Once this has done you'll have no gateway and be unable to talk to non-local hosts.

Add the new route with :

/sbin/route add default gw 192.168.1.100
Share/Save/Bookmark

Start reading the books regularly!!!

1) Python

2) Detection and Estimation theory

Regularly reading books at morning

Using SSH to zip files

tar.gz is better for linux

so, to compress
tar -cvzf filename.tar.gz /home/path
and to decompress
tar -xvzf filename
Upload the file to server:
scp file user:password@host:/path

2010年10月21日星期四

Classify the channel environment

The possible solutions includes:

1) Using Kolmogorov-Smirnov test
--> Try to find the difference D on the CDF of received envelope
--> In our case, we can compute received signal envelope by using RSSI and noise floor over some time period.
--> Two Ds are needed to classify three channel models.
--> Cons: computation complexity; the threshold is a critical parameter
http://www.physics.csbsju.edu/stats/KS-test.html


2) Kurtosis index
--> not only for classification, but also identify the quality of link (seem to reflect SNR)
--> Kurtosis is the degree of peakedness of a distribution.
http://mvpprograms.com/help/mvpstats/distributions/SkewnessKurtosis
http://davidmlane.com/hyperstat/A53638.html
http://www.itl.nist.gov/div898/handbook/eda/section3/eda35b.htm

I believe we can use both Skewness and Kurtosis to classify, even for a fine classification.

CGRAN link for gnuradio

https://www.cgran.org/

Fix MBR for Ubuntu ZZ

在win7下卸载ubuntu直接删除ubuntu的分区会导致grub破坏,开机进不了系统,修复方式如下:

第一种方法:
1.下载fixmbr工具,放在c盘,利用命令提示符,进入软件所在目录,cd c:\fixmbr (cd后面一个空格)

2.输入 MBRFix /drive 0 fixmbr /yes

3.重启,发现直接进入win7,现在可以格式化ubuntu所在分区了
这种方法中下载的fixmbr工具必须是最新版,不然在win7下用不起来
第二种方法:
用带dos的启动盘或者启动u盘启动到dos,运行 fdisk /mbr
第三种方法:
用win7或者vista的光盘修复,从光盘启动,然后选择修复系统,再选择命令提示符,输入:bootrec /fixmbr提示完成后继续输入:bootrec /fixboot

2010年10月18日星期一

To be a good Phd student ZZ

Work hard and play hard!

Be focused especially in face of stumbling blocks

Disciplined in time management

Pace your publication

More theory courses at the early stage


----------- from my advisor's note

2010年10月9日星期六

Networking Over White Spaces (KNOWS)

To the best of our knowledge this is the first urban WSN. (Click here for deployment pictures)

Technologies tested include:

    • An opportunistic data network in the UHF and VHF bands
    • Channel occupancy database service with real-time Longley-Rice RF propagation modeling over NASA Terrain Data
    • Coexistence with wireless microphones
    • Handling mobile clients
    • Varying channel widths to accommodate varying needs of the application

http://research.microsoft.com/en-us/projects/KNOWS/deployment.aspx

Connecting to multiple IEEE 802.11 networks with one WiFi card

virtualwifi

http://research.microsoft.com/en-us/um/redmond/projects/virtualwifi/

2010年10月7日星期四

I am Back :)

Just come back from China and enjoy a great long vacation :)

Start working hard for the brand new life!