Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Scrungie
 
Posts: n/a
Default Change worksheet radian default


Is there an easy way to change the worksheet radian default to degrees
so that I donīt have to use the 180/PI or PI/180 or the degrees
function.

The following is a formula to derive the Log Haversine of the number
30,

Log((1-Cos(30*PI()/180)))/2)+10

and the following is to derive the number 30 from the Log Haversine,

(Acos(1-(10^((D18-10))*2))*180/PI())/24 D18 being the cell
with the log haversine.

Surely there is an easier way to get a log haversine than this. Any
help will be most appreciated.

Scrungie.


--
Scrungie
------------------------------------------------------------------------
Scrungie's Profile: http://www.excelforum.com/member.php...o&userid=16030
View this thread: http://www.excelforum.com/showthread...hreadid=466913

  #2   Report Post  
JE McGimpsey
 
Posts: n/a
Default

There's no way to change the default. However, you could use the
RADIANS() function:

=LOG((1-COS(RADIANS(30)))/2)+10

You could also use a UDF, which will be cleaner, though slower:

Public Function CosD(degrees As Double) As Double
Const dRad As Double = 0.0174532925199433
CosD = Cos(degrees * dRad)
End Function

call it as

=LOG((1-CosD(30))/2)+10

and of course, you could put it all in a UDF:

Public Function LogHaversine(degrees As Double) As Double
Const dRad As Double = 0.0174532925199433
LogHaversine = Log((1 - Cos(degrees * dRad)) / 2) / Log(10) + 10
End Function

if you're not familiar with UDFs see

http://www.mvps.org/dmcritchie/excel/getstarted.htm


In article ,
Scrungie
wrote:

Is there an easy way to change the worksheet radian default to degrees
so that I donīt have to use the 180/PI or PI/180 or the degrees
function.

The following is a formula to derive the Log Haversine of the number
30,

Log((1-Cos(30*PI()/180)))/2)+10

and the following is to derive the number 30 from the Log Haversine,

(Acos(1-(10^((D18-10))*2))*180/PI())/24 D18 being the cell
with the log haversine.

Surely there is an easier way to get a log haversine than this. Any
help will be most appreciated.

Scrungie.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to change the tab order for a protected worksheet dvonj Excel Worksheet Functions 2 March 18th 05 08:23 PM
how to change default comment format in excel (2000) superiorparties Excel Discussion (Misc queries) 1 February 3rd 05 12:43 AM
Change the default chart colours TonyJD Charts and Charting in Excel 2 January 20th 05 01:06 AM
Increase default size of worksheet Westontony New Users to Excel 9 December 16th 04 11:03 PM
Worksheet Row Change event crazybass2 Excel Discussion (Misc queries) 4 December 8th 04 05:29 PM


All times are GMT +1. The time now is 05:25 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright Đ2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"