dynamically created symbol
- Subject: dynamically created symbol
- From: Barton Willis
- Date: Tue, 3 Jul 2012 13:45:52 +0000
Interesting macro Robert; fun example:
(%i3) with_local_context([a : 1, b : 2, ratfac : true], integrate(1/x,x,a,b));
(%o3) log(2)
(%i4) [a,b,ratfac];
(%o4) [a,b,false]
Compare:
with_local_context(a : 1, b : 2, ratfac : true, integrate(1/x,x,a,b)
with_local_context([[a : 1, b : 2, ratfac : true]], integrate(1/x,x,a,b));
with_local_context([a : 1, b : 2, ratfac : true], integrate(1/x,x,a,b));
Maybe there is a call for a newcontext version?
--Barton
________________________________