Solved

Mathematics Problem ??

Posted on 1998-10-29
3
193 Views
Last Modified: 2010-04-30
How can I do this mathematics problem using VB ??

Let say 2 power of 3 is 8.
Q1) 2* = 8     ## where * equal 3

And now using the Q1, I want to find the * by given the other two values(2,8),
How to do this using VB??
0
Comment
Question by:abc1234
  • 3
3 Comments
 
LVL 18

Accepted Solution

by:
deighton earned 100 total points
ID: 1442260
Private Function Star(x As Double, y As Double) As Double

    Star = Log(y) / Log(x)

End Function


Private Sub Command1_Click()
   
    MsgBox Star(2, 8)
   

End Sub

0
 
LVL 18

Expert Comment

by:deighton
ID: 1442261
Oh yes another thing. How does this work?

 y
X  = Z

taking logs of both sides (any base 10 or natural it doesn't matter which, as long as U use the same for each)

y * log(X) = Log(Z)

y = Log(Z)/Log(X)

QED
0
 
LVL 18

Expert Comment

by:deighton
ID: 1442262
U posted this twice. If U want U'r points back send a question to Linda in the Customer Services dept.  She'll delete the duplicate and refund your points, if you ask nicely.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

816 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now