
×InformationFix Windows 10 Update Issues
Resolve Windows 10 related issues for your HP computers or printers by HP Windows 10 Support Center

×InformationFix Windows 10 Update Issues
Resolve Windows 10 related issues for your HP computers or printers by HP Windows 10 Support Center
 HP Community
 >
 Other Products
 >
 Calculators
 >
 Normal Distribution Table
 Mark Topic as New
 Mark Topic as Read
 Float this Topic for Current User
 Bookmark
 Subscribe
 Mute
 Printer Friendly Page
Create an account on the HP Community to personalize your profile and ask a question
Solved!
Normal Distribution Table
01282017 05:44 PM  edited 01282017 05:54 PM
Is it possible create a program that takes as input a 10X3 matrix where each row is an observation and each column represents one of the three arguments (mean distribution (m)=column 1, standard deviation(s)=column 2 and a parameter (x)=column 3) for the builtin function NDIST?
The NDIST function has this form NDIST(m,s,x)
NDIST is equivalent to ( exp(xm)^2/(2*s))/(sqrt(2*pi*s)
The program that I created takes 3 arguments from the stack to produce the equivalent normal probability distribution single value, but I am interesed in getting 10 normal probability distributions simultaneously from a 10X3 matrix or the equivalent 3 10X1 vectors.
'normD' << > m s x << 'EXP((xm)^2/(2*s))/sqroot(2*pi *s)' >NUM >>
Example for NDIST(10,2,3) the probability is 1.3498*106
Any help would is very much appreciated.
Thanks
Reynel
Solved! Go to Solution.
01292017 04:35 AM
Hello Reynel,
why not, what is the problem?
The hp 50g has a lot of matrix functions and you have access to every element of a matrix.
The primer question is, from where your values of the matrix come from, randomigly generated or manually typed in a matrix?
The further question is, why you don't use NDIST and wrote an own proggie which does the same?
Sincerely
calcpeace
01292017 11:45 AM
Hi!, @REYNEL:
You can see, this video with many examples, created as Library, for Statistical. The unique problem is what is created in Spanish Language ... https://youtu.be/NZnL_UzBWJE
Now, you can download from ... https://sites.google.com/site/cesarv1821/statdes. Press, in ... Statdes V3.01
The Library, is ... STATDES+V301.zip
Have a nice day !.
@Maké (Technical Advisor Premium  HP Program Top Contributor).
Provost in HP Spanish Public Forum ... https://h30467.www3.hp.com/
01292017 06:05 PM
Hi Calcpeace,
Thank you very much for your suggestions! I followed your hints and I came up with a short prog by using the first 3 rows of the example matrix in my first post. I am really very newbi in UserRPL programming, most of the very little I know of HP 50g programming has been the result of valuable help given by the HP forum community in previous posting that I have submitted. I am really very thankful to all of you.
This is what I did.
step 1: I created a 3x3 matrix [[10 2 3][13 2 4][11 2 5]]
This is an arbitrary matrix (manually generated)
setp 2: I created a short program based on your suggestions.
( >ROW DROP OBJ >« NDIST » EVAL SWAP OBJ>DROP « NDIST » EVAL ROT OBJ> DROP « NDIST » EVAL)
step 3: This is the final results
3.4813...E5
4.5282...E10
1.3438...E6.
So I was able to use a 3X3 matrix as the argument of the NDIST function. Things get complicated with a bigger matrix, because my program will grow longer by repeating the same sequence of commands if I have to add new rows to the matrix. That would result in an inefficient program. My guess is that I have to cycle through a loop that counts the number of rows in the matrix and it executes few lines of common codes in every row of the matrix. There my be other ways to deal with this problem, but I am stucked at this point.
Any hints about how to go from here, or are there other methods of solving this problem? Eventually the program should be able to get any matrix size as input.
Thank you very much for any help.
Reynel
01292017 06:11 PM
Thank very much professor Make, I don't have difficulties in listening & understanding Spanish. I was able to listen to the video and find it very interesting although it doesn't address directly my question. Further suggestions would be very much appreciated.
Reynel
01312017 09:20 AM
Hi Calcpeace,
Thank you very much for your suggestions! I followed your hints and I came up with a short prog by using the first 3 rows of the example matrix in my first post. I am really very newbi in UserRPL programming, most of the very little I know of HP 50g programming has been the result of valuable help given by the HP forum community in previous posting that I have submitted. I am really very thankful to all of you.
This is what I did.
step 1: I created a 3x3 matrix [[10 2 3][13 2 4][11 2 5]]
This is an arbitrary matrix (manually generated)
setp 2: I created a short program based on your suggestions.
( >ROW DROP OBJ >« NDIST » EVAL SWAP OBJ>DROP « NDIST » EVAL ROT OBJ> DROP « NDIST » EVAL)
step 3: This is the final results
3.4813...E5
4.5282...E10
1.3438...E6.
So I was able to use a 3X3 matrix as the argument of the NDIST function. Things get complicated with a bigger matrix, because my program will grow longer by repeating the same sequence of commands if I have to add new rows to the matrix. That would result in an inefficient program. My guess is that I have to cycle through a loop that counts the number of rows in the matrix and it executes few lines of common codes in every row of the matrix. There my be other ways to deal with this problem, but I am stucked at this point.
Any hints about how to go from here, or are there other methods of solving this problem? Eventually the program should be able to get any matrix size as input.
Thank you very much for any help.
Reynel
02032017 09:20 AM
Hi Mrk4files,
I appreciate very very much for this little marvel. Your program worked very well as intended. Now I can use it in many different situations. You really found for me the missing part. I can't thank you enough!
Kind regards,
Reynel
Didn't find what you were looking for? Ask the community