init
This commit is contained in:
66
docs/diagram.puml
Normal file
66
docs/diagram.puml
Normal file
@@ -0,0 +1,66 @@
|
||||
@startuml
|
||||
package "function.base" {
|
||||
interface ISin {
|
||||
+sin(x: Double, eps: Double = 1e-10): Double
|
||||
}
|
||||
interface ILn {
|
||||
+ln(x: Double, eps: Double = 1e-10): Double
|
||||
}
|
||||
class SinTaylor implements ISin
|
||||
class LnTaylor implements ILn
|
||||
}
|
||||
|
||||
package "function.trigonometric" {
|
||||
class Cos implements ICos
|
||||
class Csc implements ICsc
|
||||
class Sec implements ISec
|
||||
class Cot implements ICot
|
||||
Cos --> ISin
|
||||
Csc --> ISin
|
||||
Sec --> ISin
|
||||
Cot --> ISin
|
||||
}
|
||||
|
||||
package "function.logarithmic" {
|
||||
class Log implements ILog
|
||||
Log --> ILn
|
||||
}
|
||||
|
||||
package "function.stubs" {
|
||||
class SinStub implements ISin
|
||||
class LnStub implements ILn
|
||||
class CosStub implements ICos
|
||||
class CscStub implements ICsc
|
||||
class SecStub implements ISec
|
||||
class CotStub implements ICot
|
||||
class LogStub implements ILog
|
||||
}
|
||||
|
||||
class FunctionSystem {
|
||||
-sinImpl: ISin
|
||||
-lnImpl: ILn
|
||||
-cosImpl: ICos
|
||||
-cscImpl: ICsc
|
||||
-secImpl: ISec
|
||||
-cotImpl: ICot
|
||||
-logImpl: ILog
|
||||
+compute(x: Double, eps: Double = 1e-10): Double
|
||||
}
|
||||
|
||||
FunctionSystem --> ISin
|
||||
FunctionSystem --> ILn
|
||||
FunctionSystem --> ICos
|
||||
FunctionSystem --> ICsc
|
||||
FunctionSystem --> ISec
|
||||
FunctionSystem --> ICot
|
||||
FunctionSystem --> ILog
|
||||
|
||||
package "util" {
|
||||
class CsvWriter {
|
||||
+writeToCsv(filename: String, data: List<Pair<Double,Double>>, label: String)
|
||||
}
|
||||
}
|
||||
|
||||
Main --> FunctionSystem
|
||||
Main --> CsvWriter
|
||||
@enduml
|
||||
Reference in New Issue
Block a user