473,805 Members | 2,076 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

arithmetic of random bit using gmp library?

3 New Member
i want to representation the large random bit to operate the arithmetic, like this

example
input n=10, then
10 random bit has create
A[]=[1011011100]
B[]=[0010010011]

i want to divide the array to any part like
A[]=[[10110],[11100]]
B[]=[[00100],[10011]]
_______________ ______xor (per block)
B[]=[[10010],[01111]]

how can i implementing it, using the gmp library

nb: n up to 1000 or more...

regard,
Jun 29 '10 #1
0 994

Sign in to post your reply or Sign up for a free account.

Similar topics

32
5895
by: Protoman | last post by:
I have a function that calculates the mean of the some numbers; I need it to accept any number of parameters (one needs to be the number of the other parameters) Can you help me out here? Here's the function: const long double& mean(long long x) { vector<int> v(x); for(int i= 1; i <=x; ++i) { v.push_back(i);
10
1621
by: David Soukal | last post by:
Hello, I have an interesting problem that I'm tackling with. I'm sure there must be some obvious solution... I have this big project. It's composed of several *.lib modules. Now, one of the modules uses IJG JPEG library. But, another module needs to use *modified* verzion of the library: the application displays images - for that it uses "normal" jpeg-6b library. However, some functionality is required that modifies the jpeg files as...
1
1017
by: vertigo | last post by:
Hello I write program in C#. I wanted to load mp3 files to read it's size, title and others. So i downloaded id3lib from: id3lib.sourceforge.net, compiled it using Visual Studio NET (with project conversion). And i received id3libD.lib file. I added that file to my project - but what next ? In examples of usage of that library i need to include: #include <id3/tag.h>
1
1279
by: A.Dagostino | last post by:
hi everyone i have developed a library in vb6 to import an excel file ftom client to a sql 2000 table on the server.This object must run at server. How can i create this object on a web asp page? Does it run if the oject use Excel library but on the server Excel is not installed? thanks
4
2038
by: =?Utf-8?B?Sm9l?= | last post by:
I have a .NET class library called NorthwindLib and a class called Customer. I have a web server that exposes a web method GetCustomer() and returns a NorthwindLib.Customer object. I want to consume this web service in another .NET application that references NorthwindLib. When the web reference is created I want the GetCustomer method to return an instance of NorthwindLib.Customer NOT a generated ServiceProxy.Customer. What is the...
0
1122
by: tigger | last post by:
Hi there, I have a problem displaying the correct random values extracted from the database. I'm using arrayRandom that stores left250 values and make it appear 90% of the time. arrayReallyRandom stores left250 values and appears 60% of the time. I have a combo box and a list of names. For eg. when i select Mark (the first name on the combo box), it will retrieve AC250L, store it as left250 and store it in arrayRandom and...
4
1347
by: almon | last post by:
I am beginner in programming.I want to make a program which reads pdf documents.For this (after googling) I found that a library pdflib is uded to do so.but i dont know how to use any library.
4
4594
by: Reshmi | last post by:
Hi, I have this C code which does complex number arithmetic. When I try to write a similar file for C++, it says that "creal’ was not declared in this scope". Can anyone give a better idea to write it using "complex.h", other than using own data structures? #include <stdio.h> #include <complex.h>
3
3339
by: tokcy | last post by:
hi everyone, i have a large database and i want to update one colomn(type is TIME) using RAND() function but i am not able to do so. please help me out. how can i use RAND() function.
0
9718
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10614
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10363
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10369
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9186
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7649
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6876
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4327
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
3008
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.