user21627: Is it possible to manually declare a global variable that is inside of a function. The only current way I know how to do so is to declare that variable within the setup() function or simply outside of any function, but I was hoping there was a way to manually declare a variable as global so that I may call one variable from within one function in another function.

user313: 
even though I understand this takes up a bit of dynamic memory

There is no way around that. They have to go somewhere and that place is RAM (exception: constants could be stored in flash).
Another variation (which goes beyond your question) is that a parent function could declare and build a collection of data in a local array or struct and pass a pointer to it to any sub-functions. It still takes RAM, but it will be on the parent function's stack, so only for the duration of parent function's execution(s); it will be released when the parent function exits.

user10394: You need to research 'Scope'.
Your variable has to be at the same level as all functions that will use it.  So at a simple level the answer has to be no.
int variableOne = 0;
void setup ()
{
  variableOne = 1;
}
void loop ()
{
  variableOne = 2;
}

The above code will work, but if you move int variableOne = 0; inside either function then it won't work, because the variable will not be in scope in the other function.
You can use parameters to functions.  
void AFunction (const int& variable);

Will let you pass a single integer value to the function from the parent.  You can't change that value, because of the const qualifier.  If you remove the const then the & means pass the parameter by reference, which means you are passing in a reference (pointer) to the variable in the parent function and you can change it.  A better way to change the parent's value is to return a value from the call.
int AFunction (const int& variable);

So you could use this like this:
int AFunction (const int& variable)
{
  return (++variable);
}
void loop (void)
{
  int value = 0;
  value = AFunction(value);
  // value now == 1.
}

You could use a Singleton class, but this is hardcore and I'm not sure you would see any real benefit on an Arduino.  A class is a grouping of related function and variables that you see in libraries and a Singleton class means there will only ever be one during the lifetime of the program.  In this way you can declare an instance of the class (i.e. CSingleInstanceClass onlyOne;) and then retrieve/set data from the setup and loop function, i.e.
void setup ()
{
  CSingleInstanceClass onlyOne;  // Single instance class
  onlyOne.SetVariableOne (1);
}
void loop ()
{
  CSingleInstanceClass onlyOne;  // Single instance class
  Serial.println(onlyOne.GetVariableOne());// Prints 1
}

Hope that helps.

21627: <p>Is it possible to manually declare a global variable that is inside of a function. The only current way I know how to do so is to declare that variable within the <code>setup()</code> function or simply outside of any function, but I was hoping there was a way to manually declare a variable as global so that I may call one variable from within one function in another function.</p>
 313: <blockquote>
  <p>even though I understand this takes up a bit of dynamic memory</p>
</blockquote>

<p>There is no way around that. They have to go somewhere and that place is RAM (exception: constants could be stored in flash).</p>

<p>Another variation (which goes beyond your question) is that a parent function could declare and build a collection of data in a local array or struct and pass a pointer to it to any sub-functions. It still takes RAM, but it will be on the parent function's stack, so only for the duration of parent function's execution(s); it will be released when the parent function exits.</p>
 10394: <p>You need to research 'Scope'.</p>

<p>Your variable has to be at the same level as all functions that will use it.  So at a simple level the answer has to be no.</p>

<pre><code>int variableOne = 0;
void setup ()
{
  variableOne = 1;
}
void loop ()
{
  variableOne = 2;
}
</code></pre>

<p>The above code will work, but if you move <code>int variableOne = 0;</code> inside either function then it won't work, because the variable will not be in scope in the other function.</p>

<p>You can use parameters to functions.  </p>

<pre><code>void AFunction (const int&amp; variable);
</code></pre>

<p>Will let you pass a single integer value to the function from the parent.  You can't change that value, because of the <code>const</code> qualifier.  If you remove the const then the <code>&amp;</code> means pass the parameter by reference, which means you are passing in a reference (pointer) to the variable in the parent function and you can change it.  A better way to change the parent's value is to return a value from the call.</p>

<pre><code>int AFunction (const int&amp; variable);
</code></pre>

<p>So you could use this like this:</p>

<pre><code>int AFunction (const int&amp; variable)
{
  return (++variable);
}
void loop (void)
{
  int value = 0;
  value = AFunction(value);
  // value now == 1.
}
</code></pre>

<p>You could use a Singleton class, but this is hardcore and I'm not sure you would see any real benefit on an Arduino.  A class is a grouping of related function and variables that you see in libraries and a Singleton class means there will only ever be one during the lifetime of the program.  In this way you can declare an instance of the class (i.e. <code>CSingleInstanceClass onlyOne;</code>) and then retrieve/set data from the setup and loop function, i.e.</p>

<pre><code>void setup ()
{
  CSingleInstanceClass onlyOne;  // Single instance class
  onlyOne.SetVariableOne (1);
}
void loop ()
{
  CSingleInstanceClass onlyOne;  // Single instance class
  Serial.println(onlyOne.GetVariableOne());// Prints 1
}
</code></pre>

<p>Hope that helps.</p>
