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

Development #5

Merged
merged 84 commits into from
Feb 5, 2024
Merged

Development #5

merged 84 commits into from
Feb 5, 2024

Commits on Jul 15, 2023

  1. docs: adding documentation

    [Documentation]
    
    adding information about using testing example
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 15, 2023
    Configuration menu
    Copy the full SHA
    754a885 View commit details
    Browse the repository at this point in the history

Commits on Jul 16, 2023

  1. docs: adding documentation

    [Documentation]
    
    ``include/constants.h``
    
    adding commented code for information about variable ``chop``, `maxn`, `eps`
    
    ``include/internal/classFunction/iomanip.h``
    
    ``IDisplay`` class is an abstract class the provides a generic interface for displaying object . the ``Display_Impl_`` class concrete class that implements the ``IDisplay`` interface for Eigen matrices.
      - the first constructor takes an eigen matrix as input and double as a parameter, the double parameter specifies amount of chopping that should be done whne displaying the matrix
      - the second constructure takes a complex number as input an a double as parameter, the double parameter specifieds tha amount of chopping that soubld be done when displaying the complex number
    
    ``include/traits.h``
    
    adding preprocessor directive to check the version of the GCC compiler
    
    ``clara_test/tests/traits.cpp``
    
    adding testing for test ``traits.h``
    
    ``clara_test/run_test``
    
    adding support for macOs and support for ubuntu and arch based package
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 16, 2023
    Configuration menu
    Copy the full SHA
    bdcc821 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    b21993f View commit details
    Browse the repository at this point in the history
  3. fix: fixing directories

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 16, 2023
    Configuration menu
    Copy the full SHA
    eeb7a50 View commit details
    Browse the repository at this point in the history
  4. fix: fixing directories

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 16, 2023
    Configuration menu
    Copy the full SHA
    c6a4a9c View commit details
    Browse the repository at this point in the history
  5. chroe: evects function (#1)

    added necessary using statements to define ComplexScalar and ComplexMatrix types for handling complex numbers.
    replaced dyn_mat with Eigen::Matrix to match the type of rA.
    improved the check for matrix size by comparing the rows and columns separately.
    changed rA.template cas<cplx>() to rA.template cast<ComplexScalar>() to handle complex matrix conversion.
    khairanabila authored Jul 16, 2023
    Configuration menu
    Copy the full SHA
    f96ab26 View commit details
    Browse the repository at this point in the history

Commits on Jul 17, 2023

  1. chore(add): adding more information and unitest

    [Documentation]
    
    adding reference used in clara
    adding unitest for mac os
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 17, 2023
    Configuration menu
    Copy the full SHA
    81a8aaa View commit details
    Browse the repository at this point in the history
  2. fix: fix interpreter

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 17, 2023
    Configuration menu
    Copy the full SHA
    f77e840 View commit details
    Browse the repository at this point in the history
  3. fix: fix interpreter

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 17, 2023
    Configuration menu
    Copy the full SHA
    e900dfe View commit details
    Browse the repository at this point in the history

Commits on Jul 21, 2023

  1. chore(feat): improvement exception function call

    [Documentation]
    
    make expection hierarchy for custom exceptions, this exception based on the standard ``std::exception`` class, provide a mechanisem for creating custom exception types with specific description that can be thrown and caught in the application code
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 21, 2023
    Configuration menu
    Copy the full SHA
    f13be23 View commit details
    Browse the repository at this point in the history
  2. chore(feat): update testing/_test.cpp

    [Documentation]
    
    testing quantum bit manipulation
    
    - the code initialize the number of bits and the number of trials. it creates a vector of vectors called `indices`, where each sub-vector contains indices representing bits for trial operations
    - it perform a series trials using `TOF` operation on the `Bit_circuit`, the `TOF` operation applies controlled NOT operation on the specified bits in the circuit
    - after the trials the code display the initial and final states of the bit circuit as well as the hamming weight ( number of set bits )
    - create `ket` and `bra` instance representing quantim states and display them using the `disp` function
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 21, 2023
    Configuration menu
    Copy the full SHA
    ae4feab View commit details
    Browse the repository at this point in the history

Commits on Jul 22, 2023

  1. chore(feat): update testing/grover_search.cpp

    [Documentation]
    
    grover algorithm starts with equal superposition of all possible states, then iteratively applies the oracle and diffusion operator to amplify the probability of the marked state while reducing the probability of other states, after a sufficient number of iterations, measuring the final state gives a high probability of obtaining the marked state
    
    fix: fixing ``clara/include/operations.h``
    
    [Documentation]
    
    fixing code to provide a flexible efficient way to apply a controlled quantum gate a quantum state, allowing for various types of control and target subsystem configurations. the use of eigen library provides efficient matrix operations, and the code is optimized for performance using multi-threading
    
    fix: fixing ``clara/include/random.h``
    
    fixing function to provide a convenient and safe way to generate random indices whithin specified range, making use of the standard library random number generation capabilitesm use of thread local random number generators is particularly helpful multi-threading applications to avoid potential concurency issues
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 22, 2023
    Configuration menu
    Copy the full SHA
    bad07d9 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    358b33c View commit details
    Browse the repository at this point in the history
  3. docs: adding documentation

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 22, 2023
    Configuration menu
    Copy the full SHA
    bf3af3d View commit details
    Browse the repository at this point in the history

Commits on Jul 23, 2023

  1. Configuration menu
    Copy the full SHA
    5be026c View commit details
    Browse the repository at this point in the history
  2. fix: typo spelling run

    slowy07 authored Jul 23, 2023
    Configuration menu
    Copy the full SHA
    50aae54 View commit details
    Browse the repository at this point in the history
  3. fix: header fix test on macOS clara

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 23, 2023
    Configuration menu
    Copy the full SHA
    ce0a334 View commit details
    Browse the repository at this point in the history
  4. fix: header fix test on macOS clara

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 23, 2023
    Configuration menu
    Copy the full SHA
    1b897fe View commit details
    Browse the repository at this point in the history
  5. fix: header fix test on macOS clara

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 23, 2023
    Configuration menu
    Copy the full SHA
    1b13dd8 View commit details
    Browse the repository at this point in the history
  6. fix: header fix test on macOS clara

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 23, 2023
    Configuration menu
    Copy the full SHA
    f13e192 View commit details
    Browse the repository at this point in the history
  7. fix: header fix test on macOS clara

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 23, 2023
    Configuration menu
    Copy the full SHA
    17300a9 View commit details
    Browse the repository at this point in the history
  8. fix: header fix test on macOS clara

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 23, 2023
    Configuration menu
    Copy the full SHA
    458eee6 View commit details
    Browse the repository at this point in the history
  9. fix: remove temporary macos

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 23, 2023
    Configuration menu
    Copy the full SHA
    7b98ffc View commit details
    Browse the repository at this point in the history

Commits on Jul 28, 2023

  1. Configuration menu
    Copy the full SHA
    8327109 View commit details
    Browse the repository at this point in the history

Commits on Jul 31, 2023

  1. docs: update Documentation

    [Documentation]
    
    code documentation is a collection of documents and code comments explaining how code works and how to use it.
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    4269c26 View commit details
    Browse the repository at this point in the history
  2. docs: update Documentation

    [Documentation]
    
    code documentation is a collection of documents and code comments explaining how code works and how to use it.
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    00c50b2 View commit details
    Browse the repository at this point in the history
  3. chore: adding docker testing

    [Documentation]
    
    adding docker test to testing scale lib into any environment
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    164e790 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    02a6ca4 View commit details
    Browse the repository at this point in the history
  5. fix: identation action test

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    54dfcfc View commit details
    Browse the repository at this point in the history
  6. chore: adding operation testing

    [Documentation]
    
    AllTest: applies a custom quantum gate represented by the Pauli X gate (`gt.x`) to a single qubit state (`ket psi = 1_ket`) and checks if the result matches the expected state ('0_ket') and checks if the result matches the expected state (`0_ket`)
    
    EmptyControl: test case validation the functionally of applying controlled quantum gates (`U`) to a pure state (`ket psi`) and a density matrix (`cmat rho`). it randomly generates a quantum state and applies the random quantum gate `u` to both he pure state and the corresponding density matrix. the result are compared to check if they are approximately equal within a specified tolerance
    
    [Documentation random testing clara]
    
    AllTest: generate two `bigint` value `a` and `b`, both set to 42. it then calls the `clara::rand` function with `a` and `b` as input parameter. the test verifies that the output of the `clara:rand` function falls within the range [a, b] (inclusive), and thus, it is expected to be equal to either `a` or `b`
    
    Average: further examines the random double generation by calculation by calculating the average of the generated `N` random double values within range [-10, 10]. the average value is then checked to ensure that its approximately close to 0 with a tolerance of 2e-1
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    c15c3cf View commit details
    Browse the repository at this point in the history
  7. chore: trying update code with macOS test clara

    [Documentation]
    
    testing on macOS according issue #4
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    615b878 View commit details
    Browse the repository at this point in the history
  8. fix: environment changes

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    152fe86 View commit details
    Browse the repository at this point in the history
  9. fix: try use xcode --install

    referenced issues #4
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    44b519d View commit details
    Browse the repository at this point in the history
  10. fix: try use xcode --install

    referenced issues #4
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    4e5006b View commit details
    Browse the repository at this point in the history
  11. fix: fixing cmake

    referenced issues #4
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    fd6b7eb View commit details
    Browse the repository at this point in the history
  12. fix: testing timer

    according #4
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    43e85ba View commit details
    Browse the repository at this point in the history
  13. fix: testing timer

    according #4
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    04f7144 View commit details
    Browse the repository at this point in the history
  14. fix: testing timer

    according #4
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    4dcae5a View commit details
    Browse the repository at this point in the history
  15. docs: update documentation

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Jul 31, 2023
    Configuration menu
    Copy the full SHA
    6822dc0 View commit details
    Browse the repository at this point in the history

Commits on Aug 2, 2023

  1. docs: adding more documentation

    [Documentation]
    
    adding more documentation on ``include``
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 2, 2023
    Configuration menu
    Copy the full SHA
    5f87806 View commit details
    Browse the repository at this point in the history

Commits on Aug 3, 2023

  1. chore: testing adding action environment windows test

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    34a6be6 View commit details
    Browse the repository at this point in the history
  2. fix: test with specific command to test on windows

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    89a5639 View commit details
    Browse the repository at this point in the history
  3. fix: test rmdir to rd

    according information from microsoft official website : https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/rd
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    6428c16 View commit details
    Browse the repository at this point in the history
  4. fix: test rd to rmdir with shell powershell

    according information from microsoft official website : https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/rd
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    4baa0e3 View commit details
    Browse the repository at this point in the history
  5. fix: test to adding path from eigen was installed

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    a429456 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    0392ebe View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    7e350a0 View commit details
    Browse the repository at this point in the history
  8. fix: attemp fixing on directory command

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    13347d1 View commit details
    Browse the repository at this point in the history
  9. fix: try to adding cmake list for windows

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    975e069 View commit details
    Browse the repository at this point in the history
  10. fix: typo

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    f3e5e36 View commit details
    Browse the repository at this point in the history
  11. fix: call cmake

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    f53e2a0 View commit details
    Browse the repository at this point in the history
  12. fix: call cmake

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    44ee71a View commit details
    Browse the repository at this point in the history
  13. fix: call cmake

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    2372046 View commit details
    Browse the repository at this point in the history
  14. fix: call cmake

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    b389a7b View commit details
    Browse the repository at this point in the history
  15. fix: remove windows test and adding on arch latest

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    f70f221 View commit details
    Browse the repository at this point in the history
  16. fix: adding

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    48430b8 View commit details
    Browse the repository at this point in the history
  17. fix: adding separate the install test

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    cbf5c59 View commit details
    Browse the repository at this point in the history
  18. fix: adding arch based by separated the test

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    7fc1eb3 View commit details
    Browse the repository at this point in the history
  19. fix: adding arch based by separated the test

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    a46eb5b View commit details
    Browse the repository at this point in the history

Commits on Aug 4, 2023

  1. chore: update shell test

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 4, 2023
    Configuration menu
    Copy the full SHA
    a558f5b View commit details
    Browse the repository at this point in the history

Commits on Aug 5, 2023

  1. fix: rename testing filename

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 5, 2023
    Configuration menu
    Copy the full SHA
    b46e154 View commit details
    Browse the repository at this point in the history

Commits on Aug 7, 2023

  1. chore: testing GPU support install

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    1bb72d7 View commit details
    Browse the repository at this point in the history
  2. chore: attemp (1) test gpu CUDA

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    35ec562 View commit details
    Browse the repository at this point in the history
  3. chore: attemp (2) test gpu CUDA

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    ea40b0b View commit details
    Browse the repository at this point in the history
  4. chore: attemp (3) test base on windows

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    189bd37 View commit details
    Browse the repository at this point in the history
  5. chore: attemp (4) test base on windows

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    f4c4701 View commit details
    Browse the repository at this point in the history
  6. chore: attemp (5) test base on windows

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    01b8ca0 View commit details
    Browse the repository at this point in the history
  7. chore: attemp (6) test base on windows

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    c6ecdbc View commit details
    Browse the repository at this point in the history
  8. chore: attemp (7) test base on windows

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    705b872 View commit details
    Browse the repository at this point in the history
  9. fix: fixing CWE-120, CWE-20

    [Documentation]
    
    information CWE-120: The product copies an input buffer to an output buffer without verifying that the size of the input buffer is less than the size of the output buffer, leading to a buffer overflow.
    
    fix: typo on input_output.h
    fix: delete windows test
    
    chore: adding ``input_output_testing``
    
    [Documentation]
    adding unitesting using google test framwork to test the functionallity of the `save` and `load` function from `clara` library `input_output`
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    0e5a02b View commit details
    Browse the repository at this point in the history

Commits on Aug 8, 2023

  1. docs: adding documentation code

    chore: update ``experimental_test``
    [Documentation]
    The `experimental_test.h` header file defines classes and functions for simulating quantum circuits. The classes provided are:
    - `clara::experimental::ClaraCircuit`: Represents a quantum circuit for simulation.
    - `clara::experimental::LogicalCircuit`: Represents a logical circuit with gates and their details.
    - `clara::experimental::Test`: Represents a test class for quantum circuit operations.
    ClaraCircuit Class
    This class represents a quantum circuit for simulation. It provides functionalities for creating, manipulating, and simulating quantum circuits.
    
    Class: `clara::experimental::ClaraCircuit<T>`
    - Constructor:
      Initializes a quantum circuit.
      Parameters:
      - `number_qubit`: Number of qubits in the circuit.
      - `number_classical`: Number of classical bits in the circuit.
      - `dimension`: Dimension of the quantum state space (default: 2).
    - Methods:
      - `measure(std::vector<idx> subsys)`: Measures specified subsystem qubits.
      - `measure_all()`: Measures all unmeasured qubits in the circuit.
      - `apply(const cmat& gate, const std::vector<idx>& subsys)`: Applies a quantum gate to specified subsystem qubits.
      - `apply_all(const cmat& gate)`: Applies a quantum gate to all unmeasured qubits.
      - `reset()`: Resets the quantum circuit to its initial state.
      - Accessor methods for retrieving circuit information:
        - `dimension()`: Returns the dimension of the quantum state space.
        - `get_number_qubit()`: Returns the number of qubits in the circuit.
        - `get_number_classical()`: Returns the number of classical bits in the circuit.
        - `get_size()`: Returns the total size of the circuit (qubits + classical bits).
        - `get_num_measured_qubits()`: Returns the number of measured qubits.
        - `get_num_active_qubits()`: Returns the number of active (unmeasured) qubits.
        - `get_psi()`: Returns the current quantum state of the circuit.
        - `get_results()`: Returns the measured results as a vector of indices.
        - `get_results_as_N()`: Returns the measured results as an integer in base-N representation.
        - `bits()`: Returns a reference to the classical bits associated with the circuit.
    LogicalCircuit Class
    This class represents a logical circuit with gates and their details.
    
    Class: `clara::experimental::LogicalCircuit`
    - Methods:
      - `add(const cmat& gate, const std::string& gate_name, const idx_vec& ctrl, const idx_vec& target)`: Adds a gate to the logical circuit.
      - `gate_gate_count()`: Returns the total count of gates added to the logical circuit.
      - `display(std::ostream& os) const`: Displays the logical circuit's gates and their details.
    
    chore: add more testing for make sure code works very well
    
    chore: adding reversible
    [Documentation]
    provided functionalities to work with dynamic bitset, perform bitwise operations, and represent bit circuits with various gate operations
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 8, 2023
    Configuration menu
    Copy the full SHA
    bda75ac View commit details
    Browse the repository at this point in the history
  2. fix: testing timer

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 8, 2023
    Configuration menu
    Copy the full SHA
    365ae9b View commit details
    Browse the repository at this point in the history

Commits on Aug 10, 2023

  1. chore: more upgrade stuff

    [Documentation]
    change from `pi` to `std::pi`
    
    docs: add more documentation `gates.h`
    fix: fixing entanglement which testing always return `out of range`
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 10, 2023
    Configuration menu
    Copy the full SHA
    81fd7ea View commit details
    Browse the repository at this point in the history

Commits on Aug 11, 2023

  1. chore: add quantum operation

    [Documentation]
    
    this code demonstrate various quantum channels using clara lib. it perform operations on a quantum state, such as partial transpose, measurement channels application and entropy computation.
    `performChannelsOperations()`:
      - step process
        - create the initial state `|00⟩ + |11⟩` and display it
        - perform partial transpose on the first subsystem of the state and display eigen values
        - set up a measurement channels with two kraus operators (pauli Z operatios for `|0⟩` and `|11⟩`)
        - apply the measurement channels to first subsystem and display the resulting state
        - partially trace down the second subsystem and display the resulting state.
        -compute and diplasy the von-neummann entropy of the final state.
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 11, 2023
    Configuration menu
    Copy the full SHA
    64744bc View commit details
    Browse the repository at this point in the history

Commits on Aug 16, 2023

  1. docs: adding documentation on functions.h

    [Documentation]
    
    function applies a scalar function element-wise to each entry of the input matrix 'A'. the result is a new matrix of the same dimensions, where each entry is the result of applying the provided scalar function to the corresponding entry in 'A'.
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 16, 2023
    Configuration menu
    Copy the full SHA
    764cf7a View commit details
    Browse the repository at this point in the history

Commits on Aug 19, 2023

  1. chore: adding quantum fourier transform

    [Documentation]
    
    adding algorithm that can be used to efficiently transform a quantum state from one basis to another.
    - Command Line Argument
      the code check if exactly two command line arguments are provided, if not it prints an errpr message and exists the program
    - Extracting Command Line Arguments
      - the number CPU cores to use (`num_core`) and the number qubits in quantum system (`n`) are extracted from the command line arguments
    - Setting OpenMP Threads
      - the number of OpenMP threads to use for parallel processing is set to `num_core`
    - Creating Quantum State Vector
      - A vector `qubits` is created to store indices
      - A quantum state vector `psi` is created using `mket` function with the qubit indices.
      - An initial copy `result` of the quantum state is also created
    - Measuring Execution Time
      - A `Timer` object `t` is created to measure the execution time
    - Quantum operations
      - A loops iterates over each qubit index
      - A hadamard gate (`gt.H`) applied to each qubit
      - Another Nested llop applies controlled-phase gate, where the control and target qubits are determined by the loop indices
      - The gate are applied to the `result` quantum state vector
    - Qubit Swap Operations
      - Another loop swaps qubit state using the `gt.SWAP` gate
      - Qubit at specific indices are swapped
    - Printing Result
      - the program prints the number of CPU cores used, the number of qubits, and the execution time measured by the timer
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 19, 2023
    Configuration menu
    Copy the full SHA
    443601b View commit details
    Browse the repository at this point in the history

Commits on Aug 21, 2023

  1. .git/refs/COMMIT_EDITMSG

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 21, 2023
    Configuration menu
    Copy the full SHA
    9d42922 View commit details
    Browse the repository at this point in the history
  2. fix: remove testing shoutOperator

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 21, 2023
    Configuration menu
    Copy the full SHA
    cd5ecce View commit details
    Browse the repository at this point in the history
  3. fix: adding preprocessor directive to catch macos

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 21, 2023
    Configuration menu
    Copy the full SHA
    cca7da7 View commit details
    Browse the repository at this point in the history

Commits on Aug 22, 2023

  1. docs: adding CONTRIBUTING

    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 22, 2023
    Configuration menu
    Copy the full SHA
    ae8c6dd View commit details
    Browse the repository at this point in the history
  2. chore: adding entropies

    [Documentation]
    
    adding entropies, entrpoies is a measure of the amount of randomness or
    uncertainty ins tate of a quantum system.
    - creating quantum system
      the code creates a complex matrix `rho` representing a quantum state
      using predefined state `st.pb00`, the state is likely defined in the
      include `clarah.h` header
    - partial trace calculation
      the `ptrace()` function is used to compute the partial trace of the
      quantums state `rho` over subsystem B. the result stored in the matrix
      `rhoA`
    - displaying states
      the `disp()` function is used to display the original quantum state
      matrix `rho` and the result of the partial trace `rhoA`
    - entropy calculation
      the `tsallis()` function is used to calculate the tsallis-1 and
      tsallis-2 entropies for the quantum matrix `rho`. the calculated
      entropies displayed
    - quantum mutual information calculation
      teh `qmutualinformation()` function to calculation the quantum mutual
      information between subsystem A and B the quantum state `rho`. the
      calculated mutual information is displayed
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Aug 22, 2023
    Configuration menu
    Copy the full SHA
    18f43af View commit details
    Browse the repository at this point in the history

Commits on Sep 4, 2023

  1. chore: adding quantum circuit simulation

    [Documentation]
    
    demonstrate the simulation of quantum circuit, including gate operations
    and measurement, the process code by:
    - create quantum state `psi` and initialized to |00⟩ state
    - controlled (CNOT) gate `U` is created using the tensor product (`kron`) of the hadamard gate (`gt.H`) and the identity gate (`gt.Id2`)
    - the gate `U` applied to the quantums state `psi` resulting in a new
      state stored in the variable `result` state
    - X gate (`gt.X`) is applied to the `result` state at qubit 1, updating
      the state
    - print the `producing` bell state
    - the state measurement is performed on the `result` state using
      hadamard gate (`gt.H`) on qubit 0. the measurement result,
      probabilites, and resulting states are store in the `measured tuple`
    
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Sep 4, 2023
    Configuration menu
    Copy the full SHA
    f222f51 View commit details
    Browse the repository at this point in the history

Commits on Dec 27, 2023

  1. fix: remove unused header

    chore: commented some code
    Signed-off-by: slowy07 <[email protected]>
    slowy07 committed Dec 27, 2023
    Configuration menu
    Copy the full SHA
    1b00299 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f17f53d View commit details
    Browse the repository at this point in the history