Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fix dimension handling for matrix indexing (WIP) #292

Merged
merged 6 commits into from
Oct 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
250 changes: 132 additions & 118 deletions public/dimensional_analysis.py

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/PlotCell.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -633,12 +633,12 @@
</TooltipIcon>
{:else if !unitsValid($results[index][i].data[0].displayInputUnits)}
<TooltipIcon direction="right" align="end">
<span slot="tooltipText">X-axis upper and/or lower limit dimension error{$results[index][i].data[0].asciiInputUnits === "Exponent Not Dimensionless" ? ": Exponent Not Dimensionless": ""}</span>
<span slot="tooltipText">X-axis upper and/or lower limit dimension error{$results[index][i].data[0].asciiInputUnits.startsWith("Dimension Error:") ? $results[index][i].data[0].asciiInputUnits.slice(15) : ""}</span>
<Error class="error"/>
</TooltipIcon>
{:else if !unitsValid($results[index][i].data[0].displayOutputUnits)}
<TooltipIcon direction="right" align="end">
<span slot="tooltipText">Y-axis dimension error{$results[index][i].data[0].asciiOutputUnits === "Exponent Not Dimensionless" ? ": Exponent Not Dimensionless": ""}</span>
<span slot="tooltipText">Y-axis dimension error{$results[index][i].data[0].asciiOutputUnits.startsWith("Dimension Error:") ? $results[index][i].data[0].asciiOutputUnits.slice(15) : ""}</span>
<Error class="error"/>
</TooltipIcon>
{:else if $results[index][i].data[0].unitsMismatch}
Expand Down
4 changes: 2 additions & 2 deletions src/cells/FluidCell.ts
Original file line number Diff line number Diff line change
Expand Up @@ -294,10 +294,10 @@ export default class FluidCell extends BaseCell {
name: this.mathField.statement.name,
sympy: `${fluidFuncName}(0,0)`,
params: [],
isExponent: false,
isUnitlessSubExpression: false,
isFunctionArgument: false,
isFunction: false,
exponents: [],
unitlessSubExpressions: [],
implicitParams: [],
functions: [],
arguments: [],
Expand Down
Loading
Loading