Skip to content
Snippets Groups Projects
Commit 1009d0e7 authored by Amanda Ghassaei's avatar Amanda Ghassaei
Browse files

ui for simulation

parent 25ab786f
No related branches found
No related tags found
No related merge requests found
<% if(conductorGroups && conductorGroups.length > 0){ %>
Simulation Resolution: &nbsp;&nbsp;<input data-property="simulationRes" value="<%= simulationRes %>" placeholder="Resolution" class="form-control intInput eSim voltageInput" type="text"><br/><br/>
Dielectric Permittivity (k): &nbsp;&nbsp;<input data-property="dielectricPerm" value="<%= dielectricPerm %>" placeholder="k" class="form-control floatInput eSim voltageInput" type="text"><br/>
<label class="radio">
<input type="radio" <% if (visibleConductorGroup == -2){ %>checked<% } %> name="visibleConductorGroup" value="-2" data-toggle="radio" class="custom-radio eSim"><span class="icons"><span class="icon-unchecked"></span><span class="icon-checked"></span></span>
......@@ -32,12 +33,21 @@
<li><a class="eSim dropdownSelector" data-property="currentUnits" data-value="<%= key %>" href="#"><%= unit %></a></li>
<% }); %>
</ul>
</div><br/><br/>
<div class="inlineSwatch capacitance"></div>Capacitance:<br/>
<div class="inlineSwatch inductance"></div>Inductance:<br/><br/>
</div><br/><br/><br/>
<!--<div class="inlineSwatch inductance"></div>Inductance:<br/><br/>-->
Num Relaxation Steps: &nbsp;&nbsp;<input data-property="numRelaxationSteps" value="<%= numRelaxationSteps %>" placeholder="Num Steps" class="form-control floatInput eSim" type="text"><br/><br/>
<a href="#" id="calcEField" class="btn btn-block btn-lg btn-default"><% if(electricField){ %>Re-<% } %>Calculate Electric Field</a><br/>
<a href="#" id="calcCapacitance" class="btn btn-block btn-lg btn-default"><% if(globalCapacitance){ %>Re-<% } %>Calculate Capacitance</a><br/>
<a href="#" id="calcInductance" class="btn btn-block btn-lg btn-default"><% if(globalInductance){ %>Re-<% } %>Calculate Inductance</a><br/>
<div class="inlineSwatch capacitance"></div>Global Capacitance:<br/><br/>
<!--<a href="#" id="calcInductance" class="btn btn-block btn-lg btn-default"><% if(globalInductance){ %>Re-<% } %>Calculate Inductance</a><br/>-->
Visible Field:
<% _.each(visibleStaticSimTypes, function(simType, key){ %>
<label class="radio">
<input type="radio" <% if (key == visibleStaticSim){ %>checked<% } %> name="visibleStaticSim" value="<%= key %>" data-toggle="radio" class="custom-radio eSim"><span class="icons"><span class="icon-unchecked"></span><span class="icon-checked"></span></span>
<%= simType%>
</label>
<% }); %>
Simulation Z Height: &nbsp;&nbsp;<input data-property="simZHeight" value="<%= simZHeight %>" placeholder="Height" class="form-control intInput eSim" type="text"><br/><br/>
<% } else { %>
<div class="inlineWarning">No conductive groups detected, please navigate to previous tab and calculate.</div>
<% } %>
\ No newline at end of file
......@@ -16,6 +16,13 @@ define([], function(){
allVoltageUnits:{
1: "V",
0.001: "mV"
},
visibleStaticSimTypes: {
none: "None",
eField: "Electric Field",
charge: "Charge Distribution",
capacitance: "Capacitance"
}
}
......
......@@ -9,12 +9,22 @@ define(['underscore', 'backbone'], function(_, Backbone){
defaults:{
conductorGroups: null,//[{id: xx, current:xx, voltage:xx}]
visibleConductorGroup: -1,
globalCapacitance: null,
visibleConductorGroup: -1,//-2 = show everything, -1 = show all conductors
globalInductance: null,
voltageUnits: "1",
currentUnits: "0.001",
dielectricPerm: 1.00
dielectricPerm: 1.00,
simulationRes: 3,
simZHeight: 1,
//statics
electricField: null,
chargeField: null,
capacitanceField: null,
globalCapacitance: null,
numRelaxationSteps: 5,
visibleStaticSim: "none"//eField, charge, capacitance
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment