Memristors are novel electronic devices, a device that can be used and give a great advantage in many applications such as memory, logic, neuromorphic systems and so on. A computer model of the memristor would be a useful tool to analysis circuit behavior to help in develops application of this memristor as passive circuit element via simulation. In this paper, we incorporate a memristor SPICE for designing memristor circuit which is more focusing on non-linear model and analog circuits. SPICE model would be appropriate way to describe real device operation. We incorporating the memristor with various window functions that have been proposed in non linear ion drift memristor devices. In investigating and characterizing the physical electronic and behavioral properties of memristor devices, the circuit analysis of the proposed memristor models are then been studied. The simulation output should have a current-voltage hysteresis curve, which looks like bow tie. The loops map the switching behavior of the device. Then, we come out with a simple analog circuit which in this case we construct a simple integrator op-amp and differentiator op-amp circuit and make comparison between memristor implemented circuit and normal circuit. The research verifies the proposed memristor model, the possibilities of implementing memristor model and the advantage implementing the memristor in analog circuit.

## Keywords – memristor, SPICE model, non linear, window functions, analog circuit.

## Introduction

Memristor is the contraction of memory resistor which is a passive device that provides a functional relation between charge and flux. It is a two-terminal circuit element in which the flux between the two terminals is a function of the amount of electric charge that has passed through the device [1]. A memristor is said to be charge-controlled if the relation between flux and charge is expressed as a function of electric charge and it is said to be flux-controlled if the relation between flux and charge is expressed as a function of the flux linkage [2].

In 1971, Leon Chua proposed that there should be a fourth fundamental passive circuit element to create a mathematical relationship between electric charge and magnetic flux which he called the memristor which is short for memory resistor [2].

The current is defined as the time derivative of the charge. The voltage is defined as the time derivative of the flux according the faraday law. A resistor is defined by the relationship between voltage and current dv=Rdi, the capacitor is defined by the relationship between charge and voltage dq=Cdv, the inductor is defined by the relationship between flux and current dÏ†=Ldi. The fourth fundamental circuit element completes the symmetry of the relation between charge and magnetic flux dÏ†=Mdq. Table 1 show the relationship between the fundamental circuit element.

Basic two terminal devices

Equation

Relationship between fundamental circuit element

Resistor,R

dv=Rdi

v and i

Capacitor,C

dq=Cdv

v and q

Inductor,L

dÏ†=Ldi

i and Ï†

Memristor,M

dÏ†=Mdq

q and Ï†

Table 1: The four fundamental element (resistor, capacitor, inductor and memristor).

In 2008, Stanley Williams and his team at Hewlett Packard had succesfully fabricated the first memristor in physical device form which is a long wait from Leon Chua discovery in 1971 [3]. Memristance is a property of memristor. When the charge flows in one direction through a circuit, the resistances of the memristor increase. The resistance decreases when the charge flows in the opposite direction in the circuit. If the applied voltage is turned off, thus stopping the flow of charge and the memristor remembers the last resistance that it had [1].

In HP memristor model, to create a memristor, they used a very thin film of titanium dioxide (TiO2). The thin film is then sandwiched between the two platinum (Pt) contacts. One side of TiO2 is doped with oxygen vacancies denoted as TiO2-x which x is usually 0.05. The oxygen vacancies are positively charged ion and make it conductive, thus it behaves as a semiconductor. Another side of the TiO2 junction is undoped. The undoped region has insulating properties. The device established by HP is shown in Figure 1 [3].

Figure 1: Memristor model adapt from [3].

When a positive voltage is applied, the positively charged oxygen vacancies in the doped TiO2-x layer are repelled and moving them towards to the undoped TiO2 layer. When the boundary between the two materials moves, the percentage of the conducting TiO2-x layer is increase. Thus, the conductivity of the whole device increases.

When a negative voltage is applied, the positively charged oxygen vacancies are attracted and pulling them out of TiO2 layer. This increases the amount of insulating TiO2, thus increasing the resistivity of the whole device. When the voltage is turned off, the oxygen vacancies do not move. The boundary between the two titanium dioxide layers is frozen. This is how the memristor remembers the voltage last applied [1].

## Methodology

Our aim in this research is to provide a simulation program adequately simulates and can be used as a circuit element in design work. To model the electrical characteristics of the memristor, SPICE would be appropriate way to describe real device operation [4]. Moreover, using the model as a sub-circuit can highly guarantee a reasonable high flexibility and scalability features [5]. We use LTSPICE to create a memristor model and design new symbol of the memristor circuit for the simulation because LTSPICE is much easier to handle compared to others. On the other hand, LTSPICE is a freeware and it will give a great advantage to the students in doing research for this newly devices. We use SPICE model that been adapt from [6] and we made some adjustment so we can use it for several window functions that has been proposed for non linear ion drift model.

The SPICE model is created based on the mathematical model of the HP Labs memristor. After the memristor has been modeled, we first studied the difference between proposed memristor and then we will start design and implement the memristor with an analog circuit. We also investigate and made a comparison between the memristor circuit with analog circuit to see the difference and study the behavior of the circuits.

## Model Of The Memristor from HP Labs

In the model of a memristor presented here, there is a thin semiconductor film that has two regions, one with a high concentration of dopant that behaves like a low resistance called RON and the other with a low dopant concentration with higher resistance called ROFF [3]. The film is sandwiched between two metal contacts as in figure 1.

The total resistance of the memristor, RMEM, is a sum of the resistances of the doped and undoped regions, w is the width of the doped region and D is the total length of the TiO2 layer. ROFF and RON will be the limit values of the memristor resistance for w=0 and w=D. The ratio of the two resistances is usually given as 102 – 103.

(1)

(2)

From the ohm’s law relation between the memristor voltages and current, we get

(3)

Then, we insert (1) into (3). The voltage v(t) across the device will move the boundary between the two regions causing the charged dopants to drift. So, there is a drift ion mobility µv in the device. The change of the boundary is denoted as in (5).

(4)

(5)

To get x(t), we then integrates the right side of equation (5) which then yields the following formula

(6)

By inserting equation (6) into equation (4) and since usually RON<<roff, we=”” then=”” obtained=”” the=”” memristance=”” of=”” this=”” system<=”” p=””></roff,>

(7)

Where µv is the average drift velocity and has the units cm2/sV, D is the thickness of titanium-dioxide film ROFF and RON are on-state and off-state resistances and q(t) is the total charge passing through the memristor device.

## Non Linear Ion Drift Model

Even a small voltage across the nanodevices will produce a large electric field [7]. This causing the ion boundary position will move in a decidedly non-linear. Nonlinear dopant drift adds nonlinear window function f(x) to the state equation. The window function decreases as the state variables drift speed approaches the boundaries until it reaches zero when reaching either boundaries [8]. The speeds of the movement of the boundary between the doped and undoped regions are depending on several factors.

(8)

Where µv is the dopant mobility. The speed of the boundary between the doped and undoped regions decreases gradually to zero at the film edges [1]. We simulate the nonlinear ion drift memristor model with these window function to see the difference and the issue that been faced by them.

## Window Function

Window function is a function of the state variable. Window function forces the bounds of the device and to add nonlinear behavior close to these bounds. In other words, it creates the boundary for the memristor. Any effective window function should therefore fulfill the following conditions [8]:

Take into account the boundary conditions at the top and bottom electrodes of the device;

Be capable of imposing nonlinear drift over the entire active core of the device;

Provide linkage between the linear and nonlinear dopant drift models;

Be scalable, meaning a range of fmax(x) can be obtained such that 0 â‰¤ fmax(x) â‰¤ 1;

Utilize a built-in control parameter for adjusting the model.

There are several window functions that have been proposed for non-linear model till date which are by Strukov, Joglekar and, Biolek, and Prodromakis. Strukov proposed the following window function [3].

(9)

However, as we can see in the figure 2, this window function lacks of flexibility.

Figure 2: Plot of Strukov window function.

Another window function was proposed by Joglekar [4], which has a control parameter p which is a positive integer. The purpose of having a control parameter as an exponent is to incorporate scalability and flexibility in window function f(x) that describes the dopant kinetics.

(10)

Figure 3 displays a graphical representation of the window function described by Joglekar for various p parameter (p=1, 5 and 10). This control parameter controls the linearity of the model, where it becomes more linear as p increases. This window function ensures zero drift at the boundaries. From the plotted graph, we noticed that the maximum f(x) value is occurs at the center of the device and zero is obtained at two boundaries. However, a significant liability of this model lies in the fact that if w hits any of the boundaries (w = 0 or w = D) the state of the device cannot be further adjusted. This will be from now on termed as the terminal state problem.

Figure 3: Plot of Joglekar window function for p=1, 5 and 10.

Then, Biolek proposed another window function that allows the memristor to come back from the terminal state problem.

(11)

The reversed bias is now should move back the state variable after it reaches either boundary. This feature is described by a current dependent step function, stp(i), which is a part of a new window function f(x) that behaves differently in each voltage bias direction.

(12)

Figure 4: Plot of Biolek window function for p=1, 5 and 10.

Figure 4 displays a graphical representation of the window function described by Biolek for various p parameter (p=1, 5 and 10). When x starts at 0, we noticed that the function equal to 1. As x increase approaching D, the function approaches 0. Once the current reverse the direction, the function immediately switch to 1. As x decrease back to 0, the function also decreases to 0. Biolek window function eliminates convergence issues at the devices boundaries.

The last window function for non-linear model is proposed by Prodromakis [8].

(13)

Figure 5 displays a graphical representation of the window function described by Prodromakis for various p parameter (p=1, 5 and 10). As we can see, it allows the window function to scale upwards which implies that fmax(x) can take any value within 0 < fmax(x) < 1. Also noticed that when p=1, it become identical to Strukov model. In addition, p can take any positive real number allowing a greater extent of flexibility. The boundary issues are also resolved with the window function returning a zero-value at the active bi-layer edges.

Figure 5: Plot of Prodromakis window function for p=1, 5 and 10.

## SPICE Model of Memristor

Figure 6: Stucture of the SPICE model from [6].

In the above circuit in figure 6, VMEM is the input voltage and Imem is modeled to be the current through the memristor. The flux is calculated by integrating the voltage VMEM and the charge is calculated by integrating the current IMEM.

Figure 7: Resistive port of the memristor model.

As we can see in figure 7, the circuit is actually referred to total resistor RMEM. RMEM (x) = ROFF -xâˆ†R where âˆ†R= ROFF-RON. ROFF is the resistor in series voltage source whose terminal voltage is controlled by the formula -xâˆ†R.

Figure 8: Differential equation modeling of the memristor.

Figure 8 shows the differential equation modeling of the memrsitor. It consist a part of the voltage controlled source xâˆ†R and the differential equation from equation (6) which serves as an integrator of the quantities on the right side of the state equation (6) which is to get the value of normalize x. EMEM is the voltage source whose terminal voltage is controlled according to the formula -xâˆ†R. GX is a current source whose current is controlled according to the equation IMEMf(V(x)) where V(x) is the voltage across the capacitor Cx and it models the normalized width x of the doped layer. F(V(x)) is the window function, k is µvRON/D2 and x0 is the initial voltage of the capacitor.[6].

The relation between memristor current and voltage is modeled as on the basis of RMEM (x) = ROFF -xâˆ†R where âˆ†R= ROFF-RON. The voltage V(x) across the capacitor CX models the normalized width x of the doped layer. The initial state of x is modeled by the initial voltage of the capacitor. The flux is calculated by the time-integral of voltage, and the charge is calculated by the time-integral of current.

## Result and Discussion

All models were simulated in LTSpice using SPICE model that was given in [6], we add new nonlinear window functions that was proposed by prodromakis and strukov to the model and compare all suggested window functions.

## memristor

Figure 9: Memristor circuit.

Figure 9 shows configuration of single memristor for measuring the behavior of memristor model in LTSPICE with a sine wave input voltage of 1.2V with 1Hz frequency. The values for the memristor parameters µv, D, RON, ROFF and RINITIAL are 10-10cm2s-1V-1, 10 nm, 100ohm, 16kohm and 11Kohm. All model are using same window function parameter p=10.

C:UsersFadzDesktopresultstrukovstrukov1.png

Figure 10: Strukov memristor model – voltage, IMEM, RMEM and normalized x.

Figure 10 shows the simulation result of memristor SPICE model for Strukov window function of voltage, IMEM, RMEM and normalized x. As we can see, the current of the memristor, IMEM is varying up to approximately 100µA for maximum of 1.2V voltage applied. The RMEM for this model show that the values are in range of 11kOhm till 12kohm which means the effect of the voltage applied to the memristor only give slightly changes on the value of the memristor. Noticed that when positive voltage is applied, the conductivity of the device increases thus the memristance is decrease. When negative voltage is applied, the resistivity of the device increase thus the memristance is also increase. This verifies the memristive system on the device. In normalize x graph, we also noticed that the normalized x is at higher state in the beginning. Figure 11 shows the I-V characteristic of the devices and the relationship between charge and flux. The charge and flux curve curves confirms the well known fact that there is a one-to-one correspondence between them in spite of the 1-4 hysteresis effect. Strukov memristor shows lack of flexibility of controlling the device.

C:UsersFadzDesktopresultstrukovstrukov4.png

Figure 11: Strukov memristor model – I-V loop hysteresis and relationship of charge and flux.

C:UsersFadzDesktopresultjoglekarjoglekar1.png

Figure 12: Joglekar memristor model – voltage, IMEM, RMEM and normalized x.

Joglekar window function seems to be promising as the existence of controlling parameter. Figure 12 shows the simulation result of memristor SPICE model for Joglekar window function of voltage, IMEM, RMEM and normalized x. Same as strukov memristor, when positive voltage is applied, the conductivity of the device increases thus the memristance is decrease. When negative voltage is applied, the resistivity of the device increase thus the memristance is also increase. The current of the memristor, IMEM is varying up to approximately 300µA for maximum of 1.2V voltage applied. Joglekar window function give higher current compared to others. It shows that the current in the memristor are much easier to move. The RMEM are within range of nearly 0ohm to 11kohm which give full range of value for the memristor. Figure 13 show the I-V hysteresis loop of the devices and the relationship between charge and flux. The switching behavior is much more sensitive on the voltage level than Strukov window function. But, in term of stability, Joglekar window function cannot perform for an arbitrary length of time. This failure is caused by the convergence issue where when the memristor reach w=0 or w=D, the state of the device cannot be further adjusted.

C:UsersFadzDesktopresultjoglekarjoglekar4.png

Figure 13: Joglekar memristor model – I-V loop hysteresis and relationship of charge and flux.

Biolek window functions are supposed to solve terminal state problem as in literature [4]. It should solve the boundry problem of the terminal state. Figure 14 and 15 shows the simulation result of memristor SPICE model for Biolek window function. The current of the memristor, IMEM is varying up to approximately 220µA for maximum of 1.2V voltage applied. The RMEM are within range of nearly 1kohm to 11kohm. Figure 15 show the I-V hysteresis loop of the devices and the relationship between charge and flux. From the figures, we observe that the biolek memristor preserve the highly non-linear device characteristic behavior. In addition, Biolek’s model allows for general asymmetric I-V device behavior modeling.

C:UsersFadzDesktopresultbiolekbiolek1.png

Figure 14: Biolek memristor model – voltage, IMEM, RMEM and normalized x.

C:UsersFadzDesktopresultbiolekbiolek4.png

Figure 15: Biolek memristor model – I-V loop hysteresis and relationship of charge and flux.

Prodromakis window functions are also said to solve the boundry issue. Figure 16 shows the simulation result of memristor SPICE model for Joglekar window function of voltage, IMEM, RMEM and normalized x. The current of the memristor, IMEM is varying up to approximately nearly 180µA for maximum of 1.2V voltage applied. The RMEM are within range of nearly 3kohm to 11kohm.

C:UsersFadzDesktopresultprodromakisprodromakis1.png

Figure 16: Prodromakis memristor model – voltage, IMEM, RMEM and normalized x.

Figure 17 show the I-V hysteresis loop of the devices and the relationship between charge and flux. The hysteresis loop is shown to be asymmetrical while the OFF state of the device is highly non-linear compared with other.

C:UsersFadzDesktopresultprodromakisprodromakis4.png

Figure 17: Prodromakis memristor model – I-V loop hysteresis and relationship of charge and flux.

In comparing of I-V characteristic hysteresis loop, as we can see in figure 18, it shows all hysteresis loops for all proposed window functions. By using same parameter we can see the difference in each model. Joglekar window function seems to have a strong memristance compared to others.All models seem to be a good approximation of the measurement of the real memristor produces by HP Labs. But, Prodromakis memristor model satisfies all the prerequisites and improves on the shortcomings of existing models.

C:UsersFadzDesktopresultall iv loop hysteresisiv hysteresis loop all.png

Figure 18: I-V Hysteresis Loop for all models.

C:UsersFadzDesktopresultdiff parameterprodromakis p=1, p=5, p=10.png

Figure 19: Prodromakis I-V Hysteresis Loop when p=1, p=5 and p=10.

Then, we try change the parameter of p of the model. In this case, we use prodromakis memristor model and change the value of integer p=1, p=5 and p=10 to see the difference. As we can see in figure 19, as the value of p is increase, the hysteresis is shrinking. Similar with changing the parameter p, figure 20 also confirm that the hysteresis shrinks at higher frequencies.

C:UsersFadzDesktopresultdiff frequency1hz-5hz.png

Figure 20: Prodromakis I-V Hysteresis Loop when frequency f=1Hz, f=2Hz and f=5Hz.

In term of power dissipation, as we simulates our results. We can get the value of maximum IMEM for each model. We can calculate the power by using P=IV equation. Table 2 show the maximum power dissipation for each memristor.

Memristor

model

Max IMEM, µA

Power, W

Strukov

100µA

120µW

Joglekar

300 µA

360µW

Biolek

220µA

264µW

Prodromakis

180 µA

216µW

Table 2: IMEM and Power dissipation for all at the memristor.

As in table 2, we can see that the Strukov model give lowest power which is 120µW while Joglekar model give much higher power dissipation which is about 360µW compared to the others. We also noticed that as the memristor model is improves, the power become lesser. Prodromakis give quite good power dissipation which is 216µW as the best windows function and model as till now.

In implementing memristor with analog circtuit, we pick a two simple analog circuit to be tested. Figure 21 shows the SPICE topology of the memristor based integrator op amplifier with the input voltage Vp-p=2.4V from -1.2V to 1.2V and C1=25µF. Using the memristor model that we create earlier with various types of window functions, we see the difference on the simulated result on each model. The values for the memristor parameters are same for all model with uv, D, RON, ROFF and RINITIAL are 10-10cm2s-1V-1, 10nm, 100ohm, 16kohm and 11Kohm.

memristor integrator op amp

Figure 21: Memristor Implemented Integrator Circuit

C:UsersFadzDesktopresultintegrator+ve integrator .png

Figure 22: Positive Integrator simulation

C:UsersFadzDesktopresultintegrator-ve integrator .png

Figure 23: Negative Integrator simulation

Figure 22 and 23 shows the simulation result for the implemented memristor integrator op amplifier for positive input and negative input respectively. In this case, we implement prodromakis memristor to the integrator circuit. As we know, the integrator acts like a storage element that produces a voltage output which is proportional to the integral of its input voltage with respect to time. The magnitude of the output signal is determined by the length of time a voltage is present at its input as the current through the feedback loop charges or discharges the capacitor as the required negative feedback occurs through the capacitor. For positive starting input, we vary the voltage from 1.2V down to -1.2V and going back to 1.2V over time. When positive voltage are applied in the beginning, the output voltage tend to discharge and drop from 0V to negative voltage and charging back to 0V when the input voltage are drop to negative voltage. The output for negative voltage applied from starting point give a vice versa result. The charging and discharge are depends the voltage applied over time and the value of the capacitor. We can say the memristor models give quite good result for an integrator.

Figure 24: Memristor Implemented Differentiator Circuit.

C:UsersFadzDesktopresultdifferentiatordifferentiator.png

Figure 25: Saw tooth input of Memristor implemented differentiator op-amp simulation.

Figure 25 shows the simulation result for the implemented memristor differentiator op amplifier. We are using prodromakis memristor model for the memristor implementation. As we know, for differentiator op-amp, the magnitude of its output is determined by the rate at which the voltage is applied to its input changes. The faster the input voltage changes, the greater the output voltage becomes. If a saw tooth input signal is applied to the input of the differentiator op-amp a square wave signal will be produced. As we can see in figure 25, the simulation shows a quite good result for differentiator. We also noticed some spikes at the output voltage. Each spikes occurs only occurs the brief moment the saw tooth is changing from one level to the next. The voltage spikes represent a temporary output voltage.

## Conclusion

As a conclusion to this research is that it could bring a new light of familiarization in the integration of memristive components in any kinds of electronic devices that are at nanoscale. It is useful to have a computer model of the memristor as a tool for the analysis of the behavior of the circuits in developing application of this memristor as passive circuit element via simulation. SPICE model will definitely help us to conduct interesting simulation experiments and can be of great importance for such a research in future while the memristor are still hard to fabricate to study the behavior of the circuit. Different models with strong behavior and reason give a lot of benefits in development purpose to create the possibilities of the implementation in an integrated circuit. The possibilities for implementation of the memristor with analog circuit are wide open.

## Appendix

.SUBCKT memristor plus minus PARAMS:

+ Ron=100 Roff=16K Rinit=11K D=10N uv=10F p=10

## ***********************************************

* DIFFERENTIAL EQUATION MODELING *

## ***********************************************

Gx 0 x value={ I(Emem)*uv*Ron/D**2*f(V(x),p)}

Cx x 0 1 IC={(Roff-Rinit)/(Roff-Ron)}

Raux x 0 1T

* RESISTIVE PORT OF THE MEMRISTOR *

## ***********************************************

Emem plus aux value={-I(Emem)*V(x)*(Roff-Ron)}

Roff aux minus {Roff}

## ***********************************************

*Flux computation*

## ***********************************************

Eflux flux 0 value={SDT(V(plus,minus))}

## ***********************************************

*Charge computation*

## ***********************************************

Echarge charge 0 value={SDT(I(Emem))}

## ***********************************************

* WINDOW FUNCTIONS

* FOR NONLINEAR DRIFT MODELING *

## ***********************************************

*proposed by joglekar

;.func f(x,p)={1-(2*x-1)**(2*p)}

*proposed by biolek

;.func f(x,i)={1-(x-stp(-i))**(2*p)}

*proposed by prodromakis

;.func f(x,p)={1-(((x-0.5)**2)+0.75)**p}

*proposed by strukov

.func f(x,p)={x-x*2}

.ENDS memristor

## Acknowledgment

This paper participates in the IEEE Student Conference Research & Development SCORED 2012. The author would like to thank Dr. Wan Fazlida Hanim bte Abdullah for being supervisor in this final year project. The author also would like to thank Universiti Teknologi MARA for funding the research work through the Excellence Fund Grant 600-RMI/ST/DANA 5/3/RIF(360/2012).