13.02.2013 Views

Design of an Automatic Control Algorithm for Energy-Efficient ...

Design of an Automatic Control Algorithm for Energy-Efficient ...

Design of an Automatic Control Algorithm for Energy-Efficient ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Optimiser code 169<br />

690 ∗ Latest Revision : 10 28 98<br />

692 ∗<br />

694 ∗/<br />

{<br />

∗ http://www.cs.wm.edu/~va/s<strong>of</strong>tware/park/<br />

∗ ===========================================================<br />

696 return (a + (b a ) ∗ R<strong>an</strong>dom ( ) ) ;<br />

698<br />

}<br />

700 real_T R<strong>an</strong>dom( void) {<br />

/ ∗ ===========================================================<br />

702 ∗ Returns r<strong>an</strong>dom value between 0 <strong>an</strong>d 1.0.<br />

∗ Uses internal r<strong>an</strong>d() generator<br />

704 ∗ ===========================================================<br />

∗/<br />

706 return (real_T) r<strong>an</strong>d () /RAND_MAX;<br />

708<br />

}<br />

710 /∗<br />

712 ∗<br />

714 {<br />

716 }<br />

void Pl<strong>an</strong>tSeeds(int_T x)<br />

∗ Use this function to initialise the r<strong>an</strong>dom number generator<br />

∗/<br />

sr<strong>an</strong>d ((unsigned)x) ;

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!