module Drasil.PDController.GenSysDesc where import Data.Drasil.Concepts.Documentation (environment, software, softwareSys, sysCont, system, user) import Drasil.PDController.Concepts import Language.Drasil import Language.Drasil.Chunk.Concept.NamedCombinators gsdSysContextFig :: LabelledContent gsdSysContextFig :: LabelledContent gsdSysContextFig = Reference -> RawContent -> LabelledContent llcc (String -> Reference makeFigRef "systemContextDiag") (RawContent -> LabelledContent) -> RawContent -> LabelledContent forall a b. (a -> b) -> a -> b $ Lbl -> String -> RawContent fig (NamedChunk -> Lbl forall n. NamedIdea n => n -> Lbl titleize NamedChunk sysCont) "../../../../datafiles/pdcontroller/Fig_SystemContext.png" gsdSysContextP1, gsdSysContextP2 :: Contents gsdSysContextP1 :: Contents gsdSysContextP1 = [Lbl] -> Contents foldlSP [LabelledContent -> Lbl forall r. (HasUID r, HasRefAddress r, HasShortName r) => r -> Lbl refS LabelledContent gsdSysContextFig, String -> Lbl S "shows the" Lbl -> Lbl -> Lbl +:+. NamedChunk -> Lbl forall n. (HasUID n, NamedIdea n) => n -> Lbl phrase NamedChunk sysCont, String -> Lbl S "The circle represents an external entity outside the", NamedChunk -> Lbl forall n. (HasUID n, NamedIdea n) => n -> Lbl phrase NamedChunk software Lbl -> Lbl -> Lbl `sC` NP -> Lbl forall n. NounPhrase n => n -> Lbl phraseNP (NamedChunk -> NP forall t. NamedIdea t => t -> NP the NamedChunk user) Lbl -> Lbl -> Lbl +:+. String -> Lbl S "in this case", String -> Lbl S "The rectangle represents the", NamedChunk -> Lbl forall n. (HasUID n, NamedIdea n) => n -> Lbl phrase NamedChunk softwareSys, String -> Lbl S "itself" Lbl -> Lbl -> Lbl `sC` ConceptChunk -> Lbl forall n. (HasUID n, NamedIdea n) => n -> Lbl phrase ConceptChunk pidC Lbl -> Lbl -> Lbl +:+. String -> Lbl S "in this case", String -> Lbl S "Arrows are used to show the data flow between the", NP -> Lbl forall n. NounPhrase n => n -> Lbl phraseNP (NamedChunk system NamedChunk -> NamedChunk -> NP forall c d. (NamedIdea c, NamedIdea d) => c -> d -> NP `andIts` NamedChunk environment)] gsdSysContextP2 :: Contents gsdSysContextP2 = [Lbl] -> Contents foldlSPCol [ConceptChunk -> Lbl forall n. (HasUID n, NamedIdea n) => n -> Lbl phrase ConceptChunk pidC, String -> Lbl S "is self-contained. The only external interaction is" Lbl -> Lbl -> Lbl +:+. String -> Lbl S "with the user", String -> Lbl S "The responsibilities of the", NP -> Lbl forall n. NounPhrase n => n -> Lbl phraseNP (NamedChunk user NamedChunk -> NamedChunk -> NP forall c d. (NamedIdea c, NamedIdea d) => c -> d -> NP `andThe` NamedChunk system), String -> Lbl S "are as follows"] gsdTitle :: [Sentence] gsdTitle :: [Lbl] gsdTitle = [NamedChunk -> Lbl forall n. NamedIdea n => n -> Lbl titleize NamedChunk user Lbl -> Lbl -> Lbl +:+ String -> Lbl S "Responsibilities", ConceptChunk -> Lbl forall n. (HasUID n, NamedIdea n) => n -> Lbl phrase ConceptChunk pidC Lbl -> Lbl -> Lbl +:+ String -> Lbl S "Responsibilities"] gsdUsrResp :: [Sentence] gsdUsrResp :: [Lbl] gsdUsrResp = [String -> Lbl S "Feed inputs to the model", String -> Lbl S "Review the response of the" Lbl -> Lbl -> Lbl +:+ ConceptChunk -> Lbl forall n. (HasUID n, NamedIdea n) => n -> Lbl phrase ConceptChunk powerPlant, String -> Lbl S "Tune the controller gains"] gsdSysResp :: [Sentence] gsdSysResp :: [Lbl] gsdSysResp = [String -> Lbl S "Check the validity of the inputs", String -> Lbl S "Calculate the outputs of the" Lbl -> Lbl -> Lbl +:+ NP -> Lbl forall n. NounPhrase n => n -> Lbl phraseNP (ConceptChunk pidC ConceptChunk -> ConceptChunk -> NP forall c d. (NamedIdea c, NamedIdea d) => c -> d -> NP `and_` ConceptChunk powerPlant)] gsdSysContextList :: Contents gsdSysContextList :: Contents gsdSysContextList = UnlabelledContent -> Contents UlC (UnlabelledContent -> Contents) -> UnlabelledContent -> Contents forall a b. (a -> b) -> a -> b $ RawContent -> UnlabelledContent ulcc (RawContent -> UnlabelledContent) -> RawContent -> UnlabelledContent forall a b. (a -> b) -> a -> b $ ListType -> RawContent Enumeration (ListType -> RawContent) -> ListType -> RawContent forall a b. (a -> b) -> a -> b $ [Lbl] -> [ListType] -> ListType bulletNested [Lbl] gsdTitle ([ListType] -> ListType) -> [ListType] -> ListType forall a b. (a -> b) -> a -> b $ ([Lbl] -> ListType) -> [[Lbl]] -> [ListType] forall a b. (a -> b) -> [a] -> [b] map [Lbl] -> ListType bulletFlat [[Lbl] gsdUsrResp, [Lbl] gsdSysResp] gsduserCharacteristics :: Contents gsduserCharacteristics :: Contents gsduserCharacteristics = [Lbl] -> Contents foldlSP [String -> Lbl S "The end-user of", ConceptChunk -> Lbl forall n. (HasUID n, NamedIdea n) => n -> Lbl phrase ConceptChunk pidC, String -> Lbl S "is expected to have taken a course on Control Systems at an", String -> Lbl S "undergraduate level"]