Re: How to parametrize a block of commands?
- To: mathgroup at smc.vnet.net
- Subject: [mg111039] Re: How to parametrize a block of commands?
- From: Helen Read <hpr at together.net>
- Date: Sun, 18 Jul 2010 01:03:09 -0400 (EDT)
- References: <email@example.com>
- Reply-to: HPR <read at math.uvm.edu>
On 7/17/2010 8:16 AM, Sam Takoy wrote: > > My question is this: could this entire block be turned into a function > "paramtrized" by F and Z. For example, denote that whole block by XXXXX. > Is there something along the lines of > > DiffGeom[F_, Z_] := XXXXX > r[g_] := a Cosh[(g - H/2)/a] > z[g_] := g > DiffGeom[r, z] > > In other words, once I have taught Mathematica to compute these objects > for general surfaces of revolution, I want it to apply it to a > particular surface of revolution. What's the best way to organize this? Use Module or Block Look them up in the Documentation. -- Helen Read University of Vermont