[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference rusure::math

Title:Mathematics at DEC
Moderator:RUSURE::EDP
Created:Mon Feb 03 1986
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:2083
Total number of notes:14613

1525.0. "MATHEMATICAL EXPERTISE NEEDED (HELP!) " by SALEM::ARSENAULT () Sat Nov 23 1991 16:17

I NEED HELP IN SOLVING THE FOLLOWING FOR 'F'.  ANY ASSISTANCE WOULD BE 
APPRECIATED.

 	1/SQRTF = 2LOG10(XSQRTF)-0.8

         F = ??????????

THANKS...

MARC
T.RTitleUserPersonal
Name
DateLines
1525.1What's XSQRTF?ELIS::GARSONV+F = E+2Mon Nov 25 1991 04:560
1525.2SALEM::ARSENAULTMon Nov 25 1991 09:309
(XSQRTF)

X is a variable

SQRT F is the square root of F

X * SQRTF    multiply X by SQRTF

Marc
1525.3Can't be done?HERON::BLOMBERGTrapped inside the universeMon Nov 25 1991 13:297
    
    I don't think there is any explicit solution expressed with a
    finite number of elementary functions.
    
    If you write y=1/sqrt(f) you get
    
    y + 2*log(y) = 2*log(x) - 0.8 and I don't see how to solve that. 
1525.4Sort of.CADSYS::COOPERTopher CooperMon Nov 25 1991 15:2113
    Maple provides a partial solution to the equation in .3:

                      W(1/2 ln(10) exp(ln(x) - 2/5 ln(10)))
		y = 2 -------------------------------------
				   ln(10)

    W is a special function designed for solving problems like this which
    is defined to be "the function satisfying  W(x) * exp(W(x)) = x".

    Fast numerical routines can be designed for finding the value of W for
    various arguments (which are used by Maple).

					Topher
1525.5One for Newton-Raphson!BRSTR2::SYSMANDirk Van de moortelTue Nov 26 1991 07:1354
Re .0

What happened to good old Newton-Raphson and BASIC?
Here is a small VAX-BASIC program that gives you an 'f' for every 'x' you
want (not smaller than 1!)
It converges very quickly (at most 7 iterations)
Try it... if you don't have a BASIC compiler at hand, I'll copy the object
and/or executable to your account...

PROGRAM SOLVE
!======================================================================
!       Newton-Raphson:
!
!                          f(y)
!               y   = y  - -----
!                n+1   n   f'(y)
!
!       where   y  = 1/sqrt(f)
!             f(y) = y + 2*log10(y) - 2*log10(x) + 0.8 
!
!       when y  and y    come together, you have a solution for the
!             n      n+1
!
!       equation f(y) = 0, which is what you're looking for.
!
!======================================================================

	option type = real, size = real double

	ln10 = log(10)

	input "x [quit=0]"; x
	while x >= 1
		lx2	= 2 * log10(x)		! remember this
		y	= 1			! start value
		diff	= 100			! start difference
		iter	= 0			! iteration number
		print ,"Iter","Diff"
		print ,"----","----"
		while (diff > .0000001) and (iter < 1000)
			y_next = y - ( y+2*log10(y)-lx2+0.8 ) / &
					( 1 + 2/(y*ln10) )
			diff = abs(y_next-y)
			y = y_next
			iter = iter + 1
			print ,iter,diff
		next				
		f = 1/(y*y)			! that's it
		print "Result: f =",f,bel
		check = 1/sqrt(f) - 2*log10(x*sqrt(f)) + 0.8
		print "Check: Left term - Right term ="; check
		input "x [quit=0]"; x
	next
END
1525.6SALEM::ARSENAULTWed Nov 27 1991 11:404
THANKS FOR YOUR HELP.  I LATER FOUND OUT THAT THERE IS NO WAY OF ISOLATING
'F'.  I DEVELOPED A FORTRAN ROUTINE THAT SOLVE IT.

MARC