# Glossary This glossary defines the terms used for solve inputs and results. The definitions describe how `jcmsuite` uses each term. ```{glossary} Project A JCM project file or template passed to {func}`solve `. A project with all values filled in uses the `.jcmp` extension. A project {term}`template ` uses the `.jcmpt` extension and is rendered before the solve runs. See [Solving Projects](core/solve/index.md). ```python import jcmsuite result = jcmsuite.solve("project.jcmp") ``` Ordered project bundle A {func}`solve ` input that contains more than one {term}`project` in an ordered sequence. `jcmsuite` runs the projects in the given order and treats them as one solve unit. A later project can use files produced by an earlier project. See [Ordered Project Bundles](core/solve/bundles.md). ```python import jcmsuite bundle = jcmsuite.solve([ "prepare.jcmp", "analyze.jcmp", ]) analysis_result = bundle[1] ``` Project support file An input file used with a {term}`project` while the solve runs. The supported files are `layout.jcm`, `grid.jcm`, `materials.jcm`, `sources.jcm`, and `boundary_conditions.jcm`. `jcmsuite` can render `.jcmt` versions of `layout.jcm`, `materials.jcm`, `sources.jcm`, and `boundary_conditions.jcm`. `grid.jcm` has no `.jcmt` variant. See [Selecting Project Support Files](core/solve/index.md). ```text project.jcmp layout.jcm materials.mie.jcm sources.jcm ``` Templating The process of rendering a {term}`project` or {term}`project support file` from a template. A template can contain JCM text, replacements based on {term}`project keys`, and Python blocks. `jcmsuite` renders `.jcmt` files to `.jcm` files and `.jcmpt` files to `.jcmp` files. See [Templating](project_tools/templating.md). A template can contain a printf-style place for a project keys value: ```jcm Radius = %(radius)e ``` Pass the value with `keys=`: ```python result = jcmsuite.solve( "project.jcmp", keys={"radius": 0.33}, ) ``` JCMT pattern An optional choice for a {term}`project support file`. For {func}`solve("project.jcmp") `, the default selects file names without a suffix. For {func}`solve("project.jcmp", jcmt_pattern="mie") `, the solve selects files such as `layout.mie.jcm` before `layout.jcm`. See [Selecting Project Support Files](core/solve/index.md). The JCMT pattern selects both `.jcmt` templates and plain `.jcm` files. It does not select `project.mie.jcmp` as an alternate project start file. `project.jcmp` remains the {term}`project` file. ```python result = jcmsuite.solve( "project.jcmp", jcmt_pattern="mie", ) ``` Project keys Named values used when filling a JCM template. Pass one set of {term}`project keys` to {func}`solve ` with `keys=`. The names must match the places for values in the template. See [Project Key substitution](project_tools/templating.md). ```python import jcmsuite project_keys = {"radius": 0.5} result = jcmsuite.solve("project.jcmp", keys=project_keys) ``` Batched project keys A sequence of sets of {term}`project keys` passed to {func}`solve ` with `keys=`. The sets are handled in input order, and the result is a {class}`BatchSolveResult `. See [Batched Solves](core/solve/batched.md). ```python import jcmsuite batched_project_keys = [ {"radius": 0.3}, {"radius": 0.4}, {"radius": 0.5}, ] batch = jcmsuite.solve("project.jcmp", keys=batched_project_keys) ``` Filter function A function that receives one set of {term}`project keys` and returns `True` when the command must select that {term}`Resultbag entry`. Pass a filter function to {meth}`resultbag.management.remove `. See [Resultbag Management](resultbag/management.md). ```python resultbag.management.remove( filter_function=lambda project_keys: project_keys.get("material") == "Si" ) ``` Solve results The values returned by {func}`solve ` or {meth}`get_results `. Solve results can contain data for one {term}`project`, several sets of {term}`project keys`, or an {term}`ordered project bundle`. Use the [Working With Results](results/index.md) guide to inspect and export this data. See the [Result API](reference/results.md) for the exact return types. Fieldbag A native JCMsuite file containing computed field data. A solution fieldbag holds the saved solution used for postprocessing. For main-solve results, {attr}`file ` gives the solution fieldbag's path. See [SolveResult Access](results/solveresult/index.md). SolveResult The return type for one {term}`project` and no or one set of {term}`project keys`. Use its attributes to access costs, eigenvalues, postprocesses, logs, and result information. See {class}`SolveResult ` and [SolveResult Access](results/solveresult/index.md). BatchSolveResult The return type for one {term}`project` and {term}`batched project keys`. It preserves the input order and adds batch selection and export behavior. See [Batched Results](results/batched.md). The API type is {class}`BatchSolveResult `. BundledSolveResult The return type for one {term}`ordered project bundle` and no or one set of {term}`project keys`. Select a {term}`project` to work with its result as a {class}`SolveResult `. See [Bundled Results](results/bundled.md). ```python bundle = jcmsuite.solve(["prepare.jcmp", "analyze.jcmp"]) result = bundle[1] ``` BundledBatchSolveResult The return type for one {term}`ordered project bundle` repeated over {term}`batched project keys`. Select a {term}`project` to work with its results as a {class}`BatchSolveResult `. See [Bundled Results](results/bundled.md). ```python bundle_batch = jcmsuite.solve( ["prepare.jcmp", "analyze.jcmp"], keys=[{"radius": 0.3}, {"radius": 0.5}], ) analysis_batch = bundle_batch[1] ``` Submission A solve handle sent to a daemon that you complete later with {meth}`wait `. Use a submission when the solve must continue while the code performs other operations. See [Submit And Wait](runtime/daemon/submit_wait.md). ```python submission = jcmsuite.solve( "project.jcmp", dispatch="submit", ) result = submission.wait() ``` Resultbag entry One stored result record in a {term}`Resultbag`, identified by {term}`project keys` and an optional {term}`JCMT pattern`. A Resultbag can contain one entry for each set of project keys and multiple versions with a suffix. See [Resultbag](resultbag/index.md). Resultbag Storage for solved results and access to saved runs. A {class}`Resultbag ` stores entries in a `.jcmrb` file and can reuse matching results in later solves. See [Resultbag](resultbag/index.md). ```python import jcmsuite with jcmsuite.results.Resultbag("results.jcmrb") as resultbag: result = jcmsuite.solve( "project.jcmp", keys={"radius": 0.5}, resultbag=resultbag, ) ``` Base fields The field values without parameter derivatives in a field export. Base fields do not include derivative fields. Use the {attr}`base ` attribute of a {class}`FieldExportPayload ` to access them. See {class}`FieldExportPayload ` and [Field Exports](results/solveresult/field_exports.md). ```python base_fields = fields.base ``` ```