Wednesday, October 28, 2009

Install language packs on Windows 7 professional version

The following content is adapted from http://bauforum.wirklichewelt.de/forum_entry.php?nr=5844 and http://www.winmatrix.com/forums/index.php?/topic/25680-can-i-install-a-language-pack-in-windows-7-professional/page__p__245434&#entry245434.

We know Microsoft only allows ultimate Windows 7 users to enjoy multi-language user interface. Thanks to Martin Vogel, we can install the language pack on Windows 7 professional.

  1. Prepare your language pack DVD, insert it in D driver, here D is your DVD drive. Locate your required language pack. For example, if we want to install German language pack, the lp.cab file will have a path of D:\langpacks\de-de\lp.cab.

  2. Run command window with administrator privileges. To run it as an administrator, go to "all programs - accessories", right-click "command prompt" and choose "run as administrator".

  3. In the command window, type the following line and press Enter (dism"space"/online"space"/add-package"space"/packagepath:d:\langpacks\de-de\lp.cab), note that the space in between:
    dism /online /add-package /packagepath:d:\langpacks\de-de\lp.cab
  4. When a message pops up and tells you the operation is completed successfully, press "Windows key + R" to call the run window, type in regedit to run the registry editor.

  5. Navigate to \HKLM\SYSTEM\CurrentControlSet\Control\MUI\ UILanguage\eu-us and delete the key eu-us.

  6. Restart your system, now your Windows 7 Professional should be switched to the German language version.

  7. To change the language of "Starting Windows", run the following command in the command window (still take the German as example):

    bcdedit /set {current} locale de-de
    bcdboot %WinDir% /l de-de
Because I have no Windows 7 installed, cannot test the method. If you successfully installed your language pack, please either leave comments here or on Martin Vogel's page at http://bauforum.wirklichewelt.de/forum_entry.php?nr=5844.

Update:
  1. It seems this trick works on home premium version as well.
  2. I have changed an English Windows 7 system into a Chinese one.

Chinese version:

在Windows 7 专业版上安装语言包

Friday, October 02, 2009

Scale a matrix into a specified range

function data_s= scale_matrix2(data, range)
% scale_matrix2 scales a matrix into [0 1] or a range specified by range
%
% Usage:
% data_s= scale_matrix2(data, range);
%data_s= scale_matrix2(data);
%
% Wenbin, 28-Jul-2009


if nargin ==1
range =[0 1];
end

data_c =data(:);

data_s =(data-min(data_c))./(max(data_c) -min(data_c)).*(range(2) -range(1)) +range(1);