Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - intelx86

Pages: [1]
1
News / Re: Release of FormulaPro for the Nspire
« on: November 11, 2012, 01:23:39 pm »
Do you remember, in my first posts, where I suggested to control the orderand the visibility of the variables?

This could be implemented, by including an optional parameter for function addSubCat().
An array, U("var1", "var2", "var3"...) could be saved as well, indicating the order and the visibility of variables.
If you do not include a variable, ti won't be shown, but only used for calculations.

Optionally, a third button could be included to show "hidden" vars, if applicable.

2
News / Re: Release of FormulaPro for the Nspire
« on: November 11, 2012, 12:53:52 pm »
When I enter a formula again, but in another category, it is being left out.

Revert
Code: [Select]
    if not checkIfFormulaExists(Formulas, fr.formula) then
        table.insert(Formulas, fr)
    end
    if not checkIfFormulaExists(Categories[cid].sub[sid].formulas, fr.formula) then
        table.insert(Categories[cid].sub[sid].formulas, fr)
    end]
to
Code: [Select]
    table.insert(Formulas, fr)
    table.insert(Categories[cid].sub[sid].formulas, fr)]

or check only inside the subcategory for repetition.

3
News / Re: Release of FormulaPro for the Nspire
« on: November 11, 2012, 11:04:57 am »
Don't even mention it! Thank you for this fine code and thanks for sharing in the first place.
Bugs are inevitable! :)

4
News / Re: Release of FormulaPro for the Nspire
« on: November 11, 2012, 10:54:11 am »
Like I said, nothing changes.

5
News / Re: Release of FormulaPro for the Nspire
« on: November 11, 2012, 10:53:01 am »
I have another category named #1 and have also replaced your database.

The version is definitely 1.4a from git source obtained today.
Code: [Select]
git clone git://github.com/adriweb/EEPro-for-Nspire.git
Changing the solver made no difference.

I opened a new tab, and displayed every variable. If it had a value, it showed the value. If not, the variable's name.

6
News / Re: Release of FormulaPro for the Nspire
« on: November 11, 2012, 09:35:08 am »
Using the latest git-version and a Nspire CX CAS v3.1 calculator, I have a serious problem.

I have a set of 4 principal equations in applied hydraulics.
The only way I get an answer is when I implement all four into one. (look Missing D #4)
If I implement them into two-tree equations and providing I give f (provided by Missing D #4), I get the desired D. (look Missing D #2 & #3)
If I have all four, and I provide the D, I'll get the f, but if I provide the f only, I don't get D. (look Missing D #1)

It seems to be a solver issue. Does FormulaPro uses the built-in CAS solvers and if not, is there a way to select the desired solver?


Input
Q = 0.25 m3/s
ν = 1.1E-06 m2/s
ks = 0.00025 m
L = 1015 m
hf = 9.4 m

Expected output
f = 0.0181
D = 0.3988 m

Code: [Select]
addCat(2, "Applied Hydraulics", "Darcy-Weisbach, Colebrook-White etc.")

addCatVar(2, "hf", "Head loss due to friction", "m")
addCatVar(2, "f", "Darcy friction factor", "unitless")
addCatVar(2, "Re", "Reynolds number", "unitless")
addCatVar(2, c_nu, "Kinematic viscosity", "m2/s")
addCatVar(2, "Ks", "Roughness Factor", "m")
addCatVar(2, "L", "Length of the pipe", "m")
addCatVar(2, "D", "Hydraulic diameter", "m")
addCatVar(2, "V", "Mean velocity", "m/s")
addCatVar(2, "Q", "Volumetric flow rate", "m3/s")

addSubCat(2, 1, "Missing D #1", "")
--Darcy-Weisbach
aF(2, 1, "hf=f*(L/D)*(V^2/(2g))", U("hf","f","L","D","V","g"))

--Colebrook-White
aF(2, 1, "1/sqrt(f)+2log(Ks/D+9.35/(Re*sqrt(f)))=1.14", U("f","Ks","D","Re"))

--Reynolds number
aF(2, 1, "Re=V*D/"..c_nu, U("Re","V","D",c_nu))


aF(2, 1, "Q=V*"..c_pi.."*D^2/4", U("Q","V","D"))


addSubCat(2, 2, "Missing D #2", "")
--Darcy-Weisbach with flow rate
aF(2, 2, "hf=f*(L/D^5)*(8*Q^2/("..c_pi.."^2*g))", U("hf","f","L","D","Q","g"))

--Reynolds number
aF(2, 2, "Re*sqrt(f)=sqrt(2*g*hf/L)*D^(1.5)/"..c_nu, U("Re","f","g","hf","L","D",c_nu))

--Colebrook-White
aF(2, 2, "1/sqrt(f)+2log(Ks/D+9.35/(Re*sqrt(f)))=1.14", U("f","Ks","D","Re"))


addSubCat(2, 3, "Missing D #3", "")
--Darcy-Weisbach with flow rate
aF(2, 3, "D=(8*f*L*Q^2/("..c_pi.."^2*g*hf))^(0.2)", U("hf","f","L","D","Q","g"))

--Colebrook-White with Raynolds number
aF(2, 3, "1/sqrt(f)+2log(Ks/D+9.35/(sqrt(2*g*hf/L)*D^(1.5)/"..c_nu.."))=1.14", U("f","Ks","D","g","hf","L",c_nu))

addSubCat(2, 4, "Missing D #4", "")
--Colebrook-White, with the above
aF(2, 4, "1/sqrt(f)+2log(Ks/((8*f*L*Q^2/("..c_pi.."^2*g*hf))^(0.2))+9.35/(sqrt(2*g*hf/L)*((8*f*L*Q^2/("..c_pi.."^2*g*hf))^(0.2))^(1.5)/"..c_nu.."))=1.14", U("f","Ks","g","hf","L","Q",c_nu))

7
News / Re: Release of FormulaPro for the Nspire
« on: September 24, 2012, 02:56:44 pm »
Code: [Select]
While in Units.lua (Git version) I have:
[code]Units["Pa"] = {}
Units["Pa"]["MPa"] = {Mt.M    , 0}
Units["Pa"]["GPa"] = {Mt.G    , 0}
Units["Pa"]["hPa"] = {Mt.h    , 0}
Units["Pa"]["bar"] = {1/100000, 0}
Units["Pa"]["atm"] = {1.01325 , 0}
the output is
Code: [Select]
Pa
hPa
atm
GPa
bar
MPa
which is totally confusing.

When I say default values, I mean either an implementation of a dropbox, in the same manner to the units, where I can select from predefined values or a default value in case a variable is not set.

Furthermore, default units, are really useful, because in civil engineering, units are massive, from  KN to MN, and MPa to GPa.

About my last question, what I meant was that in my field, some values follow a different curve according to some variable. For example, the coefficient α_cw, is
Code: [Select]
1+σ_cp/f_cd      for 0 < σ_cp <= 0.25 f_cd
1.25             for 0.25 f_cd < σ_cp <= 0.5 f_cd
2.5(1-σ_cp/f_cd) for 0.5 f_cd < σ_cp <= 1.0 f_cd

Should I implement the default values and the slope change in that last example, by creating an equation, using max(), min() and abs() in order to make the gradual change?

Finally, the constants, to not update according to constants.lua. They seem to be fixed.


Don't worry about the web version. I don't need it. But many of my friends who are willing to buy the same calculator, would certainly need it.

I am currently preparing for an exam at Saturday, so programming my nspire is of paramount importance.[/code]

8
News / Re: Release of FormulaPro for the Nspire
« on: September 24, 2012, 05:44:36 am »
  • Is it possible to control the order of the variables used in a subcategory?
  • Is it possible to control the order of the units?
  • Is it possible to have default values for some equations, in case one or more variables are missing?
  • Can we predifine some variables and/or their units
  • Why the constants do not regenerate according to constants.lua
  • Can we choose to hide some variables which are of secondary importance?
  • How can we assign different functions for the same variable, according to the value of an input variable?
    example:

Code: [Select]
y = x^2, x<=0
y = 2*x, x>0

9
News / Re: Release of FormulaPro for the Nspire
« on: September 17, 2012, 11:46:58 am »
Hello everyone!
I am a happy owner of a TI Nspire CX CAS and I have just discovered this "state of the art" applications.
I would like to know, if it is possible to update the http://education.bwns.be/FormulaPro/ to the latest version of FormulaPro (or EEPro) as the current one seems a bit outdated. Furthermore, as I happen to be a AJAX/PHP hobbyist programmer, I would appreciate it if you could make an svn where we could get all the necessary files for the web based database creator, as I would like to implement an xml input/output to save and load databases to the web application.

Thanks for your time, and once again congratulations on your good work.

PS: The main field of my work is in civil engineering, and I would like to sumbit to the community a CVEPro database.

Pages: [1]