티스토리 툴바



2011/03/10 22:50

New Balance 870


쇼핑몰 운영자가 신은 870(무단으로 펌 ㅜㅜ)


Trackback 0 Comment 0
2011/03/04 22:47

574

뉴발란스 574.
편하고, 가격도 합리적이다.
Trackback 0 Comment 0
2009/10/05 15:36

내 처지

나는 내년의 나에 대해서 말 할 수 없다.
심지어는 다음달의 나에 대해서 말 할 수 조차도 없다.
1초 후의 나, 1분 후의 나에 대해서만 생각하고 행동하자...
이것이 향후 몇년간 내가 가져야 할 마음가짐이요, 행동이다.

언젠가는 1년후의 나, 몇년 후의 나에 대해 말 할 수 있겠지...
Trackback 0 Comment 1
2009/07/22 15:43

Mac에서 macport를 이용하여 mysql 설치하는 방법

이 글은 나의 경험과 구글링으로 찾은 웹페이지 http://mdzyuba.blogspot.com/2007/11/mysql-macport-install-on-mac-os-x-tiger.html 을 부분적으로 번역 한 것임을 밝힌다.

먼저 macport를 설치한다. 구글에서 macport 등으로 검색하면 찾을 수 있을 것이다.

macport가 설치되면 다음 명령을 통해 mysql5를 설치 한다.
$ sudo port install mysql5

mysql5의 설치가 끝났으면 이제, 초기 database를 설치 해야 한다.
$ sudo /opt/local/lib/mysql5/bin/mysql_install_db --user=mysql

아웃풋은 다음과 같이 나와야 한다.
Installing MySQL system tables...
071118 0:06:29 [Warning] Setting lower_case_table_names=2 because file system for /opt/local/var/db/mysql5/ is case insensitive
OK
Filling help tables...
071118 0:06:29 [Warning] Setting lower_case_table_names=2 because file system for /opt/local/var/db/mysql5/ is case insensitive
OK

To start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:
/opt/local/lib/mysql5/bin/mysqladmin -u root password 'new-password'
/opt/local/lib/mysql5/bin/mysqladmin -u root -h my-computer.local password 'new-password'
See the manual for more instructions.
You can start the MySQL daemon with:
cd /opt/local ; /opt/local/lib/mysql5/bin/mysqld_safe &

You can test the MySQL daemon with mysql-test-run.pl
cd mysql-test ; perl mysql-test-run.pl

Please report any problems with the /opt/local/lib/mysql5/bin/mysqlbug script!

The latest information about MySQL is available on the web at
http://www.mysql.com
Support MySQL by buying support/licenses at http://shop.mysql.com

이 상태에서 mysql 데몬을 띄우면 다음과 같이 에러가 난다.
$ sudo /opt/local/lib/mysql5/bin/mysqld_safe 
mkdir: /opt/local/var/run: No such file or directory
chown: /opt/local/var/run/mysql5: No such file or directory
chmod: /opt/local/var/run/mysql5: No such file or directory
Starting mysqld daemon with databases from /opt/local/var/db/mysql5
STOPPING server from pid file /opt/local/var/db/mysql5/mykola-dzyubas-computer-2.local.pid
071118 00:27:12 mysqld ended

따라서 다음 명령어 들을 입력하여 같이 디렉토리를 수동으로 생성 해 준다.
sudo mkdir /opt/local/var/run
sudo chmod g+w /opt/local/var/run
sudo mkdir /opt/local/var/run/mysql5
sudo chown mysql /opt/local/var/run/mysql5

그러면 이제 mysql 데몬이 잘 실행 될 것이다.
$ sudo /opt/local/lib/mysql5/bin/mysqld_safe &
Starting mysqld daemon with databases from /opt/local/var/db/mysql5

mysql 서버가 잘 떠 있는지 체크하는 방법은 다음과 같다.
$ mysqladmin5 -u root -p ping
Enter password:
mysqld is alive

다음과 같이 mysql 명령으로 mysql5 클라이언트를 띄울 수 있도록 만들면 편하다.

$ cd /opt/local/bin
$ ln -s mysql5 mysql


보안을 강화하기 위하여 다음과 같은 명령어를 내리면 좋다. 특히 mysql로 조그마한 서비스라도 제공한다면 보안 강화 명령을 주는 것이 좋다.

$ cd /opt/local/bin
$ ./mysql_secure_installation5

mykola-dzyubas-computer-2:/opt/local/bin mykola$ ./mysql_secure_installation5

NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQL
SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY!


In order to log into MySQL to secure it, we'll need the current
password for the root user. If you've just installed MySQL, and
you haven't set the root password yet, the password will be blank,
so you should just press enter here.

Enter current password for root (enter for none):
OK, successfully used password, moving on...

Setting the root password ensures that nobody can log into the MySQL
root user without the proper authorisation.

Set root password? [Y/n] y
New password:
Re-enter new password:
Password updated successfully!
Reloading privilege tables..
... Success!


By default, a MySQL installation has an anonymous user, allowing anyone
to log into MySQL without having to have a user account created for
them. This is intended only for testing, and to make the installation
go a bit smoother. You should remove them before moving into a
production environment.

Remove anonymous users? [Y/n]
... Success!

Normally, root should only be allowed to connect from 'localhost'. This
ensures that someone cannot guess at the root password from the network.

Disallow root login remotely? [Y/n]
... Success!

By default, MySQL comes with a database named 'test' that anyone can
access. This is also intended only for testing, and should be removed
before moving into a production environment.

Remove test database and access to it? [Y/n] n
... skipping.

Reloading the privilege tables will ensure that all changes made so far
will take effect immediately.

Reload privilege tables now? [Y/n]
... Success!

Cleaning up...



All done! If you've completed all of the above steps, your MySQL
installation should now be secure.

Thanks for using MySQL!

이상.
Trackback 0 Comment 1
2009/06/30 10:07

Before Pyosoon going back to Korea.

We have talked a lot in my room.
My feet.

Pyosoon


Pyosoon

My feet and Pyosoon's
Trackback 0 Comment 4
2009/06/30 09:57

One fine day - Fishing

Fishing at the Medicin Lake.
I had a lot of fun.
We got 7~8 fishes in about three hours. Because it's illegal to catch small fishes like 2~3 inches, we released about three fishes.
Cat fish(메기) was biggest one among all the fished we have caught.

Cosmin and Me.

Cosmin and Ben


Cosmin got a fish.


Beach.


Baits... Yummy!


Concentration.


Ben is fixing his rod and string.

Concentration.


Cosmin got big cat fish.

My Last Fish. Name of the fish is crappy(?). I don't know the spell :(.


Trackback 0 Comment 1
2009/06/24 15:27

Weather in Minnesota



It's too hot these days.
Yesterday: 35 degrees in centigrade....Today: 36 degrees.  :(
In the winter, it's too cold and too hot in the summer in MN.
Now, it's 1:21AM, but still the temperature is 26 degrees in centigrade. 
I cannot concentrate on anything.
I cannot sleep deeply.
In the house, it's much more hotter than outside. 
I think 26 degrees outside means that about 35 degrees inside my house.

T.T
Trackback 0 Comment 5
2009/06/11 03:29

니코니코 동화에서 동영상 다운로드 방법

이 글의 제목을 다르게 표현하자면 flv 다운로드 방법이다.

동영상을 다운로드 해 , 퍼, 혹은 훔쳐 오는 방법은 다음과 같다.


1. 윈도우즈 유져의 경우 urlhelper 라는 프로그램을 이용하는 방법을 많이 사용하는 듯 하다.
아래의 포스팅을 참조 하도록 하자.
http://study4u.justgoo.com/forum-f8/topic-t316.htm

2. 맥을 이용하여 내가 쓰는 방법인데, 윈도우에서도 될 것 같다.
real player 를 설치하면 realplayer downloader 라는 프로램도 동시에 설치된다. 만일 설치 안되면 찾아서 깔자.
그 다음 realplayer downloader를 실행시킨 뒤 유튜브, 판도라 티비, 니코니코 동화 등에서 동영상을 재생시키면 자동으로 동영상이 다운로드(?) 된다.
이게 계속해서 내가 재생하는 모든 동영상을 자동으로 다운로드 시키면 내 하드는 금방 꽉 찰 것이 분명하다.
따라서 내가 프로그램을 몇일간 이용해 본 바로는 하드에 임시로 저장 해 놨다가 프로그램을 종료하면 그것도 같이 지우는 듯 하다.
아무튼, 재생하면서 다운로드 된 동영상 제목 옆에 보면 download 버튼이 클릭하는데, 맥 버전에서는 1초의 딜레이도 없이 다운로드 폴더에 바로 저장이 된다.
그래서 미리 어딘가에 임시로 저장 해 놓았다가 download 버튼을 클릭하는 순간 다운로드 폴더로 옮기는 것으로 생각했다. (윈도우 버전은 사용해 보지 않음)

그렇게 해서 테스트로 니코니코 동화에서 퍼 온 동영상이 바로 아래의 동영상이다.



Trackback 0 Comment 3
2009/05/03 10:27

Electrial Eng. and Computer Science Building

매일 수업을 듣는곳.(수업의 3/4이 이 건물)

자주 조별 프로젝트 하는 곳.(계단 밑에 의자 거기서 모임)

몇달 뒤면 떠날 곳.

나중에 사진 보면 그리울 곳.



표순이가 사진을 잘 찍었군..ㅎㅎ(트랙백)





Trackback 0 Comment 3
2009/04/29 07:53

소수와 알고리즘 이야기

P: P is the class of languages that are decidable in polynomial time on a deterministic single tape Turing machine.
NP: NP is the class of languages that are decidable in polynomial time on a non-deterministic single tape Turing machine.

현재 수학자들은 P와 NP가 같은 것인지 다른 것인지 모른다. 이 P와 NP가 같은지 다른지 알아내는 문제에는 큰 현상금이 걸려 있다.

P와 NP에 대해선 이미 자세한 자료가 인터넷에 많이 있다.

그리고 수학자들이 풀지 못한 비슷한 문제가 하나 더 있다.
그것은 NP=co-NP 인지의 여부이다. 이 문제에는 현상금이 걸려 있는지 안걸려 있는지 모르겠다.

소수(Prime numbers)는 수학(특히 정수론)에서 기본적으로 매우 중요성을 지닌다. 그래서 소수의 특성에 대한 많은 연구가 이루어 져 왔다.
그런 연구들 중 하나는 효율적으로 어떤 수가 소수인지 판단하는 문제이다. 어떤 수가 소수인지 효율적으로(빠르게) 판단하는 문제는 암호학 등에서 중요하게 다루어 진다. 왜냐하면 많은 암호 프로토콜들이 큰 소수를 이용하기 때문이다.
PRIMES 를 모든 소수의 집합이라 가정하자. 즉,
        PRIMES = {p ∈ N : p is prime}
이다.
어떤 수 n이 PRIMES에 속하는지 알기 위해서는 sqrt(n) 보다 작거나 같은 모든 정수 m 으로 나누어 보면 된다.
만일 하나의 m이라도 n을 나누면 n은 PRIMES에 속하지 않으며, n을 나누는 m이 존재치 않으면 n은 PRIMES에 속한다.
이 방법은 고대 그리스 시대부터 알려 져 온 방법이다. 하지만 이 방법은 효율적이지 않다. 왜냐면  n이 소수인지 판단하기 위해서 Ω(√n) step의 연산이 필요하기 때문이다.
1960년대 부터 복잡도 이론(complexity theory)가 발전하면서 여러 복잡도 클래스(complexity class)들이 정의 되었다.
소수 판정 문제는 co-NP 로 분류된다. 왜냐면 n이 소수가 아니라면, 짧은 certificate을 이용하여 판별(verifiable) 할 수 있기 때문이다.
1974년, Pratt은 소수 판정 문제가 NP로도 분류됨을 알아 내었다.(어떻게 알아 냈는지는 논문을 읽어봐야 알 것 같다. 한마디로 나도 모르겠다) 따라서 이 소수 판정 문제는  NP ∩ co-NP 영역에 속하게 되었다.

NP와 co-NP 문제에 동시에 속하는 문제가 하나 더 있다.
FACTORING 문제 있데, FACTORING 이라는 집합은 다음과 같이 정의한다.
        FACTORING = {(n, k) : n has some factor d with 1 < d < k}
그런데 만일 FACTORING이 NP-complete라면 NP=co-NP가 된다.
엄밀한 증명은 지금 잘 생각이 나지 않는데, 대충 이유를 적자면,
모든 NP문제들은 어떤 NP-Complete 문제로 다항시간(polynomial time) 내에 환원(reduce) 될 수 있다.
그런데, 가정에서 FACTORING은 NP-complete라고 했으므로 모든 NP문제는 FACTORING으로 다항시간 내에  환원 될 수 있다.
그런데 FACTORING은 co-NP에 속하므로 이 경우 NP는 co-NP의 부분집합(subset)이 된다.
그렇다면, NP에 속하는 문제들의 complement들의 집합은 co-NP에 속하는 문제들의 complement들의 집합의 부분집합이 된다. 따라서 co-NP는 NP의 부분집합이 된다.
결론: 만일 FACTORING이 NP-complete라면 NP=co-NP가 된다.
하지만 아직까지는 아무도 FACTORING에 NP-complete인지 아닌지 알아내지 못했다.

위에 설명한 내용의 자세한 증명들은 나중에 시간 날 때 적어 봐야겠다.
(근데 아마 시간 안 날 거 같다.)



Trackback 0 Comment 0