R Under development (unstable) (2023-04-23 r84305 ucrt) -- "Unsuffered Consequences" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 (64-bit) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > > library(rcdd) If you want correct answers, use rational arithmetic. See the Warnings sections in help pages for functions that do computational geometry. > > hrep <- rbind(c(0, 1, 1, 1, -1), + c(0, 1, 1, -1, -1), + c(0, 1, -1, -1, -1), + c(0, 1, -1, 1, -1), + c(0, 0, 0, 0, 1)) > > qout <- allfaces(d2q(hrep)) > print(qout) $dimension $dimension[[1]] [1] 2 $dimension[[2]] [1] 1 $dimension[[3]] [1] 2 $dimension[[4]] [1] 1 $dimension[[5]] [1] 0 $dimension[[6]] [1] 1 $dimension[[7]] [1] 2 $dimension[[8]] [1] 1 $dimension[[9]] [1] 0 $dimension[[10]] [1] 1 $dimension[[11]] [1] 2 $dimension[[12]] [1] 1 $dimension[[13]] [1] 0 $dimension[[14]] [1] 1 $dimension[[15]] [1] 0 $dimension[[16]] [1] 0 $dimension[[17]] [1] 1 $dimension[[18]] [1] 2 $dimension[[19]] [1] 3 $active.set $active.set[[1]] [1] 5 $active.set[[2]] [1] 4 5 $active.set[[3]] [1] 4 $active.set[[4]] [1] 3 5 $active.set[[5]] [1] 3 4 5 $active.set[[6]] [1] 3 4 $active.set[[7]] [1] 3 $active.set[[8]] [1] 2 5 $active.set[[9]] [1] 2 3 5 $active.set[[10]] [1] 2 3 $active.set[[11]] [1] 2 $active.set[[12]] [1] 1 5 $active.set[[13]] [1] 1 4 5 $active.set[[14]] [1] 1 4 $active.set[[15]] [1] 1 2 5 $active.set[[16]] [1] 1 2 3 4 $active.set[[17]] [1] 1 2 $active.set[[18]] [1] 1 $active.set[[19]] integer(0) $relative.interior.point $relative.interior.point[[1]] [1] "0" "0" "0" $relative.interior.point[[2]] [1] "1/2" "-1/2" "0" $relative.interior.point[[3]] [1] "1/4" "-1/4" "1/2" $relative.interior.point[[4]] [1] "1/2" "1/2" "0" $relative.interior.point[[5]] [1] "1" "0" "0" $relative.interior.point[[6]] [1] "1/3" "0" "2/3" $relative.interior.point[[7]] [1] "1/4" "1/4" "1/2" $relative.interior.point[[8]] [1] "-1/2" "1/2" "0" $relative.interior.point[[9]] [1] "0" "1" "0" $relative.interior.point[[10]] [1] "0" "1/3" "2/3" $relative.interior.point[[11]] [1] "-1/4" "1/4" "1/2" $relative.interior.point[[12]] [1] "-1/2" "-1/2" "0" $relative.interior.point[[13]] [1] "0" "-1" "0" $relative.interior.point[[14]] [1] "0" "-1/3" "2/3" $relative.interior.point[[15]] [1] "-1" "0" "0" $relative.interior.point[[16]] [1] "0" "0" "1" $relative.interior.point[[17]] [1] "-1/3" "0" "2/3" $relative.interior.point[[18]] [1] "-1/4" "-1/4" "1/2" $relative.interior.point[[19]] [1] "0" "0" "1/2" > > dout <- allfaces(hrep) > > identical(qout$dimension, dout$dimension) [1] TRUE > identical(qout$active.set, dout$active.set) [1] TRUE > all.equal(lapply(qout$relative.interior.point, FUN = q2d), + dout$relative.interior.point) [1] TRUE > > > proc.time() user system elapsed 0.18 0.10 0.28