Newer
Older
Multi-StageDesignTool / AlgebraicDataflowArchitectureModel / models / Triangle.model
Okina-kina on 15 Mar 281 bytes firsr commit
channel cio1 {
	out base(x: Double, setBase(x2)) == x2
}

channel cio2 {
	out height(y: Double, setHeight(y2)) == y2
}

channel triangle {
	in base(x, update(x2, y2)) == x2
	in height(y, update(x2, y2)) == y2
	out hypothenuse(z: Double, update(x2, y2)) == sqrt(x2 * x2 + y2 * y2)
}