20.07.2013 Views

Raport de cercetare - Lorentz JÄNTSCHI

Raport de cercetare - Lorentz JÄNTSCHI

Raport de cercetare - Lorentz JÄNTSCHI

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

$y_values=array();<br />

foreach($r as $k => $v){<br />

if($vbrowse_names();<br />

die("normal shutdown.\r\n");<br />

class <strong>de</strong>scriptor_filter{<br />

function __construct(&$m_list,&$y_list){<br />

$this->m=count($m_list);<br />

$this->ml=$m_list;<br />

$this->y=$y_list;<br />

$this->x=array();<br />

$this->my1=$this->m1($this->y);<br />

$this->dy2=$this->m2($this->y,$this->y)-$this->my1*$this->my1;<br />

$this->mx1=0.0;<br />

$this->dx2=0.0;<br />

$this->r2=0.0;<br />

$this->qs="SELECT `".implo<strong>de</strong>("`, `",$m_list)."` FROM `".setd."_mdfv` WHERE `id` = ";<br />

$this->qi="INSERT INTO `".setd."__".propd."` VALUES ('',";<br />

$this->qk="SELECT `".implo<strong>de</strong>("`, `",$m_list)."` FROM `".setd."__".propd."` WHERE `kc` = ";<br />

$this->qn="SELECT `name` FROM `_mdfv` WHERE `id` = ";<br />

$this->l=array();<br />

$this->n=0;<br />

}<br />

function coef_r2(){<br />

$mxy=$this->m2($this->x,$this->y);<br />

$this->r2=pow($mxy-$this->mx1*$this->my1,2)/($this->dx2*$this->dy2);<br />

}<br />

function coeg_r2(&$y){<br />

$m1y=$this->m1($y);<br />

$m2y=$m1y*$m1y;<br />

$my2=$this->m2($y,$y);<br />

$dy2=$my2-$m2y;<br />

if(!$dy2)return(-1.0);<br />

$mxy=$this->m2($y,$this->x);<br />

return pow($mxy-$this->mx1*$m1y,2)/($this->dx2*$dy2);<br />

}<br />

function get_mdfv(&$id){<br />

$q=mysql_query($this->qs."'".$id."'");<br />

$this->x=mysql_fetch_row($q);<br />

mysql_free_result($q);<br />

}<br />

function table_insert($i,$k){<br />

$q=mysql_query($this->qn."'".$i."'");<br />

if(!$q)die("SELECT NAME ERROR!");<br />

$n=mysql_fetch_row($q);<br />

mysql_free_result($q);<br />

$query=$this->qi."'".$n[0]."','".$k."','".$this->r2."','".implo<strong>de</strong>("', '",$this->x)."')";<br />

$q=mysql_query($query);<br />

if(!$q) die($query." :insert error\r\n");<br />

}<br />

function table_select($k){<br />

$q=mysql_query($this->qk."'".$k."'");<br />

if(!$q) die("select error\r\n");<br />

return($q);<br />

}<br />

function in<strong>de</strong>x(){<br />

$val=$this->r2*pow(10,clas);<br />

$val=trim(sprintf("%.0f",$val));<br />

return($val);<br />

}<br />

function one_row(){<br />

196

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

Saved successfully!

Ooh no, something went wrong!