Commit Graph

  • a931252e9c Convert render system to sample the simulation at a fixed resolution; no more decimation Colin 2020-09-25 19:40:49 -07:00
  • 341acf367d Explain how the cell is generalized to 3d Colin 2020-09-25 19:29:10 -07:00
  • 3d9a78efab Change from Array2 to Array3 with depth = 1 Colin 2020-09-22 12:03:59 -07:00
  • 6d77c85179 Abstract coordinates behind a Coord type Colin 2020-09-22 11:23:58 -07:00
  • b96f9c5dcc step_e now makes the boundary condition explicit as well Colin 2020-09-22 10:13:45 -07:00
  • 2549ac9940 step_h uses optional left/down nodes. Colin 2020-09-22 08:56:41 -07:00
  • f21c43d655 Misc measurement improvements Colin 2020-09-20 21:56:30 -07:00
  • 253ffe585f Fix current measurement Colin 2020-09-20 11:53:05 -07:00
  • d713c79bbd Improve the UPML parameters by properly summing the axis conductivities in the corners Colin 2020-09-19 20:10:10 -07:00
  • f6e4ed8cb9 Add a UPML boundary condition (needs improving in the corners, though) Colin 2020-09-19 20:02:11 -07:00
  • ae93101676 Allow conductivity to be specified as a vector Colin 2020-09-19 19:33:11 -07:00
  • a7899d9be1 Add a toroid example where the B field is actually directed circularly inside the toroid Colin 2020-09-18 22:23:37 -07:00
  • 1d303df409 Fix rendering to render (Bx,By,Ez). Also fix an infinite loop due to rounding errors in MHCurve Colin 2020-09-18 22:22:54 -07:00
  • 8a70276c78 Make measurements also be 3d Colin 2020-09-18 17:11:05 -07:00
  • 7029c8bcfa SimState *should* be capable of simulating either ex/ey/bz or bx/by/ez type planes Colin 2020-09-17 23:02:28 -07:00
  • a1f5b96ae1 Model the H/B field in 3d, mostly Colin 2020-09-17 22:53:12 -07:00
  • 54b23a0494 step_h is 2.5d; need to update material trait Colin 2020-09-17 21:09:37 -07:00
  • 144c7a85d4 CellState now holds the full e field as a 3-vector (was a 2-vector) Colin 2020-09-17 20:58:25 -07:00
  • d65dab763f Rewrite the step_e function to handle up to 3 dimensions Colin 2020-09-17 20:48:05 -07:00
  • c0174b6483 Rename flt::Priv/Pub to Real and Flt Colin 2020-09-13 22:45:02 -07:00
  • 3e12f5384d Update benchmarks after switch from f64 -> f32 as default Colin 2020-09-13 22:38:42 -07:00
  • f50dbf7d4e Make the float depth compile-time configurable Colin 2020-09-13 22:38:00 -07:00
  • d4334565a7 Add an example where the ferromagnet is a ring around the conductor Colin 2020-09-13 18:33:31 -07:00
  • 75008a6bd5 Consolidate duplicate 3r1 material definitions into mat::db module Colin 2020-09-13 18:32:43 -07:00
  • 0581820388 Update benchmarks Colin 2020-09-13 18:25:28 -07:00
  • 6664fea7c2 Use unchecked floats for release builds Colin 2020-09-13 18:22:58 -07:00
  • 53da11c874 Assorted minor aesthetic touchups Colin 2020-09-13 17:19:44 -07:00
  • 003dde12a0 Record perf as it changes Colin 2020-09-13 17:08:52 -07:00
  • cb9f413710 Add energy measurement Colin 2020-09-13 17:08:33 -07:00
  • 3f7ab1a39a Simplify the SimState decimation logic. Colin 2020-09-13 16:29:18 -07:00
  • b4b0fde8af Use ndarray's parallelism features Colin 2020-09-12 20:37:31 -07:00
  • f4cdd1240d Switch to Criterion for benchmarking Colin 2020-09-12 19:47:38 -07:00
  • 896ac4e655 Add a benchmark for Driver::step Colin 2020-09-12 11:17:57 -07:00
  • 0fc973b409 Toy around with some other setups. Colin 2020-09-09 22:41:41 -07:00
  • 4d8ef1c9f3 Add a measurement for magnetization Colin 2020-09-07 21:58:07 -07:00
  • 995b5b7c54 Render current as a vector field Colin 2020-09-07 21:34:33 -07:00
  • 0c6a01c671 Make vector field rendering logic generic Colin 2020-09-07 21:14:26 -07:00
  • 0b9861d619 Cleanup RenderSteps Colin 2020-09-07 21:07:26 -07:00
  • d611e822dd Add a 'Measurement' concept, e.g. to display current at a point. Colin 2020-09-07 20:14:41 -07:00
  • fbca8622df Remove usize casts Colin 2020-09-07 17:54:50 -07:00
  • 5d61765a84 Move the Driver away from the builder pattern and use mutators instead Colin 2020-09-07 17:46:42 -07:00
  • 14fa68bfb2 Snapshot and decimate before rendering; add an explicit boundary layer Colin 2020-09-07 17:42:05 -07:00
  • 5d9c086137 Parameterize the SimState over the Material Colin 2020-09-06 12:23:35 -07:00
  • b7716d2dea Repurpose mat::Conductor to mat::Static Colin 2020-09-06 12:18:31 -07:00
  • c8ac13f1b2 3-fold increase in simulation stepping by processing whole rows in parallel instead of processing every individual cell in parallel Colin 2020-09-06 11:37:45 -07:00
  • d26b4197af Introduce a Driver abstraction to encapsulate the SimState and the Renderers Colin 2020-09-06 11:24:48 -07:00
  • 3b1397e90c Implement a NullRenderer Colin 2020-09-05 23:41:28 -07:00
  • 8ce5ef1c07 Parallelize the simulation loop Colin 2020-09-05 23:32:02 -07:00
  • 313e44c978 Restructure the simulation loop to make it easier to parallelize in future patches Colin 2020-09-05 23:20:50 -07:00
  • fc14961d32 Render simulations to the terminal and to disk simultaneously Colin 2020-09-05 17:43:51 -07:00
  • 861d7430e2 Tune some rendering constants Colin 2020-09-05 14:44:26 -07:00
  • 08461267be Properly cast from RGB -> YCbCr Colin 2020-09-05 14:31:29 -07:00
  • fd4e10b0d0 add transparency to vector fields Colin 2020-09-05 14:21:32 -07:00
  • d6d42330c6 Apply a log-like scaling to all values being rendered Colin 2020-09-05 14:06:53 -07:00
  • 98f9cf4df5 Use field lines to display the electric field Colin 2020-09-05 10:16:19 -07:00
  • 8e71e02ac1 Fix clippy errors Colin 2020-09-04 16:49:24 -07:00
  • a48481db0d Share the frame render logic across all display backends (color term, Y4M video) Colin 2020-09-04 16:42:29 -07:00
  • 6d7bb5becb Generalize rendering into a trait Colin 2020-09-04 16:12:33 -07:00
  • 99cb824a36 Implement a mp4 renderer Colin 2020-09-03 22:34:56 -07:00
  • 4cd9bb86bb Add tests for demagnetization across edges Colin 2020-08-28 12:50:36 -07:00
  • 48f362cb3c Simplify the MHCurve tests Colin 2020-08-28 12:42:50 -07:00
  • 29a1b066cc Test magnetization across edges Colin 2020-08-28 12:37:14 -07:00
  • c38f06a02c Test demagnetization Colin 2020-08-28 12:29:50 -07:00
  • 6b509b6994 Tests for magnetizing in the negative direction Colin 2020-08-28 12:19:38 -07:00
  • 65c6f6caa4 Fix movement along a rising edge Colin 2020-08-28 12:02:43 -07:00
  • 8d4d23b1c8 Add some tests for the MHCurve material Colin 2020-08-28 11:37:18 -07:00
  • aff8764114 Implement a BH-curve material (example material is 3R1) Colin 2020-08-27 23:41:57 -07:00
  • b25ccc2471 Factor mat.rs and sim.rs out of lib.rs Colin 2020-08-27 19:17:07 -07:00
  • 57258eb6cc Advance the E field by using Ampere's circuital law MACROSCOPIC equation Colin 2020-08-27 15:23:52 -07:00
  • f948820edf Implement a BHCurve Colin 2020-08-27 14:41:35 -07:00
  • e9f7e739ff Use enum_dispatch to simplify the GenericMaterial implementation Colin 2020-08-27 13:22:28 -07:00
  • 6ac0dafa47 Have the GenericMaterial be an enum to make it easier to replace the ferromagnet model Colin 2020-08-27 12:51:12 -07:00
  • c68964403d Fix COMSOL ferromagnet model, and make a new example for it Colin 2020-08-22 22:35:45 -07:00
  • f4d8ffdf34 Untested ferromagnetic model Colin 2020-08-22 21:55:27 -07:00
  • 3830cf2ef8 Store magnetic state as H_z instead of B_z Colin 2020-08-22 21:17:03 -07:00
  • 5677670d05 Fix the incorrect expansion of E about T in Cell::step_e Colin 2020-08-22 13:50:30 -07:00
  • dff8166906 Format these math comments so that they render properly for a tex-aware editor Colin 2020-08-16 20:14:46 -07:00
  • 4bfe282c36 cleanup: use consts::real::HALF when possible Colin 2020-07-31 19:02:17 -07:00
  • 72c2ee599e Track the simulation time, and configure the feature size Colin 2020-07-31 19:01:00 -07:00
  • 5e4699b3e6 Fix the conductivity error (was calculating the wrong timestep) Colin 2020-07-31 18:46:19 -07:00
  • 5388658b00 Add [broken] conductivity support Colin 2020-07-31 18:03:40 -07:00
  • 56cc5980dd Demo a B-imulse, because it behaves more symmetrically Colin 2020-07-25 00:27:58 -07:00
  • 1d9aa738ac Render just the B field: it gives a better visualization here Colin 2020-07-24 23:39:07 -07:00
  • 2e92980113 Buffer the rendering for better framerates; create a more useful example Colin 2020-07-24 23:25:16 -07:00
  • 5360d2c6d3 Add a 2d color-based renderer Colin 2020-07-16 00:31:20 -07:00
  • b890d8dc3a Fix the math errors so that 2d simulations appear to now conserve energy. Colin 2020-07-15 23:34:51 -07:00
  • a82c2f60e7 broken: expand to two dimensions. Colin 2020-07-14 23:26:27 -07:00
  • 80cb3a9d52 Add a color terminal renderer Colin 2020-07-12 23:00:54 -07:00
  • 52c2b5be5a Render the B/E fields in a way that's a little more insightful Colin 2020-07-12 21:52:20 -07:00
  • 2174113e7d Fix the inverted sign so that the energy looks reasonable now Colin 2020-07-12 21:35:40 -07:00
  • 0ea06af0b0 Add a way to render the state Colin 2020-07-12 21:16:42 -07:00
  • ccd7b45fc8 Implement time stepping of both the B and E field Colin 2020-07-12 20:50:58 -07:00
  • 5e237800b4 Initial commit Colin 2020-07-12 19:14:13 -07:00