Skip to content
Snippets Groups Projects
Commit 06447617 authored by wactbprot's avatar wactbprot
Browse files

merge

parents 1fb5e384 5df78e12
No related branches found
No related tags found
No related merge requests found
......@@ -76,13 +76,13 @@ ce3.calDeltaVDeltat <- function(ccc){
ci <- mp - slope * mt
t0 <- (mean(mp, na.rm =TRUE) - ci) / slope
out <- which(correlCoef < 0.8)
out <- which(correlCoef < 0.9)
if(length(out) > 0){
t0[out] <- NA
msg <- paste(msg
, "exclude saw tooth:"
, toString(out)
, "because of bad (<0.8) correlation")
, "because of bad (<0.9) correlation")
}
......@@ -124,9 +124,12 @@ ce3.calDeltaVDeltat <- function(ccc){
## Leitwert = dV/dt *(1- m.D/m.SZ)
## dVdt <- mean(deltaV, na.rm =TRUE) / mean(deltat, na.rm =TRUE) * (1 - dcorr[j])
dVdt <- mean(deltaV, na.rm =TRUE) / mean(deltat, na.rm =TRUE)
if( j > 1){
dVdt <- mean(deltaV, na.rm =TRUE)/mean(deltat, na.rm =TRUE)*(1-dcorr[j])
}else{
dVdt <- mean(deltaV, na.rm =TRUE) / mean(deltat, na.rm =TRUE)
}
L[j] <- mean(dVdt, na.rm =TRUE)
sddV[j] <- sd(deltaV, na.rm =TRUE)/ mean(deltaV, na.rm =TRUE)
......
......@@ -31,8 +31,9 @@ source("load.R")
## cdb$id <- "ac36e53c6c34d30886c210a6f60aa61b"
## cdb$id <- "ac36e53c6c34d30886c210a6f60a9091" # daresb H2
## cdb$id <- "ac36e53c6c34d30886c210a6f608ad31" ## lwc, lw1, lw2
cdb$id <- "ac36e53c6c34d30886c210a6f6089e5a"
## cdb$id <- "ac36e53c6c34d30886c210a6f6089e5a"
## cdb$id <- "ac36e53c6c34d30886c210a6f60a9091" # daresb H2
cdb$id <- "ac36e53c6c34d30886c210a6f61bd27e" # LEY
doc <- cdbGetDoc(cdb)$res
if(TRUE){
......
......@@ -120,6 +120,6 @@ doc$Calibration$Analysis$Values$Uncertainty <-
doc <- ce3.uncertTotal(doc)
doc <- dispatchResSum(doc)
cdb$DBName <- "vaclab_work" ## DBName
cdb$dataList <- doc
res <- cdbUpdateDoc(cdb)$res
\ No newline at end of file
## cdb$DBName <- "vaclab_db" ## DBName
## cdb$dataList <- doc
## res <- cdbUpdateDoc(cdb)$res
......@@ -17,7 +17,7 @@ if(length(doc$Calibration) > 0){
doc <- ce3.writePind(doc)
##
doc <- dispatchResCal(doc)
if(FALSE){
## uncertainty ...
## ... fm3 related
doc <- fm3.uncertPfill(doc)
......@@ -56,6 +56,6 @@ if(length(doc$Calibration) > 0){
doc <- dispatchResSum(doc)
#
doc <- ce3.compareCDGs(doc)
if(FALSE){
}
}
......@@ -24,8 +24,8 @@ if((a$cmscg == "N2" || a$cmscg == "Ar" || a$cmscg == "D2"|| a$cmscg == "H2") & i
if(pcal < 1e-4){
lw <- "lw1"
}
#if(pcal < 9e-7){
if(pcal < 1e-5){ ## H2
if(pcal < 9e-7){
#if(pcal < 1e-5){ ## H2
lw <- "lw0"
}
if(pcal < 1e-10){
......
......@@ -16,6 +16,7 @@ getConductIndex <- function(ccc){
## --- Lw2 --- kl. Lw ---
lw2List <- getSubList(a$cms, "useLw2")
<<<<<<< HEAD
iLw2 <- which((cnom > as.double(lw2List$From)) &
as.double(lw2List$To))
......@@ -27,6 +28,22 @@ getConductIndex <- function(ccc){
iLw1 <- which((cnom > as.double(lw1List$From)) &
as.double(lw1List$To))
=======
iLw2 <- which((cnom > as.double(lw2List$From)) & as.double(lw2List$To))# (cnom < 8e-6)
## --- Lw1 --- gr. Lw ---
lw1List <- getSubList(a$cms, "useLw1")
iLw1 <- which((cnom > as.double(lw1List$From)) & as.double(lw1List$To)) # (cnom < 1e-4)
## --- LwC --- constLw ---
lwCList <- getSubList(a$cms, "useLwC")
iLwC <- which(pfill > as.double(lwCList$From) &
pfill < as.double(lwCList$To)
)
>>>>>>> 5df78e123fa69ede6b910c4fb3cbd0895e6a24da
## -------------------
return(list(iLw1 = iLw1,
......
......@@ -2,13 +2,16 @@ resSrgError <- function(ccc){
msg <- "calculated by resSrgError"
## - data reduction as given by ToDo
## - round
a <- abbrevList(ccc)
## 10% max. Abw. vom Zieldruck als default
maxdev <- 0.1
a <- abbrevList(ccc)
p.target <- as.numeric(a$cpt$Values$Pressure$Value)
maxdev <- as.numeric(a$cpt$MaxDev)
if(length(a$cpt$Values$Pressure$MaxDev) == 1){
maxdev <- as.numeric(a$cpt$Values$Pressure$MaxDev)
}
k <- 2 # Erweiterungsfaktor
## 10% max. Abw. vom Zieldruck als default
if(length(maxdev) == 0) maxdev <- 0.30
##-------------##
## pcal
......@@ -45,11 +48,12 @@ resSrgError <- function(ccc){
i.out <- NULL
i.take <- which(pcal > (p.target[i] *(1- maxdev)) &
pcal < (p.target[i] *(1+ maxdev)))
print(itake)
print(pcal)
print(p.target)
msg <- paste(msg,"; For target pressure:",p.target[i],
"I take the points:", toString(i.take))
if(length(i.take) > 1){
if(length(i.take) > 2){
## ut ist schon k=2, eswerden alle Punkte genommen,
## bei dem e.delta kleiner als 3-sigma ist
## wobei e.delte die Abweichung vom Reverenzwert ist
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment