[Date Index]
[Thread Index]
[Author Index]
Re: Defining Functions and Simplifying Solutions
*To*: mathgroup at smc.vnet.net
*Subject*: [mg90557] Re: [mg90498] Defining Functions and Simplifying Solutions
*From*: Sseziwa Mukasa <mukasa at jeol.com>
*Date*: Sat, 12 Jul 2008 05:35:46 -0400 (EDT)
*References*: <200807110602.CAA03726@smc.vnet.net>
On Jul 11, 2008, at 2:02 AM, Locus wrote:
> Hello!
>
> I actually have to questions:
>
> 1. Is there a more handy way to define/use functions as compared to
> the following way (which works, but is complicated always typing
> the variable definitions):
>
> G[\[Alpha]1_Real, \[Alpha]2_Real, e1_Real,
> e2_Real] = \[Alpha]1*e1 + \[Alpha]2*e2
>
> v[G_Real] = a*G[\[Alpha]1, \[Alpha]2, e1, e2] + b
I'm not sure what you mean, using greek characters for variables can
be laborious, do you really need to? The fastest way to type alpha
is Esc a Esc so you save five keystrokes per alpha there (look up
entering Greek letters in the help guide).
Also why are you using = instead of :=?
> 2. After several steps, I receive the following solution
>
> {{a -> (0. (e1 \[Beta]1 + e2 \[Beta]2 \[Lambda]))/(rA \[Tau]^2)}}
>
> which obviously equals zero. How can I 'force' Mathematica to
> display only 0 as result and not such a unnessecarily complicated
> expression? FullSimplify does not work here.
The problem with Simplification is that 0. is a machine precision
number, if you replace it with 0 you get your desired result:
In[10]:= Simplify[(0 (e1 \[Beta]1+e2 \[Beta]2 \[Lambda]))/(rA \[Tau]^2)]
Out[10]= 0
Regards,
Ssezi
Prev by Date:
**Re: Question about diference between Animate and Manipulate**
Next by Date:
**Re: Defining Functions and Simplifying Solutions**
Previous by thread:
**Defining Functions and Simplifying Solutions**
Next by thread:
**Re: Defining Functions and Simplifying Solutions**
| |