does anyone know what could be causing this? (pasted notebook below -
i would publish this on sagenb.org, but its publishing feature isn't
working for me right now (keeps giving an invalid url))
---------------begin notebook after this line-----------------
Lift Coefficient
system:sage
{{{id=21|
var('Cv Vr k g SWL Design')
assume(Cv>1,Vr>=0,k>0,g>0,SWL>0,Design>0)
eqns={1:Cv==1+Vr*sqrt(k/(g*SWL)),2:SWL*Cv==Design}
eqns
///
{1: Cv == sqrt(k)*Vr/(sqrt(g)*sqrt(SWL)) + 1, 2: Cv*SWL == Design}
}}}
{{{id=34|
power_eq = lambda eq, n: eq.operator()(eq.lhs()^n, eq.rhs()^n) #from
mhansen on sage-devel
subs_eq = lambda eq, *args: eq.operator()(eq.lhs().subs_expr
(*args),eq.rhs().subs_expr(*args))
///
}}}
{{{id=38|
var('alpha')
assume(alpha>0)
eqns[3]=alpha==k*Vr^2/g/Design
///
}}}
{{{id=25|
eqns[4]=subs_eq(power_eq(eqns[1]-1,2),*solve(map(eqns.get,range
(2,3+1)),k,SWL)[0]);eqns[4]
///
(Cv - 1)^2 == alpha*Cv
}}}
{{{id=37|
eqns[5]=(eqns[4]-alpha*Cv).expand();eqns[5]
///
Cv^2 - alpha*Cv - 2*Cv + 1 == 0
}}}
{{{id=40|
solve[eqns[5],Cv]
///
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/sage/sagenb/sage_notebook/worksheets/chris.chiasson/0/
code/6.py", line 7, in <module>
exec compile(ur'solve[eqns[_sage_const_5 ],Cv]' + '\n', '',
'single')
File "/home/sage/sage_install/sage-a/local/lib/python2.5/site-
packages/SQLAlchemy-0.4.6-py2.5.egg/", line 1, in <module>
TypeError: 'function' object is unsubscriptable
}}}
{{{id=42|
eqns[5]
///
Cv^2 - alpha*Cv - 2*Cv + 1 == 0
}}}
{{{id=43|
solve(Cv^2 - alpha*Cv - 2*Cv + 1 == 0,Cv)
///
[Cv == (-sqrt(alpha)*sqrt(alpha + 4) + alpha + 2)/2, Cv == (sqrt(alpha)
*sqrt(alpha + 4) + alpha + 2)/2]
}}}
{{{id=44|
///
}}}
{{{id=45|
///
}}}
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---