Tampilkan postingan dengan label trigonometry. Tampilkan semua postingan
Tampilkan postingan dengan label trigonometry. Tampilkan semua postingan

Swiss Micros DM42: Time Dilation

Swiss Micros DM42:  Time Dilation 



Introduction


The program DILATE calculates the time passage from the traveler's perspective:


t' = t * √(1 - (v/c)^2)


where c = Speed of Light = 299,792,458 m/s


We can also state the equation as:


t' = t * cos(arcsin (v/c)) 


because cos(arcsin(x)) = √(1 - x^2) for |x| ≤ 1



Why cos(arcsin(x)) = √(1 - x^2)?


Let Θ = arcsin x.  Then x = sin Θ.  Assume that -1 ≤ x ≤ 1.


From the trigonometric identity:


cos^2 Θ + sin^2 Θ = 1

(cos Θ)^2 +  (sin Θ)^2 = 1


With sin Θ = x,


(cos Θ)^2 + x^2 = 1

(cos Θ)^2 = 1 -  x^2

cos Θ = √(1 - x^2)

cos(arcsin x) = √(1 - x^2)



Swiss Micros DM42 Program:  DILATE

Also:  Free42, Plus42


00 {52-Byte Prgm}

01  LBL "DILATE"

02  "TIME?"

03  PROMPT

04  "VEL (M/SEC)?"

05  PROMPT

06  299792458

07  ÷

08  ASIN

09  COS

10  ×

11 "T'= "

12  ARCL ST X

13  AVIEW

14  RTN

15  END



Example


A spaceship traveling at a velocity of 186,000,000 m/s (about 416,070,150 mph) for 1 year from our perspective.


XEQ DILATE

TIME?  1

VEL (M/SEC)? 186000000

 

Result:  0.78426 year would have passed on the spaceship, which is about 9 months and almost 13 days


Until next time,


Eddie 


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 


TI-58/TI-59 Week: Law of Cosines

TI-58/TI-59 Week:  Law of Cosines


Introduction


[ A ]:  stores either the angle θ or a 

[ B ]:  stores the length of side b

[ C ]:  stores the length of side c


[ D ]:  calculates the length of side a:

a^2 = b^2 + c^2 - 2 * b * c * cos θ


[ E ]:  calculates the angle θ

cos θ = (b^2 + c^2 - a^2) / (2 * b * c)


The angle θ is opposite slot of side a.


Program Listing


000 76 LBL

001 11 A

002 42 STO 

003 01 01

004 92 INV SBR (RTN)


005 76 LBL

006 12 B

007 42 STO

008 02 02

009 92 INV SBR


010 76 LBL

011 13 C

012 42 STO

013 03 03

014 92 INV SBR


015 76 LBL

016 14 D

017 43 RCL

018 02 02

019 33 x^2

020 85 +

021 43 RCL

022 03 03

023 33 x^2

024 75 -

025 02 2

026 65 ×

027 43 RCL

028 02 02

029 65 ×

030 43 RCL

031 03 03

032 65 ×

033 43 RCL

034 01 01

035 39 cos

036 95 =

037 34 √

038 42 STO 

039 04 04

040 INV SBR


041 76 LBL

042 15 E

043 53 (

044 43 RCL

045 02 02

046 33 x^2

047 85 +

048 43 RCL

049 03 03

050 33 x^2

051 75 -

052 43 RCL 

053 01 01

054 33 x^2

055 54 )

056 55 ÷

057 53 (

058 02 2

059 65 ×

060 43 RCL

061 02 02

062 65 ×

063 43 RCL

064 03 03

065 54 )

066 95 =

067 02 INV

068 39 cos  (arccos)

069 42 STO 

070 04 04

071 92 INV SBR


Examples


Calculating a:


Set the TI-58/TI-59 to Degrees mode:


Input:


50° [ A ]

45  [ B ]  (b)

35 [ C ] (c)

[ D ] returns a:  35.00312885


85° [ A ]

100  [ B ]  (b)

70 [ C ] (c)

[ D ] returns a:  116.9607609


Calculating θ:


52 [ A ]  (a)

38 [ B ] (b)

49 [ C ] (c)

[ E ] returns θ:  72.15813198


80 [ A ]  (a)

60 [ B ] (b)

65 [ C ] (c)

[ E ] returns θ:  79.47338145


Note:  The next post will be on July 23, 2022.


Eddie


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 


Retro Review: Hewlett Packard HP 45

Retro Review:   Hewlett Packard HP 45





Quick Facts:


Model:  HP 45

Company:  Hewlett Packard

Years:  1973-1976

Type:  Scientific

Batteries: (original) HP Battery Pack 82001A (rechargeable), compatible batteries can be found on eBay, AC Adapter 82002A

Operating Mode:  RPN

Memory Registers: 9 (R1 - R9), some are used in statistics

Undocumented (by the manual) Feature:  Stopwatch

Original Price:  $395.00 (US) 

Package Includes AC Adapter, User Manual, Pocket Guide, Carrying Case 


Features - History


The HP 45 is the second scientific calculator by Hewlett Packard, first brought to the market in 1973; after the legendary HP 35 was released in 1972.  The HP 45 is the second Hewlett Packard calculator to feature a shift key, after HP's first financial calculator, the HP 80.  


The HP 45 operates on Reverse Polar Notation (RPN).   Here is a Wikipedia page on RPN:  https://en.wikipedia.org/wiki/Reverse_Polish_notation


The HP 45 added more functions to the HP 35, which features include:


* trigonometric functions and inverses

* logarithms and antilogs

* powers and roots

* fixed and scientific 

* factorial of integers

* polar/rectangular conversions

* degrees/degree-minute-second conversions (DD.MMSSSS)

* percent and percent change

*  three angle modes: degree, radians, grads 

* Last x

* three unit conversions

* statistics

* storage and recall arithmetic


When the HP 45 is powered on, the calculator will be in FIX 2 mode.  


Factorial of Integers:   The function n! allows only integers from 0 to 69.  It will be later HP calculators to extend the factorial function to the real numbers.


Polar and Rectangular Conversions:  The conversions involve the X and Y stack.  In polar form, X represents r and Y represents θ.


Conversions:  The HP 45 provides conversion factors for unit conversions. Examples provided in FIX 2 mode. 


[ shift ] [ 7 ]: cm/in.   1 in = 2.54 cm.    


18 in to cm:  18 [ shift ] [ 7 ] [ × ] returns 45.72 cm

50 cm to in:  50 [ shift ] [ 7 ] [ ÷ ] returns 19.69 ft


[ shift ] [ 8 ]:  kg/lb.   1 lb ≈ .4536 kg


200 lb to kg:  200 [ shift ] [ 8 ] [ × ] returns 90.72 kg 

66.5 kg to lb:  66.5 [ shift ] [ 8 ] [ ÷ ] returns 146.61 lb


[ shift ] [ 9 ]: ltr/gal.  1 gal ≈ 3.7854 ltr


150 gal to ltr:  150 [ shift ] [ 9 ] [ × ] returns 567.81ltr

690 ltr to gal:  690 [ shift ] [ 9 ] [ ÷ ] returns 182.28 gal


Percent:  The [ % ] key returns x% of y, while leaving the value in the Y stack.  This could be followed up with [ + ] or [ - ] for percent adding and subtracting calculations.  


Add 6% to 150.

150 [ ENTER ] 6 [ % ] [ + ] returns 159.00


Percent Change:  The [ shift ] [ % ] (∆%) calculates percent change:  (y - x)/y * 100 with the value of the Y stack remains. y is old, x is new.


What is the percent change from 35 to 45?

35 [ ENTER ] 45 [ shift ] [ % ] returns 28.57 (%)


The HP 45 has storage and recall arithmetic for the four arithmetic functions (+, -, ×, ÷).  I love storage arithmetic and any time we get recall arithmetic, it's a huge bonus. 


The keyboard feels good and the keys feel responsive.  


Statistics


The HP 45 has one-variable statistics, which some sums for y-data.


R5 = n

R6 = Σx^2

R7 = Σx

R8 = Σy

RCL Σ+ returns Σx to the X stack and Σy to the Y stack

[ shift ] [ R↓ ] returns x-bar to the X stack and sx to the Y stack


Stopwatch


A famous and undocumented feature of the HP 45 is a stopwatch.  The stopwatch is accessed by the sequence [ RCL ] then pressing [ 7 ], [ 8 ], and [ CHS ] keys at the same time.  Done right the display will be in the form:


hh.mm ss     'ss


Press [ CHS ] to start and stop the timer, and any number keys can be used to store the time for lap records.  The stored time will be stored as a decimal and the two two digit exponent will store the hundredths of seconds. 


Pressing [ CLx ] clears the time and [ ENTER ] returns us to the operator mode.  I understand that due to the lack of crystal, the timer is somewhat inaccurate.   


Closing Thoughts


I love this calculator!   It's good to have a calculator from the 1970s, especially from HP.  


Until next time,


Eddie


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 


Applications: Sharp EL-5150

Applications:  Sharp EL-5150 


Note:  spaces included for readability

Fan Laws

AER Equation:
1; f(BCDI) = B * ( C ÷ D ) Y^x ( 1 ÷ I  )

Variables:
Calculate CPM_new
B = CPM_old

1st Fan Law:
I = 1
C = RPM_new
D = RPM_old

2nd Fan Law:
I = 2
C = SP_new
D = SP_old

3rd Fan Law:
I = 3
C = BHP_new
D = BHP_old

Example 1:

Fan Law 2:
CPM_old = B = 4000 CPM
SP_new = C = 48 
SP_old = D = 36
I = 2

Result:  4618.802153

Example 2:

Fan Law 3:
CPM_old = B = 3500 CPM
BHP_new = C = 59
BHP_old = D = 52
I = 3

Result:  3650.488072


Ideal Shockley Diode Equation


I = I0 * e^((VD/(n* VT) - 1)
where VT = K * T/q

I = diode current (amps)
I0 = saturation current (amps)
VT = thermal voltage (V) - see notes below
VD = voltage across the diode (V)
n = ideality factor, in ideal situations, n = 1

Notes:  

*  The equation below assumes the ideal diode, n = 1
*  The equation uses a ratio of scientific constants:  k/q 
*  k = Boltzmann's Constant = 1.380649 * 10^-23 J/K
*  q = Charge of an Electron = 1.602176634 * 10^-19 C  (on some calculators, like the Casio fx-991EX, this constant is labeled e)
*  k/q = 8.617332385 * 10^-5 J/(K*C) = 8.617332385 * 10^-5 V/K  (volts/degrees Kelvin)

AER Equation:
1; f(IDE) = 8.617332385E-5 × E STO A, I ×(e(D ÷ A) - 1)

Calculate VT (stored in A), the I 
I = I0
D = VD
E = temperature in Kelvin

Example 1:

I = 4E-6 A 
D = 0.08 V
E = 280 K

Results:
A = 0.024128531, (I) 0.00001061
 
Example 2:

I = 4E-6 A 
D = 0.06 V
E = 300 K

Results:
A = 0.025852000, (I) 0.00003674

Dot and Cross Product of Two 3D Vectors

For the two vectors [A, B ,C] and [D, E, F]:

AER Equations:
1; f(ABCDEF) = A × D + B × E + C × F ◣
2; B × F - C × E, C × D - A × F, A × E - B × D

Example 1:
[ A, B, C ] and [ D, E, F]

[ 4.5, -2.5, -8 ] and [ 1.6, 3.9, 6 ]

Dot Product:  -50.55
Cross Product:  [ 16.2, -39.8, 21.55 ]

Example 2:
[ A, B, C ] and [ D, E, F]

[ 4, 3, 2 ] and [ 2, 7, 0 ]

Dot Product:  29
Cross Product:  [ -14, 4, 22 ]

Law of Cosines

Sides with lengths A, B, C with D as the angle opposite of A.  Equation 1 finds the length of side A, while Equation 2 finds the angle D.

AER Equations:
1; f(BCD) = √(B^2 + C^2 - 2 × B × C × COS D) STO A ◣
2; f(ABC) = cos^-1 ((B^2 + C^2 - A^2) ÷ (2 × B × C)) STO D

Example 1 - find A:
Degree Mode Set
Input:  B = 4.5, C = 3.7, D = 30°
Run 1:

Result:  2.258617731


Example 2 - find D:
Degree Mode Set
Input:  A = 40, B = 56, C = 38
Run 2:

Result:  45.5579132°


Note:  Due to the incredible amount of spam comments that get sent on this blog, which I moderate so the readers don't see them, I have decided to turn comments off.  I will review whether to turn comments back on at a later time.  My apologizes to those who leave legitimate comments.  

Eddie 


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 

Backlink 9999 Traffic Super

Order Now...!!!!