Lee Mac Posted June 14, 2009 Share Posted June 14, 2009 It does not matter what the formula says, you can see that the code is setting a variable to something that involves dividing by zero - hence the error. Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 14, 2009 Author Share Posted June 14, 2009 It does not matter what the formula says, you can see that the code is setting a variable to something that involves dividing by zero - hence the error. Ok I added it to the error check, Now where is the bracket mix-up you had mentioned? Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted June 14, 2009 Share Posted June 14, 2009 Ok I added it to the error check, Now where is the bracket mix-up you had mentioned? I fixed it in that code I posted in post #52 Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 14, 2009 Author Share Posted June 14, 2009 I am speaking of formula 3 on the wheel which is multiplication.We are also filling in R in addition to this. So I guess this still needs to be in the error check even if the formula selected shows multiplication? I am getting this now:error: function undefined for argument Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted June 14, 2009 Share Posted June 14, 2009 I am getting this now:error: function undefined for argument I'm not sure what this is. The code i added was such a small snippet, there really isn't much that can go wrong. Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 14, 2009 Author Share Posted June 14, 2009 I'm not sure what this is. The code i added was such a small snippet, there really isn't much that can go wrong. Lee, Can you please test this copy for me. Just want to make sure we are both on the same channel. Thanks OLCv3.zip Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 15, 2009 Author Share Posted June 15, 2009 Lee, Can you please test this copy for me. Just want to make sure we are both on the same channel. Thanks I took the liberty of testing one of those free internet Ohm's Law Calculators. I enter one negative value and one positive value. In the results it replies NaN. When I do the same with my calculator I get this: ; error: function undefined for argument: -14400.0 after the program crashes. I am not sure if before putting in the latest changes that the program would have done the same thing. I am also not sure what the latest changes are supose to do. If I enter good values, The program works as it should, So I am a bit confused over this. The (setq c$plex i) I would assume is suppose to place an i after the value, But I have yet to see this happen. What am I doing wrong? or What is suppose to happen? Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted June 15, 2009 Share Posted June 15, 2009 Try this, a couple of ABS were missed. Ohm.zip Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 15, 2009 Author Share Posted June 15, 2009 Try this, a couple of ABS were missed. HOT DOG Lee! Thats the ticket! I will sleep good tonight! Thank You! Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 15, 2009 Author Share Posted June 15, 2009 HOT DOG Lee!Thats the ticket! I will sleep good tonight! Thank You! One more question Lee, What is the interpertation of the i or j if your an engineer mean? Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 15, 2009 Author Share Posted June 15, 2009 One more question Lee, What is the interpertation of the i or j if your an engineer mean? Ok Lee, I dug this up on Wikipedia. In electrical engineering and related fields, the imaginary unit is often written as to avoid confusion with electrical current as a function of time, traditionally denoted by i(t) or just i. The Python programming language also uses j to denote the imaginary unit, while in MATLAB, both notations i and j are associated with the imaginary unit. Some extra care needs to be taken in certain textbooks which define j = −i, in particular to travelling waves (e.g. a right travelling plane wave in the x direction ). Some texts use the Greek letter iota ( ι ) to write the imaginary unit to avoid confusion. For example: Biquaternion. After all that, I much rather not know. I will be making some more changes to the interface and some internal programming changes. I will repost to the first post when all has been completed. Again Thanks for your time, knowledge & patience. The Buzzard Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 15, 2009 Author Share Posted June 15, 2009 To All, Version 4 of the Ohm's Law Calculator is now available on the first post. Thank You Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted June 15, 2009 Share Posted June 15, 2009 I'm glad we got it sorted. One more thing I did notice (and changed in the posted version), is this line: (action_tile "sFN" ;When action_tile sFN is selected "(setq IMG $value) ;Set variable IMG ~ (Image) to list value (itoa 0) ;Return the conversion of an integer into a string (OLC_UFI)" ;Go to OLC_UFI Image Function ) What is the purpose of the (itoa 0)? Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 15, 2009 Author Share Posted June 15, 2009 I'm glad we got it sorted. One more thing I did notice (and changed in the posted version), is this line: (action_tile "sFN" ;When action_tile sFN is selected "(setq IMG $value) ;Set variable IMG ~ (Image) to list value (itoa 0) ;Return the conversion of an integer into a string (OLC_UFI)" ;Go to OLC_UFI Image Function ) What is the purpose of the (itoa 0)? Lee, That has remained the same. I may have made somevariable changes. (itoa 0) It returns the conversion of an integer into a string. It is the opposite of atoi. I am suprised you are asking me that? And yes thanks to your help this one got put to bed soon. I wished I could have gone to bed sooner. I did not think that this code was going to be a problem. I figured with the standard formulas that this one was cut & dry. Then comes the imaginary numbers. I must of been imaginning things. Was I wrong. Anyway you know as well as I the learning benefits of this stuff. You have get past the pain in order to gain. Thank again Lee Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted June 15, 2009 Share Posted June 15, 2009 (itoa 0) It returns the conversion of an integer into a string.It is the opposite of atoi. I am suprised you are asking me that? Of course I know what itoa does, but why do have you included it in your code. It is not doing anything. Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 15, 2009 Author Share Posted June 15, 2009 Of course I know what itoa does, but why do have you included it in your code. It is not doing anything. Its changing the image. Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted June 15, 2009 Share Posted June 15, 2009 You are setting a variable "IMG" to the value of the tile: (setq IMG $value) then invoking your program to change the image, based on the value of this variable. The (itoa 0) is not doing anything. Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 15, 2009 Author Share Posted June 15, 2009 You are setting a variable "IMG" to the value of the tile: (setq IMG $value) then invoking your program to change the image, based on the value of this variable. The (itoa 0) is not doing anything. Would you please explain? Quote Link to comment Share on other sites More sharing options...
CAB Posted June 15, 2009 Share Posted June 15, 2009 Not keeping up with all the thread talk but I updated My version 4 with changed to the DCL file and lisp. The functions have been Incorporated to keep variables local and some variables renamed. Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted June 15, 2009 Author Share Posted June 15, 2009 Would you please explain? Your right, I just tested it and it doing nothing. I will clean it up later. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.