# Changeset 138

Ignore:
Timestamp:
Jan 26, 2007, 3:21:01 PM (15 years ago)
Message:

Adjust the measurement units of some examples.

Location:
trunk/sample/miscellaneous
Files:
9 edited

Unmodified
Removed
• ## trunk/sample/miscellaneous/sample_arrays2.mso

 r83 diff(Var1(2:Dimension,:))*"s" = Scalar*Var2(2:Dimension,:); exp(Scalar)*Var2 = sin(time/"s"); exp(Scalar)*Var2 = sin(time*"rad/s"); end
• ## trunk/sample/miscellaneous/sample_car.mso

 r83 EQUATIONS diff([xl, yl, xr, yr]) = q; diff([xl, yl, xr, yr])*"s" = q; eps^2*M/2 * diff(q(1)) = (l0-ll)*xl/ll eps^2*M/2 * diff(q(1))*"s" = (l0-ll)*xl/ll +lambda(1)*xb +2*lambda(1)*(xl-xr); eps^2*M/2 * diff(q(2)) = (l0-ll)*yl/ll eps^2*M/2 * diff(q(2))*"s" = (l0-ll)*yl/ll +lambda(1)*yb +2*lambda(2)*(yr-yl) - eps^2*M/2; eps^2*M/2 * diff(q(3)) = (l0-lr)*(xr-xb)/lr eps^2*M/2 * diff(q(3))*"s" = (l0-lr)*(xr-xb)/lr -2*lambda(2)*(xl-xr); eps^2*M/2 * diff(q(4)) = (l0-lr)*(yr-yb)/lr eps^2*M/2 * diff(q(4))*"s" = (l0-lr)*(yr-yb)/lr -2*lambda(2)*(yl-yr) - eps^2*M/2; xb = sqrt(l^2-yb^2); yb = r*sin(w*time); yb = r*sin(w*time*"rad/s"); ll = sqrt(xl^2 + yl^2);
• ## trunk/sample/miscellaneous/sample_cstr_simple.mso

 r83 k0 as frequency; Ea as energy_mol (Brief = "Energia de Ativação"); R  as energy_mol; R  as entr_mol; VARIABLES "Constante de Reação" k=k0*exp(Ea/R*(1/436.15 - 1*"K"/T)); k=k0*exp(Ea/R*(1/(436.15*"K") - 1/T)); "Taxas de Reação" "Cp da mistura" Cps=(0.5*250)*3;# *"cal/mol/K"; Cps=(0.5*250)*3 * "J/mol/K"; "Balanço de Energia"
• ## trunk/sample/miscellaneous/sample_galvanic.mso

 r83 VARIABLES y1  as  current(Default=0.5, Brief="Mole fraction of NiOOH"); y2  as  current(Default=0.5, Brief="Potential difference at the solid-liquid interface"); y1  as  Real(Default=0.5, Brief="Mole fraction of NiOOH"); y2  as  Real(Default=0.5, Brief="Potential difference at the solid-liquid interface"); "Equation 1(a)" pho*V/W*diff(y1) = i01*(2*(1-y1)*exp(0.5*F/(R*T)*(y2-phi1))-2*y1*exp(-0.5*F/(R*T)*(y2-phi1)))/F; pho*V/W*diff(y1)*"s" = i01*(2*(1-y1)*exp(0.5*F/(R*T)*(y2-phi1))-2*y1*exp(-0.5*F/(R*T)*(y2-phi1)))/F; "Equation 1(b)" INITIAL #Parameters used for the initial conditions #y1 = 0.05; #y1 = 0.05"; y2 = 0.38;
• ## trunk/sample/miscellaneous/sample_hyperbolics.mso

 r107 Pi              as constant  (Brief="Pi Number",Default=3.14159265); Theta   as angle     (Brief ="theta angle",Default=0.5); Theta   as Real      (Brief ="Argument",Default=0.5); VARIABLES Pi         = 3.14159265; Theta  = 0.6*Pi*"rad"; Theta  = 0.6*Pi; EQUATIONS
• ## trunk/sample/miscellaneous/sample_if_tanh.mso

 r83 A = 10*xif + 5*xelse; xif = (1 + tanh(B * (time - 3)))/2; xelse = (1 - tanh(B * (time - 3)))/2; xif = (1 + tanh(B * (time/"s" - 3)))/2; xelse = (1 - tanh(B * (time/"s" - 3)))/2; SET
• ## trunk/sample/miscellaneous/sample_manipulation.mso

 r107 PARAMETERS Number(2)      as Real; Number(3)      as Real; VARIABLES absolute(2)     as Real  (Brief ="abs function"); maximum(2)      as Real  (Brief ="max function"); minimum(2)              as Real  (Brief ="Natural log function"); signal(2)       as Real  (Brief ="square root function"); rounds(2)       as Real  (Brief ="square root function"); absolute(3)     as Real  (Brief ="abs function"); maximum         as Real  (Brief ="max function"); minimum                 as Real  (Brief ="Natural log function"); signal(3)       as Real  (Brief ="square root function"); rounds(3)       as Real  (Brief ="square root function"); SET Number  = [-10.3,5.001]; Number  = [-10.3,0,5.001]; EQUATIONS
• ## trunk/sample/miscellaneous/sample_mathematicals.mso

 r107 EQUATIONS exponential     = exp(time); log10                   = log(time); NatLog                  = ln(time); squareRoot      = sqrt(time); exponential     = exp(time/"s"); log10                   = log(time/"s"); NatLog                  = ln(time/"s"); squareRoot      = sqrt(time/"s"); OPTIONS
• ## trunk/sample/miscellaneous/sample_trigonometrics.mso

 r107 tangent as Real  (Brief ="tangent function",Default=0.5); arccosine  as Real  (Brief ="arc cosine function",Default=0.5); arcsine    as Real  (Brief ="arc sine function",Default=0.5); arctangent as Real  (Brief ="arc tangent function",Default=0.5); arccosine  as angle  (Brief ="arc cosine function",Default=0.5); arcsine    as angle  (Brief ="arc sine function",Default=0.5); arctangent as angle  (Brief ="arc tangent function",Default=0.5); SET
Note: See TracChangeset for help on using the changeset viewer.