Posted: February 16, 2011 in Uncategorized

At first glance I was so astonished while scrolling my mouse down in viewing Khan Academy page. The fabulous list of subject, starting of  SAT preparation, Chemistry, Algebra, Biology, Organic Chemistry, till History. The page also includes exercise dashboard, and I can do by following recommendation, wh0se 1st problem is addition1. You only need to sign up first through your google account to fullfiled exercise dashboard tasks.

While accessing my tweeter account  in 29th  July ago ,  I found an interesting tweet from @BillGates, the founder of  Microsoft .corp and the  second world richest man as listed in Forbes magazine.  He wrote about his nice impression after watching many youtube online courses   provided by Khan Academy.  Khan Academy is an educational site  created by Salman Khan at his residence in Sillicon Valley. After determining to quit from his accounting  job, this  Harvard master degree owner had so much leisure time. Knowing his hobby to watch youtube, he then made a tutorial site aiming firstly for his nephew. Later, he accepted some e-mails from some  children in USA, telling they’re helped by his video. This information triggered him to more enriched his site with more subjects. His visitors are more less about 20 millions over a month recently.

This site has a lot of visitors mainly in USA, Canada, India. Telling about his success page in India, this 33 years old man joked that his fortune is due to he shared his name with a famous Indian actor,  Salman Khan.

Calculate Age.3

Graphical User Interface

Matlab is a tool to calculate any mathematic problems. It uses simple syntax, not as difficult such as C++ or other Javascript-based programmes.You can create graphical user interface ( GUI ) such image on the right which show how to calculate age. Below are the steps :

Open Matlab version R2007a, at my desktop, but otherwise you can have the latest one.

Then please select File, create a new GUI.

Select a static text toolbox on the left pane. Then type ‘ DOB :’ ( Date of Birth ). Place a drop-down menu toolbox to insert entry on the right side. Please open m-file editor to change : DOB=str2double(get(handles.DOB_input,’String’));

and give tag : ”  DOB”  for the drop-down toolbox by double  clicking it.

Select a static text toolbox  again and type ‘ # Leap Years : ‘. Insert edit text toolbox on the right, double click it and give tag ‘leap years’. Then type  :

leap_years=str2double(get(handles.leap_years_input,’String’));

within its m-file editor.

More Fun in SeaWorld Ancol Jakarta

Posted: August 10, 2010 in Travel
Tags: , ,

If you want to see undersea fishes then you don’t need to take a picnic to seashore and have diving.For kids and a oldster going to Ancol in North Jakarta is suggested.There is big aquariums for underwater creature, which located at SeaWorld zone.You can watch a mammal “Dolphin” exhibition at Gelanggang Samudera. For detail information please click here.

2 تلكوم القمر قمرا صناعيا للاتصالات الثابت بالنسبة للأرض الموقف. يزن هذا القمر الصناعي 1930 كجم والمركبات الفضائية التي أطلقها آريان 5 قاذفة في عام 2005. مثل الأقمار الصناعية الأخرى الاندونيسية العمل تلكوم (2) ، الأقمار الصناعية على نطاق التردد سي. 2 تلكوم تحتل عصابة بريتيش تيليكوم 118. تليكوم 2 منطقة تغطية القمر الصناعي تغطي جنوب شرق آسيا وأجزاء من الهندتليكوم 2 الأقمار الصناعي

Keong Emas (Golden Snail), an IMAX theater loc...

IMX Theatre "Keong Emas" at Taman Mini Indonesia Indah

Many of us like travel. Do you like travel ? Perhaps the map inserted into this article  isn’t clear enough to see. All right, it shows many big cities around the world. For example,  you can choose Moscow as your destination. There are some places such as The Moscow Zoo, Monument to the city founder, Yuri Dolgoruki, fountain at Square of Europe which lit at night, Sukhov Tower, etc. But remember, Moscow is one of top most expensive cities. If  you’re a low budget traveller, please don’t go there.

Paris is known with its particularly comfortable but high priced restaurant. It’s labelled as a mode city.

Jakarta, the capital city of my country is known as a cheap metropolitan. It headed north to Jakarta Bay. There was also wonderful  Seribu Islands, which lies on Java Sea. In Central Jakarta you can watch some parts of Jakarta from the top of  National Monument. Just go south then you will be cheered up by so many various faunas in Ragunan Zoo. You don’t need to travel around Indonesia for knowing its diverse culture. At Taman Mini Indonesia Indah, East Jakarta, you’ll see various ethnic clothes, weapons, and houses. There is also Komodo dragon ( Varanus Komodoensis ), one of  ” The Seven Wonders of  The World ” at TMII.

I. Pendahuluan
Persamaan diferential partial adalah salah satu jenis persamaan diferensial yang melibatkan fungsi yang belum diketahui yang mengandung beberapa variabel.
Persamaan diferential parsial digunakan untuk memecahkan problem-problem físika seperti propagasi suara atau panas, elektrostatik, elektrodinamik, aliran fluida, elastisitas, dan potensial. Salah satu penerapan persamaan diferensial parsial adalah persamaan Poisson dan Laplace yang akan dibahas berikut ini.

II. Persamaan Laplace

Jika fungsi potensial dalam tata koordinat bola adalah , maka persamaan Laplace nya :

\nabla^2 {V}=\frac{1}{r^2}\frac{\partial}{\partial r}(r^2\frac{\partial}{\partial r})+\frac{1}{r^2\sin\theta}\frac{\partial}{\partial r}(\sin\theta\frac{\partial V}{\partial \theta})+\frac{1}{r^2sin^\theta}\frac{\partial^2 V}{\partial \phi^2}=0 (1)

\frac{1}{r^2R}\frac{\ d}{\ dr}(r^2\frac{\ dR}{\ dr})+\frac{1}{r^2P\sin\theta}\frac{\ d}{\ d\theta}(\sin\theta\frac{P}{\ d\theta})+\frac{1}{r^2Q\sin^2\theta}\frac{\ d^2Q}{\ d\phi^2}=0  (2)

Kalikan dengan r^2\sin^2\theta :
\frac{\sin^2\theta}{R}\frac{\ d}{\ dr}(r^2\frac{\ dR}{\ dr}+\frac{\sin\theta}{P}\frac{\ d}{\ d\theta}(\sin\theta\frac{\ dP}{\ d\theta})=-\frac{1}{Q}\frac{\ d^2Q}{\ d\phi^2} (3)

Ruas kiri bergantung terhadap r dan θ sedangkan ruas kanan bergantung hanya terhadap φ. Jika masing-masing ruas berharga m2, maka ruas kiri yang merupakan fungsi dapat ditulis menjadi :V(r,\theta)=R(r)P(\theta)
\frac{\sin^2\theta}{R}\frac{\ d}{\ dr}(r^2\frac{\ dR}{\ dr})+\frac {\sin\theta}{P\sin\theta}\frac{\ d}{\ d\theta}(\sin\theta}\frac{\ dP}{\ d\theta})=\frac{m^2}{{\sin^2\theta} (4)
Bagi kedua ruas dengan :\sin^2\theta
\frac{1}{R}\frac{\ d}{\ dr}(r^2\frac{\ dR}{\ dr})+\frac {1}{P\sin\theta}\frac{\ d}{\ \d\theta}(\sin\theta}\frac{\ dP}{\ d\theta}) (5)
\frac{1}{R}\frac{\ d}{\ dr}(r^2\frac{\ dR}{\ dr})=-\frac {1}{P\sin\theta}\frac{\ d}{\ d\theta}(\sin\theta}\frac{\ dP}{\ d\theta})+\frac{m^2}{\sin^2\theta} (6)
Ruas kiri yang baru bergantung pada r dan ruas kanan pada θ. Asumsi : harga ruas kiri & kanan = $latex l(l+1) . Maka :
1) Menentukan R(r)

Ruas kiri persamaan (6) menjadi :

\frac{1}{R}\frac{\ d}{\ dr}(r^2 \frac{\ dR}{\ dr})=l(l+1)
\frac{\ d}{\ dr}(r^2 \frac{\ dR}{\ dr})-l(l+1)=0
r^2\frac{\ d^2R}{\ dr^2}+2r\frac{\ dR}{\ dr}-l(l+1)R=0 (6a)
Solusi umum persamaan di atas diperoleh dengan cara :
Asumsi : $latex R=r^{m} , maka

R'=mr^{m-1}
R"=m(m-1)r^{m-2}

Masukkan masing-masing R, R’, dan R” ke dalam persamaan :

R1=r dan R2=
Solusi umum : (7)

2) Menentukan

Ruas kanan persamaan (6) menjadi :

Fungsi P(θ) dapat diubah menjadi P(x) dengan cara :

Sehingga :
atau

Suku pertama persamaan di atas diuraikan sehingga persamaan menjadi :

Untuk kasus simetri sumbu maka m=0 sehingga :

Solusi persamaan Legendre di atas berupa polynomial Legendre : sehingga solusi umum untuk persamaan Laplace dalam tata koordinat bola untuk kasus simetri sumbu adalah :
(9)
3) Menentukan

Ruas kanan persamaan (6 ) juga berharga m2, sehingga :
m = 0,1,2,…

Namun karena kasus ini diasumsikan simetri sumbu maka potensial hanya fungsi r dan θ seperti dinyatakan dalam persamaan (9).

Penerapan syarat batas :
Di dalam bola :
(10)

Di luar bola
rgen.

B

ρE.ρ=∇

E = medan listrik
ρ
ε0

Gambar 2. Muatan seragam

Medan listrik adalah adalah gaya listrik persatuan muatan. Medan vector dari potensial listrik. Potensial listrik adalah kemampuan untuk melakukan kerja yang ditimbulkan
engecil. VE−∇=
nsubstitukan
02Vερ−=∇= (14)

222V1Vsin1Vr1Vρ−=∂+⎟⎞⎜⎛∂θ∂+⎟⎞⎜⎛∂∂=∇

Perhitungan potensial listrik diasumsikan bahwa :
1. Muatan listrik hanya bervariasi dalam arah r, sedangkan pada arah θ dan Ф dianggap konstan.
2. Hanya dibatasi pada

Potensial listrik di luar bola ( r ≥ R )
Untuk daerah yang tidak dipengaruhi muatan listrik atau potensial listrik nol maka persamaan Laplace lah yang dipakai.
Jika

Persamaan (6a) dengan memakai asumsi 2 akan berbentuk :

Untuk menentukan solusi homogen :
Cara 1 :

Gambar 3. Persamaan Euler-Cauchy

Kalikan dengan r2 supaya berbentuk persamaan Euler-Cauchy :

a=2, b=0

Persamaan karakteristiknya :

Cara 2 : jika diamsusikan dan dengan m dan madalah akar-akar persamaan. Maka : 12

Sehingga ,
Maka potensial listrik V :

Potensial listrik nol dapat terletak sebarang di luar bola, sehingga pemilihan letak yang tak hingga bisa menjadi acuan. Harga c1 =0. Potensial listrik untuk bola bermuatan seragam di bernilai seperti potensial listrik untuk muatan titik, yaitu :

Gambar 4. Potensial listrik akibat muatan titik

Jika,

dan
Rumus Rodríguez
maka :
Untuk

Sehingga :

Atau dengan membalik batas atas menjadi batas bawah dan sebaliknya, menjadi :

Untuk

Sehingga :

Atau dengan membalik batas atas menjadi batas bawah dan sebaliknya, menjadi :

Untuk

dihitung melalui persamaan (11) :
adalah potensial listrik di luar bola
Potensial listrik di dalam bola

Karena V hanya bergantung terhadap r dan independent terhadap variabel θ dan Φ, maka persamaan Poisson di atas dapat diubah ke bentuk persamaan diferensial biasa orde 2 menjadi :

Solusi khusus diperoleh dengan cara :
$latex

$Solusi umumnya : V= VH+Vp
Untuk di dalam bola VH yang memenuhi syarat adalah c1 sehingga :

Syarat batas pada permukaan bola :
r = R ,

Q= muatan total , maka :

adalah potensial listrik di dalam bola bermuatan seragam

Build a heavy-weight satellite needs high cost either in construction or launch budget. A micro satellite, with a weight less than 100 kg is a solution for multidiscipline engineers to launch a low budget satellite.

Twenty-two Masters of Engineering students at the Electronic Systems Laboratory in the Department of Electrical and Electronic Engineering at Stellenbosch University then built and test SunSAT (Stellenbosch University Satellite) which launched on the 23rd February 1999 on a DELTA 7926 launcher into sun-synchronous orbit. The spacecraft was launched with ARGOS and ØRSTED. It is,
Mission specification
• Inclination : 97°
• Altitude : 450 – 860 km
• Size : 45 x 45 x 60 cm
• Mass : 64 kg
• Average power : 30 W
• Launcher : Delta II rocket, Mission P-91
• Program size : US $5M (the spacecraft is reported to cost $US2.5m, with a value of US$2.5m for the launch)
• Lifetime : 4-5 years (NiCad Battery pack life)
• Main payloads:
o Amateur radio communications
o Data interchange
o Stereo multispectral imager
• Altitude control : Gravity gradient and magnetorque, reaction wheels when imaging
• Accuracy : 3 mrad pitch/roll, 6 mrad yaw
• Ground pixel size : 15 m x 15 m
• Image width : 51.8 km

Figure 1 : SUNSAT 1 in its Operational Configuration

Figure 2: Instrumentation on zenith pointing face of SUNSAT

Figure 3: SUNSAT General Structural Configuration (Exploded View)
Sunsat payloads :
1. Imager payload
Function : to maximise the imaging ( high-resolution imagery ) capability, which can be achieved by implementing both small pixel spacing, and many pixels. CCD TV sensors were limited to below 1000 pixels, but linear CCD sensors with up to 5000 pixels were available.
At wavelengths longer than visible light, (near-IR), photons penetrate deeply into Silicon sensors, and generate photo-electrons that can diffuse to adjacent photo-sites. The MTF (Modulation Transfer Function ~ resolution) of sensors with fine pixels thus drops significantly at longer (NIR) wavelengths.
To obtain good Chlorophyl-band imagery, a TC104 3456 pixel linear CCD Silicon sensor with 10.7micron spacing was chosen rather than a sensor with a larger number of smaller pixels.
The merit of Sunsat imager payload :
SUNSAT’s small pixel produces only 20% of the CCD’s saturated signal level for a 30% reflective object and normal solar incidence
Components :
 optical tube assembly, containing a 45 degree mirror, lens system, pentaprism with dichroic colour splitter, three vertically mounted Texas Instruments TC104 linear CCD sensors and their clock drivers and output buffers.
 diameter : 12 cm
 Position : in the bottom tray of the satellite, mounted diagonally across the bottom of the satellite on bearings, and can be rotated by a stepper motor as shown in Figure 3.

Figure4: SUNSAT optical tube and rotating mirror

Table 1 : Imager Specification Summary
Work principle
 Stereo ( hard ) images are taken with the optical tube horizontal and normal to the velocity vector (forward or backwards pitching of up to 24º to obtain various stereo base/height ratios).
 Images to the left or right of the ground track can be taken by placing the optical tube parallel to the velocity vector. A 64 MByte RAM enables an image to be stored for subsequent downlinking.
 The spectral band selection is identical to that of TM of the Landsat missions (LS-2, -3, and -4).
 A ground pointing accuracy of the imagery : 1 km

2. Communications payload

The realisation and laboratory tests of VHF and UHF amateur radio compatible communications modules are described, as well as the operation of an S band down link transmitter for image data and an L-band up link for rapid file transfers.
The communications payloads comprise high speed data links and as well as Amateur Radio transmitters and receivers in the 145 and 435 MHz amateur radio bands.
SUNSAT’s communications provide for :
 Amateur radio communications (VHF, UHF, L, S bands)
L-band :
Can uplinking of data at 2 Mbit/s, and can be coupled to the image data transmitter for data gateway experiments. This means that large data files can be exchanged among remote locations on earth which are not well served by other Amateur communications systems.
 data downlinking (VHF, UHF, SBand)
S-band :
 power 5W
 downlink will convey image data at up to 60 Mbit/s to the 4.5 m diameter dish antenna at Stellenbosch and possibly at other locations.
 data collection (VHF, UHF)
 command and control
Figure 5 : UHF Communications System Block Diagram

3. Sun sensor

 to obtain mainly yaw attitude information within a ± 60° range to an accuracy of below 0.1°
 A fine slit sun sensor of similar CCD technology

Figure 6: Sun sensor device

Figure 7 Fine Sun Sensor (Schmidtbauer, el al., 1973)

4. Horizon sensor

 To obtain mainly pitch and roll attitude angles within a ± 15° range to an accuracy of 0.02°
 A 2-Axis horizon sensor utilizing a two linear CCD array and lens assemblies
 These sensors, based on a design by one of the SUNSAT team members, are currently flown on UoSAT-5

Figure 8: Horizon sensor device

5. Magnetometer

 To measure the strength and direction of the geomagnetic field vector. This information is used to calculate the magnetic torques and to obtain full attitude information by comparing the measurements to geomagnetic field model data
 Provided by the Hermanus Magnetic Observatory (South Af-rica).
 A 3-Axis flux gate magnetometer
 Provides a complementary measurement of the magnetic field to the Ørsted geo-magnetic satellite.
 Collocated with a star camera on the tip of SUNSAT’s gravity gradient boom to provide the magnetic field vector.

Figure 9 Dual-Core Fluxgate Magnetometers Wilh Primary and Secondary Induclion C
(Adapled From Geyger [1964].)

Calibration
A three-axis magnetometer can measure the geomagnetic field strength and direction to high accuracy if it is well calibrated and free from magnetic disturbances. If the magnetometer is used in magnetorquing control applications only, a crude sensor will suffice. In contrast, when doing attitude determination to accuracies better than 0.5° per axis an accurate sensor will be required. A new RLS (Recursive Least Squares) algorithm for in-flight magnetometer .
A first order calibration model (with Bcalib the calibrated measurement and Bmeas the raw measurement) is used:
Bcalib k G k Bmeas k bk

G = scale factor/misalignment matrix
b = bias vector
If the calibrated vector is recursively compared to the modelled geomagnetic field vector (from IGRF model) to obtain the error to be minimized by a least squares method:

ekymodel k ycalib kAkBo kGkBmeas kbk

Figure 10 : Bias value convergence for a RLS calibrated magnetometer

6. Star sensor

The prime objective of the star sensor is to update the attitude of the satellite at one second intervals.
A star sensor where a 10×10 image is projected onto a 752×582 interline transfer CCD. The dynamic range of the star sensor is limited to the range Mv 2.5 and Mv 6.5 to measure the angular position of a star to an accuracy of at least 12 arcsec. A minimum of 3 separated stars must be detectable within the sensor’s field of view to employ a full attitude determination algorithm using a star catalogue.

Work principle
1. On SUNSAT the star sensor will be used in the period prior to earth imaging and during earth
imaging.
2. The angular rate of the satellite should be very low during this time and the camera will be pointed nominally in the orbit normal direction. Since the same stars will remain within the FOV for a long time it is not necessary to search for a new matching constellation during each iteration.
3. An initial attitude estimate can be obtained from the ADCS or the matching algorithm to locate the FOV on the celestial sphere. The catalogue stars within this FOV can then be transformed back to the CCD plane to become the reference stars. An area surrounding the centroid of each reference star (expected star) is then searched to find the matching observed star.

Figure 11 : Block diagram of the star sensor hardware

 The Transputer microprocessor control the CCD imager by setting the integration time and enabling the readout of CCD frames to memory.
 The Flash RAM is used to store the software algorithms and the star catalogue or sub catalogue information.
 A 6-bit Flash A/D convertor is used to digitize the CCD pixels in 64 quantization levels. These digital values are then stored sequentially into the image static RAM. The processed star vectors is normally supplied to the ADCS microprocessor (Transputer) via a serial link.
 For backup purposes the CCD imager and the image memory can also be alternatively controlled and read, using a general satellite memory bus. This bus can be used by three different on-board processors.

Table 2 Performance parameters of the SUNSAT star sensor

Figure 12 : Star tracking (white stars = selected reference, black stars = observed)

A few coordinate systems are used by the imaging software. Transformation matrices are used to transform star positions and vectors between the various coordinate sets. From these pairs of matching vectors the satellite’s attitude can be determined – the rotations (roll, pitch and yaw) from body to orbit coordinates.
The satellite will only do small pitch librations caused by gravity gradient and aerodynamic induced torques for the slightly elliptical orbit, when not actively controlled. These pitch rotations will be more difficult to measure accurately by the star sensor, compared to roll and yaw rotations, due to the smaller shift in star centroids on the CCD plane for equal rotational angles. The star separation distance determines the amount of shift on the CCD plane for pitch rotations, whereas the focal length determines the shift for roll and yaw rotations. For the SUNSAT star sensor the focal length to star separation distance ratio is at best 25 mm to 6.1 mm (FOV diagonal), but will at least be twice as worse under normal imaging conditions (assuming a 3 mm star distance for the furthest two stars).

Satellite state determination

Figure 13 : satellite determination using EKF

Two extended Kalman filters (EKF) to determine the full satellite state from vector information will be utilized on SUNSAT. The first EKF will make use of magnetometer measurements and an IGRF geomagnetic field model to supply the vector pairs needed for determination of the satellite’s attitude to an angular accuracy of below 1. The second EKF will use measurements from the higher accuracy sensors (CCD type horizon, sun and star sensors) and orbital models plus star catalogues to determine the attitude to below 0.1. The discrete full state vector to be estimated, is defined as:

= inertially referenced body angular rate vector
I = inertially referenced body angular rate vector
q = attitude quaternion vector
ndoy (k) = disturbance torque maximum magnitude caused by aerodynamic pressure variations
The innovations used in the EKF are the vector difference between the measured (observed) vectors in body coordinates and the orbit modelled (reference) vectors transformed to the body coordinates by the estimated attitude transformation matrix:

ekvobskAobq$ kvref k

Figure 14. EKF estimation results with 3 matching star pairs

Simulation studies have shown that the SUNSAT magnetometer based EKF has an improved convergence and stability performance compared to the Psiaki et.al. method.

Figure 15 Typical pointing angle estimation of the Horizon/Sun EKF

Figure 15 presents typical results from the Horizon/Sun sensor EKF when measurement data is only available for short periods of time (when a valid sunlid horizon or sun within the field of view is detected). Convergence is achieved within one orbit and accurate attitude tracking (< 0.1) is established during periods when data from all the sensors becomes available simultaneously.

Attitude Control System Principles
Add or modify feedback loops for rate and altitude data, define gains and constants, and fine tune the equations of motion. To do so, a good mathematical simulations of the entire system is required, including internal and external disturbances. Usually, linear differential equations with constant coefficients describe the dynamics of a control system.

Figure 16 Diagram of a Typical Attitude Control System

References :

1. Schoonwinkel, G.W. Milne, S. Mostert , W.H. Steyn and K. van der Westhuizen. Pre-flight performance of sunsat, south africa’s first remote sensing and packet communications microsatellite
2. W.H. Steyn, M.J. Jacobs and P.J. Oosthuizen. A high performance star sensor system for full attitude determination on a microsatellite.
3. http://www.1999.htm
4. Steyn, Herman, Dr. Attitude Determination and Control System for SUNSAT. SSS_96.pdf.
5. W.J. Larson and J.R. Wertz (eds.), Space Mission Analysis and Design(“SMAD”) (3rd edition), Space Technology Series, Microcosm Inc. and Kluwer Academic Publishers, 1999
6. Garth W. Milne, A. Schoonwinkel, J.J. du Plessis, S. Mostert, W.H. Steyn*, K vd Westhuizen, D.A. vd Merwe, H. Grobler, J.A. Koekemoer, N. Steenkamp. SUNSAT – Launch and First Six Month's Orbital Performance.

Fluxgate magnetometer. Length of the coil arou...

Fluxgate magnetometer

If you are an aerospace engineer than you should understand spacecraft sensors principle work and how to integrate them into a payload. Sensors are significant in contributing data about spacecraft orientation and attitude. One of sensors we’ll described here is a magnetometer. It is function as vector sensors, providing both the direction and magnitude of the magnetic field.
Vector magnetometer systems consist of three mutually orthogonal, single-axis fluxgate magnetometers. The system can be packaged as a single unit mounted within the spacecraft or attached to a boom.

Generalized Magnetometer Block Diagram

As depicted in the scheme above, magnetometers consist of 2 parts : a magnetic sensor and an electronics unit that transform the sensor measurement into a usable format. Magnetic sensors are divided into 2 categories :
1. Quantum magnetometers,: utilize fundamental atomic properties such as Zeeman splitting or nuclear magnetic resonance
2. Induction magagnetometers : based on Faraday’s Law of magnetic Inductance.

One type of iInduction magagnetometers is search- coil magnetometers , which are often applied on spin stabilized spacecraft.
Function : to provide precise phase information.
Weakness : any spacecraft precession or nutation will affect data interpretation because of search-coil is sensitive to the variation of magnetic components along the magnetic field axis.
The basic measurement provided voltage, V which is defined by :

a = magnetometer scale factor
V0=magnetometer bias
=the net local magnetic intensity in body coordinates

Reference :
Wertz, James R. Spacecraft Attitude Determination & Control. Kluwer Academic Publishers. 1978.

Using Orbiter software you can play any scenario to simulate some spacecraft. This software is free downloadable. I used it to simulate LDEF deployment.
Gravity gradient stabilization is a kind of spacecraft stabilization method. It is a passive stabilization which means it doesn’t need any commands. It’s working is based on a net torque resulting from a mass difference of dumbbells. Below are gravity gradient stabilization characteristics :
Advantages :
1. Maintains stable orientation relative to central body
2. Not subject to decay or drift due to environmental torques unless environment changes
Disadvantages :
1. Limited 1 or 2 possible orientations
2. Effective only near massive central body
3. Requires long booms or elongated mass distribution
4. Displays librational motion
In the early 1960’s, gravity gradient was heralded as “ free” stabilization : no sensors, no power, no logic, and no actuators. Off course, it is not really free. It requires long booms, tip masses, and damping devices. And it doesn’t work particularly well. Most modern spacecraft require pointing accuracies that are orders of magnitude better than can be derived from purely passive gravity stabilization, the weight budget for gravity gradient equipment is better spent on sophisticated attitude sensors, microprocessors, and devices for managing internally stored angular momentum.
Since gravity gradients in low orbits around various bodies vary with μ/r3, the gradients are independent of the size of the body, and linearly dependent on its density. Therefore the gradients are highest around the inner planets and Earth’s moon, and 60-80% lower around the outer planets.
Gravitational torques are quite weak, and satellites to be stabilized by the gravity gradient field must be carefully designed to resist enyi.ronmental disturbances. All of the disturbing torques can be present to some degree, each causing unwanted librations. Librational consequences of aerodynamic torque occur at low altitudes, while at high altitudes solar radiation pressure becomes dominant. Even meteoroidal disturbances can occasionally produce ~ 0.5° attitude deviations.
Within this research, The U.S. Long Duration Exposure Facility (LDEF) is chosen to be simulated because it is three-axis stabilized gravitationally. Deployed in orbit on April 7, 1984 by Shuttle Challenger and intended for retrieval after one year, the LDEF satellite was stayed in orbit for six years after the Challenger accident On orbit, the Shuttle’s Remote Manipulator Arm lifted the LDEF from the cargo bay and placed it in the proper attitude for release and flight.

The crew of STS-32 recovered the LDEF from its decaying orbit on January 11, 1990, two months before it would have re-entered the Earth’s atmosphere and would have been destroyed. Table 1 below lists the LDEF mission statistics :
Table 1. Mission statistics
Mission: LDEF
Shuttle:
Challenger and Columbia

Launch pad: 39-A
Launch: April 6, 1984, 8:58:00 a.m. EST STS-41-C

Mass: 2500 kg
Size: 24 m
PMI: 12,12,3
XPDR: 131.50 Mhz
Deployment: April 7, 1984

Retrieval: January 12, 1990, 10:16 a.m. EST

Landing: January 20, 1990, 1:35:37 a.m. PST, Edwards Air Force Base, STS-32

Deployed duration: 2076 days (5 years, 8 months, 1 week)
Orbit altitude: 313 to 179 nautical miles (580 to 332 km)

Orbit inclination: 28.5 degrees
Distance traveled: 741,928,999 nautical miles (1,374,052,506 km)

Damping on LDEF is provided by a single viscous-fluid-filled, spherical magnetically anchored damper of the type shown in Fig.2. Located near the vehicle centroid, this damper is 20 cm in diameter and has a mass of 7 kg.
2. Methods
The simulation used Orbiter 2006 which includes gravity gradient torque and non-spherical gravitational sources as perturbations :

(1)
(2)

Linier and angular state propagations are simulated using 8th order Runge-Kutta, which is defined as :
(3)
Where is an increment function :
(4)
Another numerical integration method is 8th symplectic integrators for Hamiltonian systems which have the property of preserving the total energy of the problem.

3. Results and analysis

Hence the angle of attack is defined as the angle between the longitudinal axis of the satellite and the velocity vector,
(5)
Figure 3 indicates a slope with magnitude 0.1417 which is larger than figure 4. Thus symplectic integrator 8th reflects better stability than Runge-Kutta 8th order.
While observations of the yaw angle at specific times were made and are tabulated in this paper. These values range from 4.3 to 12.4 deg with maximum uncertainty of plus or minus 2.0 deg and an average of 7.9 deg. No specific measurements of pitch or roll were made but the data indicates that LDEF had an average pitch down attitude of less than 0.7 deg.

4. Conclusion
Although The LDEF simulation using orbiter doesn’t represent result as expected in a gravity gradient satellite attitude, its small increment in angle of attack can be regarded as an approach to a stable pitch angle. For most applicatons, gravity gradient stabilization is inadequate. Nevertheless, for certain special situations, particularly in near-Earth orbits, it can profitably be used when accurate pointing isn’t required.

References
[1] Boas, Mary L. (1983), Mathematical Methods in The Physical Sciences, . Singapore: John Wiley & Sons,Inc., 225.
[2] Chapra, S.C, Canale,R.P. (1991), Metode Numerik untuk Teknik, Jakarta: UI Press, 617.
[3] Cornelisse,J.W, Schoyer,H.F.R,Wakker,K.F. (1979), Rocket Propulsion and Spaceflight Dynamicss, Northern Ireland: Pitman, 250.
[4] Hughes,P.C. (1986), Spacecraft Attitude Dynamics, New York: John Wiley & Sons,Inc., 334-335.
[5] Wertz, J.R. (1978), Spacecraft Attitude Determination and Control, Netherlands: Kluwer Academic Publishers, 19.